diff options
author | Andreas Schneider <asn@samba.org> | 2014-09-26 03:09:08 +0200 |
---|---|---|
committer | Karolin Seeger <kseeger@samba.org> | 2014-10-09 21:23:05 +0200 |
commit | 306e7e3746e86ecea0f36411d98ba52532dfba02 (patch) | |
tree | a911c832eb3633d5db33c87d9fbec2da916c104b /source3 | |
parent | f42d65e94d4aeebc7471187a85905fba83a17ace (diff) | |
download | samba-306e7e3746e86ecea0f36411d98ba52532dfba02.tar.gz |
s3-libnet: Add libnet_join_get_machine_spns().
BUG: https://bugzilla.samba.org/show_bug.cgi?id=9984
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
(cherry picked from commit 7e0b8fcce5572c88d50993a1dbd90f65638ba90f)
Diffstat (limited to 'source3')
-rw-r--r-- | source3/libnet/libnet_join.c | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/source3/libnet/libnet_join.c b/source3/libnet/libnet_join.c index 14183853bd..3611cc720f 100644 --- a/source3/libnet/libnet_join.c +++ b/source3/libnet/libnet_join.c @@ -358,6 +358,26 @@ static ADS_STATUS libnet_join_find_machine_acct(TALLOC_CTX *mem_ctx, return status; } +static ADS_STATUS libnet_join_get_machine_spns(TALLOC_CTX *mem_ctx, + struct libnet_JoinCtx *r, + char ***spn_array, + size_t *num_spns) +{ + ADS_STATUS status; + + if (r->in.machine_name == NULL) { + return ADS_ERROR_SYSTEM(EINVAL); + } + + status = ads_get_service_principal_names(mem_ctx, + r->in.ads, + r->in.machine_name, + spn_array, + num_spns); + + return status; +} + /**************************************************************** Set a machines dNSHostName and servicePrincipalName attributes ****************************************************************/ |