Apache form authentication issues
- by rfcoder89
I am trying to authenticate users through Apache using the form authentication method to restrict https requests to a certain folder. Although, regardless of whether the correct login details are provided it keeps reloading the same page except the url has the form values embedded in it instead of redirecting to the appropriate page. I need to use the form authentication type instead of basic so I can write my own html for the user to login. I am using Apache 2.4.9 and this is our current configuration.
Apache config file
<Location C:/wamp/www/directory>
SetHandler form-login-handler
AuthFormLoginRequiredLocation https://localNetwork.com/username/TestBed/HTML/login.html
AuthFormLoginSuccessLocation https://localNetwork.com/username/TestBed/HTML/test.html
AuthFormProvider file
AuthUserFile "C:/wamp/passwords"
AuthType form
AuthName realm
Session On
SessionCookieName session path=/
SessionCryptoPassphrase secret
</Location>
And in the login html page I've added that for the user to login
<form method="POST" action="/test.html">
User: <input type="text" name="httpd_username" value="" />
Pass: <input type="password" name="httpd_password" value="" />
<input type="submit" name="login" value="Login" />
</form>