[tac_plus] PAM support for PAP
john heasley
heas at shrubbery.net
Tue Mar 20 22:23:53 UTC 2012
Fri, Mar 16, 2012 at 11:25:31PM +0100, Jeroen Nijhof:
> Dear John,
>
> Since I've noticed my old pam patch for pap is still used I've decided
> to rewrite the patch.
>
> Attached you can find the patch which will enable PAM support for PAP. I
> used the 4.0.4.23 branch but it also works for 4.0.4.19 and 4.0.4.22.
>
> Maybe it's worth to integrate the patch with the upstream code?
got it. thanks, Jeroen.
> Thanks!
>
> With kind regards,
> Jeroen Nijhof
> diff -ur tacacs+-F4.0.4.23.orig/config.c tacacs+-F4.0.4.23/config.c
> --- tacacs+-F4.0.4.23.orig/config.c 2012-01-24 01:05:22.000000000 +0100
> +++ tacacs+-F4.0.4.23/config.c 2012-03-16 22:15:38.835033501 +0100
> @@ -86,6 +86,7 @@
> #endif
> pap = cleartext <string> |
> pap = des <string> |
> + pap = PAM |
> opap = cleartext <string> |
> global = cleartext <string> |
> msg = <string>
> @@ -1134,6 +1135,12 @@
> parse(S_separator);
> switch(sym_code) {
>
> +#ifdef HAVE_PAM
> + case S_pam:
> + user->pap = tac_strdup(sym_buf);
> + break;
> +#endif
> +
> case S_cleartext:
> case S_des:
> sprintf(buf, "%s ", sym_buf);
> @@ -1143,7 +1150,11 @@
> break;
>
> default:
> - parse_error("expecting 'cleartext', or 'des' keyword after "
> + parse_error("expecting 'cleartext', "
> +#ifdef HAVE_PAM
> + "'PAM', "
> +#endif
> + "or 'des' keyword after "
> "'pap =' on line %d", sym_line);
> }
> sym_get();
More information about the tac_plus
mailing list