SAML belirteci beyanları başvurusu

Microsoft kimlik platformu, her kimlik doğrulama akışının işlenmesinde çeşitli türlerde güvenlik belirteci yayar. Bu belgede SAML 2.0 belirteçlerinin biçimi, güvenlik özellikleri ve içeriği açıklanmaktadır.

SAML belirteçlerindeki beyanlar

Veri Akışı Adı Eşdeğer JWT Talebi Açıklama Örnek
Hedef Kitle aud Belirtecin hedeflenen alıcısı. Belirteci alan uygulamanın hedef kitle değerinin doğru olduğunu doğrulaması ve farklı bir hedef kitleye yönelik belirteçleri reddetmesi gerekir. <AudienceRestriction>
<Audience>
https://contoso.com
</Audience>
</AudienceRestriction>
Kimlik Doğrulaması Anı Kimlik doğrulamasının gerçekleştiği tarihi ve saati kaydeder. <AuthnStatement AuthnInstant="2011-12-29T05:35:22.000Z">
Kimlik Doğrulama Yöntemi amr Belirtecin sahibinin kimliğinin nasıl doğrulandığını tanımlar. <AuthnContextClassRef>
http://schemas.microsoft.com/ws/2008/06/identity/claims/authenticationmethod/password
</AuthnContextClassRef>
Ad given_name Microsoft Entra kullanıcı nesnesinde ayarlandığı gibi kullanıcının ilk veya "verilen" adını sağlar. <Attribute Name="http://schemas.xmlsoap.org/ws/2005/05/identity/claims/givenname">
<AttributeValue>Frank<AttributeValue>
Gruplar groups Konunun grup üyeliklerini temsil eden nesne kimlikleri sağlar. Bu değerler benzersizdir (bkz. Nesne Kimliği) ve bir kaynağa erişmek için yetkilendirme zorunlu kılma gibi erişimi yönetmek için güvenle kullanılabilir. Gruplar talebine dahil edilen gruplar, uygulama bildiriminin "groupMembershipClaims" özelliği aracılığıyla uygulama başına yapılandırılır. Null değeri tüm grupları dışlar, "SecurityGroup" değeri dizin rollerini ve Active Directory Güvenlik Grubu üyeliklerini içerir ve "Tümü" değeri hem Güvenlik Gruplarını hem de Microsoft 365 Dağıtım Listelerini içerir.

Notlar:
Kullanıcının içinde bulunduğu grup sayısı bir sınırın üzerindeyse (SAML için 150, JWT için 200) fazla kullanım talebi, kullanıcı için grupların listesini içeren Graph uç noktasına işaret eden talep kaynakları eklenir.
<Attribute Name="http://schemas.microsoft.com/ws/2008/06/identity/claims/groups">
<AttributeValue>07dd8a60-bf6d-4e17-8844-230b77145381</AttributeValue>
Gruplar Fazla Kullanım Göstergesi groups:src1 Uzunluğu sınırlı olmayan ancak belirteç için hala çok büyük olan belirteç istekleri için, kullanıcının tam grup listesine bir bağlantı eklenir. SAML için bu, talebin groups yerine yeni bir talep olarak eklenir.

Notlar:
Azure AD Graph API'sinin yerini Microsoft Graph API'sini alır. Eşdeğer uç nokta hakkında daha fazla bilgi edinmek için bkz . kullanıcı: getMemberObjects.
<Attribute Name=" http://schemas.microsoft.com/claims/groups.link">
<AttributeValue>https://graph.windows.net/{tenantID}/users/{userID}/getMemberObjects<AttributeValue>
Kimlik Sağlayıcısı idp Belirtecin öznesinin kimliğini doğrulayan kimlik sağlayıcısını kaydeder. Bu değer, kullanıcı hesabı verenden farklı bir kiracıda olmadığı sürece Veren talebi değeriyle aynıdır. <Attribute Name=" http://schemas.microsoft.com/identity/claims/identityprovider">
<AttributeValue>https://sts.windows.net/aaaabbbb-0000-cccc-1111-dddd2222eeee/<AttributeValue>
VerilenAyrı iat Belirtecin verildiği zamanı depolar. Genellikle belirtecin yeniliğini ölçmek için kullanılır. <Assertion ID="_d5ec7a9b-8d8f-4b44-8c94-9812612142be" IssueInstant="2014-01-06T20:20:23.085Z" Version="2.0" xmlns="urn:oasis:names:tc:SAML:2.0:assertion">
Sertifikayı veren iss Belirteci oluşturan ve döndüren güvenlik belirteci hizmetini (STS) tanımlar. Microsoft Entra Id'nin döndürdüğü belirteçlerde veren sts.windows.net. Veren talep değerindeki GUID, Microsoft Entra dizininin kiracı kimliğidir. Kiracı kimliği, dizinin sabit ve güvenilir bir tanımlayıcısıdır. <Issuer>https://sts.windows.net/aaaabbbb-0000-cccc-1111-dddd2222eeee/</Issuer>
Soyadı family_name Microsoft Entra kullanıcı nesnesinde tanımlandığı gibi kullanıcının soyadını, soyadını veya aile adını sağlar. <Attribute Name=" http://schemas.xmlsoap.org/ws/2005/05/identity/claims/surname">
<AttributeValue>Miller<AttributeValue>
Veri Akışı Adı unique_name Belirtecin konusunu tanımlayan ve okunabilir bir değer sunar. Bu değerin bir kiracı içinde benzersiz olması garanti değildir ve yalnızca görüntüleme amacıyla kullanılacak şekilde tasarlanmıştır. <Attribute Name="http://schemas.xmlsoap.org/ws/2005/05/identity/claims/name">
<AttributeValue>frankm@contoso.com<AttributeValue>
Nesne kimliği oid Microsoft Entra Id'de bir nesnenin benzersiz tanımlayıcısı içerir. Bu değer sabittir ve yeniden atanamaz veya yeniden kullanılamaz. Microsoft Entra Id sorgularındaki bir nesneyi tanımlamak için nesne kimliğini kullanın. <Attribute Name="http://schemas.microsoft.com/identity/claims/objectidentifier">
<AttributeValue>528b2ac2-aa9c-45e1-88d4-959b53bc7dd0<AttributeValue>
Roller roles Konuya hem doğrudan hem de dolaylı olarak grup üyeliği aracılığıyla verilmiş olan ve rol tabanlı erişim denetimini zorunlu kılmak için kullanılabilen tüm uygulama rollerini temsil eder. Uygulama rolleri, uygulama bildiriminin appRoles özelliği aracılığıyla uygulama başına temelinde tanımlanır. value Her bir uygulama rolünün özelliği, rol talebinde görünen değerdir. <Attribute Name="http://schemas.microsoft.com/ws/2008/06/identity/claims/role">
Konu sub Belirtecin, bir uygulamanın kullanıcısı gibi bilgileri onayladığı sorumluyu tanımlar. Bu değer sabittir ve yeniden atanamaz veya yeniden kullanılamaz, bu nedenle yetkilendirme denetimlerini güvenli bir şekilde gerçekleştirmek için kullanılabilir. Konu, Microsoft Entra Id sorunlarının belirteçlerinde her zaman mevcut olduğundan, bu değerin genel amaçlı yetkilendirme sisteminde kullanılması önerilir.
SubjectConfirmation bir talep değildir. Belirtecin konusunun nasıl doğrulandığı açıklanır. Bearer , konunun belirtecin sahip olduğu tarafından onaylandığını gösterir.
<Subject>
<NameID>S40rgb3XjhFTv6EQTETkEzcgVmToHKRkZUIsJlmLdVc</NameID>
<SubjectConfirmation Method="urn:oasis:names:tc:SAML:2.0:cm:bearer" />
</Subject>
Kiracı kimliği tid Belirteci veren dizin kiracısını tanımlayan sabit, yeniden kullanılamayan bir tanımlayıcı. Çok kiracılı bir uygulamada kiracıya özgü dizin kaynaklarına erişmek için bu değeri kullanabilirsiniz. Örneğin, Graph API'sine yapılan bir çağrıda kiracıyı tanımlamak için bu değeri kullanabilirsiniz. <Attribute Name="http://schemas.microsoft.com/identity/claims/tenantid">
<AttributeValue>aaaabbbb-0000-cccc-1111-dddd2222eeee<AttributeValue>
Belirteç Ömrü nbf, exp Belirtecin geçerli olduğu zaman aralığını tanımlar. Belirteci doğrulayan hizmet geçerli tarihin belirteç ömrü içinde olduğunu doğrulamalıdır, aksi halde belirteci reddetmelidir. Hizmet, Microsoft Entra Id ile hizmet arasındaki saat süresi ("zaman dengesizliği") farklarını hesaba eklemek için belirteç yaşam süresi aralığının beş dakika kadar ötesine izin verebilir. <Conditions
NotBefore="2013-03-18T21:32:51.261Z"
NotOnOrAfter="2013-03-18T22:32:51.261Z"
>

Örnek SAML Belirteci

Bu, tipik bir SAML belirtecinin bir örneğidir.

<?xml version="1.0" encoding="UTF-8"?>
<t:RequestSecurityTokenResponse xmlns:t="http://schemas.xmlsoap.org/ws/2005/02/trust">
    <t:Lifetime>
        <wsu:Created xmlns:wsu="https://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd">2014-12-24T05:15:47.060Z</wsu:Created>
        <wsu:Expires xmlns:wsu="https://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd">2014-12-24T06:15:47.060Z</wsu:Expires>
    </t:Lifetime>
    <wsp:AppliesTo xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy">
        <EndpointReference xmlns="https://www.w3.org/2005/08/addressing">
            <Address>https://contoso.onmicrosoft.com/MyWebApp</Address>
        </EndpointReference>
    </wsp:AppliesTo>
    <t:RequestedSecurityToken>
        <Assertion xmlns="urn:oasis:names:tc:SAML:2.0:assertion" ID="_3ef08993-846b-41de-99df-b7f3ff77671b" IssueInstant="2014-12-24T05:20:47.060Z" Version="2.0">
            <Issuer>https://sts.windows.net/aaaabbbb-0000-cccc-1111-dddd2222eeee/</Issuer>
            <ds:Signature xmlns:ds="https://www.w3.org/2000/09/xmldsig#">
                <ds:SignedInfo>
                    <ds:CanonicalizationMethod Algorithm="https://www.w3.org/2001/10/xml-exc-c14n#" />
                    <ds:SignatureMethod Algorithm="https://www.w3.org/2001/04/xmldsig-more#rsa-sha256" />
                    <ds:Reference URI="#_3ef08993-846b-41de-99df-b7f3ff77671b">
                        <ds:Transforms>
                            <ds:Transform Algorithm="https://www.w3.org/2000/09/xmldsig#enveloped-signature" />
                            <ds:Transform Algorithm="https://www.w3.org/2001/10/xml-exc-c14n#" />
                        </ds:Transforms>
                        <ds:DigestMethod Algorithm="https://www.w3.org/2001/04/xmlenc#sha256" />
                        <ds:DigestValue>cV1J580U1pD24hEyGuAxrbtgROVyghCqI32UkER/nDY=</ds:DigestValue>
                    </ds:Reference>
                </ds:SignedInfo>
                <ds:SignatureValue>j+zPf6mti8Rq4Kyw2NU2nnu0pb{lots of characters}ut93UTyTAIGOs5fvP9ZfK2vNeMVJW7Xg==</ds:SignatureValue>
                <KeyInfo xmlns="https://www.w3.org/2000/09/xmldsig#">
                    <X509Data>
                        <X509Certificate>MIIDPjCCAabcAwIBAgIQsRiM0jheFZhKk49YD0SK1TAJBgUrDg{lots of characters}OBcXWLAIarZ</X509Certificate>
                    </X509Data>
                </KeyInfo>
            </ds:Signature>
            <Subject>
                <NameID Format="urn:oasis:names:tc:SAML:2.0:nameid-format:persistent">m_H3naDei2LNxUmEcWd0BZlNi_jVET1pMLR6iQSuYmo</NameID>
                <SubjectConfirmation Method="urn:oasis:names:tc:SAML:2.0:cm:bearer" />
            </Subject>
            <Conditions NotBefore="2014-12-24T05:15:47.060Z" NotOnOrAfter="2014-12-24T06:15:47.060Z">
                <AudienceRestriction>
                    <Audience>https://contoso.onmicrosoft.com/MyWebApp</Audience>
                </AudienceRestriction>
            </Conditions>
            <AttributeStatement>
                <Attribute Name="http://schemas.microsoft.com/identity/claims/objectidentifier">
                    <AttributeValue>aaaaaaaa-0000-1111-2222-bbbbbbbbbbbb</AttributeValue>
                </Attribute>
                <Attribute Name="http://schemas.microsoft.com/identity/claims/tenantid">
                    <AttributeValue>aaaabbbb-0000-cccc-1111-dddd2222eeee</AttributeValue>
                </Attribute>
                <Attribute Name="http://schemas.xmlsoap.org/ws/2005/05/identity/claims/name">
                    <AttributeValue>sample.admin@contoso.onmicrosoft.com</AttributeValue>
                </Attribute>
                <Attribute Name="http://schemas.xmlsoap.org/ws/2005/05/identity/claims/surname">
                    <AttributeValue>Admin</AttributeValue>
                </Attribute>
                <Attribute Name="http://schemas.xmlsoap.org/ws/2005/05/identity/claims/givenname">
                    <AttributeValue>Sample</AttributeValue>
                </Attribute>
                <Attribute Name="http://schemas.microsoft.com/ws/2008/06/identity/claims/groups">
                    <AttributeValue>5581e43f-6096-41d4-8ffa-04e560bab39d</AttributeValue>
                    <AttributeValue>07dd8a89-bf6d-4e81-8844-230b77145381</AttributeValue>
                    <AttributeValue>0e129f4g-6b0a-4944-982d-f776000632af</AttributeValue>
                    <AttributeValue>3ee07328-52ef-4739-a89b-109708c22fb5</AttributeValue>
                    <AttributeValue>329k14b3-1851-4b94-947f-9a4dacb595f4</AttributeValue>
                    <AttributeValue>6e32c650-9b0a-4491-b429-6c60d2ca9a42</AttributeValue>
                    <AttributeValue>f3a169a7-9a58-4e8f-9d47-b70029v07424</AttributeValue>
                    <AttributeValue>8e2c86b2-b1ad-476d-9574-544d155aa6ff</AttributeValue>
                    <AttributeValue>1bf80264-ff24-4866-b22c-6212e5b9a847</AttributeValue>
                    <AttributeValue>4075f9c3-072d-4c32-b542-03e6bc678f3e</AttributeValue>
                    <AttributeValue>76f80527-f2cd-46f4-8c52-8jvd8bc749b1</AttributeValue>
                    <AttributeValue>0ba31460-44d0-42b5-b90c-47b3fcc48e35</AttributeValue>
                    <AttributeValue>edd41703-8652-4948-94a7-2d917bba7667</AttributeValue>
                </Attribute>
                <Attribute Name="http://schemas.microsoft.com/identity/claims/identityprovider">
                    <AttributeValue>https://sts.windows.net/aaaabbbb-0000-cccc-1111-dddd2222eeee/</AttributeValue>
                </Attribute>
            </AttributeStatement>
            <AuthnStatement AuthnInstant="2014-12-23T18:51:11.000Z">
                <AuthnContext>
                    <AuthnContextClassRef>urn:oasis:names:tc:SAML:2.0:ac:classes:Password</AuthnContextClassRef>
                </AuthnContext>
            </AuthnStatement>
        </Assertion>
    </t:RequestedSecurityToken>
    <t:RequestedAttachedReference>
        <SecurityTokenReference xmlns="https://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" xmlns:d3p1="https://docs.oasis-open.org/wss/oasis-wss-wssecurity-secext-1.1.xsd" d3p1:TokenType="http://docs.oasis-open.org/wss/oasis-wss-saml-token-profile-1.1#SAMLV2.0">
            <KeyIdentifier ValueType="http://docs.oasis-open.org/wss/oasis-wss-saml-token-profile-1.1#SAMLID">_3ef08993-846b-41de-99df-b7f3ff77671b</KeyIdentifier>
        </SecurityTokenReference>
    </t:RequestedAttachedReference>
    <t:RequestedUnattachedReference>
        <SecurityTokenReference xmlns="https://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" xmlns:d3p1="https://docs.oasis-open.org/wss/oasis-wss-wssecurity-secext-1.1.xsd" d3p1:TokenType="http://docs.oasis-open.org/wss/oasis-wss-saml-token-profile-1.1#SAMLV2.0">
            <KeyIdentifier ValueType="http://docs.oasis-open.org/wss/oasis-wss-saml-token-profile-1.1#SAMLID">_3ef08993-846b-41de-99df-b7f3ff77671b</KeyIdentifier>
        </SecurityTokenReference>
    </t:RequestedUnattachedReference>
    <t:TokenType>http://docs.oasis-open.org/wss/oasis-wss-saml-token-profile-1.1#SAMLV2.0</t:TokenType>
    <t:RequestType>http://schemas.xmlsoap.org/ws/2005/02/trust/Issue</t:RequestType>
    <t:KeyType>http://schemas.xmlsoap.org/ws/2005/05/identity/NoProofKey</t:KeyType>
</t:RequestSecurityTokenResponse>

Sonraki adımlar