문서의 선택한 두 판 사이의 차이를 보여줍니다.
양쪽 이전 판 이전 판 다음 판 | 이전 판 | ||
python:ldap [2013/08/29 15:26] kwon37xi |
python:ldap [2013/08/29 15:31] kwon37xi [검색] |
||
---|---|---|---|
줄 20: | 줄 20: | ||
l = ldap.initialize(' | l = ldap.initialize(' | ||
l.set_option(ldap.OPT_REFERRALS, | l.set_option(ldap.OPT_REFERRALS, | ||
- | l.simple_bind_s(' | + | l.simple_bind_s(' |
</ | </ | ||
- | ===== 계정 비밀번호 일치 여부 판단 ===== | + | ===== 값비교 및 계정 비밀번호 일치 여부 판단 ===== |
<code python> | <code python> | ||
- | l.compare_s(' | + | # 기본적인 비교 |
+ | l.compare_s(' | ||
# 결과가 1이면 일치, 0이면 불일치 | # 결과가 1이면 일치, 0이면 불일치 | ||
- | </ | ||
+ | l.compare_s(' | ||
</ | </ | ||
+ | ===== 검색 ===== | ||
+ | <code python> | ||
+ | l.search_s(' | ||
+ | [' | ||
+ | |||
+ | # 결과는 튜플의 배열이다. | ||
+ | </ | ||
+ | * 검색 Scope | ||
+ | * '' | ||
+ | * '' | ||
+ | * '' |