Class Verification
java.lang.Object
org.jboss.resteasy.security.doseta.Verification
-
Field Summary
Modifier and TypeFieldDescriptionprotected String
protected boolean
protected String
protected String
protected boolean
protected PublicKey
protected KeyRepository
protected boolean
protected int
protected int
protected int
protected int
protected int
protected int
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiongetKey()
int
int
int
int
int
int
boolean
boolean
boolean
void
setAlgorithm
(String algorithm) void
setBodyHashRequired
(boolean bodyHashRequired) void
setIdentifierName
(String identifierName) void
setIdentifierValue
(String identifierValue) void
setIgnoreExpiration
(boolean ignoreExpiration) void
void
setRepository
(KeyRepository repository) void
setStaleCheck
(boolean staleCheck) void
setStaleDays
(int staleDays) void
setStaleHours
(int staleHours) void
setStaleMinutes
(int staleMinutes) void
setStaleMonths
(int staleMonths) void
setStaleSeconds
(int staleSeconds) void
setStaleYears
(int staleYears) verify
(DKIMSignature signature, Map headers, byte[] body, PublicKey publicKey) Headers can be a Map<String, Object> or a Map<String, List<Object>>.
-
Field Details
-
key
-
repository
-
algorithm
-
requiredAttributes
-
identifierName
-
identifierValue
-
staleCheck
protected boolean staleCheck -
ignoreExpiration
protected boolean ignoreExpiration -
staleSeconds
protected int staleSeconds -
staleMinutes
protected int staleMinutes -
staleHours
protected int staleHours -
staleDays
protected int staleDays -
staleMonths
protected int staleMonths -
staleYears
protected int staleYears -
bodyHashRequired
protected boolean bodyHashRequired
-
-
Constructor Details
-
Verification
public Verification() -
Verification
-
Verification
-
-
Method Details
-
isBodyHashRequired
public boolean isBodyHashRequired() -
setBodyHashRequired
public void setBodyHashRequired(boolean bodyHashRequired) -
getIdentifierName
-
setIdentifierName
-
getIdentifierValue
-
setIdentifierValue
-
isIgnoreExpiration
public boolean isIgnoreExpiration() -
setIgnoreExpiration
public void setIgnoreExpiration(boolean ignoreExpiration) -
isStaleCheck
public boolean isStaleCheck() -
setStaleCheck
public void setStaleCheck(boolean staleCheck) -
getRequiredAttributes
-
getAlgorithm
-
setAlgorithm
-
getKey
-
setKey
-
getRepository
-
setRepository
-
getStaleSeconds
public int getStaleSeconds() -
setStaleSeconds
public void setStaleSeconds(int staleSeconds) -
getStaleMinutes
public int getStaleMinutes() -
setStaleMinutes
public void setStaleMinutes(int staleMinutes) -
getStaleHours
public int getStaleHours() -
setStaleHours
public void setStaleHours(int staleHours) -
getStaleDays
public int getStaleDays() -
setStaleDays
public void setStaleDays(int staleDays) -
getStaleMonths
public int getStaleMonths() -
setStaleMonths
public void setStaleMonths(int staleMonths) -
getStaleYears
public int getStaleYears() -
setStaleYears
public void setStaleYears(int staleYears) -
verify
public jakarta.ws.rs.core.MultivaluedMap<String,String> verify(DKIMSignature signature, Map headers, byte[] body, PublicKey publicKey) throws SignatureException Headers can be a Map<String, Object> or a Map<String, List<Object>>. This gives some compatibility with JAX-RS's MultivaluedMap. If a map of lists, every value of each header duplicate will be added.- Parameters:
signature
- signatureheaders
- headers mapbody
- bodypublicKey
- public key- Returns:
- map of validated headers and their values
- Throws:
SignatureException
- if verification fails
-