LaunchDarkly Hardening Guide
Feature flag security for SDK keys, environment access, and approval workflows
Overview
LaunchDarkly manages feature flags controlling application behavior across environments. REST API, SDK keys, and webhook integrations control feature rollouts. Compromised access enables feature manipulation, environment privilege escalation, or extraction of targeting rules revealing business logic.
Intended Audience
- Security engineers managing feature flag systems
- DevOps/Platform administrators
- GRC professionals assessing release management
- Third-party risk managers evaluating deployment integrations
Table of Contents
1. Authentication & Access Controls
1.1 Enforce SSO with MFA
Profile Level: L1 (Baseline) NIST 800-53: IA-2(1)
ClickOps Implementation
Step 1: Configure SAML SSO
- Navigate to: Account settings → Security → SAML
- Configure SAML IdP
- Enable: Require SSO
Step 2: Configure SCIM
- Enable SCIM provisioning
- Configure user/group sync
- Set deprovisioning behavior
1.2 Role-Based Access Control
Profile Level: L1 (Baseline) NIST 800-53: AC-3, AC-6
ClickOps Implementation
Step 1: Define Custom Roles
| Role | Permissions |
|---|---|
| Admin | Full access |
| Writer | Create/modify flags |
| Reader | View only |
| No access | Blocked |
Step 2: Configure Project/Environment Access
- Navigate to: Account settings → Roles
- Create environment-specific roles
- Apply least privilege
2. SDK & API Security
2.1 Secure SDK Keys
Profile Level: L1 (Baseline) NIST 800-53: IA-5
Description
Protect LaunchDarkly SDK keys.
Rationale
Attack Scenario: Exposed SDK key enables flag enumeration; mobile SDK key in client bundle allows targeting rule extraction.
Implementation
SDK Key Types:
| Key Type | Exposure Risk | Use Case |
|---|---|---|
| SDK Key | Server-side only | Backend services |
| Mobile Key | Client-side safe | Mobile apps |
| Client-side ID | Client-side safe | Browser apps |
Step 1: Rotate Keys
- Navigate to: Project settings → Environments
- Reset SDK keys periodically
- Update applications
2.2 API Token Security
Profile Level: L1 (Baseline) NIST 800-53: IA-5
ClickOps Implementation
Step 1: Audit Access Tokens
- Navigate to: Account settings → Authorization → Access tokens
- Review all tokens
- Remove unused tokens
Step 2: Create Scoped Tokens
- Create tokens with custom roles
- Limit to specific projects/environments
- Set expiration dates
3. Environment Security
3.1 Environment Segmentation
Profile Level: L1 (Baseline) NIST 800-53: CM-3
ClickOps Implementation
Step 1: Configure Environment Settings
- Navigate to: Project settings → Environments
- Configure:
- Require comments for changes
- Require review for production
- Enable change history
Step 2: Approval Workflows (Enterprise)
- Configure approval requirements
- Set minimum approvers
- Define bypass conditions
3.2 Flag Security
Profile Level: L2 (Hardened) NIST 800-53: CM-7
Implementation
Step 1: Tag Sensitive Flags
- Tag flags controlling security features
- Apply additional review requirements
- Audit changes
Step 2: Targeting Rule Protection
- Limit who can view targeting rules
- Audit rule changes
- Monitor for enumeration
4. Monitoring & Detection
4.1 Audit Log
Profile Level: L1 (Baseline) NIST 800-53: AU-2, AU-3
ClickOps Implementation
Step 1: Access Audit Log
- Navigate to: Account settings → Audit log
- Review changes
- Configure SIEM export
Detection Focus
-- Detect production flag changes
SELECT user_email, flag_key, action
FROM launchdarkly_audit_log
WHERE environment = 'production'
AND action IN ('updateFlag', 'toggleFlag')
AND timestamp > NOW() - INTERVAL '24 hours';
-- Detect bulk flag modifications
SELECT user_email, COUNT(*) as changes
FROM launchdarkly_audit_log
WHERE action LIKE '%Flag%'
AND timestamp > NOW() - INTERVAL '1 hour'
GROUP BY user_email
HAVING COUNT(*) > 10;
Appendix A: Edition Compatibility
| Control | Pro | Enterprise |
|---|---|---|
| SAML SSO | ✅ | ✅ |
| SCIM | ❌ | ✅ |
| Custom Roles | ✅ | ✅ |
| Approval Workflows | ❌ | ✅ |
Changelog
| Date | Version | Maturity | Changes | Author |
|---|---|---|---|---|
| 2025-12-14 | 0.1.0 | draft | Initial LaunchDarkly hardening guide | Claude Code (Opus 4.5) |