2020-11-05 Fred Gleason <fredg@paravelsystems.com>

* Added logging for failed PAM authentication in
	'RDPam::authenticate()'.

Signed-off-by: Fred Gleason <fredg@paravelsystems.com>
This commit is contained in:
Fred Gleason 2020-11-05 09:56:18 -05:00
parent 7d87f6e93f
commit bb577beb76
2 changed files with 6 additions and 1 deletions

View File

@ -20538,3 +20538,6 @@
* Incremented the package version to 3.4.1int3.
2020-11-02 Fred Gleason <fredg@paravelsystems.com>
* Added a 'donut-spinner' indicator to Webget.
2020-11-05 Fred Gleason <fredg@paravelsystems.com>
* Added logging for failed PAM authentication in
'RDPam::authenticate()'.

View File

@ -80,12 +80,14 @@ bool RDPam::authenticate(const QString &username,const QString &token)
conv.conv=RDPamCallback;
conv.appdata_ptr=(RDPam *)this;
if((err=pam_start(system_pam_service,username,&conv,&pamh))!=PAM_SUCCESS) {
rda->syslog(LOG_WARNING,"PAM Error: %s",pam_strerror(pamh,err));
rda->syslog(LOG_WARNING,"PAM error [%s]",pam_strerror(pamh,err));
pam_end(pamh,err);
CleanupPam();
return false;
}
if((err=pam_authenticate(pamh,0))!=PAM_SUCCESS) {
rda->syslog(LOG_WARNING,"PAM authentication failed [%s]",
pam_strerror(pamh,err));
pam_end(pamh,err);
CleanupPam();
return false;