Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 151388
Collapse All | Expand All

(-)xdm/config/Xresources.cpp (+2 lines)
Lines 27-32 Link Here
27
xlogin*namePrompt: \040\040\040\040\040\040\040Login:
27
xlogin*namePrompt: \040\040\040\040\040\040\040Login:
28
#endif /* XPM */
28
#endif /* XPM */
29
xlogin*fail: Login incorrect
29
xlogin*fail: Login incorrect
30
xlogin*alternativeAuth: 0
30
#ifdef XPM
31
#ifdef XPM
31
XHASHif WIDTH > 800
32
XHASHif WIDTH > 800
32
xlogin*greetFont: -adobe-helvetica-bold-o-normal--24-240-75-75-p-138-iso8859-1
33
xlogin*greetFont: -adobe-helvetica-bold-o-normal--24-240-75-75-p-138-iso8859-1
Lines 78-83 Link Here
78
xlogin*useShape: true
79
xlogin*useShape: true
79
xlogin*logoPadding: 10
80
xlogin*logoPadding: 10
80
#endif /* XPM */
81
#endif /* XPM */
82
xlogin*alternativeAuth: false
81
83
82
XConsole.text.geometry:	480x130
84
XConsole.text.geometry:	480x130
83
XConsole.verbose:	true
85
XConsole.verbose:	true
(-)xdm/dm.h (+1 lines)
Lines 271-276 Link Here
271
	/* add new fields below this line, and preferably at the end */
271
	/* add new fields below this line, and preferably at the end */
272
	Boolean		allow_null_passwd; /* allow null password on login */
272
	Boolean		allow_null_passwd; /* allow null password on login */
273
	Boolean		allow_root_login; /* allow direct root login */
273
	Boolean		allow_root_login; /* allow direct root login */
274
	Boolean		allow_pam_first; /* allow direct call of PAM without entering username and password */
274
};
275
};
275
276
276
/* setgroups is not covered by POSIX, arg type varies */
277
/* setgroups is not covered by POSIX, arg type varies */
(-)xdm/greeter/greet.c (-2 / +7 lines)
Lines 293-301 Link Here
293
293
294
    XtSetArg (arglist[0], XtNallowAccess, False);
294
    XtSetArg (arglist[0], XtNallowAccess, False);
295
    XtSetValues (login, arglist, 1);
295
    XtSetValues (login, arglist, 1);
296
297
    Debug ("dispatching %s\n", d->name);
296
    Debug ("dispatching %s\n", d->name);
298
    done = 0;
297
    
298
    done = greet->allow_pam_first;
299
    while (!done) {
299
    while (!done) {
300
	XtAppNextEvent (context, &event);
300
	XtAppNextEvent (context, &event);
301
	switch (event.type) {
301
	switch (event.type) {
Lines 352-357 Link Here
352
    DrawFail (login);
352
    DrawFail (login);
353
    bzero (greet->name, strlen(greet->name));
353
    bzero (greet->name, strlen(greet->name));
354
    bzero (greet->password, strlen(greet->password));
354
    bzero (greet->password, strlen(greet->password));
355
    greet->allow_pam_first = 0;
355
}
356
}
356
357
357
358
Lines 363-368 Link Here
363
    struct dlfuncs        *dlfuncs)
364
    struct dlfuncs        *dlfuncs)
364
{
365
{
365
    int i;
366
    int i;
367
    Arg		arglist[1];
366
368
367
#ifdef GREET_LIB
369
#ifdef GREET_LIB
368
/*
370
/*
Lines 418-423 Link Here
418
#ifdef __OpenBSD__
420
#ifdef __OpenBSD__
419
    openlog("xdm", LOG_ODELAY, LOG_AUTH);
421
    openlog("xdm", LOG_ODELAY, LOG_AUTH);
420
#endif
422
#endif
423
    XtSetArg (arglist[0], XtNalternativeAuth, (char *) &(greet->allow_pam_first));
424
    XtGetValues (login, arglist, 1);
425
    Debug ("allow_pam_first from xresources xlogin*alternativeAuth = %d\n", greet->allow_pam_first);
421
    for (;;) {
426
    for (;;) {
422
	/*
427
	/*
423
	 * Greet user, requesting name/password
428
	 * Greet user, requesting name/password
(-)xdm/greeter/Login.c (+5 lines)
Lines 120-125 Link Here
120
/* end (amit) */
120
/* end (amit) */
121
#endif /* XPM */
121
#endif /* XPM */
122
122
123
/* added by Josef Hajas */
124
        {XtNalternativeAuth, XtCAlternativeAuth, XtRBoolean, sizeof(Boolean),
125
        offset(alternativeAuth), XtRImmediate, (XtPointer) False},
126
/* end (josef) */
127
    
123
    {XtNfont, XtCFont, XtRFontStruct, sizeof (XFontStruct *),
128
    {XtNfont, XtCFont, XtRFontStruct, sizeof (XFontStruct *),
124
    	offset (font), XtRString,	"*-new century schoolbook-medium-r-normal-*-180-*"},
129
    	offset (font), XtRString,	"*-new century schoolbook-medium-r-normal-*-180-*"},
125
    {XtNpromptFont, XtCFont, XtRFontStruct, sizeof (XFontStruct *),
130
    {XtNpromptFont, XtCFont, XtRFontStruct, sizeof (XFontStruct *),
(-)xdm/greeter/Login.h (+3 lines)
Lines 112-117 Link Here
112
# define XtCAllowNullPasswd	"AllowNullPasswd"
112
# define XtCAllowNullPasswd	"AllowNullPasswd"
113
# define XtCAllowRootLogin	"AllowRootLogin"
113
# define XtCAllowRootLogin	"AllowRootLogin"
114
114
115
#define XtNalternativeAuth "alternativeAuth"
116
#define XtCAlternativeAuth "AlternativeAuth"
117
115
/* notifyDone interface definition */
118
/* notifyDone interface definition */
116
119
117
#ifdef __OpenBSD__
120
#ifdef __OpenBSD__
(-)xdm/greeter/LoginP.h (+1 lines)
Lines 90-95 Link Here
90
	Boolean		allow_null_passwd; /* allow null password on login */
90
	Boolean		allow_null_passwd; /* allow null password on login */
91
	Boolean		allow_root_login; /* allow root login */
91
	Boolean		allow_root_login; /* allow root login */
92
	XIC		xic;		/* input method of input context */
92
	XIC		xic;		/* input method of input context */
93
        Boolean 	alternativeAuth;/* biometrics support */
93
#ifdef XPM
94
#ifdef XPM
94
	/*caolan begin*/
95
	/*caolan begin*/
95
	int lastEventTime;
96
	int lastEventTime;
(-)xdm/greeter/verify.c (+5 lines)
Lines 507-512 Link Here
507
	PAM_BAIL;
507
	PAM_BAIL;
508
	pam_error = pam_setcred(*pamhp, 0);
508
	pam_error = pam_setcred(*pamhp, 0);
509
	PAM_BAIL;
509
	PAM_BAIL;
510
	/* if identification was performed, username is known now */
511
	if (strlen (greet->name) == 0) {
512
		pam_error = pam_get_user(*pamhp, &(greet->name), NULL);
513
		PAM_BAIL;
514
	}
510
	p = getpwnam (greet->name);
515
	p = getpwnam (greet->name);
511
	endpwent();
516
	endpwent();
(-)xdm/xdm.man.cpp (+5 lines)
Lines 987-992 Link Here
987
if the account does not require a password at all.
987
if the account does not require a password at all.
988
The default is ``false'', so only users that have passwords assigned can
988
The default is ``false'', so only users that have passwords assigned can
989
log in.
989
log in.
990
.IP "\fBxlogin.alternativeAuth\fP"
991
If set to ``true'', don't give prompt for the first time and directly call PAM.
992
Give login box only after first PAM authorization fail. This is useful set to 
993
``true'' if you have biometrics identification functional.
994
The default is ``false''.
990
.IP "\fBxlogin.Login.translations\fP"
995
.IP "\fBxlogin.Login.translations\fP"
991
This specifies the translations used for the login widget.  Refer to the X
996
This specifies the translations used for the login widget.  Refer to the X
992
Toolkit documentation for a complete discussion on translations.  The default
997
Toolkit documentation for a complete discussion on translations.  The default

Return to bug 151388