クラス EmbeddedLdapServerContextSourceFactoryBean

java.lang.ObjectSE
org.springframework.security.config.ldap.EmbeddedLdapServerContextSourceFactoryBean
実装されたすべてのインターフェース:
org.springframework.beans.factory.Awareorg.springframework.beans.factory.DisposableBeanorg.springframework.beans.factory.FactoryBean<DefaultSpringSecurityContextSource>org.springframework.context.ApplicationContextAware

public class EmbeddedLdapServerContextSourceFactoryBean extends ObjectSE implements org.springframework.beans.factory.FactoryBean<DefaultSpringSecurityContextSource>, org.springframework.beans.factory.DisposableBean, org.springframework.context.ApplicationContextAware
LDAP 認証を実行するために使用される DefaultSpringSecurityContextSource を作成し、メモリ内の LDAP サーバーを起動します。
導入:
5.7
  • コンストラクターの詳細

    • EmbeddedLdapServerContextSourceFactoryBean

      public EmbeddedLdapServerContextSourceFactoryBean()
  • メソッドの詳細

    • fromEmbeddedLdapServer

      public static EmbeddedLdapServerContextSourceFactoryBean fromEmbeddedLdapServer()
      組み込み LDAP サーバーを使用して LDAP 認証を実行する EmbeddedLdapServerContextSourceFactoryBean を作成します。これには、`com.unboundid:unboundid-ldapsdk` への依存が必要です。
      戻り値:
      EmbeddedLdapServerContextSourceFactoryBean
    • setLdif

      public void setLdif(StringSE ldif)
      組み込み LDAP サーバーの起動時にロードする LDIF を指定します。デフォルトは "classpath*:*.ldif" です。
      パラメーター:
      ldif - 組み込み LDAP サーバーの起動時にロードする ldif。
    • setPort

      public void setPort(int port)
      LDAP に接続するポート(デフォルトは 33389、または使用できない場合はランダムに使用可能なポート)。ポートとして 0 を指定すると、使用可能なランダムなポートを選択する必要があることを示します。
      パラメーター:
      port - 接続するポート
    • setRoot

      public void setRoot(StringSE root)
      組み込み LDAP サーバーのオプションのルートサフィックス。デフォルトは "dc=springframework,dc=org" です。
      パラメーター:
      root - 組み込み LDAP サーバーのルートサフィックス
    • setManagerDn

      public void setManagerDn(StringSE managerDn)
      LDAP サーバーへの認証に使用される「マネージャー」ユーザー ID("uid=admin,ou=system" など)のユーザー名(DN)。省略した場合、匿名アクセスが使用されます。
      パラメーター:
      managerDn - LDAP サーバーへの認証に使用される「マネージャー」ユーザー ID のユーザー名(DN)。
    • setManagerPassword

      public void setManagerPassword(StringSE managerPassword)
      マネージャー DN のパスワード。これは、setManagerDn(String) が指定されている場合に必要です。
      パラメーター:
      managerPassword - マネージャー DN のパスワード
    • getObject

      次で指定:
      インターフェース org.springframework.beans.factory.FactoryBean<DefaultSpringSecurityContextSource>getObject 
      例外:
      ExceptionSE
    • getObjectType

      public ClassSE<?> getObjectType()
      次で指定:
      インターフェース org.springframework.beans.factory.FactoryBean<DefaultSpringSecurityContextSource>getObjectType 
    • destroy

      public void destroy()
      次で指定:
      インターフェース org.springframework.beans.factory.DisposableBeandestroy 
    • setApplicationContext

      public void setApplicationContext(org.springframework.context.ApplicationContext applicationContext) throws org.springframework.beans.BeansException
      次で指定:
      インターフェース org.springframework.context.ApplicationContextAwaresetApplicationContext 
      例外:
      org.springframework.beans.BeansException