MCPcopy Create free account

hub / github.com/crewjam/saml / functions

Functions2,436 in github.com/crewjam/saml

↓ 14 callersMethodsignedIDPMessage
signedIDPMessage returns the base64 encoding of el, signed by the IDP.
samlsp/middleware_logout_test.go:123
↓ 14 callersFunctionsoapEnvelope
soapEnvelope returns a SOAP 1.1 Envelope whose Body holds el.
soap.go:106
↓ 13 callersMethodAllSessionIndexes
AllSessionIndexes returns every SessionIndex of the request: SessionIndex, if set, followed by AdditionalSessionIndexes.
schema.go:180
↓ 13 callersMethodPost
Post returns an HTML form suitable for using the HTTP-POST binding with the request
service_provider.go:1197
↓ 13 callersMethodValidate
Validate checks that the logout request is well formed, was issued by a known service provider, is signed by that service provider, and is addressed t
identity_provider_logout.go:184
↓ 13 callersMethodWrite
([]byte)
samlsp/middleware_coverage_test.go:24
↓ 13 callersMethodmakeTrackedRequest
(id string)
samlsp/middleware_test.go:119
↓ 13 callersFunctionnewSOAPLogoutApp
(t *testing.T)
samlsp/middleware_soap_logout_test.go:41
↓ 13 callersFunctionnewSOAPLogoutTest
(t *testing.T)
identity_provider_logout_soap_request_test.go:28
↓ 13 callersMethodnow
now returns the current time as seen by this IdentityProvider. idp may be nil, in which case the default clock is used.
identity_provider.go:512
↓ 13 callersFunctionspecSigSign
specSigSign returns a copy of el carrying an enveloped ds:Signature built by hand, so that tests can produce signatures whose SignedInfo deviates from
spec_signature_encryption_test.go:68
↓ 12 callersFunctionDefaultServiceProvider
DefaultServiceProvider returns the default saml.ServiceProvider for the provided options.
samlsp/new.go:383
↓ 12 callersFunctionNew
New returns a new Server
samlidp/samlidp.go:147
↓ 12 callersFunctionNewIdpLogoutRequest
NewIdpLogoutRequest returns a new IdpLogoutRequest for the given HTTP request to the single logout service. A GET request is decoded as an HTTP-Redire
identity_provider_logout.go:100
↓ 12 callersMethodPublic
()
crypto_signer_test.go:26
↓ 12 callersMethodartifactResponseEl
artifactResponseEl builds an ArtifactResponse (optionally signed) wrapping an unsigned Response with an unsigned Assertion.
sp_coverage_parse_test.go:196
↓ 12 callersFunctioncheckStatus
checkStatus checks the top-level and second-level status of resp.
identity_provider_logout_soap_request_test.go:91
↓ 12 callersFunctionformFields
formFields returns the action and the hidden fields of an HTML form.
simplesign_binding_test.go:71
↓ 12 callersMethodget
get requests /app with cookie and returns the status code.
samlsp/middleware_soap_logout_test.go:80
↓ 12 callersFunctionidpErrResponseFromForm
idpErrResponseFromForm returns the Response element posted by the HTML form in body, and the form's action and fields.
idp_error_response_test.go:39
↓ 12 callersMethodlogoutRequest
logoutRequest returns an unsigned LogoutRequest from the SP to the IdP.
identity_provider_logout_test.go:104
↓ 12 callersFunctionrandomBytes
nolint:unparam // This always receives 20, but we want the option to do more or less if needed.
util.go:64
↓ 12 callersFunctionschemacovString
schemacovString serializes el as a document root and returns the XML text.
schema_coverage_test.go:26
↓ 12 callersMethodserveIDP
serveIDP sends r to the IdP's ServeSLO with the browser's IdP cookies.
identity_provider_logout_propagation_test.go:187
↓ 12 callersFunctionsessionKey
(id string)
samlidp/logout.go:111
↓ 12 callersMethodsigningContext
signingContext returns a signing context for the SP's key and certificate that signs with signatureMethod.
service_provider.go:1085
↓ 11 callersMethodClose
()
samlsp/samlsp_coverage_test.go:66
↓ 11 callersMethodMakeAssertionEl
MakeAssertionEl sets `AssertionEl` to a signed, possibly encrypted, version of `Assertion`.
identity_provider.go:1667
↓ 11 callersMethodMakeLogoutResponse
MakeLogoutResponse produces a new LogoutResponse object for idpURL and logoutRequestID, with the status Success. If sp.SignatureMethod is set, the res
service_provider.go:3086
↓ 11 callersFunctionNewMemoryReplayCache
NewMemoryReplayCache returns a MemoryReplayCache that holds at most maxEntries unexpired assertion IDs. It panics if maxEntries is not positive.
samlsp/replay_cache.go:54
↓ 11 callersMethodTrackRequest
TrackRequest starts tracking the SAML request with the given ID. It returns an `index` that should be used as the RelayState in the SAMl request flow.
samlsp/request_tracker.go:19
↓ 11 callersMethodWriteHeader
(int)
samlsp/middleware_soap_logout.go:71
↓ 11 callersFunctionclockNow
clockNow returns the current time from clock or, if it is nil, from the deprecated saml.TimeNow, which callers that have not set a Clock may still rep
samlsp/util.go:15
↓ 11 callersMethodcookie
cookie returns a session cookie for nameID, issued at issuedAt, with the given SessionIndexes, as JWTSessionCodec makes it.
samlsp/middleware_soap_logout_test.go:61
↓ 11 callersFunctioncovLoginRequest
(body string)
samlidp/session_coverage_test.go:21
↓ 11 callersFunctioncovRSAKey
(t *testing.T)
samlsp/samlsp_coverage_test.go:45
↓ 11 callersFunctionfindChildren
findChildren returns all the elements matching childNS/childTag that are direct children of parentEl. The namespace context of parentEl is built once
service_provider.go:3692
↓ 11 callersFunctionformatTime
formatTime formats t for a SAML message. saml-core §1.3.3 says SAML time values "MUST be expressed in UTC form, with no time zone component", so t is
time.go:15
↓ 11 callersFunctionidpErrCheckErrorResponse
idpErrCheckErrorResponse checks that el is a signed Response from the IdP with the given status codes and no assertion.
idp_error_response_test.go:51
↓ 11 callersMethodlogoutResponse
()
sp_coverage_helpers_test.go:150
↓ 11 callersMethodmakeUnsignedLogoutResponse
(idpURL, logoutRequestID string)
service_provider.go:3107
↓ 11 callersFunctionnewSaferFlateReader
1 MiB
flate.go:17
↓ 11 callersMethodsessionExists
(t *testing.T, id string)
samlidp/logout_test.go:78
↓ 11 callersFunctionsoapBodyElement
soapBodyElement parses soapXML as a SOAP 1.1 envelope and returns the SAML protocol element named tag (such as "Response" or "LogoutRequest") that mus
soap.go:180
↓ 11 callersFunctionsoapEnvelopeBytes
soapEnvelopeBytes wraps the LogoutRequest req in a SOAP 1.1 envelope, as a service provider sends it with the SOAP binding (saml-bindings §3.2).
identity_provider_logout_soap_request_test.go:51
↓ 11 callersFunctionspecCoreSignedResponse
specCoreSignedResponse returns a Response signed by the IDP that carries a (plaintext, unsigned) assertion. mutate, if set, edits the Assertion elemen
spec_core_assertions_test.go:26
↓ 11 callersFunctionunmarshalForTest
unmarshalForTest parses doc and reads its root into v the way the service provider reads a message it received.
attribute_namespace_test.go:17
↓ 10 callersMethodElement
Element returns an XML element representation of n.
service_provider.go:44
↓ 10 callersMethodWriteResponse
WriteResponse writes the HTTP response carrying the SAML response for req. req.ResponseEl is nil until req.MakeResponse (or req.PostBinding, which cal
identity_provider.go:132
↓ 10 callersFunctionacsselNewTest
acsselNewTest returns an IdP test whose service provider's metadata lists acs as its assertion consumer services, and a pointer that is set to true wh
idp_acs_selection_test.go:34
↓ 10 callersMethodbuild
(t *testing.T)
redirect_binding_test.go:40
↓ 10 callersFunctionidpcovSSORequest
(t *testing.T, test *IdentityProviderTest)
idp_coverage_test.go:83
↓ 10 callersMethodlogin
login logs the IdP session in to each of sps with IdP-initiated SSO, which records them as participants.
identity_provider_logout_propagation_test.go:151
↓ 10 callersMethodpost
post sends body to the SLO endpoint with the given Content-Type, as the IdP does with the SOAP binding, and returns the response.
samlsp/middleware_soap_logout_test.go:95
↓ 10 callersFunctionpostRequestBytes
(target string, buf []byte)
identity_provider_logout_test.go:127
↓ 10 callersFunctionredirectRequest
(sp *ServiceProvider, rawQuery string)
redirect_binding_test.go:99
↓ 10 callersFunctionreqSubjNewTest
reqSubjNewTest returns an IdP test whose session is alice@example.com, with the emailAddress NameID Format.
idp_request_subject_test.go:23
↓ 10 callersMethodsignedPostRequest
(t *testing.T, req *LogoutRequest)
identity_provider_logout_test.go:137
↓ 10 callersFunctionspRequestForResponse
spRequestForResponse turns the IdP's HTTP response into the request the browser sends to the SP.
identity_provider_logout_test.go:154
↓ 10 callersMethodvalidatedElement
validatedElement is validateSignature, returning on success the element to read the message from: what the signature covers, parsed from the canonical
service_provider.go:2621
↓ 9 callersFunctionFetchMetadata
FetchMetadata returns metadata from an IDP metadata URL. If httpClient is nil, a client with a two-minute timeout is used. Only a 2xx response is acc
samlsp/fetch_metadata.go:265
↓ 9 callersMethodKeySize
()
xmlenc/xmlenc.go:110
↓ 9 callersMethodMakeRedirectLogoutRequest
MakeRedirectLogoutRequest creates a SAML LogoutRequest using the HTTP-Redirect binding. It returns a URL that we will redirect the user to in order to
service_provider.go:2958
↓ 9 callersMethodMakeRedirectLogoutResponse
MakeRedirectLogoutResponse creates a SAML LogoutResponse using the HTTP-Redirect binding. It returns a URL that we will redirect the user to for Logou
service_provider.go:3135
↓ 9 callersMethodNewIdpInitiatedRequest
NewIdpInitiatedRequest returns the IdpAuthnRequest for an IdP-initiated login to the service provider serviceProviderID, with its metadata and its def
identity_provider.go:899
↓ 9 callersFunctionParseMetadata
ParseMetadata parses arbitrary SAML IDP metadata. Note: this is needed because IDP metadata is sometimes wrapped in an <EntitiesDescriptor>, and some
samlsp/fetch_metadata.go:47
↓ 9 callersMethodParseXMLArtifactResponse
ParseXMLArtifactResponse validates the SAML Artifact resolver response and returns the verified assertion. This function handles verifying the digita
service_provider.go:1444
↓ 9 callersMethodSimpleSign
SimpleSign returns an auto-submitting HTML form that sends the request to its Destination with the HTTP-POST-SimpleSign binding, signed with sp's Key
simplesign_binding.go:400
↓ 9 callersMethodValidateLogoutResponseRequest
ValidateLogoutResponseRequest validates the LogoutResponse content from the request, which may use the HTTP-Redirect, HTTP-POST or HTTP-POST-SimpleSig
service_provider.go:3315
↓ 9 callersFunctionacsselRequest
acsselRequest returns an HTTP-Redirect AuthnRequest from test.SP for the ACS at acsURL with protocolBinding, after mutate (if not nil) has changed it.
idp_acs_selection_test.go:58
↓ 9 callersMethoddeleteSession
deleteSession deletes the stored session id and its participants.
samlidp/logout_propagation.go:118
↓ 9 callersFunctionformPost
formPost returns a same-origin POST of form to uri.
samlsp/form_replay_test.go:44
↓ 9 callersMethodidpSOAP
idpSOAP returns req signed by the IdP in a SOAP envelope.
samlsp/middleware_soap_logout_test.go:143
↓ 9 callersFunctionidpcovRequest
idpcovRequest returns a request ready for MakeAssertion / MakeAssertionEl / MakeResponse, without going through Validate.
idp_coverage_test.go:94
↓ 9 callersMethodlogoutRequest
logoutRequest returns a LogoutRequest from sp for the test session, signed by sp unless sp has no SignatureMethod. modify, if set, changes it before i
identity_provider_logout_soap_request_test.go:37
↓ 9 callersMethodlogoutSignatureMethod
logoutSignatureMethod returns the signature method for the logout messages the SP sends: LogoutSignatureMethod, or SignatureMethod if that is empty. A
service_provider.go:1076
↓ 9 callersFunctionmarshalAndParse
marshalAndParse marshals v and parses the result with etree, failing on the junk encoding/xml produces for a raw *etree.Element.
metadata_signature_test.go:36
↓ 9 callersFunctionnewForceAuthnPassiveTest
(t *testing.T)
samlidp/force_authn_passive_test.go:32
↓ 9 callersFunctionparseSimpleSignRequest
parseSimpleSignRequest reads the HTTP-POST-SimpleSign message carried in messageParam (SAMLRequest or SAMLResponse) of the posted form of req. It retu
simplesign_binding.go:119
↓ 9 callersFunctionreqSubjServe
reqSubjServe sends an AuthnRequest from test.SP with the given Subject to ServeSSO with the HTTP-Redirect binding, and returns the request ID and the
idp_request_subject_test.go:48
↓ 9 callersMethodrequests
()
samlidp/logout_soap_test.go:106
↓ 9 callersMethodrun
run answers each LogoutRequest the IdP sends to an SP until the IdP sends something else, and returns that last IdP response.
samlidp/logout_propagation_test.go:99
↓ 9 callersMethodsoapLogoutRequest
soapLogoutRequest returns a LogoutRequest from the IdP for alice with the given SessionIndexes.
samlsp/middleware_soap_logout_test.go:111
↓ 9 callersFunctionsoapLogoutResponse
soapLogoutResponse checks that w holds a LogoutResponse in a SOAP envelope, signed by the IdP, as sp reads it, and returns it.
identity_provider_logout_soap_request_test.go:75
↓ 9 callersFunctionspcovArtifactRequest
(artifact string)
sp_coverage_parse_test.go:331
↓ 9 callersFunctionspcovParse
(t *testing.T, s string)
sp_coverage_helpers_test.go:186
↓ 9 callersMethodstoreError
storeError answers a request whose Store operation failed with err: 404 Not Found if the item does not exist (ErrNotFound), otherwise 500 Internal Ser
samlidp/util.go:19
↓ 9 callersMethodstoredSessionParticipants
storedSessionParticipants returns the participants recorded for the session sessionID, in a stable order.
samlidp/logout_propagation.go:91
↓ 8 callersMethodCreateSession
CreateSession is called when we have received a valid SAML assertion and should create a new session and modify the http response accordingly, e.g. by
samlsp/session.go:42
↓ 8 callersFunctionDefaultSessionCodec
DefaultSessionCodec returns the default SessionCodec for the provided options, a JWTSessionCodec configured to issue signed tokens.
samlsp/new.go:267
↓ 8 callersFunctionDefaultSessionProvider
DefaultSessionProvider returns the default SessionProvider for the provided options, a CookieSessionProvider configured to store sessions in a cookie.
samlsp/new.go:285
↓ 8 callersMethodDeleteSession
DeleteSession is called to modify the response such that it removed the current session, e.g. by deleting a cookie.
samlsp/session.go:46
↓ 8 callersMethodGetAttributes
()
samlsp/session.go:18
↓ 8 callersFunctionSessionFromContext
SessionFromContext returns the session associated with ctx, or nil if no session are associated
samlsp/session.go:77
↓ 8 callersFunctioncovSessionCodec
(t *testing.T)
samlsp/session_coverage_test.go:19
↓ 8 callersFunctiondecodeLogoutResponse
decodeLogoutResponse returns the LogoutResponse the IdP sent, without checking its signature.
identity_provider_logout_test.go:179
↓ 8 callersFunctiondeflateAndEncode
deflateAndEncode serializes el, deflates it and base64 encodes the result, as the HTTP-Redirect binding requires.
redirect_binding.go:316
↓ 8 callersFunctionfindChild
findChild finds the specified child element. Returns (nil, nil) of the element doesn't exist.
service_provider.go:3807
↓ 8 callersFunctionfirstSet
(a, b string)
service_provider.go:3678
↓ 8 callersFunctionidpErrCheckSPRejects
idpErrCheckSPRejects checks that the SP parsing the form in body for requestIDs reports ErrBadStatus with topLevel.
idp_error_response_test.go:80
← previousnext →101–200 of 2,436, ranked by callers