Advertisement
Guest User

Untitled

a guest
Jul 5th, 2015
206
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.41 KB | None | 0 0
  1. auth_param basic /usr/lib/squid/ncsa_auth.script /etc/squid/passwd.file
  2.  
  3. #!/bin/bash
  4. AUTH_DATE=`date +"%d-%m-%Y %H:%M:%S"`
  5. while read; do
  6. AUTH_STRING="$REPLY"
  7. USERNAME=`echo ${AUTH_STRING} | awk -F' ' '{print $1}'`
  8. RES=`echo ${AUTH_STRING} | /usr/lib/squid/ncsa_auth /etc/squid/passwd`
  9. echo -e $AUTH_DATE'tusername:'${USERNAME}'ttlogin result:t'$RES >> /var/log/squid/auth.log
  10. echo $RES
  11. done
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement