contentsldapserver

ldapserver  时间:2021-05-01  阅读:()
eldapCopyright2012-2021EricssonAB.
AllRightsReserved.
eldap1.
2.
9March23,2021Copyright2012-2021EricssonAB.
AllRightsReserved.
LicensedundertheApacheLicense,Version2.
0(the"License");youmaynotusethisfileexceptincompliancewiththeLicense.
YoumayobtainacopyoftheLicenseathttp://www.
apache.
org/licenses/LICENSE-2.
0Unlessrequiredbyapplicablelaworagreedtoinwriting,softwaredistributedundertheLicenseisdistributedonan"ASIS"BASIS,WITHOUTWARRANTIESORCONDITIONSOFANYKIND,eitherexpressorimplied.
SeetheLicenseforthespecificlanguagegoverningpermissionsandlimitationsundertheLicense.
EricssonAB.
AllRightsReserved.
.
March23,20211EldapUser'sGuideTheEldapapplicationprovidesanapiforaccessinganLDAPserver.
TheoriginalcodewasdevelopedbyTorbjrnTrnkvist.
EricssonAB.
AllRightsReserved.
:eldap|12ReferenceManualTheEldapapplicationprovidesanapiforaccessinganLDAPserver.
TheoriginalcodewasdevelopedbyTorbjrnTrnkvist.
2|EricssonAB.
AllRightsReserved.
:eldapeldapeldapErlangmoduleThismoduleprovidesaclientapitotheLightweightDirectoryAccessProtocol(LDAP).
References:RFC4510-RFC4519RFC2830TheabovepublicationscanbefoundatIETF.
DATATYPESTypedefinitionsthatareusedmorethanonceinthismodule:handle()Connectionhandleattribute()={Type=string(),Values=[string()]}modify_op()Seemod_add/2,mod_delete/2,mod_replace/2scope()SeebaseObject/0,singleLevel/0,wholeSubtree/0dereference()SeeneverDerefAliases/0,derefInSearching/0,derefFindingBaseObj/0,derefAlways/0filter()Seepresent/1,substrings/2,equalityMatch/2,greaterOrEqual/2,lessOrEqual/2,approxMatch/2,extensibleMatch/2,'and'/1,'or'/1,'not'/1return_value()=ok|{ok,{referral,referrals()}}|{error,Error}referrals()=[Address=string()]ThecontentsofAddressisserverdependent.
Exportsopen([Host])->{ok,Handle}|{error,Reason}Types:Handle=handle()SetupaconnectiontoanLDAPserver,theHOST'saretriedinorder.
open([Host],[Option])->{ok,Handle}|{error,Reason}Types:Handle=handle()EricssonAB.
AllRightsReserved.
:eldap|3eldapOption={port,integer()}|{log,function()}|{timeout,integer()}|{ssl,boolean()}|{sslopts,list()}|{tcpopts,list()}SetupaconnectiontoanLDAPserver,theHOST'saretriedinorder.
Thelogfunctiontakesthreearguments,fun(Level,FormatString,[FormatArg])end.
Timeoutsetthemaximumtimeinmillisecondsthateachserverrequestmaytake.
AllTCPsocketoptionsareacceptedexceptactive,binary,deliver,list,modeandpacketclose(Handle)->okTypes:Handle=handle()ShutdowntheconnectionaftersendinganunbindRequesttotheserver.
Iftheconnectionistlstheconnectionwillbeclosedwithssl:close/1,otherwisewithgen_tcp:close/1.
start_tls(Handle,Options)->return_value()Sameasstart_tls(Handle,Options,infinity)start_tls(Handle,Options,Timeout)->return_value()Types:Handle=handle()Options=ssl:ssl_options()Timeout=infinity|positive_integer()UpgradetheconnectionassociatedwithHandletoatlsconnectionifpossible.
Theupgradeisdoneintwophases:firsttheserverisaskedforpermissiontoupgrade.
Second,iftherequestisacknowledged,theupgradetotlsisperformed.
Errorresponsesfromphaseonewillnotaffectthecurrentencryptionstateoftheconnection.
Thoseresponsesare:tls_already_startedTheconnectionisalreadyencrypted.
Theconnectionisnotaffected.
{response,ResponseFromServer}TheupgradewasrefusedbytheLDAPserver.
TheResponseFromServerisanatomdeliveredbyttheLDAPserverexplainedinsection2.
3ofrfc2830.
Theconnectionisnotaffected,soitisstillun-encrypted.
Errorsinthesecondphasewillhoweverendtheconnection:ErrorAnyerrorrespondedfromssl:connect/3TheTimeoutparameterisfortheactualtlsupgrade(phase2)whilethetimeoutineldap:open/2isusedfortheinitialnegotiationaboutupgrade(phase1).
simple_bind(Handle,Dn,Password)->return_value()Types:Handle=handle()Dn=string()Password=string()Authenticatetheconnectionusingsimpleauthentication.
4|EricssonAB.
AllRightsReserved.
:eldapeldapadd(Handle,Dn,[Attribute])->return_value()Types:Handle=handle()Dn=string()Attribute=attribute()Addanentry.
Theentrymustnotexist.
add(Handle,"cn=BillValentine,ou=people,o=ExampleOrg,dc=example,dc=com",[{"objectclass",["person"]},{"cn",["BillValentine"]},{"sn",["Valentine"]},{"telephoneNumber",["54555500"]}])delete(Handle,Dn)->return_value()Types:Dn=string()Deleteanentry.
delete(Handle,"cn=BillValentine,ou=people,o=ExampleOrg,dc=example,dc=com")mod_add(Type,[Value])->modify_op()Types:Type=string()Value=string()Createanaddmodificationoperation.
mod_delete(Type,[Value])->modify_op()Types:Type=string()Value=string()Createadeletemodificationoperation.
mod_replace(Type,[Value])->modify_op()Types:Type=string()Value=string()Createareplacemodificationoperation.
modify(Handle,Dn,[ModifyOp])->return_value()Types:Dn=string()ModifyOp=modify_op()Modifyanentry.
EricssonAB.
AllRightsReserved.
:eldap|5eldapmodify(Handle,"cn=BillValentine,ou=people,o=ExampleOrg,dc=example,dc=com",[eldap:mod_replace("telephoneNumber",["55555500"]),eldap:mod_add("description",["LDAPHacker"])])modify_password(Handle,Dn,NewPasswd)->return_value()|{ok,GenPasswd}Types:Dn=string()NewPasswd=string()Modifythepasswordofauser.
Seemodify_password/4.
modify_password(Handle,Dn,NewPasswd,OldPasswd)->return_value()|{ok,GenPasswd}Types:Dn=string()NewPasswd=string()OldPasswd=string()GenPasswd=string()Modifythepasswordofauser.
Dn.
Theusertomodify.
Shouldbe""ifthemodifyrequestisfortheuseroftheLDAPsession.
NewPasswd.
Thenewpasswordtoset.
Shouldbe""iftheserveristogeneratethepassword.
Inthiscase,theresultwillbe{ok,GenPasswd}.
OldPasswd.
Sometimesrequiredbyserverpolicyforausertochangetheirpassword.
Ifnotrequired,usemodify_password/3.
modify_dn(Handle,Dn,NewRDN,DeleteOldRDN,NewSupDN)->return_value()Types:Dn=string()NewRDN=string()DeleteOldRDN=boolean()NewSupDN=string()ModifytheDNofanentry.
DeleteOldRDNindicateswhetherthecurrentRDNshouldberemovedfromtheattributelistaftertheoperation.
NewSupDNisthenewparentthattheRDNshallbemovedto.
Iftheoldparentshouldremainasparent,NewSupDNshallbe"".
modify_dn(Handle,"cn=BillValentine,ou=people,o=ExampleOrg,dc=example,dc=com","cn=BillJrValentine",true,"")search(Handle,SearchOptions)->{ok,#eldap_search_result{}}|{ok,{referral,referrals()}}|{error,Reason}Types:SearchOptions=#eldap_search{}|[SearchOption]SearchOption={base,string()}|{filter,filter()}|{scope,scope()}|{attributes,[string()]}|{deref,dereference(types_only,boolean()}|{timeout,integer()}6|EricssonAB.
AllRightsReserved.
:eldapeldapSearchthedirectorywiththesuppliedtheSearchOptions.
Thebaseandfilteroptionsmustbesupplied.
Defaultvalues:scopeiswholeSubtree(),derefisderefAlways(),types_onlyisfalseandtimeoutis0(meaninginfinity).
Filter=eldap:substrings("cn",[{any,"V"}]),search(Handle,[{base,"dc=example,dc=com"},{filter,Filter},{attributes,["cn"]}]),ThetimeoutoptionintheSearchOptionsisfortheldapserver,whilethetimeoutineldap:open/2isusedforeachindividualrequestinthesearchoperation.
baseObject()->scope()Searchbaseobjectonly.
singleLevel()->scope()Searchthespecifiedlevelonly,i.
e.
donotrecurse.
wholeSubtree()->scope()Searchtheentiresubtree.
neverDerefAliases()->dereference()Neverderefrencealiases,treataliasesasentries.
derefAlways()->dereference()Alwaysderefrencealiases.
derefInSearching()->dereference()Derefrencealiasesonlywhensearching.
derefFindingBaseObj()->dereference()Derefrencealiasesonlyinfindingthebase.
present(Type)->filter()Types:Type=string()Createafilterwhichfiltersonattributetypepresence.
substrings(Type,[SubString])->filter()Types:Type=string()SubString={StringPart,string()}StringPart=initial|any|finalCreateafilterwhichfiltersonsubstrings.
equalityMatch(Type,Value)->filter()Types:Type=string()EricssonAB.
AllRightsReserved.
:eldap|7eldapValue=string()Createaequalityfilter.
greaterOrEqual(Type,Value)->filter()Types:Type=string()Value=string()Createagreaterorequalfilter.
lessOrEqual(Type,Value)->filter()Types:Type=string()Value=string()Createalessorequalfilter.
approxMatch(Type,Value)->filter()Types:Type=string()Value=string()Createaapproximationmatchfilter.
extensibleMatch(MatchValue,OptionalAttrs)->filter()Types:MatchValue=string()OptionalAttrs=[Attr]Attr={matchingRule,string()}|{type,string()}|{dnAttributes,boolean()}Createsanextensiblematchfilter.
Forexample,eldap:extensibleMatch("Bar",[{type,"sn"},{matchingRule,"caseExactMatch"}]))createsafilterwhichperformsacaseExactMatchontheattributesnandmatcheswiththevalue"Bar".
ThedefaultvalueofdnAttributesisfalse.
'and'([Filter])->filter()Types:Filter=filter()CreatesafilterwhereallFiltermustbetrue.
'or'([Filter])->filter()Types:Filter=filter()CreateafilterwhereatleastoneoftheFiltermustbetrue.
8|EricssonAB.
AllRightsReserved.
:eldapeldap'not'(Filter)->filter()Types:Filter=filter()Negateafilter.
EricssonAB.
AllRightsReserved.
:eldap|9

妮妮云,美国cera CN2线路,VPS享3折优惠

近期联通CUVIP的线路(AS4837线路)非常火热,妮妮云也推出了这类线路的套餐以及优惠,目前到国内优质线路排行大致如下:电信CN2 GIA>联通AS9929>联通AS4837>电信CN2 GT>普通线路,AS4837线路比起前两的优势就是带宽比较大,相对便宜一些,所以大家才能看到这个线路的带宽都非常高。妮妮云互联目前云服务器开放抽奖活动,每天开通前10台享3折优惠,另外...

wordpress高级跨屏企业主题 wordpress绿色企业自适应主题

wordpress高级跨屏企业主题,通用响应式跨平台站点开发,自适应PC端+各移动端屏幕设备,高级可视化自定义设置模块+高效的企业站搜索优化。wordpress绿色企业自适应主题采用标准的HTML5+CSS3语言开发,兼容当下的各种主流浏览器: IE 6+(以及类似360、遨游等基于IE内核的)、Firefox、Google Chrome、Safari、Opera等;同时支持移动终端的常用浏览器应...

Hostodo(年付$34.99), 8TB月流量 3个机房可选

Hostodo 算是比较小众的海外主机商,这次九月份开学季有提供促销活动。不过如果我们有熟悉的朋友应该知道,这个服务商家也是比较时间久的,而且商家推进活动比较稳,每个月都有部分活动。目前有提供机房可选斯波坎、拉斯维加斯和迈阿密。从机房的地理位置和实际的速度,中文业务速度应该不是优化直连的,但是有需要海外业务的话一般有人选择。以前一直也持有他们家的年付12美元的机器,后来用不到就取消未续约。第一、开...

ldapserver为你推荐
深圳市福田区国民经济和社会发展信用卡apple企业cms最好是开源的企业cmsphpcms模板PHPCMS V9模板linux防火墙设置LINUX系统怎么关闭防火墙cisco2960配置cisco 2960 配置VLAN上网新团网美团网是谁创办的呀?腾讯公司电话腾讯总公司服务热线是多少95188是什么电话95188是什么号码我刚收到短信是什么支付宝的验证码即时通请问有没有人知道即时通是什么?怎样先可以开??
vps试用 视频空间租用 warez sharktech 美国独立服务器 arvixe 回程路由 服务器怎么绑定域名 ibox官网 idc查询 购买国外空间 512mb 空间登陆首页 美国凤凰城 七牛云存储 第八届中美互联网论坛 服务器操作系统 cdn免备案空间 iptables ssd 更多