Class SIPX509FileValidator
- java.lang.Object
-
- de.ikor.sip.foundation.security.authentication.x509.SIPX509FileValidator
-
- All Implemented Interfaces:
SIPTokenValidator<SIPX509AuthenticationToken>
@Primary @ConditionalOnSIPAuthProvider(listItemValue=SIPX509AuthenticationProvider.class, validationClass=SIPX509FileValidator.class) @Component public class SIPX509FileValidator extends Object implements SIPTokenValidator<SIPX509AuthenticationToken>
The file-based x509 validator reads an acl file in this format:# this is a comment CN=Full Name, EMAILADDRESS=name@domain.de, O=[*], C=DE CN=Full Name2, EMAILADDRESS=name2@domain.de, O=[*], C=DE
And then validates the extracted certificate data with the contents in the file.- Author:
- thomas.stieglmaier
-
-
Constructor Summary
Constructors Constructor Description SIPX509FileValidator(SecurityConfigProperties config)
Creates a file-based x509 auth token validator
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
isValid(SIPX509AuthenticationToken token)
Checks if a given token is valid
-
-
-
Constructor Detail
-
SIPX509FileValidator
public SIPX509FileValidator(SecurityConfigProperties config)
Creates a file-based x509 auth token validator- Parameters:
config
- the config containing information on where to find the file that should be read
-
-
Method Detail
-
isValid
public boolean isValid(SIPX509AuthenticationToken token)
Description copied from interface:SIPTokenValidator
Checks if a given token is valid- Specified by:
isValid
in interfaceSIPTokenValidator<SIPX509AuthenticationToken>
- Parameters:
token
- the token to be checked- Returns:
- indicates if the token is valid or not
-
-