HSTSEnforcer.setPolicy
void setPolicy(soup.hstspolicy.HSTSPolicy policy)Sets policy to hsts_enforcer.
If policy is expired, any existing HSTS policy for its host will be removed instead. If a policy existed for this host, it will be replaced. Otherwise, the new policy will be inserted. If the policy is a session policy, that is, one created with [soup.hstspolicy.HSTSPolicy.newSessionPolicy], the policy will not expire and will be enforced during the lifetime of hsts_enforcer's classSession.
Parameters
policy | the policy of the HSTS host |