Package org.keycloak.rotation
Interface KeyLocator
-
- All Known Implementing Classes:
CompositeKeyLocator
,HardcodedKeyLocator
public interface KeyLocator
This interface defines a method for obtaining a security key by ID.If the
KeyLocator
implementor wants to make all its keys available for iteration, it should implementIterable
<T extends
Key
> interface. The baseKeyLocator
does not extend this interface to enableKeyLocators
that do not support listing their keys.- Author:
- Hynek Mlnařík
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description Key
getKey(String kid)
Returns a key with a particular ID.void
refreshKeyCache()
If this key locator caches keys in any way, forces this cache cleanup and refreshing the keys.
-
-
-
Method Detail
-
getKey
Key getKey(String kid) throws KeyManagementException
Returns a key with a particular ID.- Parameters:
kid
- Key IDconfiguration
- Configuration- Returns:
- key, which should be used for verify signature on given "input"
- Throws:
KeyManagementException
-
refreshKeyCache
void refreshKeyCache()
If this key locator caches keys in any way, forces this cache cleanup and refreshing the keys.
-
-