Harici kimlik doğrulama etkinleştiriliyor

Bu bölümde, bir web sitesini ziyaret etmek için gereken bileşenlerin nasıl edinileceği, yükleneceği ve Kullanıcı kimlik doğrulaması için Apigee Edge'e bir LDAP hizmeti entegre etmesi gerekir.

Ön koşullar

  • Private Cloud 4.18.05 yüklemesi için Apigee Edge'e sahip olmanız gerekir.
  • Private Cloud için Apigee Edge'de küresel sistem yöneticisi kimlik bilgilerine sahip olmanız gerekir: bu yüklemeyi gerçekleştireceğim.
  • Private Cloud kurulumu için Apigee Edge'in kök dizinini bilmeniz gerekir. İlgili içeriği oluşturmak için kullanılan varsayılan kök dizin /opt şeklindedir.
  • Edge global sistem yöneticisi kimlik bilgilerinizi harici LDAP olabilir. Sysadmin kimlik bilgilerinin varsayılan olarak Edge'de saklandığını unutmayın. dahili LDAP. Harici LDAP'ye geçtiğinizde sysadmin kimlik bilgileriniz kimlik doğrulama işlemi burada yapılır. Bu nedenle, Edge'de harici kimlik doğrulamayı etkinleştirmeden önce harici sistemi etkinleştirin.

    Örneğin, Private Cloud için Apigee Edge'i global sistem yöneticisi kimlik bilgileri:

    username: edgeuser@mydomain.com
    password: Secret123

    Ardından, şifresiyle edgeuser@mydomain.com kullanıcısı Secret123, harici LDAP'de de bulunmalıdır.

  • Yönetim Sunucusu kümesi çalıştırıyorsanız tüm adımları uygulamanız gerektiğini unutmayın. bu belgedeki her bir Yönetim Sunucusu'nu inceleyin.

Harici kimlik doğrulamayı yapılandırma

Gerçekleştireceğiniz ana etkinlik, management-server.properties dosyasını yapılandırmaktır. Bu etkinlik, uç yönetim sunucusunu durdurup başlatmayı, doğrudan veya dolaylı bağlama, hassas kimlik bilgilerini şifreleme ve diğer ilgili görevlerden biridir.

  1. Önemli: Şimdi dolaylı erişimi mi doğrudan mı kullanmak istediğinize bağlama kimlik doğrulama yöntemidir. Bu karar, yapılandırmanın bazı özelliklerini etkileyecektir. Görüntüleyin Harici Kimlik Doğrulama.
  2. Önemli: Bu yapılandırma adımlarını her Apigee Edge Management'ta uygulamanız gerekir Sunucu (birden fazla çalıştırıyorsanız).
  3. /opt/apigee/customer/application/management-server.properties uygulamasını aç kullanabilirsiniz. Dosya yoksa, oluşturun.
  4. Aşağıdaki satırı ekleyin:
    conf_security_authentication.user.store=externalized.authentication

    Bu satır, harici kimlik doğrulama özelliğini Private Cloud için Edge'inize ekler teşekkür ederiz.

  5. Bu adımı kolaylaştırmak için, çok iyi yorumlanmış iki örnek yapılandırma oluşturduk: biri doğrudan, diğeri dolaylı bağlamayla ilgili kimlik doğrulaması içindir. Şunun için aşağıdaki örneklere bakın: kullanmak istediğiniz bağlamayı seçin ve yapılandırmayı tamamlayın:
  6. Yönetim sunucusunu yeniden başlatın:
    /opt/apigee/apigee-service/bin/apigee-service edge-management-server restart
  7. Sunucunun çalıştığını doğrulayın:
    /opt/apigee/apigee-service/bin/apigee-all status
  8. Önemli: İki yapılandırmadan birinin (veya her ikisinin de) altında ek yapılandırma yapmanız gerekir. aşağıdaki durumlardan biri söz konusu olabilir:
    1. Kullanıcıların aynı kullanıcı adıyla giriş yapmasını istiyorsanız e-posta adresleri değil. Bu durumda, sysadmin kullanıcınızın kullanıcı adı.

      VE/VEYA

    2. Harici LDAP, Apigee Edge'i Private Cloud'a gidin. Farklı sysadmin kimlik bilgileri için yapılandırma gerekli başlıklı makaleye bakın.

DOĞRUDAN BAĞLAYICI yapılandırma örneği

## The first property is always required to enable the external authorization feature.
## Do not change it.
conf_security_externalized.authentication.implementation.class=com.apigee.rbac.impl.LdapAuthenticatorImpl

## Identify the type of binding:
## Set to "true" for direct binding
## Set to "false" for indirect binding.
conf_security_externalized.authentication.bind.direct.type=true

## The next seven properties are needed regardless of direct or indirect binding. You need to
## configure these per your external authentication installation.
## The IP or domain for your external LDAP instance. 
conf_security_externalized.authentication.server.url=ldap://localhost:389

## Your external LDAP server version.
conf_security_externalized.authentication.server.version=3

## The server timeout in milliseconds. 
conf_security_externalized.authentication.server.conn.timeout=50000

## Change these baseDN values to match your external LDAP service. This attribute value will be
## provided by your external LDAP administrator, and may have more or fewer dc elements depending
## on your setup.
conf_security_externalized.authentication.user.store.baseDN=dc=apigee,dc=com

## Do not change this search string. It is used internally. 
conf_security_externalized.authentication.user.store.search.query=(&(${userAttribute}=${userId}))

## Identifies the external LDAP property you want to bind against for Authentication. For
## example if you are binding against an email address in Microsoft Active Directory, this would be
## the userPrincipalName property in your external LDAP instance. Alternatively if you are binding
## against the user's ID, this would typically be in the sAMAccountName property:
conf_security_externalized.authentication.user.store.user.attribute=userPrincipalName

## The LDAP attribute where the user email value is stored. For direct binding with AD, set it to
## userPrincipalName.
conf_security_externalized.authentication.user.store.user.email.attribute=userPrincipalName

## ONLY needed for DIRECT binding.
## The direct.bind.user.directDN property defines the string that is used for the bind against the
## external authentication service. Ensure it is set as follows:
conf_security_externalized.authentication.direct.bind.user.directDN=${userDN}

DOLAYLI BINDING yapılandırma örneği

## Required to enable the external authorization feature. Do not change it.
conf_security_externalized.authentication.implementation.class=com.apigee.rbac.impl.LdapAuthenticatorImpl

## Identifies the type of binding:
## Set to "true" for direct binding
## Set to "false" for indirect binding.
conf_security_externalized.authentication.bind.direct.type=false

## The next seven properties are needed regardless of direct or indirect binding. You need to
## configure these per your external LDAP installation.
## The IP or domain for your external LDAP instance.
conf_security_externalized.authentication.server.url=ldap://localhost:389

## Replace with your external LDAP server version.
conf_security_externalized.authentication.server.version=3

## Set the server timeout in milliseconds. 
conf_security_externalized.authentication.server.conn.timeout=50000

## Change these baseDN values to match your external LDAP service. This attribute value will be
# provided by your external LDAP administrator, and may have more or fewer dc elements
# depending on your setup.
conf_security_externalized.authentication.user.store.baseDN=dc=apigee,dc=com

## Do not change this search string. It is used internally. 
conf_security_externalized.authentication.user.store.search.query=(&(${userAttribute}=${userId}))

## Identifies the external LDAP property you want to bind against for Authentication. For example
## if you are binding against an email address, this would typically be in the
## userPrincipalName property in your external LDAP instance. Alternatively if you are binding
## against the user's ID, this would typically be in the sAMAccountName property.
## See also "Configuration required for different sysadmin credentials".
conf_security_externalized.authentication.user.store.user.attribute=userPrincipalName

## Used by Apigee to perform the Authorization step and currently, Apigee only supports email
## address for Authorization. Make sure to set it to the attribute in your external LDAP that
## stores the user's email address. Typically this will be in the userPrincipalName property.
conf_security_externalized.authentication.user.store.user.email.attribute=userPrincipalName

## The external LDAP username (for a user with search privileges on the external LDAP) and
## password and whether the password is encrypted. You must also set the attribute
## externalized.authentication.bind.direct.type to false.
## The password attribute can be encrypted or in plain text. See
## "Indirect binding only: Encrypting the external LDAP user's password"
## for encryption instructions. Set the password.encrypted attribute to "true" if the password is
## encrypted. Set it to "false" if the password is in plain text.
conf_security_externalized.authentication.indirect.bind.server.admin.dn=myExtLdapUsername
conf_security_externalized.authentication.indirect.bind.server.admin.password=myExtLdapPassword
conf_security_externalized.authentication.indirect.bind.server.admin.password.encrypted=true

Kurulumu test etme

  1. Sunucunun çalıştığını doğrulayın:
    /opt/apigee/apigee-service/bin/apigee-all status
  2. Bir dizi Apigee Edge global sistem yöneticisi sağlayarak bu komutu yürütün. kimlik bilgileri ekleyin. Test edeceğimiz API çağrısı yalnızca bir Edge sysadmin.
    curl -v http://management-server-IP:8080/v1/o -u sysadmin_username

    Örneğin:

    curl -v http://192.168.52.100:8080/v1/o -u jdoe@mydomain.com
  3. İstendiğinde şifrenizi girin.

    Komut, bir 200 durumu ve kuruluş listesi döndürürse yapılandırma doğrudur. Bu komut, Uç Yönetim Sunucusu'na yapılan API çağrısının başarıyla yapıldığını doğrular kimlik doğrulaması, harici LDAP sistemi üzerinden yapılır.