Skip to content

Agent Proxy intercepts your application’s outbound requests. Before each request reaches the target Server Workload: Server Workloads represent target services, APIs, databases, or applications that receive and respond to access requests from Client Workloads.Learn more, Agent Proxy injects the credential the request needs. The integration work therefore lives in your infrastructure and your Aembit configuration, and your application code changes only where a client library demands a credential value. This page walks you through the developer-side work: supply a placeholder credential where a library requires one, then send a request and verify the credential arrived. For the other ways to integrate, see the Developer Guide overview.

Complete both prerequisites before changing application code, because Agent Proxy only injects a credential that an Access Policy: Access Policies define, enforce, and audit access between Client and Server Workloads by cryptographically verifying workload identity and contextual factors rather than relying on static secrets.Learn more authorizes:

  • Deploy Agent Proxy in the environment where your application runs.
  • Create an Access Policy that authorizes your Client Workload: Client Workloads represent software applications, scripts, or automated processes that initiate access requests to Server Workloads, operating autonomously without direct user interaction.Learn more to reach the target Server Workload, with a Trust Provider: Trust Providers validate Client Workload identities through workload attestation, verifying identity claims from the workload's runtime environment rather than relying on pre-shared secrets.Learn more and a Credential Provider: Credential Providers obtain the specific access credentials—such as API keys, OAuth tokens, or temporary cloud credentials—that Client Workloads need to authenticate to Server Workloads.Learn more attached. You can create the Access Policy in the Tenant UI of your Aembit Tenant: Aembit Tenants serve as isolated, dedicated environments within Aembit that provide complete separation of administrative domains and security configurations.Learn more, through the Cloud API, or with the Terraform provider, and Manage your Aembit configuration compares the three paths.

Many client libraries refuse to initialize without a credential value, even though Aembit supplies the real credential at request time. Give such a library a placeholder credential, which is any non-empty string that passes the library’s validation, such as 'placeholder-client-secret'. Agent Proxy replaces the placeholder with the real credential in transit, so the placeholder never reaches the target service.

from some_oauth_library import OAuthClient
# Initialize with a placeholder - Aembit replaces it in transit
client = OAuthClient(
client_id='your-client-id',
client_secret='placeholder-client-secret',
token_url='https://oauth-provider.com/token'
)

Some libraries attach the credential per request instead of at initialization, such as an API key in a header. In that case you may have no code change at all, because Agent Proxy adds the header for you. Client library patterns for Agent Proxy shows where the placeholder goes for OAuth SDKs, API key headers, and database drivers, and links the official SDK documentation for common services.

  1. Run your application in the environment where you deployed Agent Proxy.

  2. Make a request to the target Server Workload.

  3. Confirm the request succeeded, then check the authorization event in your Aembit Tenant.

Test and debug your integration covers the verification end to end, including authorization events, credential delivery checks, and the common failure modes.

The Server Workload’s configured authentication method and scheme determine how Agent Proxy attaches the injected credential to your request. The credential can arrive as an Authorization header, a named header, a query parameter, a protocol-level password, or a certificate in the TLS handshake. Knowing the configured combination tells you what the target service receives, which is what you compare against when the target rejects a request. For choosing and configuring a combination in your Aembit Tenant, see Authentication methods and schemes.

Most methods inject credentials into the application protocol. mTLS Authentication presents the credential during the TLS handshake, beneath the application protocol.

The following table lists all supported combinations of authentication methods and schemes, along with their compatible application protocols and credential providers:

Auth MethodAuth SchemeApplication ProtocolsCredential ProviderDescriptionSpecification
HTTP AuthenticationBasicHTTPUsername & PasswordEncodes username:password in Base64 and sends it in the HTTP Authorization header.The ‘Basic’ HTTP Authentication Scheme
HTTP AuthenticationBearerHTTPAny single-valueSends a Bearer token in the HTTP Authorization header.Bearer Token Usage
HTTP AuthenticationHeaderHTTPAny single-valueInjects credentials into a user-defined HTTP header as part of HTTP authentication flow.n/a
HTTP AuthenticationAWS Signature v4HTTPAWS STS FederationSigns the HTTP request using AWS Signature v4.Create a signed AWS API request
API KeyHeaderHTTPAny single-valueInjects API key credentials into a user-defined HTTP header for API-based authentication.n/a
API KeyQuery parameterHTTPAny single-valueInjects credentials into a user-defined HTTP query parameter.n/a
Password AuthenticationPasswordMySQL, Postgres, Amazon Redshift, RedisUsername & PasswordInjects credentials according to protocol-specific requirements. Applies only to protocols with a single auth method.n/a
JWT Token AuthenticationSnowflake JWTSnowflakeJWTModifies the body of an HTTP request to /session/v1/login-request, injecting USERNAME and TOKEN.n/a
mTLS Authenticationx509 CertificateHTTPX.509-SVIDAuthenticates an Access Policy’s Client Workload and Server Workload using a SPIFFE: Secure Production Identity Framework For Everyone (SPIFFE) is an open standard for workload identity that provides cryptographically verifiable identities to services without relying on shared secrets.Learn more(opens in new tab)-compliant X.509-SVID: A SPIFFE Verifiable Identity Document in X.509 certificate format. X.509-SVIDs are certificates that embed a workload's SPIFFE ID as a URI Subject Alternative Name (SAN) and enable mutual TLS authentication between workloads. Aembit issues SVIDS with short lifetimes and automatic rotation.Learn more certificate that Agent Proxy presents during the mTLS handshake.SPIFFE X.509-SVID Standard