(client-allowed-access? settings req)Inputs: [settings :- WhitelistSettings req :- RingRequest] Returns: schema/Bool
Determines if the client in the request is allowed to access the endpoint based on the client whitelist and whether authorization is required.
Inputs: [settings :- WhitelistSettings req :- RingRequest] Returns: schema/Bool Determines if the client in the request is allowed to access the endpoint based on the client whitelist and whether authorization is required.
(client-on-whitelist? settings certificate)Test if the certificate subject is on the client whitelist.
Test if the certificate subject is on the client whitelist.
(log-access-denied uri certificate)Log a message to info stating that the client is not in the access control whitelist.
Log a message to info stating that the client is not in the access control whitelist.
(wrap-with-cert-whitelist-check handler settings)Inputs: [handler :- IFn settings :- WhitelistSettings] Returns: IFn
A ring middleware that checks to make sure the client cert is in the whitelist before granting access.
Inputs: [handler :- IFn settings :- WhitelistSettings] Returns: IFn A ring middleware that checks to make sure the client cert is in the whitelist before granting access.
(wrap-with-certname-as-compiler handler name)Function that returns middleware that add X-Puppet-Compiler-Name to the response, only for the posts to the v3 catalog endpoint. Otherwise, do nothing.
Function that returns middleware that add X-Puppet-Compiler-Name to the response, only for the posts to the v3 catalog endpoint. Otherwise, do nothing.
(wrap-with-puppet-version-header handler version)Function that returns a middleware that adds an X-Puppet-Version header to the response.
Function that returns a middleware that adds an X-Puppet-Version header to the response.
(wrap-with-trapperkeeper-or-client-whitelist-authorization base-handler
authorization-fn
whitelist-path
whitelist-settings)Inputs: [base-handler :- IFn authorization-fn :- IFn whitelist-path :- schema/Str whitelist-settings :- (schema/maybe WhitelistSettings)]
Middleware function that routes a request through either an authorization handler derived from the supplied 'authorization-fn' or to a client-whitelist handler.
The 'authorization-fn' is expected to return a handler when called and this function and accept a single argument, an downstream handler that the authorization-fn should route a handled request to. The authorization-fn is called with 'base-handler' as its parameter.
Requests are only routed to the client-whitelist handler if the request 'uri' starts with the value provided to this function for 'whitelist-path' and if the 'whitelist-settings' are non-empty. In all other cases, requests are routed to the handler constructed from the 'authorization-fn'
Inputs: [base-handler :- IFn authorization-fn :- IFn whitelist-path :- schema/Str whitelist-settings :- (schema/maybe WhitelistSettings)] Middleware function that routes a request through either an authorization handler derived from the supplied 'authorization-fn' or to a client-whitelist handler. The 'authorization-fn' is expected to return a handler when called and this function and accept a single argument, an downstream handler that the authorization-fn should route a handled request to. The authorization-fn is called with 'base-handler' as its parameter. Requests are only routed to the client-whitelist handler if the request 'uri' starts with the value provided to this function for 'whitelist-path' and if the 'whitelist-settings' are non-empty. In all other cases, requests are routed to the handler constructed from the 'authorization-fn'
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |