{"id":661,"date":"2010-11-08T01:25:27","date_gmt":"2010-11-08T06:25:27","guid":{"rendered":"http:\/\/yourLinuxGuy.com\/?p=661"},"modified":"2010-11-01T05:42:17","modified_gmt":"2010-11-01T10:42:17","slug":"how-to-do-ldaps-queries-from-linux-to-active-directory-pt-4","status":"publish","type":"post","link":"https:\/\/yourLinuxGuy.com\/?p=661","title":{"rendered":"How to do LDAPS queries from Linux to Active Directory pt. 4"},"content":{"rendered":"<p>Sub-Title:\u00a0 &#8220;What if you don&#8217;t know the exact certificate subject of the AD server?&#8221;<\/p>\n<p><em>This is part 4 in a series of 5 posts on this subject; for background, please also see <a title=\"http:\/\/yourlinuxguy.com\/?p=635\" href=\"http:\/\/yourlinuxguy.com\/?p=635\" target=\"_blank\">part 1<\/a>, <a title=\"http:\/\/yourlinuxguy.com\/?p=649\" href=\"http:\/\/yourlinuxguy.com\/?p=649\" target=\"_blank\">part 2<\/a>, <a title=\"http:\/\/yourlinuxguy.com\/?p=659\" href=\"http:\/\/yourlinuxguy.com\/?p=659\" target=\"_blank\">part 3<\/a>, and <a title=\"http:\/\/yourlinuxguy.com\/?p=663\" href=\"http:\/\/yourlinuxguy.com\/?p=663\" target=\"_blank\">part 5<\/a>.<\/em><\/p>\n<p>If you just don&#8217;t know the certificate &#8220;subject&#8221; name of the server you&#8217;re trying to query (remember from part 1 in this series that subject name match is critical in LDAPS queries!), but you have the IP address or other resolvable hostname info, here&#8217;s how to check the subject of the certificate:<\/p>\n<pre><code>openssl s_client -connect corpdc01.yourlinuxguy.com:636 -showcerts<\/code><\/pre>\n<p>This will dump a whole bunch of SSL information, and the first couple lines will show you the server subject, but to be 100% certain you should scroll down to the &#8220;Server certificate subject&#8221; section to see the value and be sure.<\/p>\n<p>I hope that helps!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Sub-Title:\u00a0 &#8220;What if you don&#8217;t know the exact certificate subject of the AD server?&#8221; This is part 4 in a series of 5 posts on this subject; for background, please also see part 1, part 2, part 3, and part&#8230;<br \/><a class=\"read-more-button\" href=\"https:\/\/yourLinuxGuy.com\/?p=661\">Read more<\/a><\/p>\n","protected":false},"author":5,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[10,47,45,20],"tags":[],"class_list":["post-661","post","type-post","status-publish","format-standard","hentry","category-introductory","category-linuxgeneral","category-openssl","category-windowsgeneral"],"jetpack_featured_media_url":"","jetpack_shortlink":"https:\/\/wp.me\/pnjn1-aF","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/yourLinuxGuy.com\/index.php?rest_route=\/wp\/v2\/posts\/661","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/yourLinuxGuy.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/yourLinuxGuy.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/yourLinuxGuy.com\/index.php?rest_route=\/wp\/v2\/users\/5"}],"replies":[{"embeddable":true,"href":"https:\/\/yourLinuxGuy.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=661"}],"version-history":[{"count":3,"href":"https:\/\/yourLinuxGuy.com\/index.php?rest_route=\/wp\/v2\/posts\/661\/revisions"}],"predecessor-version":[{"id":684,"href":"https:\/\/yourLinuxGuy.com\/index.php?rest_route=\/wp\/v2\/posts\/661\/revisions\/684"}],"wp:attachment":[{"href":"https:\/\/yourLinuxGuy.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=661"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/yourLinuxGuy.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=661"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/yourLinuxGuy.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=661"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}