Package com.slack.api.bolt.service
Interface OpenIDConnectNonceService
- All Superinterfaces:
Service
- All Known Implementing Classes:
NullOpenIDConnectNonceService
Manages nonce parameters for Slack OpenID Connect flow.
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionvoidaddNewNonceToDatastore(String nonce) Adds a newly generated Nonce value to the server-side datastore.default voidDeletes the Nonce value from the server-side datastore and set a response header to delete the one in session.voiddeleteNonceFromDatastore(String nonce) Deletes a given Nonce value from the server-side datastore.default StringextractNonceFromQueryString(Request request) Returns the Nonce parameter value from a given query string if it exists.Generates a new unique Nonce parameter value.booleanisAvailableInDatabase(String nonce) Verifies the Nonce value is available in the datastore and returns true if it's valid.default StringissueNewNonce(Request request, Response response) Issues a new Nonce parameter and set it in both the browser session and the system's server-side datastore.default booleanVerifies the given Nonce parameter and returns true if it's valid.Methods inherited from interface com.slack.api.bolt.service.Service
initializer
-
Method Details
-
extractNonceFromQueryString
Returns the Nonce parameter value from a given query string if it exists. -
issueNewNonce
Issues a new Nonce parameter and set it in both the browser session and the system's server-side datastore.- Throws:
Exception
-
generateNewNonceValue
String generateNewNonceValue()Generates a new unique Nonce parameter value. -
addNewNonceToDatastore
Adds a newly generated Nonce value to the server-side datastore.- Throws:
Exception
-
isValid
Verifies the given Nonce parameter and returns true if it's valid. This method doesn't have any side effects, so that you can call this method multiple times. -
isAvailableInDatabase
Verifies the Nonce value is available in the datastore and returns true if it's valid. -
consume
Deletes the Nonce value from the server-side datastore and set a response header to delete the one in session.- Throws:
Exception
-
deleteNonceFromDatastore
Deletes a given Nonce value from the server-side datastore.- Throws:
Exception
-