Infisical is the open-source platform for securing secrets, certificates, access, and AI Agents.
TypeScript acmeagentsai-agentscertificate-managementdevsecopsenvironment-variableskubernetesopen-sourcepampkipostgresprivate-caprivileged-access-managementsecret-managementsecret-managersecretssecrets-managementsecuritysecurity-toolsvault
feat: quick fix for quic
=7b5926d86566
diff --git a/.github/workflows/check-api-for-breaking-changes.yml b/.github/workflows/check-api-for-breaking-changes.ymlindex c4cb6e4519..f0dcfc8cb6 100644--- a/.github/workflows/check-api-for-breaking-changes.yml+++ b/.github/workflows/check-api-for-breaking-changes.yml@@ -32,10 +32,10 @@ jobs:run: touch .env && docker compose -f docker-compose.dev.yml up -d db redis- name: Start the serverrun: |- echo "SECRET_SCANNING_GIT_APP_ID=793712" >> .env- echo "SECRET_SCANNING_PRIVATE_KEY=some-random" >> .env- echo "SECRET_SCANNING_WEBHOOK_SECRET=some-random" >> .env- docker run --name infisical-api -d -p 4000:4000 -e DB_CONNECTION_URI=$DB_CONNECTION_URI -e REDIS_URL=$REDIS_URL -e JWT_AUTH_SECRET=$JWT_AUTH_SECRET -e ENCRYPTION_KEY=$ENCRYPTION_KEY --env-file .env --entrypoint '/bin/sh' infisical-api -c "npm run migration:latest && ls && node dist/main.mjs"+ echo "SECRET_SCANNING_GIT_APP_ID=793712" >> .env+ echo "SECRET_SCANNING_PRIVATE_KEY=some-random" >> .env+ echo "SECRET_SCANNING_WEBHOOK_SECRET=some-random" >> .env+ docker run --name infisical-api -d -p 4000:4000 -e DB_CONNECTION_URI=$DB_CONNECTION_URI -e REDIS_URL=$REDIS_URL -e JWT_AUTH_SECRET=$JWT_AUTH_SECRET -e ENCRYPTION_KEY=$ENCRYPTION_KEY --env-file .env --entrypoint '/bin/sh' infisical-apienv:REDIS_URL: redis://172.17.0.1:6379DB_CONNECTION_URI: postgres://infisical:[email protected]:5432/infisical?sslmode=disable@@ -43,7 +43,7 @@ jobs:ENCRYPTION_KEY: 4bnfe4e407b8921c104518903515b218- uses: actions/setup-go@v5with:- go-version: '1.21.5'+ go-version: "1.21.5"- name: Wait for container to be stable and check logsrun: |SECONDS=0@@ -61,7 +61,7 @@ jobs:sleep 2SECONDS=$((SECONDS+2))done-+if [ $HEALTHY -ne 1 ]; thenecho "Container did not become healthy in time"exit 1diff --git a/Dockerfile.standalone-infisical b/Dockerfile.standalone-infisicalindex 7da4a6caf0..6d582ce76d 100644--- a/Dockerfile.standalone-infisical+++ b/Dockerfile.standalone-infisical@@ -122,6 +122,7 @@ RUN apt-get update && apt-get install -y \unixodbc-dev \libc-dev \freetds-dev \+ wget \openssh-client \&& rm -rf /var/lib/apt/lists/*diff --git a/backend/Dockerfile b/backend/Dockerfileindex 5db874e752..0edfdfb84d 100644--- a/backend/Dockerfile+++ b/backend/Dockerfile@@ -1,23 +1,22 @@# Build stage-FROM node:20-alpine AS build+FROM node:20-slim AS buildWORKDIR /app# Required for pkcs11js-RUN apk --update add \- python3 \- make \- g++ \- openssh--# install dependencies for TDS driver (required for SAP ASE dynamic secrets)-RUN apk add --no-cache \+RUN apt-get update && apt-get install -y \+ python3 \+ make \+ g++ \+ openssh-client++# Install dependencies for TDS driver (required for SAP ASE dynamic secrets)+RUN apt-get install -y \unixodbc \- freetds \+ freetds-bin \+ freetds-dev \unixodbc-dev \- libc-dev \- freetds-dev-+ libc-devCOPY package*.json ./RUN npm ci --only-production@@ -26,36 +25,36 @@ COPY . .RUN npm run build# Production stage-FROM node:20-alpine+FROM node:20-slimWORKDIR /appENV npm_config_cache /home/node/.npmCOPY package*.json ./-RUN apk --update add \- python3 \- make \- g+++RUN apt-get update && apt-get install -y \+ python3 \+ make \+ g++-# install dependencies for TDS driver (required for SAP ASE dynamic secrets)-RUN apk add --no-cache \+# Install dependencies for TDS driver (required for SAP ASE dynamic secrets)+RUN apt-get install -y \unixodbc \- freetds \+ freetds-bin \+ freetds-dev \unixodbc-dev \- libc-dev \- freetds-dev-+ libc-dev-RUN printf "[FreeTDS]\nDescription = FreeTDS Driver\nDriver = /usr/lib/libtdsodbc.so\nSetup = /usr/lib/libtdsodbc.so\nFileUsage = 1\n" > /etc/odbcinst.ini+RUN printf "[FreeTDS]\nDescription = FreeTDS Driver\nDriver = /usr/lib/x86_64-linux-gnu/odbc/libtdsodbc.so\nSetup = /usr/lib/x86_64-linux-gnu/odbc/libtdsodbc.so\nFileUsage = 1\n" > /etc/odbcinst.iniRUN npm ci --only-production && npm cache clean --forceCOPY --from=build /app .-RUN apk add --no-cache bash curl && curl -1sLf \- 'https://dl.cloudsmith.io/public/infisical/infisical-cli/setup.alpine.sh' | bash \- && apk add infisical=0.8.1 && apk add --no-cache git+# Install Infisical CLI+RUN apt-get install -y curl bash && \+ curl -1sLf 'https://dl.cloudsmith.io/public/infisical/infisical-cli/setup.deb.sh' | bash && \+ apt-get update && apt-get install -y infisical=0.8.1 gitHEALTHCHECK --interval=10s --timeout=3s --start-period=10s \CMD node healthcheck.jsdiff --git a/cli/packages/gateway/relay.go b/cli/packages/gateway/relay.goindex e9ad9b3b68..52636d2d3f 100644--- a/cli/packages/gateway/relay.go+++ b/cli/packages/gateway/relay.go@@ -12,10 +12,10 @@ import ("strconv""syscall"+ udplistener "github.com/Infisical/infisical-merge/packages/gateway/udp_listener""github.com/pion/logging""github.com/pion/turn/v4""github.com/rs/zerolog/log"- "golang.org/x/sys/unix""gopkg.in/yaml.v2")@@ -115,18 +115,7 @@ func (g *GatewayRelay) Run() error {// this allows us to add logging, storage or modify inbound/outbound traffic// UDP listeners share the same local address:port with setting SO_REUSEPORT and the kernel// will load-balance received packets per the IP 5-tuple- listenerConfig := &net.ListenConfig{- Control: func(network, address string, conn syscall.RawConn) error { // nolint: revive- var operr error- if err = conn.Control(func(fd uintptr) {- operr = syscall.SetsockoptInt(int(fd), syscall.SOL_SOCKET, unix.SO_REUSEPORT, 1)- }); err != nil {- return err- }-- return operr- },- }+ listenerConfig := udplistener.SetupListenerConfig()publicIP := g.Config.PublicIPrelayAddressGenerator := &turn.RelayAddressGeneratorPortRange{diff --git a/cli/packages/gateway/udp_listener/listener_unix.go b/cli/packages/gateway/udp_listener/listener_unix.gonew file mode 100644index 0000000000..8de2828b43--- /dev/null+++ b/cli/packages/gateway/udp_listener/listener_unix.go@@ -0,0 +1,26 @@+//go:build !windows+// +build !windows++package udplistener++import (+ "net"+ "syscall"++ "golang.org/x/sys/unix"+ // other imports+)++func SetupListenerConfig() *net.ListenConfig {+ return &net.ListenConfig{+ Control: func(network, address string, conn syscall.RawConn) error {+ var operr error+ if err := conn.Control(func(fd uintptr) {+ operr = syscall.SetsockoptInt(int(fd), syscall.SOL_SOCKET, unix.SO_REUSEPORT, 1)+ }); err != nil {+ return err+ }+ return operr+ },+ }+}diff --git a/cli/packages/gateway/udp_listener/listener_windows.go b/cli/packages/gateway/udp_listener/listener_windows.gonew file mode 100644index 0000000000..4904d12e00--- /dev/null+++ b/cli/packages/gateway/udp_listener/listener_windows.go@@ -0,0 +1,18 @@+//go:build windows+// +build windows++package udplistener++import (+ "fmt"+ "net"+ "syscall"+)++func SetupListenerConfig() *net.ListenConfig {+ return &net.ListenConfig{+ Control: func(network, address string, conn syscall.RawConn) error {+ return fmt.Errorf("Infisical relay not supported for windows.")+ },+ }+}