{"id":292,"date":"2018-04-27T05:32:21","date_gmt":"2018-04-27T05:32:21","guid":{"rendered":"https:\/\/ldap.com\/ldapv3-wire-protocol-reference-the-ldap-unbind-operation\/"},"modified":"2018-05-06T18:19:12","modified_gmt":"2018-05-06T23:19:12","slug":"ldapv3-wire-protocol-reference-unbind","status":"publish","type":"page","link":"https:\/\/ldap.com\/ldapv3-wire-protocol-reference-unbind\/","title":{"rendered":"LDAPv3 Wire Protocol Reference: The LDAP Unbind Operation"},"content":{"rendered":"<p>\n  The LDAP unbind operation is poorly named. It sounds as if it should undo the effects of a bind operation. For example, one might expect that an unbind operation reverts a connection to an unauthenticated state. It doesn\u2019t (although you can cause a connection to become unauthenticated using an <a href=\"https:\/\/ldap.com\/ldapv3-wire-protocol-reference-bind#simple-bind-operation\">anonymous simple bind request<\/a>).\n<\/p>\n<p>\n  Instead, the unbind operation is used to indicate that the client wants to close the connection to the directory server. There shouldn\u2019t be any attempt to use a connection after an unbind request has been sent. Immediately after sending an unbind request on a connection, the client should close that connection. Likewise, immediately after receiving an unbind request from a client, the server should close that client connection.\n<\/p>\n<blockquote><p>\n  Even though it\u2019s a good practice for clients to send an unbind request before closing a connection, directory servers must be able to handle clients that disconnect without an unbind request.\n<\/p><\/blockquote>\n<p>\n  <a href=\"https:\/\/docs.ldap.com\/specs\/rfc4511.txt\" target=\"_blank\">RFC 4511<\/a> section 4.3 defines an unbind request protocol operation as follows:\n<\/p>\n<pre>UnbindRequest ::= [APPLICATION 2] NULL<\/pre>\n<p>\n  That is, an unbind request protocol op is simply a null element with BER type <tt>0x42<\/tt> (application class, primitive, tag number two). An unbind request with message ID three and no controls is encoded as:\n<\/p>\n<pre>30 05 -- Begin the LDAPMessage sequence\n   02 01 03 -- The message ID (integer value 3)\n   42 00 -- The unbind request protocol op<\/pre>\n<p>\n  There is no response to an unbind request.\n<\/p>\n<\/p>\n<table border=\"0\" width=\"100%\">\n<tr>\n<td align=\"left\">Previous: <a href=\"https:\/\/ldap.com\/ldapv3-wire-protocol-reference-search\">The LDAP Search Operation<\/a><\/td>\n<td align=\"right\">Next: <a href=\"https:\/\/ldap.com\/ldapv3-wire-protocol-reference-intermediate-response\">The LDAP Intermediate Response<\/a><\/td>\n<\/tr>\n<\/table>\n","protected":false},"excerpt":{"rendered":"<p>The LDAP unbind operation is poorly named. It sounds as if it should undo the effects of a bind operation. For example, one might expect that an unbind operation reverts a connection to an unauthenticated state. It doesn\u2019t (although you can cause a connection to become unauthenticated using an anonymous simple bind request). Instead, the&hellip; <span class=\"excerpt-more\"><a href=\"https:\/\/ldap.com\/ldapv3-wire-protocol-reference-unbind\/\">Read More<\/a><\/span><\/p>\n","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"advanced_seo_description":"","jetpack_seo_html_title":"","jetpack_seo_noindex":false,"jetpack_seo_schema_type":"","_wpcom_ai_launchpad_about_page":false,"_wpcom_ai_launchpad_gallery_page":false,"footnotes":""},"tags":[],"class_list":["post-292","page","type-page","status-publish","hentry"],"jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/P9RddA-4I","jetpack_likes_enabled":true,"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/ldap.com\/wp-json\/wp\/v2\/pages\/292","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ldap.com\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/ldap.com\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/ldap.com\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/ldap.com\/wp-json\/wp\/v2\/comments?post=292"}],"version-history":[{"count":3,"href":"https:\/\/ldap.com\/wp-json\/wp\/v2\/pages\/292\/revisions"}],"predecessor-version":[{"id":555,"href":"https:\/\/ldap.com\/wp-json\/wp\/v2\/pages\/292\/revisions\/555"}],"wp:attachment":[{"href":"https:\/\/ldap.com\/wp-json\/wp\/v2\/media?parent=292"}],"wp:term":[{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ldap.com\/wp-json\/wp\/v2\/tags?post=292"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}