[squid-users] Basic bourne shell-based authenticator module

From: Allan Dib <allan@dont-contact.us>
Date: Thu, 13 Feb 2003 14:12:55 +1100

Hi all,

I am have written a very basic squid authenticator module. Code is as
follows:

#!/bin/sh
PASSWORDFILE="/usr/local/etc/squid/users.txt"
TEST="123"
while [ ! -z $TEST ]
do
  read AUTH
  if [ ! -z "`grep -x "$AUTH" $PASSWORDFILE`" ]; then
   echo "OK"
  else
   echo "ERR"
  fi
done

It all works fine and authenticates users from a plain text file
(/usr/local/etc/squid/users.txt) whose format is:

user password
user password

The only problem is that the authenicator module processes that squid
spawns don't get killed when squid is killed. It also seems to keep
opening many more authenicator module processes while it runs even
though I have limited it to 5 children in squid.conf.

Any suggestions? I'd really appreciate some direction.

Many thanks in advance......
Received on Wed Feb 12 2003 - 20:12:55 MST

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 17:13:22 MST