| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2011 Google Inc. All Rights Reserved. | 2 * Copyright (C) 2011 Google Inc. All Rights Reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 25 matching lines...) Expand all Loading... |
| 36 | 36 |
| 37 class SecurityOrigin; | 37 class SecurityOrigin; |
| 38 class ContentSecurityPolicy; | 38 class ContentSecurityPolicy; |
| 39 class KURL; | 39 class KURL; |
| 40 | 40 |
| 41 class SecurityContext { | 41 class SecurityContext { |
| 42 public: | 42 public: |
| 43 // The ordering here is important: 'Upgrade' overrides 'Monitor', which over
rides 'DoNotUpgrade'. | 43 // The ordering here is important: 'Upgrade' overrides 'Monitor', which over
rides 'DoNotUpgrade'. |
| 44 enum InsecureContentPolicy { | 44 enum InsecureContentPolicy { |
| 45 InsecureContentDoNotUpgrade = 0, | 45 InsecureContentDoNotUpgrade = 0, |
| 46 InsecureContentMonitor, | |
| 47 InsecureContentUpgrade | 46 InsecureContentUpgrade |
| 48 }; | 47 }; |
| 49 | 48 |
| 50 SecurityOrigin* securityOrigin() const { return m_securityOrigin.get(); } | 49 SecurityOrigin* securityOrigin() const { return m_securityOrigin.get(); } |
| 51 ContentSecurityPolicy* contentSecurityPolicy() const { return m_contentSecur
ityPolicy.get(); } | 50 ContentSecurityPolicy* contentSecurityPolicy() const { return m_contentSecur
ityPolicy.get(); } |
| 52 | 51 |
| 53 bool isSecureTransitionTo(const KURL&) const; | 52 bool isSecureTransitionTo(const KURL&) const; |
| 54 | 53 |
| 55 // Explicitly override the security origin for this security context. | 54 // Explicitly override the security origin for this security context. |
| 56 // Note: It is dangerous to change the security origin of a script context | 55 // Note: It is dangerous to change the security origin of a script context |
| (...skipping 27 matching lines...) Expand all Loading... |
| 84 | 83 |
| 85 SandboxFlags m_sandboxFlags; | 84 SandboxFlags m_sandboxFlags; |
| 86 | 85 |
| 87 bool m_hostedInReservedIPRange; | 86 bool m_hostedInReservedIPRange; |
| 88 InsecureContentPolicy m_insecureContentPolicy; | 87 InsecureContentPolicy m_insecureContentPolicy; |
| 89 }; | 88 }; |
| 90 | 89 |
| 91 } // namespace blink | 90 } // namespace blink |
| 92 | 91 |
| 93 #endif // SecurityContext_h | 92 #endif // SecurityContext_h |
| OLD | NEW |