summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAlan T. DeKok <aland@freeradius.org>2014-09-03 20:46:02 -0400
committerAlan T. DeKok <aland@freeradius.org>2014-09-03 20:46:02 -0400
commit8118169ba506bb9d49a1143aa3e97b1213e38db5 (patch)
treeca8d39dbb605e7cd1b0c347ab3f27d7ec7fb1c35 /src
parent50146dc06372256cb899fbcf68bbc886d5641160 (diff)
downloadlibpam-radius-auth-8118169ba506bb9d49a1143aa3e97b1213e38db5.tar.gz
libpam-radius-auth-8118169ba506bb9d49a1143aa3e97b1213e38db5.zip
Add Calling-Station-Id to Access-Request after challenge. Closes #13
Diffstat (limited to 'src')
-rw-r--r--src/pam_radius_auth.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/pam_radius_auth.c b/src/pam_radius_auth.c
index 5ee7ea9..dab127e 100644
--- a/src/pam_radius_auth.c
+++ b/src/pam_radius_auth.c
@@ -1223,6 +1223,11 @@ PAM_EXTERN int pam_sm_authenticate(pam_handle_t *pamh,int flags,int argc,CONST c
/* request->code is already PW_AUTHENTICATION_REQUEST */
request->id++; /* one up from the request */
+ if (rhost) {
+ add_attribute(request, PW_CALLING_STATION_ID, (unsigned char *) rhost,
+ strlen(rhost));
+ }
+
/* copy the state over from the servers response */
add_attribute(request, PW_STATE, a_state->data, a_state->length - 2);