|
|
f441eb |
From f98c4f92091f6a68f390078f73be3bb6ca6e6550 Mon Sep 17 00:00:00 2001
|
|
|
f441eb |
From: Sumit Bose <sbose@redhat.com>
|
|
|
f441eb |
Date: Tue, 30 Jan 2018 18:23:03 +0100
|
|
|
f441eb |
Subject: [PATCH 12/23] library: add adcli_conn_get_domain_sid()
|
|
|
f441eb |
|
|
|
f441eb |
https://bugs.freedesktop.org/show_bug.cgi?id=100118
|
|
|
f441eb |
|
|
|
f441eb |
Reviewed-by: Jakub Hrozek <jhrozek@redhat.com>
|
|
|
f441eb |
---
|
|
|
f441eb |
library/adconn.c | 8 ++++++++
|
|
|
f441eb |
library/adconn.h | 2 ++
|
|
|
f441eb |
tools/computer.c | 1 +
|
|
|
f441eb |
3 files changed, 11 insertions(+)
|
|
|
f441eb |
|
|
|
f441eb |
diff --git a/library/adconn.c b/library/adconn.c
|
|
|
f441eb |
index 6b84b88..d2fb1d5 100644
|
|
|
f441eb |
--- a/library/adconn.c
|
|
|
f441eb |
+++ b/library/adconn.c
|
|
|
f441eb |
@@ -1355,6 +1355,14 @@ adcli_conn_get_domain_short (adcli_conn *conn)
|
|
|
f441eb |
return conn->domain_short;
|
|
|
f441eb |
}
|
|
|
f441eb |
|
|
|
f441eb |
+const char *
|
|
|
f441eb |
+adcli_conn_get_domain_sid (adcli_conn *conn)
|
|
|
f441eb |
+{
|
|
|
f441eb |
+ return_val_if_fail (conn != NULL, NULL);
|
|
|
f441eb |
+ return conn->domain_sid;
|
|
|
f441eb |
+}
|
|
|
f441eb |
+
|
|
|
f441eb |
+
|
|
|
f441eb |
LDAP *
|
|
|
f441eb |
adcli_conn_get_ldap_connection (adcli_conn *conn)
|
|
|
f441eb |
{
|
|
|
f441eb |
diff --git a/library/adconn.h b/library/adconn.h
|
|
|
f441eb |
index ed1cc58..13cfd32 100644
|
|
|
f441eb |
--- a/library/adconn.h
|
|
|
f441eb |
+++ b/library/adconn.h
|
|
|
f441eb |
@@ -91,6 +91,8 @@ void adcli_conn_set_domain_controller (adcli_conn *conn,
|
|
|
f441eb |
|
|
|
f441eb |
const char * adcli_conn_get_domain_short (adcli_conn *conn);
|
|
|
f441eb |
|
|
|
f441eb |
+const char * adcli_conn_get_domain_sid (adcli_conn *conn);
|
|
|
f441eb |
+
|
|
|
f441eb |
LDAP * adcli_conn_get_ldap_connection (adcli_conn *conn);
|
|
|
f441eb |
|
|
|
f441eb |
krb5_context adcli_conn_get_krb5_context (adcli_conn *conn);
|
|
|
f441eb |
diff --git a/tools/computer.c b/tools/computer.c
|
|
|
f441eb |
index d8a58c9..a3d0f03 100644
|
|
|
f441eb |
--- a/tools/computer.c
|
|
|
f441eb |
+++ b/tools/computer.c
|
|
|
f441eb |
@@ -43,6 +43,7 @@ dump_details (adcli_conn *conn,
|
|
|
f441eb |
printf ("domain-realm = %s\n", adcli_conn_get_domain_realm (conn));
|
|
|
f441eb |
printf ("domain-controller = %s\n", adcli_conn_get_domain_controller (conn));
|
|
|
f441eb |
printf ("domain-short = %s\n", adcli_conn_get_domain_short (conn));
|
|
|
f441eb |
+ printf ("domain-SID = %s\n", adcli_conn_get_domain_sid (conn));
|
|
|
f441eb |
printf ("naming-context = %s\n", adcli_conn_get_default_naming_context (conn));
|
|
|
f441eb |
printf ("domain-ou = %s\n", adcli_enroll_get_domain_ou (enroll));
|
|
|
f441eb |
|
|
|
f441eb |
--
|
|
|
f441eb |
2.14.4
|
|
|
f441eb |
|