Class (GI Struct)

Soup-3.0SoupHSTSPolicy

HSTSPolicy implements HTTP policies, as described by RFC 6797.

domain represents the host that this policy applies to. The domain must be IDNA-canonicalized. HSTSPolicy.new and related methods will do this for you.

max_age contains the 'max-age' value from the Strict Transport Security header and indicates the time to live of this policy, in seconds.

expires will be non-null if the policy has been set by the host and hence has an expiry time. If expires is null, it indicates that the policy is a permanent session policy set by the user agent.

If include_subdomains is true, the Strict Transport Security policy must also be enforced on subdomains of domain.

Index

Constructors

Properties

$gtype: GType<HSTSPolicy>

Methods

  • Gets whether policy include its subdomains.

    Returns boolean

    true if policy includes subdomains, false otherwise.

  • Gets whether policy is expired.

    Permanent policies never expire.

    Returns boolean

    true if policy is expired, false otherwise.