cas monitoring
Sean R. McNamara
sean.r.mcnamara at dartmouth.edu
Thu Jan 15 10:41:39 EST 2009
Hi Mikael,
I use the following curl commands to script a login (for 3.2) -- you
should be able to adapt this to work for your version:
# Pull out the ltValue
ltValue=`curl -k --cookie-jar /tmp/cookieTmp --cookie /tmp/cookieTmp
https://path/to/cas | sed -n 's/.*<input type=\"hidden\" name=\"lt\"
value=\"\(.*\)\" \/>.*/\1/p'`
# Submit ltValue, username, password to login page
loginResponse=`curl -k --cookie-jar /tmp/cookieTmp --cookie
/tmp/cookieTmp https://path/to/cas -d "username=$CASUSERNAME" -d
"password=$PASSWORD" -d "_eventId=submit" -d "lt=$ltValue" -L`
# Remove cookie store
rm /tmp/cookieTmp
HTH,
..Sean.
More information about the cas
mailing list