Skip to content
EN-304-617.md 1.16 MiB
Newer Older
11001 11002 11003 11004 11005 11006 11007 11008 11009 11010 11011 11012 11013 11014 11015 11016 11017 11018 11019 11020 11021 11022 11023 11024 11025 11026 11027 11028 11029 11030 11031 11032 11033 11034 11035 11036 11037 11038 11039 11040 11041 11042 11043 11044 11045 11046 11047 11048 11049 11050 11051 11052 11053 11054 11055 11056 11057 11058 11059 11060 11061 11062 11063 11064 11065 11066 11067 11068 11069 11070 11071 11072 11073 11074 11075 11076 11077 11078 11079 11080 11081 11082 11083 11084 11085 11086 11087 11088 11089 11090 11091 11092 11093 11094 11095 11096 11097 11098 11099 11100 11101 11102 11103 11104 11105 11106 11107 11108 11109 11110 11111 11112 11113 11114 11115 11116 11117 11118 11119 11120 11121 11122 11123 11124 11125 11126 11127 11128 11129 11130 11131 11132 11133 11134 11135 11136 11137 11138 11139 11140 11141 11142 11143 11144 11145 11146 11147 11148 11149 11150 11151 11152 11153 11154 11155 11156 11157 11158 11159 11160 11161 11162 11163 11164 11165 11166 11167 11168 11169 11170 11171 11172 11173 11174 11175 11176 11177 11178 11179 11180 11181 11182 11183 11184 11185 11186 11187 11188 11189 11190 11191 11192 11193 11194 11195 11196 11197 11198 11199 11200 11201 11202 11203 11204 11205 11206 11207 11208 11209 11210 11211 11212 11213 11214 11215 11216 11217 11218 11219 11220 11221 11222 11223 11224 11225 11226 11227 11228 11229 11230 11231 11232 11233 11234 11235 11236 11237 11238 11239 11240 11241 11242 11243 11244 11245 11246 11247 11248 11249 11250 11251 11252 11253 11254 11255 11256 11257 11258 11259 11260 11261 11262 11263 11264 11265 11266 11267 11268 11269 11270 11271 11272 11273 11274 11275 11276 11277 11278 11279 11280 11281 11282 11283 11284 11285 11286 11287 11288 11289 11290 11291 11292 11293 11294 11295 11296 11297 11298 11299 11300 11301 11302 11303 11304 11305 11306 11307 11308 11309 11310 11311 11312 11313 11314 11315 11316 11317 11318 11319 11320 11321 11322 11323 11324 11325 11326 11327 11328 11329 11330 11331 11332 11333 11334 11335 11336 11337 11338 11339 11340 11341 11342 11343 11344 11345 11346 11347 11348 11349 11350 11351 11352 11353 11354 11355 11356 11357 11358 11359 11360 11361 11362 11363 11364 11365 11366 11367 11368 11369 11370 11371 11372 11373 11374 11375 11376 11377 11378 11379 11380 11381 11382 11383 11384 11385 11386 11387 11388 11389 11390 11391 11392 11393 11394 11395 11396 11397 11398 11399 11400 11401 11402 11403 11404 11405 11406 11407 11408 11409 11410 11411 11412 11413 11414 11415 11416 11417 11418 11419 11420 11421 11422 11423 11424 11425 11426 11427 11428 11429 11430 11431 11432 11433 11434 11435 11436 11437 11438 11439 11440 11441 11442 11443 11444 11445 11446 11447 11448 11449 11450 11451 11452 11453 11454 11455 11456 11457 11458 11459 11460 11461 11462 11463 11464 11465 11466 11467 11468 11469 11470 11471 11472 11473 11474 11475 11476 11477 11478 11479 11480 11481 11482 11483 11484 11485 11486 11487 11488 11489 11490 11491 11492 11493 11494 11495 11496 11497 11498 11499 11500 11501 11502 11503 11504 11505 11506 11507 11508 11509 11510 11511 11512 11513 11514 11515 11516 11517 11518 11519 11520 11521 11522 11523 11524 11525 11526 11527 11528 11529 11530 11531 11532 11533 11534 11535 11536 11537 11538 11539 11540 11541 11542 11543 11544 11545 11546 11547 11548 11549 11550 11551 11552 11553 11554 11555 11556 11557 11558 11559 11560 11561 11562 11563 11564 11565 11566 11567 11568 11569 11570 11571 11572 11573 11574 11575 11576 11577 11578 11579 11580 11581 11582 11583 11584 11585 11586 11587 11588 11589 11590 11591 11592 11593 11594 11595 11596 11597 11598 11599 11600 11601 11602 11603 11604 11605 11606 11607 11608 11609 11610 11611 11612 11613 11614 11615 11616 11617 11618 11619 11620 11621 11622 11623 11624 11625 11626 11627 11628 11629 11630 11631 11632 11633 11634 11635 11636 11637 11638 11639 11640 11641 11642 11643 11644 11645 11646 11647 11648 11649 11650 11651 11652 11653 11654 11655 11656 11657 11658 11659 11660 11661 11662 11663 11664 11665 11666 11667 11668 11669 11670 11671 11672 11673 11674 11675 11676 11677 11678 11679 11680 11681 11682 11683 11684 11685 11686 11687 11688 11689 11690 11691 11692 11693 11694 11695 11696 11697 11698 11699 11700 11701 11702 11703 11704 11705 11706 11707 11708 11709 11710 11711 11712 11713 11714 11715 11716 11717 11718 11719 11720 11721 11722 11723 11724 11725 11726 11727 11728 11729 11730 11731 11732 11733 11734 11735 11736 11737 11738 11739 11740 11741 11742 11743 11744 11745 11746 11747 11748 11749 11750 11751 11752 11753 11754 11755 11756 11757 11758 11759 11760 11761 11762 11763 11764 11765 11766 11767 11768 11769 11770 11771 11772 11773 11774 11775 11776 11777 11778 11779 11780 11781 11782 11783 11784 11785 11786 11787 11788 11789 11790 11791 11792 11793 11794 11795 11796 11797 11798 11799 11800 11801 11802 11803 11804 11805 11806 11807 11808 11809 11810 11811 11812 11813 11814 11815 11816 11817 11818 11819 11820 11821 11822 11823 11824 11825 11826 11827 11828 11829 11830 11831 11832 11833 11834 11835 11836 11837 11838 11839 11840 11841 11842 11843 11844 11845 11846 11847 11848 11849 11850 11851 11852 11853 11854 11855 11856 11857 11858 11859 11860 11861 11862 11863 11864 11865 11866 11867 11868 11869 11870 11871 11872 11873 11874 11875 11876 11877 11878 11879 11880 11881 11882 11883 11884 11885 11886 11887 11888 11889 11890 11891 11892 11893 11894 11895 11896 11897 11898 11899 11900 11901 11902 11903 11904 11905 11906 11907 11908 11909 11910 11911 11912 11913 11914 11915 11916 11917 11918 11919 11920 11921 11922 11923 11924 11925 11926 11927 11928 11929 11930 11931 11932 11933 11934 11935 11936 11937 11938 11939 11940 11941 11942 11943 11944 11945 11946 11947 11948 11949 11950 11951 11952 11953 11954 11955 11956 11957 11958 11959 11960 11961 11962 11963 11964 11965 11966 11967 11968 11969 11970 11971 11972 11973 11974 11975 11976 11977 11978 11979 11980 11981 11982 11983 11984 11985 11986 11987 11988 11989 11990 11991 11992 11993 11994 11995 11996 11997 11998 11999 12000
5. Test that mixed content blocking cannot be disabled by web content → Web content cannot disable mixed content protection
6. Verify that host application cannot weaken mixed content protection → Host application cannot weaken mixed content blocking
7. Test that browser console shows clear mixed content errors → upgrade-insecure-requests CSP directive automatically upgrades HTTP to HTTPS

**Pass Criteria**: Active mixed content is always blocked AND passive mixed content protection is enforced AND cannot be disabled

**Fail Criteria**: Mixed content loads successfully OR protection can be disabled OR insufficient warnings

**Evidence**: Browser console showing mixed content errors, test results with blocked HTTP resources, CSP header analysis, security configuration review, network traffic captures

**References**:

- W3C Mixed Content specification: https://www.w3.org/TR/mixed-content/
- Mixed Content (MDN): https://developer.mozilla.org/en-US/docs/Web/Security/Mixed_content
- CSP upgrade-insecure-requests: https://www.w3.org/TR/upgrade-insecure-requests/
- Chromium Mixed Content Policy: https://www.chromium.org/Home/chromium-security/deprecating-powerful-features-on-insecure-origins

### Assessment: EMB-REQ-22 (Trust decision logging)

**Reference**: EMB-REQ-22 - Trust decisions shall be logged with sufficient detail to detect trust boundary violations

**Given**: A conformant embedded browser with trust management (EMB-1 or higher)

**Task**: Trust decision logging is critical for detecting and investigating attacks that attempt to cross trust boundaries in embedded browsers, such as untrusted origins trying to access privileged JavaScript bridge APIs or certificate validation bypasses. Without comprehensive logging of trust decisions, security teams cannot identify patterns of attack attempts, investigate security incidents, or detect compromised trusted origins that begin exhibiting suspicious behavior. Detailed trust logs enable security monitoring systems to flag anomalies like repeated origin allowlist violations, certificate pinning failures, or unusual patterns of bridge API access that may indicate reconnaissance or active exploitation attempts.

**Verification**:

1. Configure logging for trust-related decisions in the embedded browser → Verify log retention policies for security-relevant events
2. Load content from trusted and untrusted origins → All trust decisions are logged with sufficient detail
3. Review logs and verify they contain: origin, timestamp, trust decision outcome, reason for decision → Logs include origin, timestamp, decision, and rationale
4. Attempt trust boundary violations (untrusted origin accessing privileged APIs) → Trust boundary violations are logged with full context
5. Verify that violations are logged with full context → Certificate validation results are logged
6. Test that certificate validation decisions are logged → Origin allowlist enforcement is logged
7. Verify that origin allowlist enforcement is logged → Logs are protected from tampering
8. Test that logs are stored securely and cannot be tampered with by web content → Log retention balances security needs and privacy

**Pass Criteria**: All trust decisions are logged with sufficient detail AND violations are logged AND logs are tamper-protected

**Fail Criteria**: Trust decisions are not logged OR insufficient detail OR logs can be tampered with

**Evidence**: Log samples showing trust decisions, log configuration documentation, test results showing violation logging, log integrity verification, log retention policy documentation

**References**:

- OWASP Logging Cheat Sheet: https://cheatsheetseries.owasp.org/cheatsheets/Logging_Cheat_Sheet.html
- NIST SP 800-92: Guide to Computer Security Log Management: https://csrc.nist.gov/publications/detail/sp/800-92/final
- CWE-778: Insufficient Logging: https://cwe.mitre.org/data/definitions/778.html

### Assessment: EMB-REQ-23 (Cryptographic signature verification for local content)

**Reference**: EMB-REQ-23 - Embedded browsers loading local/bundled content shall verify cryptographic signatures before execution

**Given**: A conformant embedded browser loading bundled/local content (EMB-2 or higher)

**Task**: Cryptographic signature verification for local content protects against tampering attacks where attackers with file system access attempt to modify bundled HTML, JavaScript, or CSS files to inject malicious code. Without signature verification, local privilege escalation or compromised backup/restore processes could allow attackers to silently modify embedded browser content that executes with full JavaScript bridge API access. Digital signatures ensure content integrity from build time through deployment, detecting any unauthorized modifications and preventing execution of tampered local resources that could otherwise compromise the entire host application through bridge exploitation.

**Verification**:

1. Identify local/bundled content loaded by the embedded browser (HTML, JS, CSS files) → All local/bundled content has cryptographic signatures
2. Verify that all bundled content is cryptographically signed → Signature verification occurs before content execution
3. Review signature verification implementation in the browser initialization code → Modified content fails signature verification
4. Attempt to modify bundled content and verify that signature verification fails → Signature verification failures block content loading
5. Test that signature verification failures prevent content loading → Secure signature algorithms are used
6. Verify that signature verification uses secure algorithms (RSA-2048+, ECDSA P-256+) → Signature verification cannot be bypassed
7. Test that signature verification cannot be bypassed or disabled → Signing keys are protected from extraction
8. Verify that signing keys are properly protected in the host application → Verification process is logged

**Pass Criteria**: All local content is signed AND signatures are verified before execution AND verification cannot be bypassed

**Fail Criteria**: Unsigned content can be loaded OR signature verification is bypassable OR weak signature algorithms

**Evidence**: Signed content bundles, signature verification code review, test results with modified content, cryptographic algorithm analysis, key protection documentation

**References**:

- Code Signing Best Practices (NIST): https://csrc.nist.gov/publications/detail/sp/800-183/final
- Android APK Signature Scheme: https://source.android.com/docs/security/features/apksigning
- Authenticode for Windows: https://docs.microsoft.com/en-us/windows-hardware/drivers/install/authenticode

### Assessment: EMB-REQ-24 (Redirect chain trust enforcement)

**Reference**: EMB-REQ-24 - Host applications shall implement mechanisms to detect and prevent redirect chains that exit trusted domains

**Given**: A conformant embedded browser with origin allowlist (EMB-1 or higher)

**Task**: Redirect chain trust enforcement prevents open redirect attacks where trusted origins inadvertently redirect to attacker-controlled domains, potentially exposing JavaScript bridge APIs to malicious content. Without redirect validation, attackers can exploit legitimate redirects on trusted sites to bypass origin allowlists, tricking the embedded browser into loading malicious content that appears to come from a trusted source. Multi-hop redirect chains are particularly dangerous because each hop in the chain could be manipulated to eventually land on an untrusted domain, requiring comprehensive validation of the entire redirect path to prevent trust boundary violations.

**Verification**:

1. Configure trusted origin allowlist in the embedded browser → Verify that JavaScript-based redirects are also subject to trust enforcement
2. Load a page from a trusted origin that redirects to another trusted origin → Redirect chain validation is enforced
3. Verify that trusted-to-trusted redirects are allowed → Trusted-to-trusted redirects are allowed
4. Load a page from a trusted origin that redirects to an untrusted origin → Any redirect to untrusted origin is blocked
5. Verify that trusted-to-untrusted redirects are blocked → Multi-hop redirect chains are fully validated
6. Test multi-hop redirect chains: trusted → trusted → untrusted → Both HTTP and JavaScript redirects are subject to enforcement
7. Verify that all redirects in the chain are validated against allowlist → Blocked redirects trigger error pages and security logs
8. Test that redirect blocking triggers security logging → Users are notified when redirects are blocked

**Pass Criteria**: Redirect chains are fully validated AND untrusted redirects are blocked AND enforcement covers all redirect types

**Fail Criteria**: Redirects to untrusted origins succeed OR JavaScript redirects bypass enforcement OR multi-hop validation is incomplete

**Evidence**: Redirect test results, browser console showing blocked redirects, security logs, network traffic captures showing redirect chains, error page screenshots

**References**:

- OWASP Open Redirect: https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html
- CWE-601: URL Redirection to Untrusted Site: https://cwe.mitre.org/data/definitions/601.html
- Android WebView shouldOverrideUrlLoading: https://developer.android.com/reference/android/webkit/WebViewClient#shouldOverrideUrlLoading(android.webkit.WebView,%20android.webkit.WebResourceRequest)
- iOS WKNavigationDelegate decidePolicyFor: https://developer.apple.com/documentation/webkit/wknavigationdelegate/1455641-webview

### Assessment: EMB-REQ-25 (HSTS enforcement for trusted origins)

**Reference**: EMB-REQ-25 - Embedded browsers shall enforce strict transport security (HSTS) for all trusted content origins

**Given**: A conformant embedded browser (EMB-1 or higher)

**Task**: HSTS enforcement for trusted origins protects against SSL stripping attacks where network attackers intercept initial HTTP requests and prevent upgrade to HTTPS, allowing interception of all subsequent traffic. Without HSTS, embedded browsers are vulnerable during the brief window between application launch and the first HTTPS connection, when attackers can downgrade connections to HTTP and conduct man-in-the-middle attacks. HSTS ensures that all connections to trusted origins use HTTPS, with non-bypassable certificate validation, preventing network-level attackers from intercepting or modifying content loaded by the embedded browser even on compromised networks.

**Verification**:

1. Configure trusted content origins with HSTS headers: `Strict-Transport-Security: max-age=31536000; includeSubDomains; preload` → HSTS headers are parsed and cached correctly
2. Make initial HTTPS request to trusted origin and verify HSTS header is received and cached → HTTP requests to HSTS hosts are automatically upgraded to HTTPS
3. Attempt to make HTTP request to same origin and verify automatic upgrade to HTTPS → HSTS state persists across browser sessions
4. Test that HSTS enforcement continues after browser restart (persistence) → includeSubDomains flag applies to all subdomains
5. Verify that HSTS includeSubDomains flag is respected for subdomains → HSTS preload list is maintained and enforced
6. Test that HSTS preload list is supported and enforced → HSTS cannot be bypassed through IP access or other means
7. Attempt to bypass HSTS through direct IP access or hosts file manipulation → Certificate errors on HSTS hosts are non-bypassable
8. Verify that certificate errors on HSTS hosts cannot be bypassed → HSTS enforcement is logged

**Pass Criteria**: HSTS is enforced for all trusted origins AND HTTP is automatically upgraded AND certificate errors are non-bypassable

**Fail Criteria**: HSTS can be bypassed OR HTTP connections succeed to HSTS hosts OR certificate errors are bypassable

**Evidence**: Network traffic captures showing HTTPS upgrades, HSTS cache inspection, test results with HTTP requests, certificate error bypass attempts, HSTS preload list verification

**References**:

- RFC 6797: HTTP Strict Transport Security (HSTS): https://datatracker.ietf.org/doc/html/rfc6797
- HSTS Preload List: https://hstspreload.org/
- OWASP HSTS: https://cheatsheetseries.owasp.org/cheatsheets/HTTP_Strict_Transport_Security_Cheat_Sheet.html
- Chromium HSTS Implementation: https://www.chromium.org/hsts

### Assessment: EMB-REQ-26 (Certificate validation failure notification)

**Reference**: EMB-REQ-26 - Certificate validation failures for trusted content sources shall trigger immediate user notification and content blocking

**Given**: A conformant embedded browser loading trusted remote content (EMB-1 or higher)

**Task**: Immediate notification and blocking on certificate validation failures for trusted content prevents silent man-in-the-middle attacks where users unknowingly interact with compromised content. Without clear error notifications and strict blocking, users might not realize that certificate validation has failed, allowing attackers to serve malicious content that appears to come from trusted origins. Non-bypassable certificate error handling for trusted origins ensures that even sophisticated attacks using fraudulent certificates cannot trick the embedded browser into loading untrusted content, protecting the integrity of the JavaScript bridge API access model.

**Verification**:

1. Configure trusted content origins with valid certificates → Certificate validation failures are detected for all failure types
2. Simulate certificate validation failures: expired certificate, hostname mismatch, untrusted CA, revoked certificate → User receives immediate, clear error notification
3. Verify that each failure type triggers immediate error notification → Content loading is completely blocked on validation failure
4. Verify that content loading is completely blocked (no partial loading) → Error messages explain the specific certificate problem
5. Test that error notifications clearly explain the problem to users → No bypass mechanism exists for certificate errors on trusted origins
6. Verify that no "continue anyway" option exists for trusted origin failures → Certificate failures are logged with full details
7. Test that certificate failures are logged to security event log → Host application can register for certificate failure callbacks
8. Verify that host application is notified of certificate failures via callback → Failure handling differs for trusted vs. untrusted origins

**Pass Criteria**: All certificate failures block content AND trigger immediate user notification AND are non-bypassable for trusted origins

**Fail Criteria**: Any certificate failure allows content loading OR notifications are missing/unclear OR bypass options exist

**Evidence**: Error page screenshots, certificate failure logs, test results with various failure types, user notification interface documentation, host callback implementation

**References**:

- RFC 5280: Certificate Validation: https://datatracker.ietf.org/doc/html/rfc5280
- CA/Browser Forum Baseline Requirements: https://cabforum.org/baseline-requirements-documents/
- Android WebView onReceivedSslError: https://developer.android.com/reference/android/webkit/WebViewClient#onReceivedSslError(android.webkit.WebView,%20android.webkit.SslErrorHandler,%20android.net.http.SslError)
- iOS WKNavigationDelegate didReceive challenge: https://developer.apple.com/documentation/webkit/wknavigationdelegate/1455638-webview

### Assessment: EMB-REQ-27 (Network security configuration)

**Reference**: EMB-REQ-27 - Host applications shall implement network security configurations that prevent cleartext traffic to trusted domains

**Given**: A conformant embedded browser (EMB-1 or higher)

**Task**: This assessment verifies that host applications implement declarative network security configurations (Android Network Security Config, iOS App Transport Security, or equivalent) that prevent cleartext HTTP traffic to trusted domains. Cleartext traffic exposes sensitive data to network eavesdropping and man-in-the-middle attacks. The configuration shall enforce HTTPS-only communication for trusted domains at the network layer, apply uniformly across all network APIs (WebView, XHR, fetch, WebSocket), integrate certificate pinning settings, be declarative and immutable at runtime (not modifiable by web content), and log blocked cleartext traffic attempts for security monitoring. Platform-specific security features shall be properly configured to prevent accidental or malicious downgrade to insecure HTTP connections.

**Verification**:

1. Review network security configuration files (Android NSConfig, iOS ATS) → Network security configuration enforces HTTPS-only for trusted domains
2. Verify cleartext HTTP traffic disabled for trusted domains → Cleartext HTTP traffic blocked at network layer
3. Attempt HTTP requests to trusted domains across all network APIs → HTTPS enforcement applies uniformly to all network APIs
4. Test runtime modification attempts of HTTPS enforcement → Configuration is declarative and immutable at runtime
5. Verify certificate pinning integration with network security config → Certificate pinning integrated into network security config
6. Test cleartext traffic blocking and verify logging → Blocked cleartext traffic is logged
7. Review configuration documentation and auditability → Configuration documented and auditable
8. Verify platform-specific security features properly utilized → Platform features (NSConfig, ATS) correctly configured

**Pass Criteria**: Cleartext traffic to trusted domains is blocked at network layer AND configuration is immutable AND applies to all network APIs

**Fail Criteria**: Cleartext traffic succeeds to trusted domains OR configuration can be modified OR inconsistent enforcement across APIs

**Evidence**: Network security configuration files, network traffic captures showing blocked HTTP, test results with various network APIs, configuration documentation, platform security feature usage audit

**References**:

- Android Network Security Configuration: https://developer.android.com/training/articles/security-config
- iOS App Transport Security: https://developer.apple.com/documentation/security/preventing_insecure_network_connections
- CWE-319: Cleartext Transmission of Sensitive Information: https://cwe.mitre.org/data/definitions/319.html

### Assessment: EMB-REQ-28 (CSP enforcement for third-party content)

**Reference**: EMB-REQ-28 - Embedded browsers shall prevent trusted content from loading untrusted third-party content without explicit CSP declarations

**Given**: A conformant embedded browser with CSP support (EMB-1 or higher)

**Task**: This assessment verifies that embedded browsers enforce Content Security Policy (CSP) to prevent trusted content from loading untrusted third-party resources without explicit declarations. Uncontrolled third-party content loading enables XSS attacks, data exfiltration, and supply chain compromises. The CSP shall restrict third-party content loading to explicitly allowlisted domains, apply uniformly to all resource types (scripts, styles, images, frames, etc.), report violations to configured endpoints, be immutable by web content, and have host-configured policies take precedence over page-specified CSP. Default CSP should be restrictive (deny by default), requiring explicit allowlisting for all third-party resources.

**Verification**:

1. Configure trusted content with restrictive CSP allowing specific third-party domains → CSP restricts third-party loading to explicitly allowed domains
2. Test loading from CSP-allowed domains and verify success → Allowed third-party content loads successfully
3. Attempt loading from non-allowed domains and verify blocking → Non-allowed third-party content is blocked
4. Test inline scripts from third-party content blocked unless CSP-allowed → CSP applies consistently across all resource types
5. Verify CSP applies to all resource types (scripts, styles, images, frames) → CSP violations generate reports to configured endpoint
6. Test CSP violations reported via report-uri or report-to → Web content cannot bypass or weaken CSP restrictions
7. Verify web content cannot weaken or disable CSP policy → Host-configured CSP cannot be overridden by page CSP
8. Test host-configured CSP takes precedence over page-specified CSP → CSP enforcement is logged and default policy is restrictive

**Pass Criteria**: Third-party content loading is restricted by CSP AND violations are blocked and reported AND policy cannot be weakened by web content

**Fail Criteria**: Third-party content bypasses CSP OR policy can be weakened OR violations not reported

**Evidence**: CSP policy headers, browser console showing CSP violations, violation reports, test results with blocked third-party content, network traffic analysis

**References**:

- Content Security Policy Level 3: https://www.w3.org/TR/CSP3/
- CSP script-src directive: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/script-src
- CSP Reporting: https://developer.mozilla.org/en-US/docs/Web/HTTP/CSP#reporting
- OWASP CSP Cheat Sheet: https://cheatsheetseries.owasp.org/cheatsheets/Content_Security_Policy_Cheat_Sheet.html

### Assessment: EMB-REQ-29 (Per-instance trust policies)

**Reference**: EMB-REQ-29 - Trust policies shall be configurable per embedded browser instance to support multi-tenant applications

**Given**: A conformant embedded browser supporting multiple instances (EMB-2 or higher)

**Task**: This assessment verifies that embedded browsers support per-instance trust policy configuration, allowing each instance to enforce different security policies independently while maintaining complete isolation from other instances.

**Verification**:

1. Create multiple embedded browser instances within the same host application → Trust policies can be configured independently per instance
2. Configure different trust policies for each instance (different origin allowlists, certificate pins, CSP policies) → Each instance enforces its own trust policy correctly
3. Load content in each instance and verify that instance-specific policies are enforced → Instances are isolated from each other (no cross-instance access)
4. Verify that instances cannot access each other's storage or state → Trust policy configuration is scoped to individual instances
5. Test that trust policy configuration is isolated per instance → Instance creation accepts custom policy configuration
6. Attempt to modify one instance's trust policy from another instance → Instance destruction cleans up policy state
7. Verify that instance destruction cleans up trust policy state → No interference between instances' trust enforcement
8. Test that host application can dynamically create instances with custom policies → Multi-tenant scenarios are properly supported

**Pass Criteria**: Per-instance trust policies are supported AND enforced correctly AND instances are isolated from each other

**Fail Criteria**: Policies cannot be configured per-instance OR instances interfere with each other OR policy isolation is broken

**Evidence**: Code showing per-instance policy configuration, test results with multiple instances, storage isolation verification, policy enforcement logs per instance, multi-tenant test scenarios

**References**:

- Android WebView Multiple Instances: https://developer.android.com/reference/android/webkit/WebView
- iOS WKWebView Configuration: https://developer.apple.com/documentation/webkit/wkwebviewconfiguration
- Electron BrowserView Isolation: https://www.electronjs.org/docs/latest/api/browser-view
- Multi-tenancy Security Best Practices: https://owasp.org/www-project-application-security-verification-standard/

### Assessment: EMB-REQ-30 (Certificate Transparency verification)

**Reference**: EMB-REQ-30 - Embedded browsers shall implement certificate transparency verification for trusted content origins

**Given**: A conformant embedded browser with Certificate Transparency support (EMB-2 or higher)

**Task**: This assessment verifies that embedded browsers implement and enforce Certificate Transparency verification for trusted content origins, validating Signed Certificate Timestamps (SCTs) and blocking content from origins with missing or invalid SCTs.

**Verification**:

1. Configure trusted content origins that require Certificate Transparency → Certificate Transparency verification is supported
2. Load content from origins with valid SCTs (Signed Certificate Timestamps) in certificates or via TLS extension → Valid SCTs allow content loading from CT-required origins
3. Verify that content loads successfully when valid SCTs are present → Missing or invalid SCTs block content loading
4. Attempt to load content with certificates lacking SCTs from CT-required origins → SCTs are validated against known CT logs
5. Verify that missing or invalid SCTs block content loading for CT-required origins → CT enforcement policy is configurable (per-origin or global)
6. Test that SCTs are validated against known CT logs → CT validation failures generate clear error messages and logs
7. Verify that CT enforcement can be configured per-origin or globally → CT log list is kept up-to-date
8. Test that CT validation failures are logged → CT enforcement integrates with certificate validation flow

**Pass Criteria**: CT verification is implemented AND enforced for configured origins AND invalid SCTs block content loading

**Fail Criteria**: CT verification not implemented OR can be bypassed OR invalid SCTs are accepted

**Evidence**: Network traffic captures showing SCTs, CT validation logs, test results with missing SCTs, CT log list version verification, CT enforcement configuration

**References**:

- RFC 6962: Certificate Transparency: https://datatracker.ietf.org/doc/html/rfc6962
- Chromium CT Policy: https://www.chromium.org/Home/chromium-security/certificate-transparency/
- Certificate Transparency Logs: https://www.certificate-transparency.org/
- Google CT Policy: https://github.com/GoogleChrome/CertificateTransparency/blob/master/ct_policy.md

### Assessment: EMB-REQ-31 (DNS rebinding attack prevention)

**Reference**: EMB-REQ-31 - Host applications shall detect and prevent DNS rebinding attacks targeting trusted local/internal origins

**Given**: A conformant embedded browser with local/internal origin access (EMB-2 or higher)

**Task**: This assessment verifies that embedded browsers detect and prevent DNS rebinding attacks targeting trusted local and internal origins through DNS caching, Host header validation, and logging of rebinding attempts.

**Verification**:

1. Identify local/internal origins accessed by the embedded browser (localhost, 127.0.0.1, private IP ranges, .local domains) → DNS rebinding attacks are detected
2. Simulate DNS rebinding attack: external domain initially resolves to attacker IP, then rebinds to local/internal IP → Unexpected DNS resolution changes trigger blocking
3. Verify that DNS rebinding is detected and blocked → Private IP address access requires explicit configuration
4. Test DNS cache behavior and TTL enforcement → DNS cache prevents rapid rebinding
5. Verify that private IP address access requires explicit allowlisting → Host header validation is enforced
6. Test that DNS resolution results are validated against expected address ranges → Resolution results are validated against address allowlists
7. Verify that Host header validation prevents rebinding exploitation → Rebinding attempts are logged as security events
8. Test that DNS rebinding attempts trigger security logging → Local/internal origins have additional protection

**Pass Criteria**: DNS rebinding attacks are detected and blocked AND private IP access is restricted AND rebinding attempts are logged

**Fail Criteria**: DNS rebinding succeeds OR no private IP restrictions OR rebinding not detected

**Evidence**: DNS rebinding test results, DNS cache configuration, Host header validation tests, security logs showing rebinding attempts, private IP access policy documentation

**References**:

- DNS Rebinding Explained: https://en.wikipedia.org/wiki/DNS_rebinding
- CWE-346: Origin Validation Error: https://cwe.mitre.org/data/definitions/346.html
- Private Network Access specification: https://wicg.github.io/private-network-access/

### Assessment: EMB-REQ-32 (Trust boundary violation security events)

**Reference**: EMB-REQ-32 - Trust boundary violations shall trigger security events with sufficient context for incident response

**Given**: A conformant embedded browser with comprehensive logging (EMB-1 or higher)

**Task**: This assessment verifies that trust boundary violations trigger comprehensive security events with sufficient context for incident response, including proper distinction from general logs, SIEM integration capability, and alert generation for high-severity violations.

**Verification**:

1. Configure security event logging for the embedded browser → Trust boundary violations generate security events
2. Trigger various trust boundary violations (accessing blocked origins, calling restricted APIs, certificate validation failures, CSP violations) → Events include comprehensive context: timestamp, type, origin, description, severity
3. Review generated security events and verify they contain timestamp, event type, origin/source, detailed description, severity level, stack trace/context → Events are distinguishable from general logs (separate channel or marked)
4. Verify that security events are distinct from general application logs → Events can be exported or forwarded to security monitoring systems
5. Test that security events can be forwarded to SIEM or security monitoring systems → High-severity events trigger immediate alerts
6. Verify that high-severity violations trigger immediate alerts → Events include actionable information for incident response
7. Test that security events include sufficient context for incident investigation → Event logging is reliable and does not impact app stability
8. Verify that event generation does not disrupt application functionality → Events are tamper-resistant

**Pass Criteria**: All boundary violations generate security events AND events include sufficient context AND can be forwarded to monitoring systems

**Fail Criteria**: Violations don't generate events OR insufficient context OR cannot be monitored externally

**Evidence**: Security event log samples, event schema documentation, SIEM integration configuration, alert configuration, incident response playbooks referencing events, event log integrity verification

**References**:

- NIST SP 800-61: Computer Security Incident Handling Guide: https://csrc.nist.gov/publications/detail/sp/800-61/rev-2/final
- OWASP Logging Cheat Sheet: https://cheatsheetseries.owasp.org/cheatsheets/Logging_Cheat_Sheet.html
- CEF (Common Event Format): https://www.microfocus.com/documentation/arcsight/arcsight-smartconnectors/pdfdoc/common-event-format-v25/common-event-format-v25.pdf
- SIEM Integration Best Practices: https://www.sans.org/white-papers/36427/

### Assessment: EMB-REQ-33 (Block web content access to host application objects at EMB-0)

**Reference**: EMB-REQ-33 - Embedded browser shall prevent all web content access to host application objects at EMB-0 capability level

**Given**: A conformant embedded browser with EMB-0 capability (no JavaScript bridge or native API exposure)

**Task**: At EMB-0 capability, embedded browsers shall completely isolate web content from host application objects, methods, and data structures to prevent JavaScript injection attacks, host context manipulation, and privilege escalation. Allowing any bridge interface, custom JavaScript objects, or window property injection at this level contradicts the security posture of complete isolation, enabling malicious web content to escape sandbox boundaries and compromise the host application. Complete object isolation with no window augmentation, strict namespace separation, and frozen global scope ensures zero native access.

**Verification**:

1. Load untrusted web content in the embedded browser → All common bridge object names undefined
2. Attempt to access common JavaScript bridge object names (AndroidBridge, webkit, chrome, nativeInterface, etc.) and verify they are undefined → Window object contains only standard web platform APIs
3. Enumerate window object properties and confirm no host-injected objects exist → No host-injected properties in global scope
4. Test reflection APIs (Object.keys, Object.getOwnPropertyNames) on window and verify no custom properties → Reflection APIs show only standard properties
5. Attempt to override native JavaScript methods and verify host does not expose overridden methods → Native method overrides not exploitable for host communication
6. Test for custom event listeners added by host and confirm none exist → No custom event listeners from host
7. Attempt to access parent/opener contexts and verify they are inaccessible or null → Parent/opener contexts inaccessible
8. Verify window.external is undefined or blocked (legacy IE bridge interface) → window.external undefined or blocked
9. Test for prompt/alert/confirm hijacking that would allow host communication → Dialog APIs do not create host communication channels
10. Verify no custom URL schemes trigger host-side callbacks at EMB-0 → Custom URL schemes do not trigger host callbacks

**Pass Criteria**: All bridge objects undefined AND window object contains only standard APIs AND no host-injected properties AND no communication channels exist

**Fail Criteria**: Bridge objects accessible OR custom window properties present OR host communication possible OR custom schemes trigger callbacks

**Evidence**: JavaScript console enumeration of window properties, reflection API output showing standard APIs only, bridge access attempt logs showing errors, URL scheme handler testing, dialog API interaction verification

**References**:

- OWASP Mobile WebView Security: https://mas.owasp.org/MASTG/tests/android/MASVS-PLATFORM/MASTG-TEST-0028/
- Android WebView addJavascriptInterface: https://developer.android.com/reference/android/webkit/WebView#addJavascriptInterface(java.lang.Object,%20java.lang.String)
- iOS WKWebView Script Message Handlers: https://developer.apple.com/documentation/webkit/wkusercontentcontroller
- Electron Context Isolation: https://www.electronjs.org/docs/latest/tutorial/context-isolation

### Assessment: EMB-REQ-34 (No JavaScript bridge exposure at EMB-0)

**Reference**: EMB-REQ-34 - No JavaScript bridge or native API exposure mechanism shall exist at EMB-0 capability level

**Given**: A conformant embedded browser with EMB-0 capability (no JavaScript bridge or native API exposure)

**Task**: JavaScript bridges create privileged communication channels between web content and native host applications, fundamentally violating EMB-0's isolation requirement. Any bridge mechanism - addJavascriptInterface (Android), WKScriptMessageHandler (iOS), contextBridge (Electron), or custom implementations - enables web content to invoke native methods, access host data, and potentially execute arbitrary code in the native context. At EMB-0, all bridge registration APIs should be disabled, configuration immutable, and attempted bridge creation blocked to ensure complete isolation.

**Verification**:

1. Review embedded browser initialization code and verify no bridge registration calls present → No addJavascriptInterface calls in Android WebView initialization
2. Test Android WebView addJavascriptInterface and confirm the API is not called or is blocked → No WKScriptMessageHandler registered in iOS WKWebView
3. Test iOS WKWebView addScriptMessageHandler and verify no handlers are registered → Electron contextBridge not exposed to renderer
4. Verify Electron contextBridge is not exposed in renderer preload scripts → Runtime bridge registration attempts fail
5. Attempt to register custom bridge handlers at runtime and verify registration fails → window.external undefined or non-functional
6. Test legacy bridge mechanisms (window.external, custom protocol schemes) and confirm they are disabled → Custom protocol scheme handlers do not create bridge channels
7. Verify embedded browser configuration prevents dynamic bridge creation → Configuration prevents dynamic bridge creation
8. Review application code for bridge-related APIs and confirm none are used → Application code audit shows no bridge APIs used
9. Test that web content cannot trigger native method invocation through any mechanism → Web content cannot invoke native methods
10. Verify security logs show zero bridge registration or access attempts → Security logs confirm zero bridge activity

**Pass Criteria**: No bridge registration APIs called AND runtime bridge creation blocked AND no legacy bridge mechanisms AND web-to-native invocation impossible

**Fail Criteria**: Bridge APIs called OR dynamic registration possible OR legacy bridges functional OR native invocation succeeds

**Evidence**: Source code review showing no bridge registration, runtime bridge attempt logs showing failures, WebView/browser configuration showing bridge disabled, security log analysis showing zero bridge activity, web content isolation testing

**References**:

- Android WebView JavaScript Interface Security: https://developer.android.com/reference/android/webkit/WebView#addJavascriptInterface(java.lang.Object,%20java.lang.String)
- iOS WKWebView Message Handlers: https://developer.apple.com/documentation/webkit/wkscriptmessagehandler
- Electron Context Isolation: https://www.electronjs.org/docs/latest/tutorial/context-isolation
- OWASP WebView Security: https://mas.owasp.org/MASTG/tests/android/MASVS-PLATFORM/MASTG-TEST-0028/

### Assessment: EMB-REQ-35 (Treat all content as untrusted at EMB-0)

**Reference**: EMB-REQ-35 - Embedded browser shall treat all loaded content as completely untrusted at EMB-0 capability level

**Given**: A conformant embedded browser with EMB-0 capability (no JavaScript bridge or native API exposure)

**Task**: At EMB-0, embedded browsers shall apply maximum security restrictions to all web content regardless of source origin, loading mechanism, or content type, treating even application-bundled content as potentially malicious. Trusting any content source creates privilege escalation risks where attackers who compromise trusted origins gain disproportionate access. Universal untrusted treatment with strict CSP enforcement, feature policy restrictions, and capability lockdown ensures consistent security posture across all content, preventing attackers from exploiting trust assumptions to escape isolation boundaries.

**Verification**:

1. Load content from application bundle resources and verify same security restrictions as remote content → Bundled content has same restrictions as remote content
2. Test application-bundled HTML/JS and confirm no privileged access granted → No privileged access for application resources
3. Load content from localhost and verify it receives no special treatment → Localhost receives no elevated privileges
4. Test file:// protocol content and confirm strict security policies applied → file:// content strictly restricted
5. Verify Content Security Policy enforced uniformly for all content sources → CSP applied uniformly to all sources
6. Test that bundled content cannot access host APIs unavailable to remote content → Host APIs equally inaccessible from all origins
7. Verify feature policy restrictions apply equally to all origins → Feature policies enforced consistently
8. Load same content from different sources (bundle, localhost, remote) and verify identical API availability → API availability identical across content sources
9. Test that no "trusted origin" configuration grants elevated privileges at EMB-0 → No trusted origin exceptions at EMB-0
10. Verify permission prompts (if any) appear for all content regardless of source → Permission requirements uniform across origins

**Pass Criteria**: All content sources treated identically AND no privileged access for bundled content AND CSP enforced uniformly AND no trusted origin exceptions

**Fail Criteria**: Bundled content has elevated privileges OR localhost trusted OR file:// bypasses restrictions OR trusted origins exist

**Evidence**: Content source comparison testing showing identical restrictions, CSP policy verification across sources, API availability enumeration by source, bundled content security analysis, trusted origin configuration audit

**References**:

- Android WebView Local Content Security: https://developer.android.com/develop/ui/views/layout/webapps/webview#local-content
- Content Security Policy: https://www.w3.org/TR/CSP3/
- Feature Policy: https://www.w3.org/TR/permissions-policy-1/
- OWASP WebView Best Practices: https://mas.owasp.org/MASTG/tests/android/MASVS-PLATFORM/MASTG-TEST-0028/

### Assessment: EMB-REQ-36 (Allowlist-only bridge API access at EMB-1)

**Reference**: EMB-REQ-36 - Only explicitly allowlisted APIs shall be accessible from web content at EMB-1 capability level

**Given**: A conformant embedded browser with EMB-1 capability (limited JavaScript bridge with explicit allowlist)

**Task**: This assessment verifies that JavaScript bridge implementations use explicit allowlisting to expose only pre-approved, security-reviewed APIs to web content, with runtime enforcement that blocks reflection-based attacks, dynamic invocation exploits, and unintended API exposure. The assessment confirms that bridge objects are immutable from web context, reflection APIs either show only allowlisted methods or are blocked entirely, and comprehensive API inventory documentation exists to prevent undocumented API access and host compromise.

**Verification**:

1. Review JavaScript bridge configuration and document complete allowlist of exposed APIs → Allowlisted APIs documented comprehensively
2. Attempt to invoke API methods not in the allowlist and verify calls are blocked with errors → Non-allowlisted method calls blocked with errors
3. Use reflection APIs in JavaScript to enumerate bridge object methods → Reflection shows only allowlisted methods or is blocked
4. Verify reflection returns only allowlisted methods (or reflection is blocked entirely) → Dynamic invocation limited to allowlist
5. Test dynamic invocation (bridge[methodName]()) and confirm only allowlisted methods callable → Prototype chain not exploitable for API discovery
6. Attempt to access bridge object prototype and verify it's not exploitable for additional access → Method name matching is strict
7. Test method name variations (case changes, encoding) and verify strict matching enforced → Bridge object immutable from web context
8. Attempt to add methods to bridge object at runtime and verify it's immutable → API additions require native code changes
9. Test that bridge API additions require host application code changes and cannot be made from web content → No undocumented APIs accessible
10. Verify documentation and implementation match (no undocumented APIs accessible) → Security review documentation exists for all allowlisted APIs

**Pass Criteria**: Only allowlisted APIs accessible AND reflection blocked or limited AND dynamic invocation restricted AND bridge immutable from web

**Fail Criteria**: Non-allowlisted APIs accessible OR reflection exposes unapproved methods OR dynamic invocation bypasses allowlist OR bridge mutable

**Evidence**: Bridge configuration showing explicit allowlist, reflection API output, method invocation logs showing blocked calls, immutability testing results, security review documentation for allowlisted APIs

**References**:

- OWASP API Security: https://owasp.org/www-project-api-security/
- Principle of Least Privilege: https://csrc.nist.gov/glossary/term/least_privilege
- Android WebView Interface Security: https://developer.android.com/reference/android/webkit/WebView#addJavascriptInterface(java.lang.Object,%20java.lang.String)
- Secure JavaScript Bridge Design: https://www.electronjs.org/docs/latest/tutorial/context-isolation

### Assessment: EMB-REQ-37 (Minimal and documented bridge API allowlist at EMB-1)

**Reference**: EMB-REQ-37 - Bridge API allowlist shall be minimal and documented at EMB-1 capability level

**Given**: A conformant embedded browser with EMB-1 capability (limited JavaScript bridge with explicit allowlist)

**Task**: JavaScript bridge security requires minimizing exposed API surface to reduce attack vectors, limit exploit potential, and simplify security review. Each exposed API creates opportunities for parameter injection, logic bugs, race conditions, and privilege escalation. Comprehensive documentation with security implications, threat models, input constraints, and usage examples enables security assessment, developer guidance, and audit compliance. Minimal API surface with complete documentation balances functionality needs with security risk management.

**Verification**:

1. Review complete bridge API allowlist and count exposed methods/functions → Complete API inventory documented
2. For each exposed API, verify security documentation exists explaining: purpose, parameters, return values, security implications, threat model → Each API has security documentation
3. Verify exposed APIs represent minimum necessary for application functionality → Security docs include threat models
4. Review application code and confirm all exposed bridge APIs are actually used → API surface justified as minimal
5. Identify any exposed APIs that are unused and flag for removal → No unused APIs exposed
6. Verify documentation includes input validation requirements for each API → Input validation requirements documented
7. Test that developers can understand API security implications from documentation alone → Security implications clearly explained
8. Verify threat model documentation covers potential attack vectors for each API → Attack vectors identified per API
9. Confirm documentation includes safe usage examples and anti-patterns to avoid → Safe usage examples provided
10. Verify security review sign-off exists for the API surface → Security review approval documented

**Pass Criteria**: API surface minimal and justified AND complete security documentation AND threat models per API AND security review approved

**Fail Criteria**: Excessive API surface OR missing documentation OR no threat models OR unused APIs exposed OR no security review

**Evidence**: Bridge API inventory with justifications, security documentation for each API, threat model documents, usage analysis showing API necessity, security review approval records

**References**:

- Attack Surface Reduction: https://csrc.nist.gov/glossary/term/attack_surface
- Threat Modeling: https://owasp.org/www-community/Threat_Modeling
- API Documentation Best Practices: https://swagger.io/specification/
- OWASP API Security: https://owasp.org/www-project-api-security/

### Assessment: EMB-REQ-38 (Bidirectional bridge security controls at EMB-2)

**Reference**: EMB-REQ-38 - Bidirectional bridge calls shall maintain same security controls in both directions at EMB-2 capability level

**Given**: A conformant embedded browser with EMB-2 capability (extended JavaScript bridge with bidirectional communication)

**Task**: Bidirectional JavaScript bridges enable both web-to-native and native-to-web communication, creating dual attack surfaces where malicious web content can exploit native-to-web callbacks and compromised native code can exploit web-to-native handlers. Asymmetric security controls create vulnerabilities where attackers bypass strict web-to-native validation by exploiting weaker native-to-web callback validation. Symmetric security enforcement with identical validation, logging, rate limiting, and permission checks in both directions prevents directional exploitation and maintains consistent security posture.

**Verification**:

1. Document all bidirectional bridge APIs (web-to-native calls and native-to-web callbacks) → Bidirectional APIs fully documented
2. Test input validation on web-to-native calls and document validation rules → Web-to-native calls validated comprehensively
3. Test input validation on native-to-web callbacks and verify identical validation strictness → Native-to-web callbacks equally validated
4. Compare validation, sanitization, and type checking between directions → Validation rules identical in strictness
5. Verify logging is comprehensive for both web-to-native and native-to-web communications → Logging comprehensive for both directions
6. Test rate limiting applies equally to both communication directions → Rate limiting symmetric
7. Verify permission checks enforced symmetrically → Permission checks enforced both ways
8. Attempt to bypass web-to-native validation by exploiting native-to-web callback path → Callback path cannot bypass validation
9. Test that callbacks cannot be used to inject unvalidated data into web context → Callbacks do not inject unvalidated data
10. Verify security audit events generated for both communication directions → Audit events generated for all communications

**Pass Criteria**: Validation symmetric across directions AND logging comprehensive for both AND rate limiting equal AND no bypass via callback path

**Fail Criteria**: Asymmetric validation OR logging gaps in one direction OR rate limiting inconsistent OR callback path bypasses controls

**Evidence**: Bidirectional API documentation, validation rule comparison, logging configuration showing symmetry, rate limiting policy analysis, bypass attempt test results, security audit logs

**References**:

- Secure IPC Design: https://chromium.googlesource.com/chromium/src/+/master/docs/security/mojo.md
- Bidirectional Communication Security: https://www.electronjs.org/docs/latest/tutorial/message-ports
- Input Validation: https://cheatsheetseries.owasp.org/cheatsheets/Input_Validation_Cheat_Sheet.html
- Defense in Depth: https://csrc.nist.gov/glossary/term/defense_in_depth

### Assessment: EMB-REQ-39 (Web content callback handler validation at EMB-2)

**Reference**: EMB-REQ-39 - Web content callback handlers shall be validated before invocation at EMB-2 capability level

**Given**: A conformant embedded browser with EMB-2 capability (extended JavaScript bridge with bidirectional communication)

**Task**: Native-to-web callbacks invoke JavaScript functions provided by web content, creating code injection and XSS risks if callbacks execute attacker-controlled functions or pass unvalidated data. Without strict validation, malicious web content registers callback handlers that exploit native invocation context, inject payloads through callback parameters, or leverage privileged execution timing. Handler validation with type checking, origin verification, parameter sanitization, and safe invocation patterns prevents callback-based attacks while enabling legitimate bidirectional communication.

**Verification**:

1. Register web content callback handler with JavaScript bridge → Callback existence validated before invocation
2. Trigger native-to-web callback from host application → Non-function callbacks rejected or handled safely
3. Verify native code validates callback handler exists and is a function before invocation → Callback parameters validated on native side
4. Test registering non-function callback and verify native code rejects or handles safely → Type checking enforced for complex objects
5. Verify callback parameters are validated and sanitized on native side before passing to web → Callbacks cannot access privileged state
6. Test passing complex objects through callbacks and confirm type checking enforced → Error handling prevents stack trace exposure
7. Attempt to register callback that accesses privileged global state and verify isolation maintained → Callbacks execute in restricted context
8. Test callback error handling and confirm errors don't expose native stack traces → Origin verification performed before invocation
9. Verify callbacks execute in restricted context without elevated privileges → Callback invocation logged for audit
10. Test that callback invocation includes origin verification → Malicious callbacks detected and blocked

**Pass Criteria**: Callbacks validated before invocation AND parameters sanitized AND error handling safe AND origin verification performed

**Fail Criteria**: Callbacks invoked without validation OR parameters unsanitized OR errors expose details OR no origin verification

**Evidence**: Callback registration and invocation code review, parameter validation testing, error handling analysis, origin verification logs, malicious callback detection results

**References**:

- Callback Security: https://www.electronjs.org/docs/latest/tutorial/security#17-validate-the-options-of-the-webcontents-opendevtools-call
- XSS Prevention: https://cheatsheetseries.owasp.org/cheatsheets/Cross_Site_Scripting_Prevention_Cheat_Sheet.html
- Safe JavaScript Invocation: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function/call
- Input Validation: https://cheatsheetseries.owasp.org/cheatsheets/Input_Validation_Cheat_Sheet.html

### Assessment: EMB-REQ-40 (Bridge message queuing with integrity protection at EMB-2)

**Reference**: EMB-REQ-40 - Bridge shall implement message queuing with integrity protection at EMB-2 capability level

**Given**: A conformant embedded browser with EMB-2 capability (extended JavaScript bridge with bidirectional communication)

**Task**: Asynchronous JavaScript bridge communication requires message queuing to decouple sender and receiver timing, but queues create attack surfaces for message tampering, injection, reordering, and replay attacks. Without integrity protection, attackers intercept queued messages to modify parameters, inject malicious messages, reorder operations to cause logic bugs, or replay messages to duplicate actions. Authenticated message queuing with sequence numbers, cryptographic MACs, and queue integrity verification prevents message manipulation while enabling reliable asynchronous communication.

**Verification**:

1. Trigger asynchronous JavaScript bridge communication requiring message queuing → Messages include sequence numbers or timestamps
2. Verify messages include sequence numbers or timestamps for ordering → Tampering detected through integrity checks
3. Attempt to tamper with queued message content and verify integrity check detects modification → Injected messages rejected due to authentication failure
4. Test message injection into queue and verify authentication prevents acceptance → Reordering detected and handled safely
5. Attempt to reorder messages in queue and verify sequence validation detects anomaly → Replay attacks prevented by sequence/nonce validation
6. Test message replay attack and verify sequence/nonce checking prevents duplicate processing → Cryptographic integrity protection used (MAC/signature)
7. Verify queue implementation uses cryptographic integrity protection (MAC, signature) → Queue overflow handled securely
8. Test queue overflow scenarios and verify graceful degradation without security compromise → Queue not manipulable by web content
9. Verify message queue is not accessible to web content for direct manipulation → Integrity failures logged as security events
10. Test that queue integrity failures trigger security events and logging → Queue implementation resists race conditions

**Pass Criteria**: Messages integrity protected AND sequence validation enforced AND tampering detected AND replay prevention implemented

**Fail Criteria**: No integrity protection OR sequence validation absent OR tampering undetected OR replay attacks succeed

**Evidence**: Message format documentation showing integrity fields, tampering test results, injection attempt logs, replay attack prevention verification, queue implementation security review

**References**:

- Message Queue Security: https://www.rabbitmq.com/security.html
- HMAC Integrity Protection: https://csrc.nist.gov/projects/hash-functions
- Replay Attack Prevention: https://cheatsheetseries.owasp.org/cheatsheets/Cryptographic_Storage_Cheat_Sheet.html
- Secure IPC: https://chromium.googlesource.com/chromium/src/+/master/docs/security/mojo.md

### Assessment: EMB-REQ-41 (Bridge traffic anomaly monitoring at EMB-2)

**Reference**: EMB-REQ-41 - Host shall monitor bridge traffic for anomalies at EMB-2 capability level

**Given**: A conformant embedded browser with EMB-2 capability (extended JavaScript bridge with bidirectional communication)

**Task**: JavaScript bridge traffic exhibits predictable patterns during normal application usage, enabling anomaly detection to identify attacks, compromised content, or exploited vulnerabilities. Monitoring for rate anomalies, suspicious method sequences, unusual parameters, or exploit patterns enables early attack detection and incident response. Without traffic monitoring, attackers exploit bridges repeatedly, probe for vulnerabilities, or exfiltrate data without detection. Real-time anomaly detection with baseline profiling, statistical analysis, and automated alerting prevents prolonged bridge exploitation.

**Verification**:

1. Establish baseline bridge traffic profile during normal application usage → Baseline traffic profile established
2. Configure anomaly detection with thresholds for: message rate, method frequency, parameter patterns, error rates → Anomaly detection thresholds configured
3. Trigger normal bridge usage and verify no false positive alerts → Normal usage generates no false positives
4. Simulate attack scenarios: rapid API calls exceeding rate limits, unusual method combinations, malformed parameters → Attack scenarios detected reliably
5. Verify anomaly detection system identifies and alerts on attack traffic → Alerts include investigation context
6. Test that alerts include sufficient context for investigation (origin, methods called, parameters, timing) → SIEM integration functional
7. Verify anomaly detection integrates with application security monitoring/SIEM → Automated responses implemented
8. Test automated responses to anomalies (throttling, blocking, enhanced logging) → Baseline adapts to usage changes
9. Verify baseline profiles updated automatically to reflect legitimate usage changes → Monitoring overhead acceptable
10. Test that monitoring performance overhead is acceptable → Security team receives actionable alerts

**Pass Criteria**: Anomaly detection functional AND attack scenarios detected AND false positives minimal AND automated alerting works

**Fail Criteria**: No anomaly detection OR attacks undetected OR excessive false positives OR no alerting integration

**Evidence**: Baseline traffic profile documentation, anomaly detection configuration, attack simulation results showing detection, alert samples, SIEM integration logs, performance impact analysis

**References**:

- Security Monitoring: https://www.sans.org/white-papers/36472/
- SIEM Integration: https://owasp.org/www-community/Log_Injection
- Behavioral Analysis: https://csrc.nist.gov/publications/detail/sp/800-94/final

### Assessment: EMB-REQ-42 (Enterprise bridge API policy configuration at EMB-2)

**Reference**: EMB-REQ-42 - Enterprise administrators shall be able to configure bridge API policies at EMB-2 capability level

**Given**: A conformant embedded browser with EMB-2 capability supporting enterprise policy management

**Task**: Enterprise deployments require centralized control over JavaScript bridge capabilities to enforce organizational security standards, prevent data exfiltration, comply with regulations, and manage risk. Without policy controls, users or developers expose sensitive APIs that violate corporate security policies, grant excessive privileges to web content, or enable unauthorized native functionality. Enterprise policy integration with API allowlist management, permission restrictions, and audit requirements enables IT governance over bridge security posture.

**Verification**:

1. Access enterprise policy configuration interface (MDM, configuration profile, policy file) → Enterprise policy interface accessible to IT administrators
2. Configure policy to restrict bridge API allowlist to specific approved methods → API allowlist restrictions enforceable via policy
3. Deploy policy to application and verify restricted methods are inaccessible to web content → Restricted APIs blocked with clear errors
4. Test that web content attempting to access policy-blocked APIs receives clear errors → Audit logging requirement enforceable
5. Configure policy requiring audit logging for all bridge communications → Logging cannot be disabled when policy requires it
6. Verify policy-mandated logging cannot be disabled by application developers → Rate limits configurable and enforced
7. Configure policy setting maximum rate limits for bridge API calls → Bridge functionality can be disabled by policy
8. Test that rate limits are enforced per policy configuration → Policy changes effective without recompilation
9. Verify policy can completely disable bridge functionality if required → Policy violations logged to enterprise monitoring
10. Test that policy changes take effect without requiring application recompilation → Administrators can audit current bridge configuration

**Pass Criteria**: Enterprise policies enforced AND API restrictions work AND logging mandatory when required AND policy updates dynamic

**Fail Criteria**: Policies not enforced OR API restrictions bypassed OR logging can be disabled OR policy updates require recompilation

**Evidence**: Enterprise policy configuration documentation, API restriction enforcement testing, audit logging verification, rate limit enforcement analysis, policy update procedures, compliance reports

**References**:

- Enterprise Mobile Management: https://developer.apple.com/documentation/devicemanagement
- Android Enterprise: https://developers.google.com/android/work
- Mobile Application Management: https://www.microsoft.com/en-us/security/business/threat-protection/mobile-application-management
- Security Policy Enforcement: https://csrc.nist.gov/glossary/term/policy_enforcement

### Assessment: EMB-REQ-43 (Core security boundaries preserved at EMB-3)

**Reference**: EMB-REQ-43 - Full integration shall not bypass core security boundaries at EMB-3 capability level

**Given**: A conformant embedded browser with EMB-3 capability (full integration with native capabilities)

**Task**: Even with extensive native integration at EMB-3, fundamental security boundaries should remain intact to prevent complete application compromise. Core boundaries include: renderer process isolation from host process memory, web content sandboxing, origin-based security policies, and cryptographic key isolation. Bypassing these boundaries through bridge integration enables attackers who compromise web content to escalate directly to host privileges, access other origins' data, or extract cryptographic material. Maintaining core boundaries while enabling integration preserves defense-in-depth and limits exploit impact.

**Verification**:

1. Verify renderer process isolation maintained even with extensive bridge integration → Renderer process isolation intact
2. Test that web content cannot access host process memory directly through bridge APIs → Host process memory inaccessible from web content
3. Verify origin-based security model enforced (same-origin policy, CORS) despite native integration → Same-origin policy enforced
4. Test that bridge APIs cannot bypass origin restrictions to access other origins' data → Bridge cannot bypass origin restrictions
5. Verify cryptographic keys and credentials remain isolated from web content → Cryptographic keys isolated
6. Test that bridge cannot expose raw file system paths or handles that bypass sandbox → File system sandbox boundaries maintained
7. Verify CSP and other content security policies remain enforced → CSP enforced for all content
8. Test that full integration does not disable process-level sandboxing → Process sandboxing active
9. Verify network security policies (certificate validation, HSTS) cannot be bypassed through bridge → Network security policies cannot be bypassed
10. Test that bridge APIs cannot grant web content ability to load arbitrary native code → Native code loading restricted

**Pass Criteria**: Process isolation maintained AND origin policies enforced AND crypto keys isolated AND sandbox boundaries intact

**Fail Criteria**: Process isolation bypassed OR origin policies circumvented OR keys accessible OR sandbox escaped

**Evidence**: Process isolation testing, origin policy enforcement verification, cryptographic key isolation audit, sandbox boundary testing, security architecture review

**References**:

- Browser Security Architecture: https://www.chromium.org/developers/design-documents/multi-process-architecture/
- Process Isolation: https://www.chromium.org/developers/design-documents/site-isolation/
- Same-Origin Policy: https://developer.mozilla.org/en-US/docs/Web/Security/Same-origin_policy
- Defense in Depth: https://csrc.nist.gov/glossary/term/defense_in_depth

### Assessment: EMB-REQ-44 (User awareness of native capabilities at EMB-3)

**Reference**: EMB-REQ-44 - User shall be informed of all native capabilities granted to web content at EMB-3 capability level

**Given**: A conformant embedded browser with EMB-3 capability (full integration with native capabilities)

**Task**: Users should understand which native capabilities are accessible to web content to make informed security and privacy decisions. Without transparency, malicious web content silently accesses camera, location, contacts, filesystem, or other sensitive native APIs through bridge integration, enabling surveillance, data theft, and privacy violations. Clear capability disclosure through permission prompts, settings interfaces, and usage indicators empowers users to grant appropriate access, revoke excessive permissions, and detect unauthorized native API usage.

**Verification**:

1. Identify all native capabilities accessible through JavaScript bridge at EMB-3 → Permission prompts appear for sensitive capabilities
2. Verify permission prompts appear when web content first requests sensitive native capabilities → Prompts clearly explain native access
3. Test that prompts clearly explain what native access is being granted (e.g., "camera access", "contact list access") → Settings show all granted capabilities
4. Access application settings and verify list of granted native capabilities is displayed → Capabilities explained in user-friendly terms
5. Verify settings interface explains each capability in user-friendly language → Web origins with capabilities visible
6. Test that users can see which web origins have been granted each capability → Active usage indicators function
7. Verify active capability usage indicators appear (e.g., camera indicator when camera accessed) → Indicators show which content is active
8. Test that users can click indicators to see which web content is using capabilities → Grants persist across restarts
9. Verify capability grants are persistent and visible across application restarts → Documentation explains permissions model
10. Test that application documentation explains bridge capabilities and permissions model → Users can make informed decisions

**Pass Criteria**: Permission prompts clear AND settings show all capabilities AND usage indicators present AND documentation complete

**Fail Criteria**: No permission prompts OR settings incomplete OR no usage indicators OR missing documentation

**Evidence**: Permission prompt screenshots, settings interface documentation, usage indicator demonstration, capability grant persistence testing, user documentation review

**References**:

- Permission UX Best Practices: https://web.dev/permission-ux/
- Mobile Permission Models: https://developer.android.com/guide/topics/permissions/overview
- iOS Permission Model: https://developer.apple.com/design/human-interface-guidelines/privacy
- User Privacy Controls: https://www.w3.org/TR/privacy-controls/

### Assessment: EMB-REQ-45 (User permission review and revocation at EMB-3)

**Reference**: EMB-REQ-45 - User shall be able to review and revoke native API access at EMB-3 capability level

**Given**: A conformant embedded browser with EMB-3 capability (full integration with native capabilities)

**Task**: Users should have granular control to review all granted native API permissions and revoke access to manage security posture and respond to threats. Without revocation capabilities, users cannot remove access from compromised web content, recover from accidental over-privileged grants, or adjust permissions as trust relationships change. Permission management interface with per-origin, per-capability revocation, immediate enforcement, and usage history enables user control, security hygiene, and privacy protection.

**Verification**:

1. Grant multiple native capabilities (camera, location, contacts, storage) to web content through bridge → All granted capabilities visible in settings
2. Access application permission management settings interface → Per-capability revocation functional
3. Verify interface lists all granted capabilities organized by web origin and capability type → Revocation takes effect immediately
4. Select individual capability and revoke it through settings → Web content receives clear errors after revocation
5. Immediately test that web content can no longer access revoked capability → Bulk revocation available per origin
6. Verify web content receives clear error when attempting to use revoked capability → Usage history displayed for capabilities
7. Test bulk revocation of all capabilities for a specific web origin → Revocations persist across restarts
8. Verify permission management shows usage history (when capabilities were last accessed) → Re-granting requires new user consent
9. Test that revocations persist across application restarts → No hidden or unrevocable capabilities exist
10. Verify revoked permissions require new user consent if web content requests again → Interface is user-friendly and accessible

**Pass Criteria**: All capabilities reviewable AND revocation immediate AND per-capability control AND usage history visible

**Fail Criteria**: Capabilities hidden OR revocation delayed OR only bulk revocation OR no usage history

**Evidence**: Permission management UI screenshots, revocation testing showing immediate effect, usage history exports, persistence verification, hidden capability audit

**References**:

- Android Permission Management: https://developer.android.com/training/permissions/requesting
- iOS Permission Management: https://developer.apple.com/documentation/uikit/protecting_the_user_s_privacy
- Permission Management UX: https://web.dev/permission-ux/
- User Privacy Controls: https://www.w3.org/TR/privacy-controls/

### Assessment: EMB-REQ-46 (Native integration audit documentation at EMB-3)

**Reference**: EMB-REQ-46 - All native integrations shall be documented and auditable at EMB-3 capability level

**Given**: A conformant embedded browser with EMB-3 capability (full integration with native capabilities)

**Task**: Extensive native integration at EMB-3 creates complex attack surfaces requiring comprehensive documentation for security review, vulnerability assessment, compliance auditing, and risk management. Without documentation of exposed native APIs, security boundaries relaxed, and integration patterns used, security teams cannot assess risk, auditors cannot verify compliance, and incident responders cannot investigate breaches effectively. Complete architecture documentation with threat models, security reviews, API inventories, and integration justifications enables informed security governance and compliance verification.

**Verification**:

1. Review application security documentation for native integration architecture → Native integration architecture documented
2. Verify complete inventory of all native APIs exposed through JavaScript bridge → Complete API inventory available
3. Confirm each exposed API has security documentation including: purpose, parameters, threat model, mitigations → Per-API security documentation exists
4. Review threat model documentation covering bridge integration attack vectors → Threat models cover bridge integration
5. Verify security review records exist for native integration design and implementation → Security review records available
6. Test that runtime diagnostics expose current bridge configuration for auditing → Runtime diagnostics expose configuration
7. Verify enterprise administrators can access detailed integration documentation → Enterprise documentation comprehensive
8. Review code comments and confirm they explain security-critical integration points → Code comments explain security-critical sections
9. Verify integration patterns and security controls are documented with examples → Integration patterns documented with examples
10. Test that documentation is maintained and updated with application versions → Documentation current with application version

**Pass Criteria**: Complete API inventory AND per-API security docs AND threat models AND security review records

**Fail Criteria**: Incomplete inventory OR missing security docs OR no threat models OR no security reviews

**Evidence**: Security documentation collection, API inventory with security annotations, threat model documents, security review approval records, runtime configuration dumps

**References**:

- Secure Development Lifecycle: https://www.microsoft.com/en-us/securityengineering/sdl/
- Threat Modeling: https://owasp.org/www-community/Threat_Modeling
- Security Documentation: https://cheatsheetseries.owasp.org/cheatsheets/Security_Documentation_Checklist.html
- API Security: https://owasp.org/www-project-api-security/

### Assessment: EMB-REQ-47 (Enterprise native integration restrictions at EMB-3)

**Reference**: EMB-REQ-47 - Enterprise policies shall be able to restrict native integration scope at EMB-3 capability level

**Given**: A conformant embedded browser with EMB-3 capability supporting enterprise policy management

**Task**: Enterprise environments require centralized control to restrict native integration capabilities that pose unacceptable risk to organizational security, intellectual property, or compliance. Without policy controls, users or developers expose unrestricted camera access, filesystem operations, contact data, or other sensitive capabilities that enable data exfiltration or violate corporate policies. Enterprise policy integration with capability blocking, API allowlisting, and permission restrictions enables IT security governance over native integration posture.

**Verification**:

1. Access enterprise policy configuration interface (MDM, configuration profile, policy file) → Enterprise policy interface accessible
2. Configure policy to block specific native capabilities organization-wide (e.g., camera, contact access) → Capability blocking enforceable
3. Deploy policy and verify blocked capabilities are inaccessible to all web content → Blocked capabilities inaccessible with clear errors
4. Test that web content attempting to access policy-blocked capabilities receives clear policy violation errors → Origin allowlisting functional for sensitive APIs
5. Configure policy to allowlist specific web origins for sensitive capabilities → Non-allowlisted origins denied access
6. Test that only allowlisted origins can access sensitive capabilities → Maximum permission scope enforceable
7. Configure policy to restrict maximum permission scope for all web content → Users cannot exceed policy limits
8. Verify users cannot grant permissions exceeding policy-defined maximum → Bridge can be fully disabled by policy
9. Test that policy can completely disable JavaScript bridge if required → Policy violations logged to enterprise systems
10. Verify policy violations are logged to enterprise security monitoring → Administrators can audit current integration configuration

**Pass Criteria**: Capability blocking enforced AND origin allowlisting works AND permission scope limits effective AND violations logged

**Fail Criteria**: Policies not enforced OR blocking bypassed OR allowlists ignored OR no violation logging

**Evidence**: Enterprise policy configuration documentation, capability blocking testing, origin allowlist verification, permission scope limit testing, policy violation logs

**References**:

- Enterprise Mobile Management: https://developer.apple.com/documentation/devicemanagement
- Android Enterprise Policies: https://developers.google.com/android/work/requirements
- Mobile Application Management: https://www.microsoft.com/en-us/security/business/threat-protection/mobile-application-management
- Enterprise Security Governance: https://csrc.nist.gov/glossary/term/security_governance


### Assessment: EMB-REQ-48 (No privileged content origin access)

**Reference**: EMB-REQ-48 - No content origin shall have privileged access at EMB-0 capability level

**Given**: A conformant embedded browser with EMB-0 capability (complete sandboxing)

**Task**: This assessment verifies that the embedded browser treats all content origins equally without privileged access, preventing scenarios where certain trusted origins bypass security controls. Without this requirement, developers create dangerous exceptions for "trusted" internal content that attackers exploit through DNS hijacking, content injection, or social engineering to gain elevated access.

**Verification**:

1. Load content from multiple different origins (https, file://, data:, blob:) → All content types load successfully
2. Verify each origin is subject to same-origin policy restrictions → SOP applies equally to all origins
3. Test that no origin can access other origins' storage (localStorage, cookies, IndexedDB) → Cross-origin storage access blocked
4. Confirm no origin can access host application objects or native APIs → Native API access blocked for all origins
5. Test that no origin receives elevated CSP policies or security exceptions → CSP applies uniformly
6. Verify no origin can bypass context isolation or sandboxing → Isolation applies to all content
7. Test that file:// URLs have same restrictions as remote content → file:// URLs properly restricted
8. Confirm data: and blob: URLs are sandboxed appropriately → data:/blob: URLs sandboxed
9. Verify no origin allowlist or trust configuration exists → No trust configuration present
10. Test that all content receives identical security boundary enforcement → Uniform security enforcement verified

**Pass Criteria**: All origins treated identically AND no privileged access granted AND no trust exceptions exist AND uniform security enforcement

**Fail Criteria**: Any origin receives privileged access OR trust allowlists exist OR security bypasses present OR inconsistent enforcement

**Evidence**: Multi-origin loading tests, SOP verification, storage isolation testing, native API access attempts, CSP policy analysis, context isolation verification

**References**:

- Same-Origin Policy: https://developer.mozilla.org/en-US/docs/Web/Security/Same-origin_policy
- Content Security Policy: https://www.w3.org/TR/CSP3/
- OWASP: Origin-Based Attacks: https://owasp.org/www-community/attacks/


### Assessment: EMB-REQ-49 (Strict CSP enforcement without exceptions)

**Reference**: EMB-REQ-49 - All CSP policies shall be strictly enforced without exceptions at EMB-0 capability level

**Given**: A conformant embedded browser with EMB-0 capability

**Task**: This assessment verifies that Content Security Policy enforcement has no exceptions, bypass mechanisms, or relaxation modes that attackers could exploit. Strict CSP enforcement prevents inline script execution, unsafe evaluations, and unauthorized resource loading that enable XSS and code injection attacks.

**Verification**:

1. Configure strict CSP policy (default-src 'none'; script-src 'strict-dynamic') → CSP policy configured
2. Attempt to execute inline JavaScript in HTML → Inline scripts blocked
3. Test eval(), Function(), and similar dynamic code execution → Dynamic code execution blocked
4. Try to load scripts from non-allowlisted origins → Unauthorized script loading blocked
5. Verify CSP violations are reported (if reporting configured) → CSP violations reported correctly
6. Test that no meta tag or header can weaken configured CSP → CSP cannot be weakened at runtime
7. Attempt to bypass CSP using data: URLs, javascript: URLs → CSP bypass attempts blocked
8. Verify unsafe-inline and unsafe-eval directives are rejected or warned → Unsafe directives rejected
9. Test that CSP applies to all frames and embedded content → CSP applies to all contexts
10. Confirm no developer mode or debug flag relaxes CSP enforcement → No CSP relaxation modes exist

**Pass Criteria**: All CSP violations blocked AND no runtime weakening possible AND no bypass mechanisms AND violations properly reported

**Fail Criteria**: CSP bypasses successful OR runtime weakening possible OR debug modes relax enforcement OR violations unreported

**Evidence**: CSP configuration documentation, inline script blocking tests, eval() attempt logs, CSP bypass testing results, violation report verification

**References**:

- CSP Level 3 Specification: https://www.w3.org/TR/CSP3/
- CSP Evaluator: https://csp-evaluator.withgoogle.com/
- Strict CSP Guide: https://web.dev/strict-csp/


### Assessment: EMB-REQ-50 (Trust allowlist immutability)

**Reference**: EMB-REQ-50 - Trust allowlist configuration shall be immutable after WebView initialization at EMB-1 capability level

**Given**: A conformant embedded browser with EMB-1 capability (selective trusted content)

**Task**: This assessment verifies that trust allowlist configuration cannot be modified after browser initialization, preventing runtime tampering where attackers inject configuration changes to add malicious origins to trusted allowlists. Immutability ensures that only deployment-time configuration controls trust relationships.

**Verification**:

1. Initialize embedded browser with trust allowlist configuration → Browser initialized with trust allowlist
2. Verify allowlisted origins are correctly trusted at initialization → Trust allowlist active
3. Attempt to add new origin to trust allowlist at runtime via API → Runtime modification blocked
4. Test JavaScript injection attempts to modify trust configuration → Configuration injection blocked
5. Verify configuration file/database cannot be modified while browser running → Configuration storage protected
6. Test that browser restart is required for configuration changes → Changes require restart
7. Attempt to bypass immutability using reflection or native debugging → Reflection attacks blocked
8. Verify allowlist stored in read-only memory region if possible → Memory protection verified
9. Test that even privileged/admin APIs cannot modify running allowlist → Admin APIs cannot modify running config
10. Confirm configuration integrity is verified on browser restart → Configuration integrity checked on restart

**Pass Criteria**: Configuration immutable at runtime AND API modifications blocked AND bypass attempts fail AND restart required for changes

**Fail Criteria**: Runtime modification possible OR APIs allow changes OR bypass successful OR no restart required

**Evidence**: Initialization configuration, runtime modification attempts, API security testing, memory protection analysis, restart behavior verification

**References**:

- Immutable Configuration Patterns: https://csrc.nist.gov/glossary/term/immutable
- Android WebView Security: https://developer.android.com/training/articles/security-config
- iOS WKWebView: https://developer.apple.com/documentation/webkit/wkwebview


### Assessment: EMB-REQ-51 (All EMB-1 requirements implemented)

**Reference**: EMB-REQ-51 - All EMB-1 requirements shall be implemented at EMB-2 capability level

**Given**: A conformant embedded browser claiming EMB-2 capability

**Task**: This assessment verifies that EMB-2 capability level properly includes all EMB-1 baseline requirements for selective trusted content, ensuring that advancing to more sophisticated trust models does not bypass foundational security controls. This prevents capability level confusion attacks where EMB-2 features are used without EMB-1 protections.

**Verification**:

1. Execute all EMB-REQ-17 verification steps (Certificate validation) → EMB-REQ-17 passes
2. Execute all EMB-REQ-18 verification steps (Pinning for allowlisted origins) → EMB-REQ-18 passes
3. Execute all EMB-REQ-19 verification steps (SRI for external resources) → EMB-REQ-19 passes
4. Execute all EMB-REQ-20 verification steps (Pin update mechanism) → EMB-REQ-20 passes
5. Execute all EMB-REQ-21 verification steps (Clear trust boundaries) → EMB-REQ-21 passes
6. Execute all EMB-REQ-22 verification steps (Trust decision logging) → EMB-REQ-22 passes
7. Execute all EMB-REQ-23 verification steps (Local content signature verification) → EMB-REQ-23 passes
8. Execute all EMB-REQ-24 verification steps (TLS version enforcement) → EMB-REQ-24 passes
9. Execute all EMB-REQ-50 verification steps (Allowlist immutability) → EMB-REQ-50 passes
10. Verify documentation explicitly states EMB-1 compliance maintained → EMB-1 compliance documented

**Pass Criteria**: All EMB-1 assessments pass AND no EMB-1 requirement bypassed AND documentation confirms compliance