Bug 11528 - net ads keytab create crashes if no servicePrincipalName exists
Summary: net ads keytab create crashes if no servicePrincipalName exists
Status: RESOLVED FIXED
Alias: None
Product: Samba 4.1 and newer
Classification: Unclassified
Component: Other (show other bugs)
Version: 4.3.0
Hardware: All All
: P5 minor (vote)
Target Milestone: ---
Assignee: Karolin Seeger
QA Contact: Samba QA Contact
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-09-23 17:19 UTC by Uri Simchoni
Modified: 2015-10-12 19:00 UTC (History)
2 users (show)

See Also:


Attachments
proposed patch (1.07 KB, patch)
2015-09-23 17:26 UTC, Uri Simchoni
no flags Details
git-am fix for 4.3.next, 4.2.next. (1.22 KB, patch)
2015-09-25 20:55 UTC, Jeremy Allison
uri: review+
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Uri Simchoni 2015-09-23 17:19:45 UTC
If the machine account in active directory does not contain servicePrincipalName attributes, the command "net ads keytab create -P" crashes.

Occasionally, when joining a machine to a domain, the machine account ends up without servicePrincipleName attributes. Not sure how to reproduce it, but it does happen against Windows Server DCs.

In such a case, trying to create a keytab should obviously fail, but what happens is that the net command "net ads keytab create" crashes.

To reproduce, servicePrincipalName can be purposefully deleted.
Comment 1 Uri Simchoni 2015-09-23 17:26:24 UTC
Created attachment 11458 [details]
proposed patch
Comment 2 Jeremy Allison 2015-09-25 20:55:30 UTC
Created attachment 11465 [details]
git-am fix for 4.3.next, 4.2.next.

Cherry-pick that went into master. Uri please review ! (PS. Activate your uri@samba.org email address in bugzilla and I can then use that to assign reviews. Much easier to remember :-).

Cheers,

Jeremy.
Comment 3 Jeremy Allison 2015-09-29 19:28:03 UTC
Reassigning to Karolin for inclusion in 4.3.next, 4.2.next !
Comment 4 Karolin Seeger 2015-10-05 07:35:18 UTC
(In reply to Jeremy Allison from comment #3)
Pushed to autobuild-v4-[3|2]-test.
Comment 5 Karolin Seeger 2015-10-12 19:00:29 UTC
(In reply to Karolin Seeger from comment #4)
Closing out bug report.

Thanks!