kazurayam / chromedriverfactory

A Java library that enables you to launch Selenium ChromeDriver using an existing user Profile. That let you to carry cookies over multiple HTTP sessions via user Profile.
0 stars 0 forks source link

enhance CookieServer to print the Authorization header decoded #49

Open kazurayam opened 1 year ago

kazurayam commented 1 year ago

I was motivated by the following post in the Katalon User forum:

The original poster wants to use GlobalVariable to carry the username/password to perform a test of HTTP Basic Authentication of REST API.

I think that a Test Case script should set the username/password into a RequestObject using setRequestAuthorization() method.

I want to prove what I think right. In order to prove it, I can write a Katalon Test Case for REST API easily. But that is not enough. I need a HTTP Server that works as a counter part of my HTTP client = the Test Case. The HTTP Server should print the HTTP Request Headers into the console. And most notably, it should be able to print the HTTP Authorization Header, which is always encoded by Base64, in a plain text = decoded text.

The CookieServer in the ChromeDriverFactory project is well fitting for this purpse.

I am not sure if the CookieServer is capable of printing the Authorization header in plain text Base64-decoded.

Why not check it. If it does not yet support it, do implement it.