Class SAD
java.lang.Object
se.swedenconnect.opensaml.sweid.saml2.signservice.sap.SAD
Representation of the Signature Activation Data (SAD) as described in the "Signature Activation Protocol for
Federated Signing" specification.
- Author:
- Martin Lindström (martin@idsec.se)
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
Represents the SAD Extension claim as described in section 3.2.1.2 of the "Signature Activation Protocol for Federated Signing" specification. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
static SAD
Creates aSAD
object from its JSON representation.Returns the entityID of the Signature Service which is the recipient of this SAD.Returns the time when this SAD is no longer valid (epoch time/seconds since 1970-01-01).Returns the time when this SAD is no longer valid as aInstant
instance.Returns the time when this SAD was issued (epoch time/seconds since 1970-01-01).Returns the time when this SAD was issued as aInstant
instance.Returns the entityID of the IdP that generated this SAD.getJwtId()
Returns the unique identifier of this JWT.Returns the SAD extension claim.Returns the attribute value of the signer's unique identifier attribute.int
hashCode()
void
setAudience
(String audience) Assigns the entityID of the Signature Service which is the recipient of this SAD.void
Assigns the time when this SAD is no longer valid (epoch time/seconds since 1970-01-01).void
Assigns the time when this SAD is no longer valid.void
setIssuedAt
(Integer issuedAt) Assigns the time when this SAD was issued (epoch time/seconds since 1970-01-01).void
setIssuedAt
(Instant issuedAt) Assigns the time when this SAD was issued.void
Assigns the entityID of the IdP that generated this SAD.void
Assigns the unique identifier of this JWT.void
setSeElnSadext
(SAD.Extension seElnSadext) Assigns the SAD extension claim.void
setSubject
(String subject) Assigns the attribute value of the signer's unique identifier attribute.toJson()
Serializes the SAD object into its JSON representation.byte[]
Serializes the SAD object into its JSON byte representation.toString()
-
Constructor Details
-
SAD
public SAD()
-
-
Method Details
-
fromJson
Creates aSAD
object from its JSON representation.- Parameters:
json
- the JSON representation- Returns:
- a
SAD
object - Throws:
IOException
- for parsing errors
-
toJson
Serializes the SAD object into its JSON representation.- Returns:
- the JSON representation
- Throws:
IOException
- for processing errors
-
toJsonBytes
Serializes the SAD object into its JSON byte representation.- Returns:
- the JSON bytes
- Throws:
IOException
- for processing errors
-
getSubject
Returns the attribute value of the signer's unique identifier attribute.- Returns:
- the user ID
-
setSubject
Assigns the attribute value of the signer's unique identifier attribute.- Parameters:
subject
- the user ID
-
getAudience
Returns the entityID of the Signature Service which is the recipient of this SAD.- Returns:
- the entityID of the recipient
-
setAudience
Assigns the entityID of the Signature Service which is the recipient of this SAD.- Parameters:
audience
- the entityID of the recipient
-
getIssuer
Returns the entityID of the IdP that generated this SAD.- Returns:
- the IdP entityID
-
setIssuer
Assigns the entityID of the IdP that generated this SAD.- Parameters:
issuer
- the IdP entityID
-
getExpiry
Returns the time when this SAD is no longer valid (epoch time/seconds since 1970-01-01).- Returns:
- number of seconds since 1970-01-01
-
getExpiryDateTime
Returns the time when this SAD is no longer valid as aInstant
instance.- Returns:
- expiration time
-
setExpiry
Assigns the time when this SAD is no longer valid (epoch time/seconds since 1970-01-01).- Parameters:
expiry
- number of seconds since 1970-01-01
-
setExpiry
Assigns the time when this SAD is no longer valid.- Parameters:
expiry
- expiration time
-
getIssuedAt
Returns the time when this SAD was issued (epoch time/seconds since 1970-01-01).- Returns:
- number of seconds since 1970-01-01
-
getIssuedAtDateTime
Returns the time when this SAD was issued as aInstant
instance.- Returns:
- timestamp
-
setIssuedAt
Assigns the time when this SAD was issued (epoch time/seconds since 1970-01-01).- Parameters:
issuedAt
- number of seconds since 1970-01-01
-
setIssuedAt
Assigns the time when this SAD was issued.- Parameters:
issuedAt
- issue time
-
getJwtId
Returns the unique identifier of this JWT.- Returns:
- JWT ID
-
setJwtId
Assigns the unique identifier of this JWT.- Parameters:
jwtId
- JWT ID
-
getSeElnSadext
Returns the SAD extension claim.- Returns:
- SAD extension claim
-
setSeElnSadext
Assigns the SAD extension claim.- Parameters:
seElnSadext
- SAD extension claim
-
toString
-
hashCode
public int hashCode() -
equals
-