Bug 957087 - net ads -k join fails without LOGNAME env variable
Summary: net ads -k join fails without LOGNAME env variable
Keywords:
Status: CLOSED EOL
Alias: None
Product: Fedora
Classification: Fedora
Component: samba
Version: 22
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Guenther Deschner
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-04-26 10:28 UTC by Stef Walter
Modified: 2016-07-19 10:10 UTC (History)
9 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-07-19 10:10:54 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Samba Project 10026 0 None None None Never

Description Stef Walter 2013-04-26 10:28:58 UTC
If the LOGNAME environment variable is not set, then 'net ads -k join domain.com' fails. This is easy to duplicate.

First configure /etc/samba/smb.conf like so:

[global]
workgroup = BORG
realm = BORG.THEWALTER.LAN
security = ads

Then kinit and join with commands like this to do a successful join:

[root@stef-fedora realmd]# kinit Administrator.LAN
Password for Administrator.LAN: 
[root@stef-fedora realmd]# net -k ads join borg.thewalter.lan
Using short domain name -- BORG
Joined 'STEF-FEDORA' to dns domain 'borg.thewalter.lan'
No DNS domain configured for stef-fedora. Unable to perform DNS Update.
DNS update failed: NT_STATUS_INVALID_PARAMETER
[root@stef-fedora realmd]# env -u LOGNAME net -k ads join borg.thewalter.lan
Error getting session_key of SAM pipe. Error was NT_STATUS_NO_USER_SESSION_KEY
Failed to join domain: failed to join domain 'borg.thewalter.lan' over rpc: No user session key available

Comment 1 Stef Walter 2013-04-26 10:39:48 UTC
realmd work around: https://bugs.freedesktop.org/show_bug.cgi?id=63956

Comment 2 Stef Walter 2013-05-27 10:24:57 UTC
Looked for the core of the issue but was unable to track it down so far.

Comment 3 Andreas Schneider 2013-05-27 12:11:46 UTC
Well I think it is the popt code in source3. I should try LOGNAME then USER and if it doesn't succeed it should try getpwuid().

source3/lib/popt_common.c and utils/net.c. I think the logic in popt_common.c is wrong too.

If LOGNAME is set and USER is set, then LOGNAME should take precedence.

Comment 4 Fedora End Of Life 2015-01-09 17:58:43 UTC
This message is a notice that Fedora 19 is now at end of life. Fedora 
has stopped maintaining and issuing updates for Fedora 19. It is 
Fedora's policy to close all bug reports from releases that are no 
longer maintained. Approximately 4 (four) weeks from now this bug will
be closed as EOL if it remains open with a Fedora 'version' of '19'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 19 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 5 Fedora End Of Life 2015-02-17 15:04:44 UTC
Fedora 19 changed to end-of-life (EOL) status on 2015-01-06. Fedora 19 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.

Comment 6 Marko Myllynen 2015-02-17 15:07:41 UTC
I think this would be worth fixing (if not fixed already, didn't check) as this might cause hard-to-debug surprises e.g. in kickstart scripts. Thanks.

Comment 7 Fedora End Of Life 2016-07-19 10:10:54 UTC
Fedora 22 changed to end-of-life (EOL) status on 2016-07-19. Fedora 22 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.


Note You need to log in before you can comment on or make changes to this bug.