Security Controls for Mavim Azure, Microsoft Entra ID and Microsoft Graph Integration
This article describes the security controls implemented by Mavim for integrations with Microsoft Entra ID, Microsoft Graph, Azure services, and browser-facing applications. It covers credential management, authentication security, source code scanning, DDoS protection, logging and monitoring, identity validation, secure transport, and data handling practices.
Credential and Secret Management Source Code Secret Scanning
Mavim uses SonarCloud to scan source code repositories hosted in Azure DevOps for hardcoded credentials, secrets, and other sensitive information.
At this time, Mavim does not use Azure DevOps Credential Scanner.
Secret Scanning Controls
- SonarCloud scans source code repositories for embedded secrets and credentials.
- Scanning is integrated into the development lifecycle.
- Secrets are prohibited from being stored in source code repositories.
- Continuous monitoring is applied as part of the secure development process.
Secret Storage and Protection
Where Mavim operates confidential client applications, secrets are:
- Stored exclusively in Azure Key Vault
- Encrypted at rest
- Protected through Azure Role-Based Access Control (RBAC)
- Accessed through Managed Identities wherever possible
- Excluded from source code repositories
- Excluded from container images
- Excluded from CI/CD pipeline variables
- Excluded from application logs
- Never exposed to browser-based clients
Credential Rotation Policy
Mavim enforces a formal credential lifecycle policy for Azure application registrations.
Controls
- Maximum client secret validity: 12 months
- Mandatory rotation before expiration
- Documented rotation procedures
- Overlapping replacement credentials to prevent downtime
- Expiration monitoring and alerting through Azure Key Vault
Credential Retirement
Once replacement credentials are successfully deployed:
- Previous secrets are removed from Azure Key Vault
- Previous secrets are removed from Azure application registrations
- Credentials associated with retired integrations are permanently deleted
Authentication Method Preference
For Azure and Microsoft Graph integrations, Mavim follows the following authentication hierarchy:
- Managed Identity
- Certificate-based authentication
- Client secrets only when platform limitations require them
Exceptions
Some Microsoft ecosystem integrations require client secrets. An example is Microsoft Power Platform custom connectors that access Mavim APIs.
These integrations remain subject to the same controls around storage, monitoring, rotation, and expiration management.
Authentication and Authorization Single Page Application Authentication
Mavim web applications use the OAuth 2.0 / OAuth 2.1 Authorization Code Flow with Proof Key for Code Exchange (PKCE).
Characteristics include:
- No client secret required
- Public client authentication model
- Browser-based authentication using Microsoft Entra ID
- Protection against authorization code interception attacks
Microsoft Graph Access
Mavim uses delegated access to Microsoft Graph through the signed-in user.
Permissions
The application requests only: User.Read
Usage
Microsoft Graph profile information is used solely for display purposes and not for authorization decisions.
Examples include:
- Display name
- Profile photo
- Given name
- Surname
OAuth Flow Details
Browser Sign-In
- OAuth Authorization Code Flow with PKCE
- No client secret
- No certificate required
Microsoft Graph
- Delegated user access model
- User.Read permission
Azure Resources
- Managed identities
- Azure RBAC authorization
Client Secrets
Only used where required by platform limitations.
These secrets are:
- Stored in Azure Key Vault
- Accessed through Managed Identities
- Protected by Azure RBAC
- Never stored in source code, containers, configuration files, or pipeline variables
Token Security Microsoft Token Signing Keys
Mavim does not control or manage Microsoft Entra ID signing keys.
Microsoft remains responsible for:
- Key generation
- Key storage
- Key rotation
Mavim validates tokens using Microsoft's published public keys.
Browser Token Storage
Authentication is implemented using Microsoft Authentication Library (MSAL.js).
Authentication tokens are temporarily stored in browser session storage.
Characteristics
- Typical validity: 60-90 minutes
- Session-based storage
- Automatic renewal
- Automatic expiration
Risk Mitigations
Mavim implements:
- XSS testing
- Application security testing
- Content Security Policy (CSP)
- Least-privilege Microsoft Graph permissions
- Microsoft-recommended authentication frameworks
Identity Validation and User Information Token Validation
ID Tokens
Validated for:
- Issuer
- Audience
- Expiration
- Nonce
Access Tokens
Validated for:
- Digital signature
- Issuer
- Audience
- Expiration
- Required scopes
Tenant Validation
Multi-tenant access is controlled through an allow-list of approved tenant identifiers.
User Identity Model
Users are uniquely identified using:
- Tenant ID (tid)
- Object ID (oid)
This combination is immutable and authoritative.
Non-Authoritative Identity Attributes
The following attributes are never used as primary identity keys:
- Email address
- User Principal Name (UPN)
- Display name
User Attribute Handling
| Attribute | Purpose | Handling |
|---|---|---|
| tid, oid | Identity and session management | Taken only from validated tokens |
| email, userPrincipalName | Existing account matching fallback together with oid | Never used independently |
| displayName | UI display only | Treated as untrusted input and encoded before rendering |
| givenName | UI display only | Retrieved from validated sources |
| surname | UI display only | Retrieved from validated sources |
| photo | UI display only | Display purposes only |
Input Protection
All Graph-derived user information is treated as untrusted input.
Protection includes:
- Framework-provided output encoding
- Prevention of script injection
- Prohibition of raw HTML rendering
Network Protection and DDoS Mitigation Browser-Facing Web Applications
The Mavim web application is:
- Hosted in Azure Blob Storage
- Served through Azure Front Door
- Delivered through a static Single Page Application architecture
The application origin is a platform-managed Azure Storage endpoint and is not hosted on a VNet-connected endpoint.
As a result:
- No public VNet endpoint exists behind Front Door for the web application
- Azure DDoS Network Protection is not applicable to the Blob Storage origin
Protection is provided through:
- Azure Front Door built-in DDoS protection
- Azure Front Door Web Application Firewall (WAF)
- Front Door rate limiting
API Platform Protection
Azure API Management (APIM) is deployed within a Virtual Network.
The APIM VNets are associated with:
Azure DDoS Network Protection (formerly Azure DDoS Protection Standard)
This configuration is consistently applied across all operating regions.
API Protection Controls
- Request throttling
- Rate limiting
- Usage quotas
- Subscription key validation
Invalid requests are rejected before reaching backend services.
Application Gateway Protection
Additional protection is provided by Azure Application Gateway WAF.
Controls include:
- Managed rule sets
- Signature inspection
- OWASP protections
- Traffic filtering before requests reach AKS workloads
Traffic Monitoring
Azure Monitor continuously tracks:
- WAF events
- WAF blocks
- HTTP 429 responses
- HTTP 5xx responses
- Endpoint health
- Service availability
Logging, Monitoring and Retention Application Security Logging
Mavim records security-relevant events including:
- Successful authentications
- Failed authentications
- Token validation failures
- Microsoft Graph API activity
- Response status codes
- Correlation identifiers
- Trace identifiers
Logged Metadata
- Timestamp
- Tenant ID
- Application ID
- Object ID
- Correlation ID
Data Minimization
The following information is intentionally excluded from application logs:
- Access tokens
- Refresh tokens
- Client secrets
- Request payloads
- Response payloads
- User Principal Names
- Email addresses
Security Alerts
Alerts are configured for:
- New consent grants
- Credential creation
- Credential modifications
- Excessive sign-in failures
- Secret expiration events
Log Retention
Application Security Logs
- Retained for 2 years
- Archived for cold-storage investigations when required
Audit Logs
- Retained for 2 years
- Archived for investigation purposes
Application Insights
- Retained for 90 days
Microsoft Entra ID Logs
Microsoft retains native audit and sign-in logs for 30 days.
Mavim exports these logs through diagnostic settings to Azure Log Analytics where they are retained for: 6 months
Customer Sign-In Logs
Customer-user authentication events are also recorded within the customer's own Microsoft Entra ID tenant and governed by the customer's retention policy.
Current Position
Mavim does not currently maintain a formal exception process for Entra ID log retention beyond the configured retention period.
Secure Transport HTTPS Enforcement
All external Mavim endpoints enforce HTTPS.
This includes:
- Web applications
- APIs
- OAuth redirects
- Authentication callback URLs
- Microsoft Graph integrations
All HTTP traffic is redirected to HTTPS.
Port 80 is used exclusively for HTTP-to-HTTPS redirection.
TLS Configuration
The following components enforce TLS 1.2 as a minimum version:
- Azure Front Door
- Azure API Management
- Azure Application Gateway
Where supported, TLS 1.3 is enabled.
Validation
The TLS configuration has been:
- Independently assessed by Securance
- Validated using Qualys SSL Labs
Latest assessments achieved ratings of:
- A
- A+
HTTP Strict Transport Security (HSTS)
Mavim enforces: HTTP
Strict-Transport-Security: max-age=31536000; includeSubDomainsThis policy is applied to:
- SPA endpoints
- API endpoints
- Authentication endpoints
- Error responses
- Application responses
Certificate Management
TLS certificates are:
- Automatically managed
- Automatically renewed
- Continuously monitored for validity
Security Architecture Summary
Mavim applies a defense-in-depth security model for Azure, Microsoft Entra ID, and Microsoft Graph integrations.
Key security controls include:
- SonarCloud secret scanning for Azure DevOps repositories
- Azure Key Vault for secret storage
- Managed Identity–first authentication architecture
- Formal credential rotation and retirement processes
- Azure Front Door DDoS protection and WAF
- Azure DDoS Network Protection for APIM VNets
- Application Gateway WAF protections
- Comprehensive monitoring and alerting
- Secure token validation
- Strict identity claim validation
- Least-privilege Microsoft Graph permissions
- Secure handling of Graph profile data
- TLS 1.2+/TLS 1.3 enforcement
- HSTS and HTTPS-only connectivity
- Long-term audit and security logging
Together, these controls help protect the confidentiality, integrity, and availability of Mavim services while aligning with Microsoft security best practices for Azure, Microsoft Entra ID, and Microsoft Graph integrations.