Reputation: 21
How can I verify there is a green lock in the url indicating that it is a secure page, using Selenium webdriver?
Upvotes: 0
Views: 197
Reputation: 13811
Why can't you try this:
String url = driver.getCurrentUrl();
Now you have url
, which shows you whether its an http
or https
. If its https
then your connection is secure.
Note: This wont work if you have local ssl certificate, accepted by you.
Upvotes: 1