A friend of mine gave me a web application for me to test and find vulnerabilities. He told me that this web application can be purposefully modified and then made to run an SQL injection. I have been trying everything, but I have not been able to gain access to information. He told me that I should be able to obtain certain information such as the debt from someone, or their credit card number, etc. Keep in mind, all the values being outputted in this website are fake and not real. The code for this website is as follows in the web login:
<html> <head><title>Online Access</title></head><body>
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tbody>
<tr>
<td valign="CENTER" bgcolor="#cbbbff">
<center>
<h2>Bank</h2>
</center>
</td>
</tr>
</tbody>
</table>
<form action="login.pl" method="post">
<p> Login denied for user <b></b>! Try again.
<br>
Please enter your access ID and your password to access your credit
card debt information.</p>
<br><b> Access ID: </b>
<input type="text" name="access" size="18"> <br>
<b> Your Bank Password: </b> <input type="password" name="password"
size="10"> <br>
<b> ID number: </b> <input type="text" name="softvulnsec"
size="3" maxlength="3"> <br>
<b> Registration code: </b> <input type="text" name="matnr"
size="7" maxlength="7"> <br>
<br>
<input type="submit" name="login" value="Login">
</form>
</body></html>
Once I am logged in I have access to this bit of code of which I have noticed that there are hidden field parameters.
<html> <head><title>Bank Online Access</title></head><body>
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tbody>
<tr>
<td valign="CENTER" bgcolor="#cbbbff">
<center>
<h2>Bank</h2>
</center>
</td>
</tr>
</tbody>
</table>
<p> Welcome to the Bank access! <br>
You have successfully logged in <i><b></b></i>.<br> Your access id is: <b>123456</b></p> <br>
<p> You can use the following services: <br>
<table border="1">
<form action="login.pl" method="post">
<tr><td>
<b>Credit card account:</b> <a href="javascript:submitForm()">Request
information</a>
</td></tr>
<input type="hidden" value="164532873134525967223123872321" name="param">
<input type="hidden" value="100" name="softvulnsec">
<input type="hidden" value="123456" name="access">
<input type="hidden" value="qwef945372quwiefjd315469875312" name="token">
</form>
<script>
function submitForm()
{
document.forms[0].submit();
}
</script>
</table>
</body></html>
Based on what I have read, since the method is "post" I can modify some of the values in order to gain access to the information, but every time I try to modify the access code in the login page, I get sent back to the login page and the access code and password revert back to the previous correct login information. I have tried to change the hidden parameter to text and then change the value within the access code to different values or to the correct value: 123456 plus an sql injection such as: 123456 AND SELECT *. None of this has given me any insight as to how to access information from the web application. Are there any hints I can get in order to access this information? Do I modify the hidden parameters with sql injection?
access
parameter value or thesoftvulnsec
parameter value is something I'd definitely try.