Closed andydkelly-ig closed 3 years ago
@andydkelly-ig I just recently commited a change that allows this parameter:
auth.submitaction=submit
This will instruct the tool to perform a submit on the form in which the Username field is located. Can you try this?
Will give it a go
By the way, you can also provide xpath in the auth.submit_field config param. So you could do: auth.submit_field='//*[@id="login-button"]/button'
Sadly this didn't work with either of my apps (one is Ember and one is Angular) - it just cannot seem to find the button to submit. I can find and fill Username and Password but on both apps the login button doesn't appear as type button or submit.
I am not a front end dev, so this is all a little over my head.
On the Angular app the XPath for the login button is //*[@id="button-1022"]
and on the Ember app it is //*[@id="login-button"]/button
I have tried adding these by ID and also by XPath as follows:
auth.submit_field='//*[@id="button-1022"]'
auth.submit_field='//*[@id="login-button"]/button'
I receive the error:
selenium.common.exceptions.NoSuchElementException: Message: Unable to locate element: //*[@type='submit' or @type='button']
@andydkelly-ig could you post a demo page or the HTML / DOM? So I can debug the issue.
https://d3sa-preview.infogixsaas.com/editor is one of them
Cool, I'll take a look!
@andydkelly-ig can you pull the latest image, it should work now without providing any field name. Alternatively you can provide auth.username_field="ember4" auth.password_field="ember5" auth.submit_field="//button"
Fantastic Dick, it's running now. Really appreciate the quick turnaround on this. Thank you very much 👍
Nice!
Hi,
First of all thank you for making this - it's a great resource we've been using for over a year
I am now moving to implement the solution against an existing product we are not yet scanning and am hitting a brick wall authenticating. I have managed to fill in the Username and Password fields on the login screen, but the XPath for our Login button is
//*[@id="login-button"]/button
and as a result i can't find a way to get this to be detected. Any ideas how i can achieve this, or is it possible to add this as an option into the Python script for buttons?Many Thanks