saml 2.0 profile of xacml - oasisdocs.oasis-open.org/xacml/access_control-xacml-2.0-saml... ·...

22
SAML 2.0 profile of XACML Committee Draft 02, 11 November 2004 Document identifier: access_control-xacml-2.0-saml_profile-spec-cd-02 Location: http://docs.oasis-open.org/xacml/access_control-xacml-2.0-saml_profile-spec-cd-02.pdf Editors: Anne Anderson, Sun Microsystems ([email protected]) Hal Lockhart, BEA ([email protected]) Abstract: This specification defines a profile for the use of the OASIS Security Assertion Markup Language (SAML) Version 2.0 to carry XACML 2.0 policies, policy queries and responses, authorization decisions, and authorization decision queries and responses. It also describes the use of SAML 2.0 Attribute Assertions with XACML. Status: This version of the specification is an approved Committee Draft within the OASIS Access Control TC. Access Control TC members should send comments on this specification to the [email protected] list. Others may use the following link and complete the comment form: http://oasis-open.org/committees/comments/form.php?wg_abbrev=xacml. For information on whether any patents have been disclosed that may be essential to implementing this specification, and any offers of patent licensing terms, please refer to the Intellectual Property Rights section of the Access Control TC web page (http://www.oasis-open.org/committees/tc_home.php?wg_abbrev=xacml ). For any errata page for this specification, please refer to the Access Control TC web page (http://www.oasis-open.org/committees/tc_home.php?wg_abbrev=xacml ). Copyright © OASIS Open 2004 All Rights Reserved. access_control-xacml-2.0-saml_profile-spec-cd-02 11 November 2004 Copyright © OASIS Open 2004. All Rights Reserved. Page 1 of 22 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28

Upload: others

Post on 01-Apr-2021

7 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: SAML 2.0 profile of XACML - OASISdocs.oasis-open.org/xacml/access_control-xacml-2.0-saml... · 2004. 12. 10. · This profile defines how to use SAML 2.0 to protect, transport, and

SAML 2.0 profile of XACML

Committee Draft 02, 11 November 2004

Document identifier:access_control-xacml-2.0-saml_profile-spec-cd-02

Location:http://docs.oasis-open.org/xacml/access_control-xacml-2.0-saml_profile-spec-cd-02.pdf

Editors:Anne Anderson, Sun Microsystems ([email protected])Hal Lockhart, BEA ([email protected])

Abstract:This specification defines a profile for the use of the OASIS Security Assertion MarkupLanguage (SAML) Version 2.0 to carry XACML 2.0 policies, policy queries and responses,authorization decisions, and authorization decision queries and responses. It alsodescribes the use of SAML 2.0 Attribute Assertions with XACML.

Status:This version of the specification is an approved Committee Draft within the OASIS AccessControl TC.

Access Control TC members should send comments on this specification to [email protected] list. Others may use the following link and complete thecomment form: http://oasis-open.org/committees/comments/form.php?wg_abbrev=xacml.

For information on whether any patents have been disclosed that may be essential toimplementing this specification, and any offers of patent licensing terms, please refer tothe Intellectual Property Rights section of the Access Control TC web page(http://www.oasis-open.org/committees/tc_home.php?wg_abbrev=xacml).

For any errata page for this specification, please refer to the Access Control TC web page(http://www.oasis-open.org/committees/tc_home.php?wg_abbrev=xacml).

Copyright © OASIS Open 2004 All Rights Reserved.

access_control-xacml-2.0-saml_profile-spec-cd-02 11 November 2004Copyright © OASIS Open 2004. All Rights Reserved. Page 1 of 22

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

Page 2: SAML 2.0 profile of XACML - OASISdocs.oasis-open.org/xacml/access_control-xacml-2.0-saml... · 2004. 12. 10. · This profile defines how to use SAML 2.0 to protect, transport, and

Table of Contents1 Introduction (non-normative)............................................................................................. .............3

1.1 Notation............................................................................................................................... ...4

1.2 Terminology.............................................................................................................. ..............5

2 Attributes (normative)........................................................................................... ..........................7

2.1 Mapping a SAML Attribute Assertion to XACML Attributes................................. ...................7

3 Authorization Decisions (normative).................................................................................... ..........9

3.1 Element <XACMLAuthzDecisionQuery>....................................................................... .........9

3.2 Element <XACMLAuthzDecisionStatement>........................................................ ................10

4 Policies (normative).................................................................................... ..................................12

4.1 Element <XACMLPolicyQuery>...................................................................... ......................12

4.2 Element <XACMLPolicyStatement>................................................................................... ..12

5 Element <saml:Assertion> (normative)................................................................................. .......14

5.1 Element <saml:Issuer>.................................................................................................. .......14

5.2 Element <ds:Signature>..................................................................................................... ..14

5.3 Element <saml:Subject>...................................................................................... .................14

5.4 Element <saml:Conditions>................................................................................... ...............15

6 Element <samlp:RequestAbstractType> (normative).............................................. ...................16

6.1 Element <saml:Issuer>.................................................................................................. .......16

6.2 Element <ds:Signature>..................................................................................................... ..16

7 Element <samlp:Response> (normative)...................................................................... ...............17

7.1 Element <samlp:Issuer>................................................................................................ .......17

7.2 Element <ds:Signature>..................................................................................................... ..17

7.3 Element <samlp:StatusCode>......................................................................................... .....17

8 References...................................................................................................... .............................19

8.1 Normative References.................................................................................................. ........19

8.2 Non-normative References.................................................................................... ...............19

access_control-xacml-2.0-saml_profile-spec-cd-02 11 November 2004Copyright © OASIS Open 2004. All Rights Reserved. Page 2 of 22

29

30

31

32

33

34

35

36

37

38

39

40

41

42

43

44

45

46

47

48

49

50

51

52

53

54

55

Page 3: SAML 2.0 profile of XACML - OASISdocs.oasis-open.org/xacml/access_control-xacml-2.0-saml... · 2004. 12. 10. · This profile defines how to use SAML 2.0 to protect, transport, and

1 Introduction (non-normative)

The OASIS eXtensible Access Control Markup Language [XACML] is a powerful, standardlanguage that specifies schemas for authorization policies and for authorization decision requestsand responses. It also specifies how to evaluate policies against requests to compute a response.A brief overview of XACML is available in [XACMLIntro].

The non-normative XACML usage model assumes that a Policy Enforcement Point (PEP) isresponsible for protecting access to one or more resources. When a resource access isattempted, the PEP sends a description of the attempted access to a Policy Decision Point (PDP)in the form of an authorization decision request. The PDP evaluates this request against itsavailable policies and attributes and produces an authorization decision that is returned to thePEP. The PEP is responsible for enforcing the decision.

In producing its description of the access request, the PEP may obtain attributes from on-lineAttribute Authorities (AA) or from Attribute Repositories into which AAs have stored attributes.The PDP (or, more precisely, its Context Handler component) may augment the PEP's descriptionof the access request with additional attributes obtained from AAs or Attribute Repositories.

The PDP may obtain policies from on-line Policy Administration Points (PAP) or from PolicyRepositories into which PAPs have stored policies.

XACML itself defines the content of some of the messages necessary to implement this model,but deliberately confines its scope to the language elements used directly by the PDP and doesnot define protocols or transport mechanisms. Full implementation of the usage model dependson use of other standards to specify assertions, protocols, and transport mechanisms. XACMLalso does not specify how to implement a Policy Enforcement Point, Policy Administration Point,Attribute Authority, Context Handler, or repository, but XACML can serve as a standard format forexchanging information with these entities when combined with other standards.

One standard suitable for providing the assertion and protocol mechanisms needed by XACML isthe OASIS Security Assertion Markup Language (SAML), Version 2.0 [SAML]. SAML definesschemas intended for use in requesting and responding with various types of security assertions.The SAML schemas include information needed to identify and validate the contents of theassertions, such as the identity of the assertion issuer, the validity period of the assertion, and thedigital signature of the assertion. The SAML specification describes how these elements are to beused. In addition, SAML has associated specifications that define bindings to other standards.These other standards provide transport mechanisms and specify how digital signatures should becreated and verified.

This profile defines how to use SAML 2.0 to protect, transport, and request XACML schemainstances and other information needed by an XACML implementation.

There are 6 types of queries and statements used in this profile:

1. AttributeQuery – A standard SAML Request used for requesting one or more attributes from anAttribute Authority.

2. AttributeStatement – A standard SAML Statement that contains one or more attributes. Thisstatement may be used in a SAML Response from an Attribute Authority, or it may be used in aSAML Assertion as a format for storing attributes in an Attribute Repository.

3. XACMLPolicyQuery – A SAML Request extension, defined in this profile. It is used forrequesting one or more policies from a Policy Administration Point.

4. XACMLPolicyStatement – A SAML Statement extension, defined in this profile. It may be usedin a SAML Response from a Policy Administration Point, or it may be used in a SAMLAssertion as a format for storing policies in a Policy Repository.

access_control-xacml-2.0-saml_profile-spec-cd-02 11 November 2004Copyright © OASIS Open 2004. All Rights Reserved. Page 3 of 22

56

57

58

59

60

61

62

63

64

65

66

67

68

69

70

71

72

73

74

75

76

77

78

79

80

81

82

83

84

85

86

87

88

89

90

91

92

93

94

95

96

97

98

99

100

101

102

Page 4: SAML 2.0 profile of XACML - OASISdocs.oasis-open.org/xacml/access_control-xacml-2.0-saml... · 2004. 12. 10. · This profile defines how to use SAML 2.0 to protect, transport, and

5. XACMLAuthzDecisionQuery – A SAML Request extension, defined in this profile. It is used bya PEP to request an authorization decision from an XACML PDP.

6. XACMLAuthzDecisionStatement – A SAML Statement extension, defined in this profile. It maybe used in a SAML Response from an XACML PDP. It might also be used in a SAMLAssertion that is used as a credential, but this is not part of the currently defined XACML usemodel.

The following diagram illustrates the XACML use model and the messages that are used tocommunicate between the various components. Not all components will be used in everyimplementation.

This specification describes all these query and statement schema elements, and describes howto use them. It also describes some other aspects of using SAML with XACML. This specificationrequires no changes or extensions to XACML, but does define extensions to SAML.

1.1 NotationIn order to improve readability, the examples in this profile assume use of the following XML

access_control-xacml-2.0-saml_profile-spec-cd-02 11 November 2004Copyright © OASIS Open 2004. All Rights Reserved. Page 4 of 22

PEP

PDP

AAAAAA

PAPAPAP

AttributeRepository

PolicyRepository

Request:AttributeQuery

Response:AttributeStatement

Response:AttributeStatement

Assertion:XACMLPolicyStatement

Response:XACMLPolicyStatement

Request:XACMLPolicyQuery

Request:XADQ

Response:XADS

Request:AttributeQuery

Assertion:AttributeStatement

Assertion:XACMLPolicyStatement

Assertion:AttributeStatement

Assertion:AttributeStatement

XADQ = XACMLAuthzDecisionQueryXADS = XACMLAuthzDecisionStatement

103

104

105

106

107

108

109

110

111

113

114

115

116

117

1

Page 5: SAML 2.0 profile of XACML - OASISdocs.oasis-open.org/xacml/access_control-xacml-2.0-saml... · 2004. 12. 10. · This profile defines how to use SAML 2.0 to protect, transport, and

Internal Entity declarations:

^lt;!ENTITY saml "urn:oasis:names:tc:SAML:2.0:assertion"^lt;!ENTITY samlp "urn:oasis:names:tc:SAML:2.0:protocol"^lt;!ENTITY xacml "urn:oasis:names:tc:xacml:2.0:"^lt;!ENTITY xacml-context

"urn:oasis:names:tc:xacml:2.0:context:schema:cd-01"^lt;!ENTITY xml "http://www.w3.org/2001/XMLSchema#"^lt;!ENTITY subject-id

"urn:oasis:names:tc:xacml:1.0:subject:subject-id"^lt;!ENTITY resource "urn:oasis:names:tc:xacml:1.0:resource:"^lt;!ENTITY resource-id

"urn:oasis:names:tc:xacml:1.0:resource:resource-id"^lt;!ENTITY action-id "urn:oasis:names:tc:xacml:1.0:action:action-id"^lt;!ENTITY environment "urn:oasis:names:tc:xacml:1.0:environment:"^lt;!ENTITY current-dateTime

"urn:oasis:names:tc:xacml:1.0:environment:current-dateTime"

For example, “&xml;#string” is equivalent tohttp://www.w3.org/2001/XMLSchema#string.

The namespace associated with the XACML schema [XACML-SAML] that extends the SAMLAssertion schema is

xacml-saml="urn:oasis:names:tc:xacml:2.0:saml:assertion:schema:cd-01"

The namespace associated with the XACML schema [XACML-SAMLP] that extends the SAMLProtocol schema is

xacml-samlp="urn:oasis:names:tc:xacml:2.0:saml:protocol:schema:cd-01"

1.2 TerminologyThe key words “MUST”, “MUST NOT”, ”REQUIRED”, ”SHALL”, ”SHALL NOT”, ”SHOULD”,”SHOULD NOT”, ”RECOMMENDED”, ”MAY”, and ”OPTIONAL” in this specification are to beinterpreted as described in IETF RFC 2119 [RFC2119]:

“they MUST only be used where it is actually required for interoperation or to limitbehavior which has potential for causing harm (e.g., limiting retransmissions)”

These keywords are thus capitalized when used to unambiguously specify requirements overprotocol and application features and behavior that affect the interoperability and security ofimplementations. When these words are not capitalized, they are meant in their natural-languagesense.

AA – Attribute Authority. An entity that binds attributes to identities. Such a binding may beexpressed using a SAML Attribute Assertion with the Attribute Authority as the issuer.

Attribute - In this Profile, the term “Attribute”, when the initial letter is capitalized, may refer toeither an XACML Attribute or to a SAML Attribute. The term will always be preceded with the typeof Attribute intended.

• An XACML Attribute is a typed name/value pair, with other optional information, specified usingan XACML Request Context <xacml-context:Attribute> element. An XACML Attributeis associated with an identity by the XACML Attribute's position within the XACML Request; forexample, an XACML Attribute contained within the <xacml-context:Resource> element isan attribute of that resource.

• A SAML Attribute is a name/value pair, with other optional information, specified using a SAMLAssertion <saml:Attribute> element. A SAML Attribute is associated with a particularsubject by its inclusion in a <saml:SubjectStatement> element. The SAML subject maycorrespond to an XACML subject, resource, action, or even environment.

attribute – In this Profile, the term “attribute”, when not capitalized, refers to a generic attribute orcharacteristic unless it is preceded by the term “XML”. An “XML attribute” is a syntactic

access_control-xacml-2.0-saml_profile-spec-cd-02 11 November 2004Copyright © OASIS Open 2004. All Rights Reserved. Page 5 of 22

118

119120121122123124125126127128129130131132133

134

135

136

137

138

139

140

141

142

143

144

145

146

147

148

149

150

151

152

153

154

155

156

157

158

159

160

161

162

163

164

165

166

167

Page 6: SAML 2.0 profile of XACML - OASISdocs.oasis-open.org/xacml/access_control-xacml-2.0-saml... · 2004. 12. 10. · This profile defines how to use SAML 2.0 to protect, transport, and

component in XML that occurs inside the opening tag of an XML element.

PAP – Policy Administration Point. An entity that issues authorization policies. Such policies maybe expressed using a SAML Policy Assertion with the Policy Administration Point as the issuer.

PDP - Policy Decision Point. An entity that evaluates an access request against one or morepolicies to produce an access decision.

PEP – Policy Enforcement Point. An entity that enforces access control for one or moreresources. When a resource access is attempted, a PEP sends an access request describing theattempted access to a PDP. The PDP returns an access decision that the PEP then enforces.

policy – A set of rules indicating which subjects are permitted to access which resources usingwhich actions under which conditions. XACML has two different schema elements used forpolicies: <Policy> and <PolicySet>. A <PolicySet> is a collection of other <Policy> and<PolicySet> elements. A <Policy> contains actual access control rules.

access_control-xacml-2.0-saml_profile-spec-cd-02 11 November 2004Copyright © OASIS Open 2004. All Rights Reserved. Page 6 of 22

168

169

170

171

172

173

174

175

176

177

178

179

Page 7: SAML 2.0 profile of XACML - OASISdocs.oasis-open.org/xacml/access_control-xacml-2.0-saml... · 2004. 12. 10. · This profile defines how to use SAML 2.0 to protect, transport, and

2 Attributes (normative)The SAML assertion schema defines an Attribute Assertion. The SAML protocol schema definesan AttributeQuery used for requesting instances of Attribute Assertions, and a Response thatcontains the requested instances. Systems using XACML MAY use instances of these SAMLelements transmit and store SAML Attributes. Systems using XACML MAY use the SAMLAttributeQuery protocol to request instances of SAML Attributes. In order to be used in an XACMLRequest Context, the SAML Attribute SHALL be mapped to an XACML Attribute. This Sectiondescribes that mapping.

2.1 Mapping a SAML Attribute Assertion to XACML AttributesA SAML Attribute Assertion is a <saml:Assertion> instance that contains one or more<saml:AttributeStatement> instances, each of which may contain one or more<saml:Attribute> instances.

In order to be used in an XACML Request Context, each SAML Attribute in the SAML AttributeAssertion SHALL comply with XACML Attribute Profile (Section 8.5), namespaceurn:oasis:names:tc:SAML:2.0:profiles:attribute:XACML, in the Profiles for theOASIS Security Assertion Markup Language [SAML-PROFILE].

An <xacml-context:Attribute> SHALL be constructed from the corresponding<saml:Attribute> element in a SAML Attribute Assertion as follows.

• XACML AttributeId XML attribute

The fully-qualified value of the <saml:Attribute> Name XML attribute SHALL be used.

• XACML DataType XML attribute

The fully-qualified value of the <saml:Attribute> DataType XML attribute SHALL beused. If the <saml:Attribute> DataType XML attribute is missing, the XACMLDataType XML attribute SHALL be http://www.w3.org/2001/XMLSchema#string.

• XACML Issuer XML attribute

The string value of the <saml:Issuer> element from the SAML Attribute Assertion SHALL beused.

• <xacml-context:AttributeValue>

The <saml:AttributeValue> value SHALL be used as the value of the <xacml-context:AttributeValue> element.

Each <saml:Attribute> instance is mapped to a single <xacml-context:Attribute>element. Not all <saml:Attribute> instances in a SAML Attribute Assertion need to bemapped; the SAML Attribute instances to be mapped may be selected by a mechanism notspecified here. The Issuer of the <saml:Assertion> element is used as the Issuer foreach <xacml-context:Attribute> element that is created.

The <xacml-context:Attribute> created from the <saml:Assertion> SHALL be placedinto the <xacml-context:Resource>, <xacml-context:Subject>, <xacml-context:Action>, or <xacml-context:Environment> element that corresponds to theentity that is the <saml:Subject> in the SAML Attribute Assertion. For example, if theSAML Attribute Assertion Subject contains a <saml:NameIdentifier> element, and the valueof that NameIdentifier matches the value of the <xacml-context:Attribute> having anAttributeId of &resource;resource-id, then <xacml-context:Attribute> instancescreated from <saml:Attribute> instances in that SAML Attribute Assertion SHALL be placedinto the <xacml-context:Resource> element. If the <xacml-context:Attribute> isplaced into an <xacml-context:Subject> element, then the XACML SubjectCategoryXML attribute SHALL also be consistent with the entity that is the Subject of the

access_control-xacml-2.0-saml_profile-spec-cd-02 11 November 2004Copyright © OASIS Open 2004. All Rights Reserved. Page 7 of 22

180

181

182

183

184

185

186

187

188

189

190

191

192

193

194

195

196

197

198

199

200

201

202

203

204

205

206

207

208

209

210

211

212

213

214

215

216

217

218

219

220

221

222

223

224

225

Page 8: SAML 2.0 profile of XACML - OASISdocs.oasis-open.org/xacml/access_control-xacml-2.0-saml... · 2004. 12. 10. · This profile defines how to use SAML 2.0 to protect, transport, and

<saml:Assertion>.

The entity performing the mapping SHALL ensure that the semantics defined by SAML for theelements in the <saml:Assertion> have been adhered to. The mapping entity need notperform these semantic checks itself, but it SHALL ensure that the checks have been done beforeany <xacml:Attribute> created from the <saml:Assertion> is used by an XACML PDP.These semantic checks include, but are not limited to, the following.

• Any NotBefore and NotOnOrAfter XML attributes in the <saml:Assertion> SHALL bevalid with respect to the <xacml:Request> in which the SAML-derived<xacml:Attribute> is used. This means that the NotBefore and NotOnOrAfter XMLattribute values SHALL be consistent with the &environment;current-time,&environment;current-date, and &environment:current-dateTime<xacml:Attribute> values associated with the <xacml:Request>.

• The entity doing the mapping SHALL ensure that the semantics defined by SAML for any<saml:AudienceRestrictionCondition> or <saml:DoNotCacheCondition>elements have been adhered to.

• If a <ds:Signature> element occurs in the <saml:Assertion>, then the entity performingthe mapping SHALL ensure that the signature is valid and that the SAML <Issuer> element isconsistent with any <ds:X509IssuerName> value in the signature. The guidelines regardingdigital signatures in Section 5: SAML and XML Signature Syntax and Processing of the SAMLcore specification [SAML] SHALL be adhered to.

access_control-xacml-2.0-saml_profile-spec-cd-02 11 November 2004Copyright © OASIS Open 2004. All Rights Reserved. Page 8 of 22

226

227

228

229

230

231

232

233

234

235

236

237

238

239

240

241

242

243

244

245

Page 9: SAML 2.0 profile of XACML - OASISdocs.oasis-open.org/xacml/access_control-xacml-2.0-saml... · 2004. 12. 10. · This profile defines how to use SAML 2.0 to protect, transport, and

3 Authorization Decisions (normative)SAML 2.0 defines a rudimentary AuthzDecisionQuery in the SAML Protocol Schema and arudimentary AuthzDecisionStatement in the SAML Assertion Schema. A SAMLAuthzDecisionQuery is unable to convey all the information that an XACML PDP is capable ofaccepting as part of its Request Context. Likewise, the SAML AuthzDecisionStatement is unableto convey all the information contained in an XACML Response Context.

In order to allow a PEP to use the SAML Request and Response syntax with full support for theXACML Request Context and Response Context syntax, this specification defines two SAMLextensions:

• <xacml-samlp:XACMLAuthzDecisionQuery> is a SAML Query that extends the SAMLProtocol Schema. It allows a PEP to submit an XACML Request Context in a SAML Request,along with other information.

• <xacml-saml:XACMLAuthzDecisionStatement> is a SAML Statement that extends theSAML Assertion schema. It allows an XACML PDP to return an XACML Response Context inthe Response to an <XACMLAuthzDecisionStatement>, along with other information. Italso allows an XACML Response Context to be stored or transmitted in the form of a SAMLAssertion.

This Section defines these extensions. The extensions are contained in [XACML-SAML] and[XACML-SAMLP].

3.1 Element <XACMLAuthzDecisionQuery>The <XACMLAuthzDecisionQuery> element MAY be used by a PEP to request anauthorization decision from an XACML PDP. It allows a SAML Request to convey an XACMLRequest Context instance.

<xs:element name=”XACMLAuthzDecisionQuery” type=”XACMLAuthzDecisionQueryType”/><xs:complexType name=”XACMLAuthzDecisionQueryType”> <xs:complexContent> <xs:extension base=”samlp:RequestAbstractType”> <xs:sequence> <xs:element ref=”xacml-context:Request”/>

</xs:sequence> <xs:attribute name="InputContextOnly" type="boolean" use="optional" default="false"/> <xs:attribute name=”ReturnContext” type=”boolean" use=”optional” default="false"/> </xs:extension> </xs:complexContent></xs:complexType>

The <XACMLAuthzDecisionQuery> element is of XACMLAuthzDecisionQueryType complextype. This element is an alternative to the SAML-defined <samlp:AuthzDecisionQuery> thatallows a PEP to use the full capabilities of an XACML PDP.

The <XACMLAuthzDecisionQuery> element contains the following XML attributes andelements:

InputContextOnly [Default “false”]

This XML attribute governs the sources of information that the PDP is allowed to use in

access_control-xacml-2.0-saml_profile-spec-cd-02 11 November 2004Copyright © OASIS Open 2004. All Rights Reserved. Page 9 of 22

246

247

248

249

250

251

252

253

254

255

256

257

258

259

260

261

262

263

264

265

266

267

268

269

270

271

272

273

274

275

Page 10: SAML 2.0 profile of XACML - OASISdocs.oasis-open.org/xacml/access_control-xacml-2.0-saml... · 2004. 12. 10. · This profile defines how to use SAML 2.0 to protect, transport, and

making its authorization decision. If this XML attribute is “true”, then the authorizationdecision SHALL be made solely on the basis of information contained in the<XACMLAuthzDecisionQuery>; no external attributes MAY be used. If this XMLattribute is “false”, then the authorization decision MAY be made on the basis of externalattributes not contained in the <XACMLAuthzDecisionQuery>.

ReturnContext [Default “false”]

This XML attribute allows the PEP to request that an <xacml-context:Request>element be included in the <XACMLAuthzDecisionStatement> resulting from therequest. It also governs the contents of that <xacml-context:Request> element.

If this XML attribute is “true”, then the PDP SHALL include the <xacml-context:Request> element in the <XACMLAuthzDecisionStatement> element inthe <XACMLResponse>. This <xacml-context:Request> element SHALL include allthose attributes supplied by the PEP in the <XACMLAuthzDecisionQuery> that wereused in making the authorization decision. The PDP MAY include additional attributes inthis <xacml-context:Request> element, such as external attributes obtained by thePDP and used in making the authorization decision, or other attributes known by the PDPthat may be useful to the PEP in making subsequent <XACMLAuthzDecisionQuery>requests.

If this XML attribute is “false”, then the PDP SHALL NOT include the <xacml-context:Request> element in the <XACMLAuthzDecisionStatement> element ofthe <XACMLResponse> .

<xacml-context:Request> [Required]

An XACML Request Context.

3.2 Element <XACMLAuthzDecisionStatement>The <XACMLAuthzDecisionStatement> MAY be used by an XACML PDP to return a SAMLResponse containing an XACML Response Context to a PEP in response to an<XACMLAuthzDecisionQuery>. It may also be used in a SAML Assertion as a format forstorage of an authorization decision in a repository.

<xs:element name=”XACMLAuthzDecisionStatement” type=”xacml-saml:XACMLAuthzDecisionStatementType”/><xs:complexType name=”XACMLAuthzDecisionStatementType”> <xs:complexContent> <xs:extension base=”saml:StatementAbstractType”> <xs:sequence> <xs:element ref=”xacml-context:Response”/> <xs:element ref=”xacml-context:Request” MinOccurs=”0”/> </xs:sequence> </xs:extension> </xs:complexContent></xs:complexType>

The <XACMLAuthzDecisionStatement> element is of XACMLAuthzDecisionStatementTypecomplex type. This element is an alternative to the SAML-defined<samlp:AuthzDecisionStatement> that allows a SAML Assertion to contain the full contentof the response from an XACML PDP.

The <XACMLAuthzDecisionStatement> element contains the following elements:

<xacml-context:Response> [Required]

The XACML Response Context created by the XACML PDP in response to the<XACMLAuthzDecisionQuery>.

<xacml-context:Request> [Optional]

access_control-xacml-2.0-saml_profile-spec-cd-02 11 November 2004Copyright © OASIS Open 2004. All Rights Reserved. Page 10 of 22

276

277

278

279

280

281

282

283

284

285

286

287

288

289

290

291

292

293

294

295

296

297

298

299

300

301

302

303

304

305

306

307

308

309

310311

312

Page 11: SAML 2.0 profile of XACML - OASISdocs.oasis-open.org/xacml/access_control-xacml-2.0-saml... · 2004. 12. 10. · This profile defines how to use SAML 2.0 to protect, transport, and

An <xacml-context:Request> containing XACML Attributes returned by the XACMLPDP in response to the <XACMLAuthzDecisionQuery>. This element SHALL beincluded if the ReturnResponse XML attribute in the <XACMLAuthzDecisionQuery>is “true”. This element SHALL NOT be included if the ReturnResponse XML attribute inthe <XACMLAuthzDecisionQuery> is “false”.

See the description of the ReturnContext XML attribute in Section 3.1: Element<XACMLAuthzDecisionQuery> for a description of the XACML <Attribute> valuesthat SHALL be returned in this element.

access_control-xacml-2.0-saml_profile-spec-cd-02 11 November 2004Copyright © OASIS Open 2004. All Rights Reserved. Page 11 of 22

313

314

315

316

317

318

319

320

Page 12: SAML 2.0 profile of XACML - OASISdocs.oasis-open.org/xacml/access_control-xacml-2.0-saml... · 2004. 12. 10. · This profile defines how to use SAML 2.0 to protect, transport, and

4 Policies (normative)XACML defines two policy schema elements: <Policy> and <PolicySet>. SAML does notdefine any Protocol or Assertion schemas for policies. This Section defines new SAMLextensions for <XACMLPolicyQuery> and <XACMLPolicyStatement> elements. Instances ofthese new elements can be used to request, transmit, and store XACML <Policy> and<PolicySet> instances. The new extensions are contained in [XACML-SAML] and [XACML-SAMLP].

4.1 Element <XACMLPolicyQuery>The <XACMLPolicyQuery> element is used by a PDP to request one or more XACML Policy orPolicySet instances from an on-line Policy Administration Point as part of a SAML Request.

<xs:element name=”XACMLPolicyQuery” type=”XACMLPolicyQueryType”/><xs:complexType name=”XACMLPolicyQueryType”> <complexContent> <xs:extension base=”samlp:RequestAbstractType”> <xs:choice minOccurs=”0” maxOccurs=”unbounded”> <xs:element ref=”xacml-context:Request”/> <xs:element ref=”xacml:Target”/> <xs:element ref=”xacml:PolicySetIdReference”/> <xs:element ref=”xacml:PolicyIdReference”/>

</xs:choice> </xs:extension> </xs:complexContent></xs:complexType>

The <XACMLPolicyQuery> element is of XACMLPolicyQueryType complex type.

The <XACMLPolicyQuery> element contains one or more of the following elements:

<xacml-context:Request> [Any Number]

Supplies an XACML Request Context. All XACML Policy and PolicySet instancesapplicable to this Request SHALL be returned. The concept of “applicability” in theXACML context is defined in the XACML 2.0 Specification [XACML].

<xacml:Target> [Any Number]

Supplies an XACML <Target> element. All XACML Policy and PolicySet instancesapplicable to this <Target> SHALL be returned.

<xacml:PolicySetIdReference> [Any Number]

Identifies an XACML <PolicySet> to be returned.

<xacml:PolicyIdReference> [Any Number]

Identifies an XACML <Policy> to be returned.

4.2 Element <XACMLPolicyStatement>The <XACMLPolicyStatement> is used by a Policy Administration Point to return one or moreXACML <Policy> or <PolicySet> instances in a SAML Response to an<XACMLPolicyQuery> SAML Request. The <XACMLPolicyStatement> may also be used ina SAML Assertion as a format for storing the <XACMLPolicyStatement> in a repository.

access_control-xacml-2.0-saml_profile-spec-cd-02 11 November 2004Copyright © OASIS Open 2004. All Rights Reserved. Page 12 of 22

321

322

323

324

325

326

327

328

329

330

331

332

333

334

335

336

337

338

339

340

341

342

343

344

345

346

347

348

Page 13: SAML 2.0 profile of XACML - OASISdocs.oasis-open.org/xacml/access_control-xacml-2.0-saml... · 2004. 12. 10. · This profile defines how to use SAML 2.0 to protect, transport, and

<xs:element name=”XACMLPolicyStatement” type=”xacml-saml:XACMLPolicyStatementType”/><xs:complexType name=”XACMLPolicyStatementType”> <xs:complexContent> <xs:extension base=”saml:StatementAbstractType”> <xs:choice minOccurs=”0” maxOccurs=unbounded”> <xs:element ref=”xacml:Policy”/> <xs:element ref=”xacmlPolicySet”/> </xs:choice> </xs:extension> </xs:complexContent></xs:complexType>

The <XACMLPolicyStatement> element is of XACMLPolicyStatementType complex type.

The <XACMLPolicyStatement> element contains the following elements. If the<XACMLPolicyStatement> is issued in response to an <XACMLPolicyQuery>, and there areno <xacml:Policy> or <xacml:PolicySet> instances that meet the specifications of theassociated <XACMLPolicyQuery>, then there SHALL be no elements in the<XACMLPolicyStatement>.

<xacml:Policy> [Any Number]

An <xacml:Policy> instance that meets the specifications of the associated<XACMLPolicyQuery>, if any.

<xacml:PolicySet> [Any Number]

An <xacml:PolicySet> instance that meets the specifications of the associated<XACMLPolicyQuery>, if any.

access_control-xacml-2.0-saml_profile-spec-cd-02 11 November 2004Copyright © OASIS Open 2004. All Rights Reserved. Page 13 of 22

349

350

351

352

353

354

355

356

357

358

359

360

Page 14: SAML 2.0 profile of XACML - OASISdocs.oasis-open.org/xacml/access_control-xacml-2.0-saml... · 2004. 12. 10. · This profile defines how to use SAML 2.0 to protect, transport, and

5 Element <saml:Assertion> (normative)An <XACMLAuthzDecisionStatement>, <XACMLPolicyStatement>, or SAML standard<saml:AttributeStatement> SHALL be encapsulated in a <saml:Assertion>, which MAYbe signed.

Most components of a <saml:Assertion> are fully specified in the SAML 2.0 specification[SAML]. The following elements and XML attributes are further specified here for use with theSAML statement types defined and used in this Profile.

Except as specified here, this Profile imposes no requirements or restrictions on information in the<saml:Assertion> element.

5.1 Element <saml:Issuer>The <saml:Issuer> element is a required element for holding information about “the SAMLauthority that is making the claim(s) in the assertion” [SAML].

In order to support 3rd party digital signatures, this Profile does NOT require that the identityprovided in the <saml:Issuer> element be consistent with the identity of the signer. It is up tothe relying party to have an appropriate trust relationship with the authority that signs the<saml:Assertion>.

When a <saml:AttributeAssertion> is used to construct an XACML Attribute, the stringvalue of the <saml:Issuer> element will be used as the value of the XACML Issuer XMLattribute, so the SAML value SHOULD be specified with this in mind. See Section 2.1: Mapping aSAML Attribute Assertion to XACML Attributes for more information.

5.2 Element <ds:Signature>The <ds:Signature> element is an optional element for holding “An XML Signature thatauthenticates the assertion, as described in Section 5.”

A <ds:Signature> element MAY be used in an assertion used with an XACML Statement. Inorder to support 3rd party digital signatures, this Profile does NOT require that the identity providedin the <saml:Issuer> element be consistent with the identity of the signer. It is up to the relyingparty to have an appropriate trust relationship with the authority that signs the<saml:Assertion>.

A relying party SHOULD verify any signature included in the assertion and SHOULD NOT useinformation derived from the assertion unless the signature is verified successfully.

5.3 Element <saml:Subject>The <saml:Subject> element is an optional element used for holding “The subject of thestatement(s) in the assertion” [SAML].

The <saml:Subject> element SHALL NOT be included in an assertion that contains an<XACMLAuthzDecision> or <XACMLPolicy>.

In a <saml:AttributeAssertion> that is to be mapped to an XACML Attribute, the<saml:Subject> element SHALL contain the identity of the entity to which the attribute and itsvalue are bound. For an XACML <Subject> Attribute, this identity SHOULD be consistent withthe value of any XACML &subject-id; Attribute that occurs in the same <Subject> element.For an XACML <Resource> Attribute, this identity SHOULD be consistent with the value of anyXACML &resource-id; Attribute that occurs in the same <Resource> element. For anXACML <Action> Attribute, this identity SHOULD be consistent with the value of any XACML&action-id; Attribute that occurs in the same <Action> element. For an XACML<Environment> Attribute, this identity SHOULD be consistent with the value of any XACML

access_control-xacml-2.0-saml_profile-spec-cd-02 11 November 2004Copyright © OASIS Open 2004. All Rights Reserved. Page 14 of 22

361

362

363

364

365

366

367

368

369

370

371

372

373

374

375

376

377

378

379

380

381

382

383

384

385

386

387

388

389

390

391

392

393

394

395

396

397

398

399

400

401

402

403

404

Page 15: SAML 2.0 profile of XACML - OASISdocs.oasis-open.org/xacml/access_control-xacml-2.0-saml... · 2004. 12. 10. · This profile defines how to use SAML 2.0 to protect, transport, and

Attribute that occurs in the same <Environment> element and provides an environment identity.

5.4 Element <saml:Conditions>The <saml:Conditions> element is an optional element that is used for “conditions that MUSTbe taken into account in assessing the validity of and/or using the assertion” [SAML].

The <saml:Conditions> element SHOULD contain NotBefore and NotOnOrAfter XMLattributes to specify the limits on the validity of the assertion. If these XML attributes are present,the relying party SHOULD ensure that information derived from the assertion is used by a PDPfor evaluating policies only when the value of the request context &current-dateTime;resource attribute is contained within the assertion's specified validity period.

access_control-xacml-2.0-saml_profile-spec-cd-02 11 November 2004Copyright © OASIS Open 2004. All Rights Reserved. Page 15 of 22

405

406

407

408

409

410

411

412

413

Page 16: SAML 2.0 profile of XACML - OASISdocs.oasis-open.org/xacml/access_control-xacml-2.0-saml... · 2004. 12. 10. · This profile defines how to use SAML 2.0 to protect, transport, and

6 Element <samlp:RequestAbstractType>(normative)

An <XACMLAuthzDecisionQuery> or <XACMLPolicyQuery> SHALL be encapsulated in a<samlp:RequestAbstractType> element, which MAY be signed.

Most components of a <samlp:RequestAbstractType> are fully specified in the SAML 2.0specification [SAML]. The following elements and XML attributes are further specified here for usewith the SAML query types defined and used in this Profile. Except as specified here, this Profileimposes no requirements or restrictions on information in the <samlp:RequestAbstractType>element.

6.1 Element <saml:Issuer>See Section 5.1: Element <saml:Issuer>.

6.2 Element <ds:Signature>See Section 5.2: Element <ds:Signature>.

access_control-xacml-2.0-saml_profile-spec-cd-02 11 November 2004Copyright © OASIS Open 2004. All Rights Reserved. Page 16 of 22

414

415

416

417

418

419

420

421

422

423

424

425

426

Page 17: SAML 2.0 profile of XACML - OASISdocs.oasis-open.org/xacml/access_control-xacml-2.0-saml... · 2004. 12. 10. · This profile defines how to use SAML 2.0 to protect, transport, and

7 Element <samlp:Response> (normative)An <XACMLAuthzDecisionStatement> or <XACMLPolicyStatement> SHALL beencapsulated in a <samlp:Response> element, which MAY be signed.

Most components of a <samlp:Response> are fully specified in the SAML 2.0 specification[SAML]. The following elements and XML attributes are further specified here for use with theSAML statement types defined and used in this Profile. Except as specified here, this Profileimposes no requirements or restrictions on information in the <samlp:Response> element.

7.1 Element <samlp:Issuer>See Section 5.1: Element <saml:Issuer>.

7.2 Element <ds:Signature>See Section 5.2: Element <ds:Signature>.

7.3 Element <samlp:StatusCode>The <samlp:StatusCode> element is a component of the <samlp:Status> element in the<samlp:Response>.

7.3.1 Response to <XACMLAuthzDecisionQuery>In the response to an <XACMLAuthzDecisionQuery> request, the <samlp:StatusCode>Value XML attribute SHALL depend on the <xacml:StatusCode> element of the authorizationdecision <xacml:Status> element as follows:

urn:oasis:names:tc:SAML:2.0:status:Success

This value for the <samlp:StatusCode> Value XML attribute SHALL be used if andonly if the <xacml:StatusCode> value isurn:oasis:names:tc:xacml:1.0:status:ok.

urn:oasis:names:tc:SAML:2.0:status:Requester

This value for the <samlp:StatusCode> Value XML attribute SHALL be used when the<xacml:StatusCode> value isurn:oasis:names:tc:xacml:1.0:status:missing-attribute or the when the<xacml:StatusCode> value isurn:oasis:names:tc:xacml:1.0:status:syntax-error due to a syntax error inthe <xacml:Request>.

urn:oasis:names:tc:SAML:2.0:status:Responder

This value for the <samlp:StatusCode> Value XML attribute SHALL be used when the<xacml:StatusCode> value isurn:oasis:names:tc:xacml:1.0:status:syntax-error due to a syntax error inan <xacml:Policy> or <xacml:PolicySet>. Note that not all syntax errors inpolicies will be detected in conjunction with the processing of a particular query, so not allpolicy syntax errors will be reported this way.

urn:oasis:names:tc:SAML:2.0:status:VersionMismatch

This value for the <samlp:StatusCode> Value XML attribute SHALL be used only whenthe SAML interface at the PDP does not support the version of the SAML requestmessage used in the query.

access_control-xacml-2.0-saml_profile-spec-cd-02 11 November 2004Copyright © OASIS Open 2004. All Rights Reserved. Page 17 of 22

427

428

429

430

431

432

433

434

435

436

437

438

439

440

441

442

443

444

445

446

447

448

449

450

451

452

453

454

455

456

457

458

459

460

461

462

463

464

465

466

Page 18: SAML 2.0 profile of XACML - OASISdocs.oasis-open.org/xacml/access_control-xacml-2.0-saml... · 2004. 12. 10. · This profile defines how to use SAML 2.0 to protect, transport, and

7.3.2 Response to <XACMLPolicyQuery>In the response to an <XACMLPolicyQuery> request, the <samlp:StatusCode> Value XMLattribute SHALL be as specified in the SAML specification.

access_control-xacml-2.0-saml_profile-spec-cd-02 11 November 2004Copyright © OASIS Open 2004. All Rights Reserved. Page 18 of 22

467

468

469

Page 19: SAML 2.0 profile of XACML - OASISdocs.oasis-open.org/xacml/access_control-xacml-2.0-saml... · 2004. 12. 10. · This profile defines how to use SAML 2.0 to protect, transport, and

8 References

8.1 Normative References

[RFC2119] S. Bradner, Key words for use in RFCs to Indicate Requirement Levels,IETF RFC 2119, March 1997, http://www.ietf.org/rfc/rfc2119.txt.

[SAML] S. Cantor, et al., eds., Assertions and Protocols for the OASIS SecurityAssertion Markup Language (SAML) V2.0, Committee Draft 01c, 18September 2004, http://www.oasis-open.org/committees/documents.php?wg_abbrev=security.

[SAML-PROFILE] J. Hughes, et al., eds., Profiles for the OASIS Security Assertion MarkupLanguage (SAML) V2.0, Committee Draft 01b, 14 September 2004,http://www.oasis-open.org/committees/documents.php?wg_abbrev=security.

[XACML] S. Godik, T. Moses, eds., OASIS eXtensible Access Control MarkupLanguage (XACML) Version 2.0, Committee Draft 01, 16 September2004, http://docs.oasis-open.org/xacml/access_control-xacml-2.0-core-spec-cd-01.pdf.

[XACML-SAML] A. Anderson, ed., access_control-xacml-2.0-saml-assertion-schema-cd-01.xsd, http://docs.oasis-open.org/xacml/access_control-xacml-2.0-saml-assertion-schema-cd-01.xsd.

[XACML-SAMLP] A. Anderson, ed., access_control-xacml-2.0-saml-protocol-schema-cd-01.xsd, http://docs.oasis-open.org/xacml/access_control-xacml-2.0-saml-protocol-schema-cd-01.xsd.

8.2 Non-normative References[XACMLIntro] S. Proctor, A Brief Introduction to XACML, http://www.oasis-

open.org/committees/download.php/2713/Brief_Introduction_to_XACML.html, 14 March 2003.

access_control-xacml-2.0-saml_profile-spec-cd-02 11 November 2004Copyright © OASIS Open 2004. All Rights Reserved. Page 19 of 22

470

471

472

473

474

475

476

477

478

479

480

481

482

483

484

485

486

487

488

489

490

491

492

493

494

495

496

Page 20: SAML 2.0 profile of XACML - OASISdocs.oasis-open.org/xacml/access_control-xacml-2.0-saml... · 2004. 12. 10. · This profile defines how to use SAML 2.0 to protect, transport, and

A. Acknowledgments

The editors would like to acknowledge the contributions of the OASIS XXX Technical Committee,whose voting members at the time of publication were:

• Frank Siebenlist, Argonne National Laboratory

• Daniel Engovatov, BEA Systems, Inc.

• Hal Lockhart, BEA Systems, Inc.

• Rebekah Metz, Booz Allen Hamilton

• Ronald Jacobson, Computer Associates

• Tim Moses, Entrust

• Simon Godik, GlueCode Software

• Bill Parducci, GlueCode Software

• Michiharu Kudo, IBM

• Michael McIntosh, IBM

• Anthony Nadalin, IBM

• Steve Anderson, OpenNetwork

• Anne Anderson, Sun Microsystems

• Seth Proctor, Sun Microsystems

• Polar Humenn, Syracuse University

• Edward Coyne, Veterans Health Administration

access_control-xacml-2.0-saml_profile-spec-cd-02 11 November 2004Copyright © OASIS Open 2004. All Rights Reserved. Page 20 of 22

497

498

499

500

501

502

503

504

505

506

507

508

509

510

511

512

513

514

515

Page 21: SAML 2.0 profile of XACML - OASISdocs.oasis-open.org/xacml/access_control-xacml-2.0-saml... · 2004. 12. 10. · This profile defines how to use SAML 2.0 to protect, transport, and

B. Revision History

Rev Date By Whom What

CD-01 16 Sept 2004 XACML committee Committee Draft

CD-02 11 Nov 2004 XACML committee -Section 5.1: changed “the string value of the<saml:Issuer> element SHALL be used” to “thestring value of the <saml:Issuer> element will beused”

-Replaced <samlp:Request> with<samlp:RequestAbstractType>

access_control-xacml-2.0-saml_profile-spec-cd-02 11 November 2004Copyright © OASIS Open 2004. All Rights Reserved. Page 21 of 22

516

517

518

Page 22: SAML 2.0 profile of XACML - OASISdocs.oasis-open.org/xacml/access_control-xacml-2.0-saml... · 2004. 12. 10. · This profile defines how to use SAML 2.0 to protect, transport, and

C. Notices

OASIS takes no position regarding the validity or scope of any intellectual property or other rightsthat might be claimed to pertain to the implementation or use of the technology described in thisdocument or the extent to which any license under such rights might or might not be available;neither does it represent that it has made any effort to identify any such rights. Information onOASIS's procedures with respect to rights in OASIS specifications can be found at the OASISwebsite. Copies of claims of rights made available for publication and any assurances of licensesto be made available, or the result of an attempt made to obtain a general license or permissionfor the use of such proprietary rights by implementors or users of this specification, can beobtained from the OASIS Executive Director.

OASIS invites any interested party to bring to its attention any copyrights, patents or patentapplications, or other proprietary rights which may cover technology that may be required toimplement this specification. Please address the information to the OASIS Executive Director.

Copyright © OASIS Open 2004. All Rights Reserved.

This document and translations of it may be copied and furnished to others, and derivative worksthat comment on or otherwise explain it or assist in its implementation may be prepared, copied,published and distributed, in whole or in part, without restriction of any kind, provided that theabove copyright notice and this paragraph are included on all such copies and derivative works.However, this document itself does not be modified in any way, such as by removing the copyrightnotice or references to OASIS, except as needed for the purpose of developing OASISspecifications, in which case the procedures for copyrights defined in the OASIS IntellectualProperty Rights document must be followed, or as required to translate it into languages otherthan English.

The limited permissions granted above are perpetual and will not be revoked by OASIS or itssuccessors or assigns.

This document and the information contained herein is provided on an “AS IS” basis and OASISDISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TOANY WARRANTY THAT THE USE OF THE INFORMATION HEREIN WILL NOT INFRINGE ANYRIGHTS OR ANY IMPLIED WARRANTIES OF MERCHANTABILITY OR FITNESS FOR APARTICULAR PURPOSE.

access_control-xacml-2.0-saml_profile-spec-cd-02 11 November 2004Copyright © OASIS Open 2004. All Rights Reserved. Page 22 of 22

519

520

521

522

523

524

525

526

527

528

529

530

531

532

533

534

535

536

537

538

539

540

541

542

543

544

545

546

547

548