Ejemplo n.º 1
0
bool SecurityOrigin::canAccessFeatureRequiringSecureOrigin(String& errorMessage) const
{
    ASSERT(m_protocol != "data");
    if (SchemeRegistry::shouldTreatURLSchemeAsSecure(m_protocol) || isLocal() || isLocalhost())
        return true;

    errorMessage = "Only secure origins are allowed. http://goo.gl/lq4gCo";
    return false;
}
Ejemplo n.º 2
0
bool SecurityOrigin::isPotentiallyTrustworthy() const
{
    ASSERT(m_protocol != "data");
    if (SchemeRegistry::shouldTreatURLSchemeAsSecure(m_protocol) || isLocal() || isLocalhost())
        return true;

    if (SecurityPolicy::isOriginWhiteListedTrustworthy(*this))
        return true;

    return false;
}
Ejemplo n.º 3
0
bool SecurityOrigin::isPotentiallyTrustworthy(String& errorMessage) const
{
    ASSERT(m_protocol != "data");
    if (SchemeRegistry::shouldTreatURLSchemeAsSecure(m_protocol) || isLocal() || isLocalhost())
        return true;

    if (SecurityPolicy::isOriginWhiteListedTrustworthy(*this))
        return true;

    errorMessage = "Only secure origins are allowed (see: https://goo.gl/Y0ZkNV).";
    return false;
}