Submit basic HTML form using Postman

Viewed 1146

I am trying to log into this website using Postman. enter image description here

There is no username and this is what the HTML look like:

<body>
    <div class="container">
        <div class="loginbox">
            <img id="logo" src="../gfx/logo.png" alt="" />
            <form action="" method="POST">
                Password: <input type="password" name="password" id="password" />
                <button type="submit" name="submit" id="submit">Submit</button>
            </form>
            <p id="message">
                &nbsp;
            </p>
        </div>
    </div>
</body>

This my POST request on Postman and I am not getting any "Wrong password." html back so I guess I am not doing the correct thing. How can I make a POST request to login using Postman?

enter image description here

2 Answers

The form includes two values, password and submit. The latter has no value associated with it, but the key is still being posted to the server.

It seems that the server-side code is using the submit key to trigger its logic. Just include that in your form data with no value.

Giving a "submit" key as empty in addition to the password field is needed . Please refer the sample request image given.

enter image description here

Related