6.7 跨域屬性查詢接口(IF-CDAQ)
IF-CDAQ是不同域的訪問控制屬性應答組件之間的接口。IF-CDAQ接口主要用于外域訪問控制屬性應答組件查詢本域某個主體的屬性。本域訪問控制屬性應答組件獲取主體的屬性后,將查詢到的屬性轉為指定格式,然后返回給外域的訪問控制屬性應答組件。
6.7.1 跨域屬性查詢支持類型接口(IF-CDAQ-SupportAT)
6.7.1.1 功能
訪問控制屬性應答組件應提供外域可查詢的屬性類型。一般情況下,外域可查詢的屬性類型要少于本域可查詢的屬性類型。
6.7.1.2 輸出參數
IF-CDAQ-SupportAT接口輸出參數描述如下:
a) 輸出參數定義
<?xml version="1.0" encoding="utf-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xs:element name="SupportAT">
<xs:complexType>
<xs:sequence>
<xs:element name="attributeId" type="xs:ID" minOccurs="0" maxOccurs="unbounded"/>
<xs:element name="messageCode" type="xs:string"/>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:schema>
b) 輸出參數說明
1) 調用跨域屬性查詢支持類型接口應可以獲得訪問控制屬性應答組件外域可查詢的屬性類型信息。返回值的數據結構,以及屬性類型的標識由訪問控制屬性應答組件自行規定。
2) 調用跨域屬性查詢支持類型接口應能夠得到一個預定義的消息碼。
表1 IF-CDAQ-SupportAT接口可以返回的消息碼
| 返回消息碼 | 條件 |
|---|---|
| IF_RESULT_SUCCESS | 獲取跨域屬性查詢支持屬性類型成功 |
| IF_RESULT_FAIL | 獲取跨域屬性查詢支持屬性類型失敗 |
6.7.2 跨域屬性查詢返回格式接口(IF-CDAQ-SupportSchema)
6.7.1.1 功能
訪問控制屬性應答組件應提供跨域屬性查詢結果返回格式。例如以SAML斷言格式返回跨域屬性查詢結果。
6.7.1.2 輸出參數
IF-CDAQ-SupportSchema接口輸出參數描述如下:
a) 輸出參數定義
<?xml version="1.0" encoding="utf-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xs:element name="SupportSchema">
<xs:complexType>
<xs:sequence>
<xs:element name="schemaName" type="xs:string" minOccurs="0" maxOccurs="unbounded"/>
<xs:element name="messageCode" type="xs:string"/>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:schema>
c) 輸出參數說明
1) 調用跨域屬性查詢返回格式接口應可以獲得訪問控制屬性應答組件跨域屬性查詢結果返回格式。返回格式的標識由訪問控制屬性應答組件自行規定。
2) 調用屬性查詢返回格式接口應能夠得到一個預定義的消息碼。
表2 IF-CDAQ-SupportSchema接口可以返回的消息碼
| 返回消息碼 | 條件 |
|---|---|
| IF_RESULT_SUCCESS | 獲取跨域屬性查詢返回格式成功 |
| IF_RESULT_FAIL | 獲取跨域屬性查詢返回格式失敗 |
6.7.2 跨域屬性查詢獲取屬性接口(IF-CDAQ-GetAttribute)
6.7.2.1 功能
訪問控制屬性應答組件應能夠返回外域查詢的本域某一主體所具有的屬性。調用此接口前一般應先調用跨域屬性查詢支持類型接口和跨域屬性查詢返回格式接口,以確定外域可查詢的屬性類型以及屬性查詢結果的返回格式。
6.7.2.2 輸入參數
IF-CDAQ-GetAttribute接口輸入參數描述如下:
a) 輸入參數定義
<?xml version="1.0" encoding="utf-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xs:element name="getAttributeRequest">
<xs:complexType>
<xs:sequence>
<xs:element name="userId" type="xs:ID"/>
<xs:element name="attributeId" type="xs:ID" minOccurs="0"/>
<xs:element name="Issuer" type="xs:QName" minOccurs="0"/>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:schema>
d) 輸入參數說明
1) 調用跨域屬性查詢獲取屬性接口應提供所查詢主體的唯一標識
2) 調用跨域屬性查詢獲取屬性接口應提供所要查詢的屬性類型標識
3) 調用跨域屬性查詢獲取屬性接口可以但不是必須提供所查詢屬性的頒發者
6.7.2.3 輸出參數
IF-CDAQ-GetAttribute接口輸出參數描述如下:
a) 輸出參數定義
<?xml version="1.0" encoding="utf-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xs:element name="getAttributeResponse">
<xs:complexType>
<xs:sequence>
<xs:element name="attribute" maxOccurs="unbounded">
<xs:complexType>
<xs:sequence>
<xs:element name="attributeId" type="xs:ID"/>
<xs:element name="attributeValue" type="xs:string"/>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="messageCode" type="xs:string"/>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:schema>
e) 輸出參數說明
1) 調用屬性查詢獲取屬性接口應獲得某一主體擁有的屬性信息。屬性信息的格式通過調用屬性查詢返回格式指定。
2) 調用屬性查詢獲取接口應能夠得到一個預定義的消息碼。
表3 IF-CDAQ-GetAttribute接口可以返回的消息碼
| 返回消息碼 | 條件 |
|---|---|
| IF_RESULT_SUCCESS | 獲取某一個主體的屬性成功 |
| IF_RESULT_FAIL | 獲取某一個主體的屬性失敗 |
| IF_RESULT_INVALID_PARAM | 屬性查詢類型標識不支持 |
GB/T 37076—2018 信息安全技術 鑒別與授權 訪問控制中間件框架與接口
推薦文章: