[X2Go-Commits] libpam-x2go.git - build-main (branch) updated: adc0f8165a106c3dfe52903726d94b695b6ab717

X2Go dev team git-admin at x2go.org
Sat Apr 27 13:45:29 CEST 2013


The branch, build-main has been updated
       via  adc0f8165a106c3dfe52903726d94b695b6ab717 (commit)
      from  debd3a94955e7a64ec3430340ea20efdaa927636 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
-----------------------------------------------------------------------

Summary of changes:
 src/Makefile.am   |    3 ++-
 src/pam-freerdp.c |   23 +++++++----------------
 2 files changed, 9 insertions(+), 17 deletions(-)

The diff of changes is:
diff --git a/src/Makefile.am b/src/Makefile.am
index f7c06f8..e5b04b2 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -14,7 +14,8 @@ pam_freerdp_la_LIBADD = \
 	-lpam
 
 pam_freerdp_la_CFLAGS = \
-	-Wall -Werror
+	-Wall -Werror \
+	-DAUTH_CHECK="\"$(pkglibexecdir)/freerdp-auth-check\""
 
 pkglibexec_PROGRAMS = \
 	freerdp-auth-check
diff --git a/src/pam-freerdp.c b/src/pam-freerdp.c
index 9fc43ed..b06a56a 100644
--- a/src/pam-freerdp.c
+++ b/src/pam-freerdp.c
@@ -130,15 +130,13 @@ pam_sm_authenticate (pam_handle_t *pamh, int flags, int argc, const char **argv)
 	case 0: { /* child */
 		dup2(stdinpipe[0], 0);
 
-		char * args[7];
+		char * args[5];
 
-		args[0] = XFREERDP;
-		args[1] = "--plugin";
-		args[2] = "rdpsnd.so";
-		args[3] = "--no-nla";
-		args[4] = "-f";
-		args[5] = "--from-stdin";
-		args[6] = NULL;
+		args[0] = AUTH_CHECK;
+		args[1] = rhost;
+		args[2] = ruser;
+		args[3] = rdomain;
+		args[4] = NULL;
 
 		struct passwd * pwdent = getpwnam(username);
 		if (pwdent == NULL) {
@@ -164,14 +162,7 @@ pam_sm_authenticate (pam_handle_t *pamh, int flags, int argc, const char **argv)
 		int forkret = 0;
 		int bytesout = 0;
 
-		bytesout += write(stdinpipe[1], ruser, strlen(ruser));
-		bytesout += write(stdinpipe[1], " ", 1);
-		bytesout += write(stdinpipe[1], password, strlen(password));
-		bytesout += write(stdinpipe[1], " ", 1);
-		bytesout += write(stdinpipe[1], rdomain, strlen(rdomain));
-		bytesout += write(stdinpipe[1], " ", 1);
-		bytesout += write(stdinpipe[1], rhost, strlen(rhost));
-		bytesout += write(stdinpipe[1], " ", 1);
+		bytesout = write(stdinpipe[1], password, strlen(password));
 
 		close(stdinpipe[1]);
 


hooks/post-receive
-- 
libpam-x2go.git (Remote login session via X2Go (PAM module))

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "libpam-x2go.git" (Remote login session via X2Go (PAM module)).




More information about the x2go-commits mailing list