Follow these security guidelines for every change to the Atlan Java SDK.
- Security Team: #bu-security-and-it on Slack
atlan-java is Atlan's Java SDK (multi-module Gradle, Kotlin DSL). Modules:
sdk/— Core Java SDK client (AtlanClient,HttpClient); API key auth viaAuthorization: Bearerheader;HttpURLConnectionClientfor HTTP transport; WireMock for unit tests.package-toolkit/runtime/— Utilities for custom packages including S3 (S3Utils), GCS, ADLS connectors, CSV/Excel processing.package-toolkit/config/— Pkl language support for package configuration.integration-tests/— E2E tests against live Atlan environment usingATLAN_BASE_URLandATLAN_API_KEYenv vars.
Review every change for:
- API key logging —
AtlanClientholds the API key and sets it asAuthorization: Bearer <key>on every HTTP request; the key must never appear in log output, SLF4J messages, or exceptiongetMessage()results; when loggingHttpClienterrors, strip theAuthorizationheader value from the logged request details;ATLAN_API_KEYread from environment for integration tests must similarly not be logged. - TLS certificate verification —
HttpURLConnectionClientmust not disable hostname verification (HttpsURLConnection.setDefaultHostnameVerifier(...)with an always-true lambda) or bypass certificate validation via a trust-allSSLContext; if custom CA bundles are needed for corporate proxies, accept the CA certificate path, not a bypass flag. - Package-toolkit S3/GCS/ADLS credential logging —
S3Utilsand equivalent GCS/ADLS utilities accept access keys, secret keys, and service account credentials; these must not be logged; use@ToString(exclude=...)Lombok annotations or equivalent to exclude credential fields fromtoString(). - Pkl config secrets —
package-toolkit/config/uses Pkl to define package configuration schemas; if any Pkl config field represents a secret (password, API key, token), mark it as sensitive and ensure it is excluded from serialization outputs used for logging or UI display. - Dependency version pinning — all direct dependencies in
sdk/build.gradle.ktsandpackage-toolkit/*/build.gradle.ktsmust use explicit version strings; avoid dynamic version ranges (+,latest.release) which allow supply-chain substitution.
- [MUST] API key (
ATLAN_API_KEY,apiKey) must never appear in log output or exception messages. - [MUST] TLS certificate verification and hostname verification must not be disabled.
- [MUST] S3/GCS/ADLS credential values must not be logged — use
@ToString(exclude=...). - [MUST] All direct dependencies must use explicit version pins — no dynamic version ranges.
- CONFIDENTIAL:
ATLAN_API_KEY, S3 secret access key, GCS service account JSON, ADLS client secret - INTERNAL:
ATLAN_BASE_URL, workspace IDs, asset GUIDs, object storage bucket names - PUBLIC: SDK version, asset type names, API endpoint names
-
ATLAN_API_KEY/apiKeyabsent from all log output and exception messages - No
trustAllCerts,setDefaultHostnameVerifier(always-true), or bypassSSLContext - S3/GCS/ADLS credential fields excluded from
toString()via Lombok or equivalent - Pkl config secret fields marked sensitive and excluded from log serialization
- All
build.gradle.ktsdependencies use explicit version pins (no+orlatest.release)