18 January 2026:


This forum is now archived and is in read-only mode. Please continue discussions on our improved new Sahi Pro Community forum.



Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.

How to allow different users log in if it's 401 authorization mode?

Scenario:
Test1:
Log in as user1 which has privilege 1
do sth

Test2:
Log in as user2 which has privilege 2
do other things

But above log in is not from log in form. It's single sign on. Sahi prompts 401 authentication page when user 1 log in. But it seems unless we kill Sahi and re-open a new Sahi, there is no way for Sahi to prompt 401 authentication page for user 2 to input user name and password. Sahi reuses user 1 info for test 2. So, we can not execute above two tests in a suite.

I tried to use _sahi.sendToServer("/_s_/dyn/SessionState_removeAllCredentials");

But it doesn't work. Can anyone help? Thanks!
Sign In or Register to comment.