Bug 1142190

Summary: realm command crashes when no input password
Product: [Fedora] Fedora Reporter: Stef Walter <stefw>
Component: realmdAssignee: Stef Walter <stefw>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 21CC: jhrozek, stefw, yelley
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: realmd-0.16.0-1.fc22 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 1142191 (view as bug list) Environment:
Last Closed: 2015-04-22 22:55:24 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1142191    

Description Stef Walter 2014-09-16 10:26:02 UTC
(gdb) bt
#0  0x00007f2887015679 in prompt_stdin (
    prompt=0x7f2888ff1e90 "Password for admin: ") at tools/realm-client.c:797
#1  build_password_credential (error=0x7fffac434ba0, 
    credential_owner=0x7f2889009861 "administrator", 
    user_name=0x7f2889009828 "admin") at tools/realm-client.c:833
#2  realm_client_build_principal_creds (self=self@entry=0x7f2888fed1d0, 
    membership=membership@entry=0x7f2888ffb580, supported=<optimized out>, 
    user_name=0x7f2889009828 "admin", user_name@entry=0x0, 
    error=error@entry=0x7fffac434ca0) at tools/realm-client.c:897
#3  0x00007f2887016c0c in perform_user_join (client=0x7f2888fed1d0, 
    membership=0x7f2888ffb580, user_name=0x0, options=0x7f2889000390)
    at tools/realm-join.c:153
#4  0x00007f28870172a7 in perform_join (args=<optimized out>, 
    string=<optimized out>, client=<optimized out>) at tools/realm-join.c:234
#5  realm_join (client=0x7f2888fed1d0, argc=2, argv=0x7fffac435088)
    at tools/realm-join.c:301
#6  0x00007f28870134c2 in main (argc=2, argv=0x7fffac435088)
    at tools/realm.c:259
(gdb) p password
$1 = (gchar *) 0x0
(gdb) l
792			password = NULL;
793		}
794	
795		g_printf ("\n");
796	
797		len = strlen (password);
798		if (len > 0 && password[len - 1] == '\n')
799			password[len - 1] = '\0';
800	
801		return password;

realmd-0.15.1-4.fc21.x86_64

Comment 1 Fedora Update System 2015-04-14 11:24:51 UTC
realmd-0.16.0-1.fc22 has been submitted as an update for Fedora 22.
https://admin.fedoraproject.org/updates/realmd-0.16.0-1.fc22

Comment 2 Fedora Update System 2015-04-22 22:55:24 UTC
realmd-0.16.0-1.fc22 has been pushed to the Fedora 22 stable repository.  If problems still persist, please make note of it in this bug report.