Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
John McEleney
/
mailutils
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
Commit
24ed1e41
...
24ed1e413c672174ab499b436c1161f968de6233
authored
2002-02-19 17:04:53 +0000
by
Sergey Poznyakoff
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
Use pam_service instead of hardcoding PAM service name
1 parent
605591d4
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
4 deletions
imap4d/login.c
pop3d/user.c
imap4d/login.c
View file @
24ed1e4
...
...
@@ -131,7 +131,7 @@ imap4d_login (struct imap4d_command *command, char *arg)
_pwd
=
pass
;
/* libpam doesn't log to LOG_MAIL */
closelog
();
pamerror
=
pam_start
(
"gnu-imap4d"
,
username
,
&
PAM_conversation
,
&
pamh
);
pamerror
=
pam_start
(
pam_service
,
username
,
&
PAM_conversation
,
&
pamh
);
PAM_ERROR
;
pamerror
=
pam_authenticate
(
pamh
,
0
);
PAM_ERROR
;
...
...
@@ -140,7 +140,7 @@ imap4d_login (struct imap4d_command *command, char *arg)
pamerror
=
pam_setcred
(
pamh
,
PAM_ESTABLISH_CRED
);
PAM_ERROR
;
pam_end
(
pamh
,
PAM_SUCCESS
);
openlog
(
"gnu-imap4d"
,
LOG_PID
,
LOG_FACILITY
);
openlog
(
"gnu-imap4d"
,
LOG_PID
,
log_facility
);
#endif
/* USE_LIBPAM */
if
(
pw
->
pw_uid
>
0
&&
!
mu_virtual_domain
)
...
...
pop3d/user.c
View file @
24ed1e4
...
...
@@ -175,7 +175,7 @@ pop3d_user (const char *arg)
_pwd
=
pass
;
/* libpam doesn't log to LOG_MAIL */
closelog
();
pamerror
=
pam_start
(
"gnu-pop3d"
,
arg
,
&
PAM_conversation
,
&
pamh
);
pamerror
=
pam_start
(
pam_service
,
arg
,
&
PAM_conversation
,
&
pamh
);
PAM_ERROR
;
pamerror
=
pam_authenticate
(
pamh
,
0
);
PAM_ERROR
;
...
...
@@ -185,7 +185,7 @@ pop3d_user (const char *arg)
PAM_ERROR
;
pam_errlab:
pam_end
(
pamh
,
PAM_SUCCESS
);
openlog
(
"gnu-pop3d"
,
LOG_PID
,
LOG_FACILITY
);
openlog
(
"gnu-pop3d"
,
LOG_PID
,
log_facility
);
if
(
pamerror
!=
PAM_SUCCESS
)
{
syslog
(
LOG_INFO
,
"User '%s': authentication failed"
,
_user
);
...
...
Please
register
or
sign in
to post a comment