본문으로 바로가기 본문 바로가기
WIKI 기술 지식 베이스

LDAP 인증 플러그인 설정 레퍼런스

원문 보기 위키 갱신

LDAP 인증 플러그인 설정 레퍼런스 (LDAP Authentication Plugin Configuration Reference)

이 문서는 Kong의 LDAP 인증 플러그인에서 사용할 수 있는 설정 옵션을 한눈에 정리한 레퍼런스예요. ldap_host나 base_dn 같은 LDAP 서버 연결 정보부터 hide_credentials, cache_ttl, anonymous 같은 동작 제어 옵션까지 각 항목의 타입과 기본값, 설명을 담고 있어요. LDAPS나 StartTLS를 사용해 연결을 암호화하는 방법과 타임아웃, keepalive 같은 세부 설정도 함께 확인할 수 있어요. 플러그인을 실제로 구성하거나 튜닝할 때 필요한 값을 빠르게 찾아보기에 좋은 문서예요

출처: 문서

본문

{
  "properties": {
    "config": {
      "properties": {
        "anonymous": {
          "description": "An optional string (consumer UUID or username) value to use as an “anonymous” consumer if authentication fails. If empty (default null), the request fails with an authentication failure `4xx`.",
          "type": "string"
        },
        "attribute": {
          "description": "Attribute to be used to search the user; e.g. cn",
          "type": "string"
        },
        "base_dn": {
          "description": "Base DN as the starting point for the search; e.g., dc=example,dc=com",
          "type": "string"
        },
        "cache_ttl": {
          "default": 60,
          "description": "Cache expiry time in seconds.",
          "type": "number"
        },
        "header_type": {
          "default": "ldap",
          "description": "An optional string to use as part of the Authorization header",
          "type": "string"
        },
        "hide_credentials": {
          "default": true,
          "description": "An optional boolean value telling the plugin to hide the credential to the upstream server. It will be removed by Kong before proxying the request.",
          "type": "boolean"
        },
        "keepalive": {
          "default": 60000,
          "description": "An optional value in milliseconds that defines how long an idle connection to LDAP server will live before being closed.",
          "type": "number"
        },
        "ldap_host": {
          "description": "A string representing a host name, such as example.com.",
          "type": "string"
        },
        "ldap_port": {
          "default": 389,
          "description": "An integer representing a port number between 0 and 65535, inclusive.",
          "maximum": 65535,
          "minimum": 0,
          "type": "integer"
        },
        "ldaps": {
          "default": false,
          "description": "Set to `true` to connect using the LDAPS protocol (LDAP over TLS).  When `ldaps` is configured, you must use port 636. If the `ldap` setting is enabled, ensure the `start_tls` setting is disabled.",
          "type": "boolean"
        },
        "realm": {
          "description": "When authentication fails the plugin sends `WWW-Authenticate` header with `realm` attribute value.",
          "type": "string"
        },
        "start_tls": {
          "default": false,
          "description": "Set it to `true` to issue StartTLS (Transport Layer Security) extended operation over `ldap` connection. If the `start_tls` setting is enabled, ensure the `ldaps` setting is disabled.",
          "type": "boolean"
        },
        "timeout": {
          "default": 10000,
          "description": "An optional timeout in milliseconds when waiting for connection with LDAP server.",
          "type": "number"
        },
        "verify_ldap_host": {
          "default": true,
          "description": "Set to `true` to authenticate LDAP server. The server certificate will be verified according to the CA certificates specified by the `lua_ssl_trusted_certificate` directive.",
          "type": "boolean"
        }
      },
      "required": [
        "attribute",
        "base_dn",
        "ldap_host"
      ],
      "type": "object"
    },
    "expressions": {
      "additionalProperties": true,
      "type": "object"
    },
    "protocols": {
      "default": [
        "grpc",
        "grpcs",
        "http",
        "https",
        "ws",
        "wss"
      ],
      "description": "A list of the request protocols that will trigger this plugin. The default value, as well as the possible values allowed on this field, may change depending on the plugin type. For example, plugins that only work in stream mode will only support tcp and tls.",
      "items": {
        "enum": [
          "grpc",
          "grpcs",
          "http",
          "https",
          "ws",
          "wss"
        ],
        "type": "string"
      },
      "type": "array"
    },
    "route": {
      "additionalProperties": false,
      "description": "If set, the plugin will only activate when receiving requests via the specified route. Leave unset for the plugin to activate regardless of the route being used.",
      "properties": {
        "id": {
          "type": "string"
        }
      },
      "type": "object"
    },
    "service": {
      "additionalProperties": false,
      "description": "If set, the plugin will only activate when receiving requests via one of the routes belonging to the specified Service. Leave unset for the plugin to activate regardless of the Service being matched.",
      "properties": {
        "id": {
          "type": "string"
        }
      },
      "type": "object"
    }
  },
  "required": [
    "config"
  ]
}

관련 리소스

더 알아보기 (Learn more)

  • 기본 LDAP 인증 플러그인보다 향상된 기능을 제공하는 고급 버전의 사용법이 궁금하면 참고해요 — LDAP Authentication Advanced