public class JwsProcessor extends InitializeObject
| Modifier and Type | Field and Description |
|---|---|
protected JoseVerifier<JoseHeader> |
headerVerifier |
protected JoseSigner |
joseSigner |
protected JsonProcessor |
jsonProcessor |
protected long |
leewayMs |
protected Set<String> |
numericDateProps |
mutex| Constructor and Description |
|---|
JwsProcessor() |
| Modifier and Type | Method and Description |
|---|---|
<A> JwsProcessor |
addHeaderVerifier(JoseVerifier.Delegate<JoseHeader,A> delegate) |
String |
compact(JwsToken jws) |
String |
compact(JwsToken jws,
boolean verify) |
void |
destroy() |
protected JwsToken |
doParse(String headerPart,
String payloadPart,
boolean verify) |
protected void |
init() |
protected void |
initHeaderVerifier() |
JoseHeader |
newHeader() |
JwsToken |
parse(String jws) |
JwsToken |
parse(String jws,
boolean verify) |
JoseHeader |
parseHeader(String headerPart) |
byte[] |
parsePayload(String payloadPart) |
JwsProcessor |
setJoseSigner(JoseSigner joseSigner) |
JwsProcessor |
setJsonProcessor(JsonProcessor jsonProcessor) |
JwsProcessor |
setLeewayMs(long leewayMs) |
JwsProcessor |
setNumericDateProps(String... numericDateProps) |
assertNotInitialized, initializeprotected JsonProcessor jsonProcessor
protected JoseSigner joseSigner
protected long leewayMs
protected final JoseVerifier<JoseHeader> headerVerifier
protected void init()
throws Exception
init in class InitializeObjectExceptionprotected void initHeaderVerifier()
public void destroy()
throws DestroyException
destroy in interface InitializeSupportdestroy in class InitializeObjectDestroyExceptionpublic JoseHeader newHeader()
public String compact(JwsToken jws) throws CryptoException, JsonException, JoseException
public String compact(JwsToken jws, boolean verify) throws CryptoException, JsonException, JoseException
public JwsToken parse(String jws) throws CryptoException, JsonException, JoseException
public JwsToken parse(String jws, boolean verify) throws CryptoException, JsonException, JoseException
protected JwsToken doParse(String headerPart, String payloadPart, boolean verify) throws JsonException, JoseException
JsonExceptionJoseExceptionpublic JoseHeader parseHeader(String headerPart) throws JsonException, JoseException
JsonExceptionJoseExceptionpublic byte[] parsePayload(String payloadPart)
public JwsProcessor setJsonProcessor(JsonProcessor jsonProcessor)
public JwsProcessor setNumericDateProps(String... numericDateProps)
public JwsProcessor setJoseSigner(JoseSigner joseSigner)
public <A> JwsProcessor addHeaderVerifier(JoseVerifier.Delegate<JoseHeader,A> delegate)
public JwsProcessor setLeewayMs(long leewayMs)
Copyright © 2019. All rights reserved.