axis root password at first boot - curl request
Posted: Sat Oct 30, 2010 8:33 pm
Hi
I'm looking how to shell script for changing the root password at boot, but no success till now.
I can manage to change it once the first password has been set up but not at the first boot time. (both ways are working: using cgi vapix in a curl request or directly through curl in the shell)
Could anybody give a hint about the right curl request for this please ?
Thx in advance
----------------------------------
Here is what I tried w/o success :
I also tried straight in the browser :
This way showed at the mean time that there is a small bug in the axis cgi script as I could connect to the axis live view despite the root password has not been reset, but this is another story.
I'm looking how to shell script for changing the root password at boot, but no success till now.
I can manage to change it once the first password has been set up but not at the first boot time. (both ways are working: using cgi vapix in a curl request or directly through curl in the shell)
Could anybody give a hint about the right curl request for this please ?
Thx in advance
----------------------------------
Here is what I tried w/o success :
Code: Select all
echo "Changing root default password : "
USER="root"
PASSWORD="new_pwd"
# GET from pwdroot/pwdRoot.shtml
# ="submitdata=action?update&user=$USER&pwd=$PASSWORD&dummy="
# POST="dummy=&user=$USER&pwd=$PASSWORD&pwd_confirm=$PASSWORD"
#POST="user=$USER&pwd=$PASSWORD&dummy="
#POST="user=$USER&pwd=$PASSWORD&pwd_confirm=$PASSWORD&dummy="
POST="submitdata=action?update&user=$USER&pwd=$PASSWORD&dummy="
URL="pwdroot/pwdRoot.shtml"
curl --data "$POST" http://my_cam_lan_ip/"$URL"
Code: Select all
http://my_cam_lan_ip/axis-cgi/pwdroot/pwdroot.cgi?action=update&user=root&pwd=test2&return_page=/