| Copyright | Will Thompson and Iñaki García Etxebarria |
|---|---|
| License | LGPL-2.1 |
| Maintainer | Iñaki García Etxebarria |
| Safe Haskell | Safe-Inferred |
| Language | Haskell2010 |
GI.Soup.Objects.HSTSEnforcer
Description
No description available in the introspection data.
Synopsis
- newtype HSTSEnforcer = HSTSEnforcer (ManagedPtr HSTSEnforcer)
- class (GObject o, IsDescendantOf HSTSEnforcer o) => IsHSTSEnforcer o
- toHSTSEnforcer :: (MonadIO m, IsHSTSEnforcer o) => o -> m HSTSEnforcer
- hSTSEnforcerGetDomains :: (HasCallStack, MonadIO m, IsHSTSEnforcer a) => a -> Bool -> m [Text]
- hSTSEnforcerGetPolicies :: (HasCallStack, MonadIO m, IsHSTSEnforcer a) => a -> Bool -> m [HSTSPolicy]
- hSTSEnforcerHasValidPolicy :: (HasCallStack, MonadIO m, IsHSTSEnforcer a) => a -> Text -> m Bool
- hSTSEnforcerIsPersistent :: (HasCallStack, MonadIO m, IsHSTSEnforcer a) => a -> m Bool
- hSTSEnforcerNew :: (HasCallStack, MonadIO m) => m HSTSEnforcer
- hSTSEnforcerSetPolicy :: (HasCallStack, MonadIO m, IsHSTSEnforcer a) => a -> HSTSPolicy -> m ()
- hSTSEnforcerSetSessionPolicy :: (HasCallStack, MonadIO m, IsHSTSEnforcer a) => a -> Text -> Bool -> m ()
- type HSTSEnforcerChangedCallback = HSTSPolicy -> HSTSPolicy -> IO ()
- afterHSTSEnforcerChanged :: (IsHSTSEnforcer a, MonadIO m) => a -> ((?self :: a) => HSTSEnforcerChangedCallback) -> m SignalHandlerId
- onHSTSEnforcerChanged :: (IsHSTSEnforcer a, MonadIO m) => a -> ((?self :: a) => HSTSEnforcerChangedCallback) -> m SignalHandlerId
- type HSTSEnforcerHstsEnforcedCallback = Message -> IO ()
- afterHSTSEnforcerHstsEnforced :: (IsHSTSEnforcer a, MonadIO m) => a -> ((?self :: a) => HSTSEnforcerHstsEnforcedCallback) -> m SignalHandlerId
- onHSTSEnforcerHstsEnforced :: (IsHSTSEnforcer a, MonadIO m) => a -> ((?self :: a) => HSTSEnforcerHstsEnforcedCallback) -> m SignalHandlerId
Exported types
newtype HSTSEnforcer Source #
Memory-managed wrapper type.
Constructors
| HSTSEnforcer (ManagedPtr HSTSEnforcer) |
Instances
| Eq HSTSEnforcer Source # | |
Defined in GI.Soup.Objects.HSTSEnforcer | |
| GObject HSTSEnforcer Source # | |
Defined in GI.Soup.Objects.HSTSEnforcer | |
| ManagedPtrNewtype HSTSEnforcer Source # | |
Defined in GI.Soup.Objects.HSTSEnforcer Methods toManagedPtr :: HSTSEnforcer -> ManagedPtr HSTSEnforcer | |
| TypedObject HSTSEnforcer Source # | |
Defined in GI.Soup.Objects.HSTSEnforcer | |
| HasParentTypes HSTSEnforcer Source # | |
Defined in GI.Soup.Objects.HSTSEnforcer | |
| IsGValue (Maybe HSTSEnforcer) Source # | Convert |
Defined in GI.Soup.Objects.HSTSEnforcer Methods gvalueGType_ :: IO GType gvalueSet_ :: Ptr GValue -> Maybe HSTSEnforcer -> IO () gvalueGet_ :: Ptr GValue -> IO (Maybe HSTSEnforcer) | |
| type ParentTypes HSTSEnforcer Source # | |
Defined in GI.Soup.Objects.HSTSEnforcer | |
class (GObject o, IsDescendantOf HSTSEnforcer o) => IsHSTSEnforcer o Source #
Type class for types which can be safely cast to HSTSEnforcer, for instance with toHSTSEnforcer.
Instances
| (GObject o, IsDescendantOf HSTSEnforcer o) => IsHSTSEnforcer o Source # | |
Defined in GI.Soup.Objects.HSTSEnforcer | |
toHSTSEnforcer :: (MonadIO m, IsHSTSEnforcer o) => o -> m HSTSEnforcer Source #
Cast to HSTSEnforcer, for types for which this is known to be safe. For general casts, use castTo.
Methods
Click to display all available methods, including inherited ones
Methods
addFeature, attach, bindProperty, bindPropertyFull, detach, forceFloating, freezeNotify, getv, hasFeature, hasValidPolicy, isFloating, isPersistent, notify, notifyByPspec, ref, refSink, removeFeature, runDispose, stealData, stealQdata, thawNotify, unref, watchClosure.
Getters
getData, getDomains, getPolicies, getProperty, getQdata.
Setters
setData, setDataFull, setPolicy, setProperty, setSessionPolicy.
getDomains
hSTSEnforcerGetDomains Source #
Arguments
| :: (HasCallStack, MonadIO m, IsHSTSEnforcer a) | |
| => a |
|
| -> Bool |
|
| -> m [Text] | Returns: a newly allocated
list of domains. Use |
Gets a list of domains for which there are policies in enforcer.
Since: 2.68
getPolicies
hSTSEnforcerGetPolicies Source #
Arguments
| :: (HasCallStack, MonadIO m, IsHSTSEnforcer a) | |
| => a |
|
| -> Bool |
|
| -> m [HSTSPolicy] | Returns: a newly
allocated list of policies. Use |
Gets a list with the policies in enforcer.
Since: 2.68
hasValidPolicy
hSTSEnforcerHasValidPolicy Source #
Arguments
| :: (HasCallStack, MonadIO m, IsHSTSEnforcer a) | |
| => a |
|
| -> Text |
|
| -> m Bool | Returns: |
Gets whether hstsEnforcer has a currently valid policy for domain.
Since: 2.68
isPersistent
hSTSEnforcerIsPersistent Source #
Arguments
| :: (HasCallStack, MonadIO m, IsHSTSEnforcer a) | |
| => a |
|
| -> m Bool | Returns: |
Gets whether hstsEnforcer stores policies persistenly.
Since: 2.68
new
Arguments
| :: (HasCallStack, MonadIO m) | |
| => m HSTSEnforcer | Returns: a new |
Creates a new HSTSEnforcer. The base HSTSEnforcer class
does not support persistent storage of HSTS policies, see
HSTSEnforcerDB for that.
Since: 2.68
setPolicy
hSTSEnforcerSetPolicy Source #
Arguments
| :: (HasCallStack, MonadIO m, IsHSTSEnforcer a) | |
| => a |
|
| -> HSTSPolicy |
|
| -> m () |
Sets policy to hstsEnforcer. 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 hSTSPolicyNewSessionPolicy, the policy
will not expire and will be enforced during the lifetime of
hstsEnforcer's Session.
Since: 2.68
setSessionPolicy
hSTSEnforcerSetSessionPolicy Source #
Arguments
| :: (HasCallStack, MonadIO m, IsHSTSEnforcer a) | |
| => a |
|
| -> Text |
|
| -> Bool |
|
| -> m () |
Sets a session policy for domain. A session policy is a policy
that is permanent to the lifetime of hstsEnforcer's Session
and doesn't expire.
Since: 2.68
Signals
changed
type HSTSEnforcerChangedCallback Source #
Arguments
| = HSTSPolicy |
|
| -> HSTSPolicy |
|
| -> IO () |
Emitted when hstsEnforcer changes. If a policy has been added,
newPolicy will contain the newly-added policy and
oldPolicy will be Nothing. If a policy has been deleted,
oldPolicy will contain the to-be-deleted policy and
newPolicy will be Nothing. If a policy has been changed,
oldPolicy will contain its old value, and newPolicy its
new value.
Note that you shouldn't modify the policies from a callback to this signal.
afterHSTSEnforcerChanged :: (IsHSTSEnforcer a, MonadIO m) => a -> ((?self :: a) => HSTSEnforcerChangedCallback) -> m SignalHandlerId Source #
Connect a signal handler for the changed signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after hSTSEnforcer #changed callback
By default the object invoking the signal is not passed to the callback.
If you need to access it, you can use the implit ?self parameter.
Note that this requires activating the ImplicitParams GHC extension.
onHSTSEnforcerChanged :: (IsHSTSEnforcer a, MonadIO m) => a -> ((?self :: a) => HSTSEnforcerChangedCallback) -> m SignalHandlerId Source #
Connect a signal handler for the changed signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on hSTSEnforcer #changed callback
hstsEnforced
type HSTSEnforcerHstsEnforcedCallback Source #
Emitted when hstsEnforcer has upgraded the protocol
for message to HTTPS as a result of matching its domain with
a HSTS policy.
afterHSTSEnforcerHstsEnforced :: (IsHSTSEnforcer a, MonadIO m) => a -> ((?self :: a) => HSTSEnforcerHstsEnforcedCallback) -> m SignalHandlerId Source #
Connect a signal handler for the hstsEnforced signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after hSTSEnforcer #hstsEnforced callback
By default the object invoking the signal is not passed to the callback.
If you need to access it, you can use the implit ?self parameter.
Note that this requires activating the ImplicitParams GHC extension.
onHSTSEnforcerHstsEnforced :: (IsHSTSEnforcer a, MonadIO m) => a -> ((?self :: a) => HSTSEnforcerHstsEnforcedCallback) -> m SignalHandlerId Source #
Connect a signal handler for the hstsEnforced signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on hSTSEnforcer #hstsEnforced callback