anchor.diff:  node:
     home: ${gravitee.home}
   
  -jetty:
  +http:
     port: 8082
  -  idleTimeout: 30000
  -  acceptors: -1
  -  selectors: -1
  -  jmx: false
  -  statistics: false
  -  pool:
  -    minThreads: 10
  -    maxThreads: 200
  -    idleTimeout: 60000
  -    queueSize: 6000
  +  secured: false
  +  compression_supported: false
  +  idle_timeout: 0
  +  tcp_keep_alive: true
  +  ssl:
  +    client_auth: false
  +    keystore:
  +      path: null
  +      password: null
  +    trustore:
  +      path: null
  +      password: null
   
   plugins:
     registry:
  
positive.code: [source,yaml]
  ----
  security:
    type: basic-auth # authentication type
    authentication-manager: # required authentication-providers parent attribute
      authentication-providers: # required authentication-provider parent attribute
        size : 3 # number of authentication-provider to use (in this sample three)
  
        # First authentication provider
        authentication-provider-1: # the authentication provider id must be <= size property
          type: ldap # authentication provider type (possible values : memory, ldap, gravitee)
  			  embedded: true # embedded mode (true to use the embedded ldap server, usefull for test/demo, possible values : true or false)
  			  # if embedded is false set the following values
          context-source-username: # context username to connect to your ldap server
          context-source-password: # context password to connect to your ldap server
          context-source-url: # your ldap server url
          role-mapping: true # role mapping mode for ldap user (possible values : true or false)
          # if role-mapping is true set the following role mapper LDAP values (syntax { "user_ldap_role" : "user_new_added_ldap_role"})
          role-mapper: {
                  ROLE_DEVELOPERS: ROLE_USER,
                  ROLE_MEMBERS: ROLE_USER,
                  ROLE_OWNERS: ROLE_ADMIN
                 }
          user-dn-patterns: uid={0},ou=people # user dn patterns (default 'uid={0},ou=people')
          group-search-base: ou=groups # groupe search base (default 'ou=groups')
          context-source-base: dc=gravitee,dc=io # the context source base
  
        # Second authentication provider
        authentication-provider-2: the authentication provider id must be <= size property
          type: memory # authentication provider type (possible values : memory, ldap, gravitee)
          users:
            size: 2 # number of users to create
            user-1: # id user must be <= to users size property
              username: user
              password: password
              roles: USER # you can declare multiple roles with comma separator (USER, OWNER, ADMIN ...)
            user-2: # id user must be <= to users size property
              username: admin
              password: admin
              roles: ADMIN # you can declare multiple roles with comma separator (USER, OWNER, ADMIN ...)
  
        # Third authentication provider
        authentication-provider-3: the authentication provider id must be <= size property
          type: gravitee # authentication provider type (possible values : memory, ldap, gravitee)
          password-encoding: # enable password encoding (possible values : true or false)
  ----
  
  
  
negative.code: # This sample file declared gravitee authentication provider
  # ===================================================================
  security:
    type: basic
    providers:
  
      # First authentication provider
      - type: ldap
        embedded: true
        role-mapping: true
        # if role-mapping is true set the following role mapper LDAP values
        role-mapper: {
          ROLE_DEVELOPERS: ROLE_USER,
          ROLE_MEMBERS: ROLE_USER,
          ROLE_OWNERS: ROLE_ADMIN
        }
        user-dn-patterns: uid={0},ou=people
        group-search-base: ou=groups
        context-source-base: dc=gravitee,dc=io
        # if embedded is false set the following values
        # context-source-username: test
        # context-source-password: test
        # context-source-url: ldap://localhost:389/dc=gravitee,dc=io
  
      # Second authentication provider
      - type: memory
        users:
          - user:
            username: user
            password: password
            roles: USER
          - user:
            username: admin
            password: admin
            roles: ADMIN
  
      # Third authentication provider
      - type: gravitee
        password-encoding: true
  ----
  
  NOTE: The authentication process will loop through the three providers to attempt user authentication
  