Unable to handle basic auth pop up

Dear Team,

Refer the attached screenshot i m not able to perform basic auth i have created script as below.

WebUI.openBrowser(‘URL’)

WebUI.authenticate(‘URL’, ‘atlas’, ‘hydra’, 5)

WebUI.navigateToUrl(‘URL’)

WebUI.closeBrowser()

able to launch the browser but its not automatically inputs the user name and password.

refer the attached screenshots and error log.

Logs-

07-24-2019 05:41:59 PM Test Cases/Pranaam_Launch

Elapsed time: 10.957s

Test Cases/Pranaam_Launch FAILED.
Reason:
com.kms.katalon.core.exception.StepFailedException: Unable to navigate to authenticated page
at com.kms.katalon.core.webui.keyword.internal.WebUIKeywordMain.stepFailed(WebUIKeywordMain.groovy:64)
at com.kms.katalon.core.webui.keyword.internal.WebUIKeywordMain.runKeyword(WebUIKeywordMain.groovy:26)
at com.kms.katalon.core.webui.keyword.builtin.AuthenticateKeyword.authenticate(AuthenticateKeyword.groovy:49)
at com.kms.katalon.core.webui.keyword.builtin.AuthenticateKeyword.execute(AuthenticateKeyword.groovy:42)
at com.kms.katalon.core.keyword.internal.KeywordExecutor.executeKeywordForPlatform(KeywordExecutor.groovy:56)
at com.kms.katalon.core.webui.keyword.WebUiBuiltInKeywords.authenticate(WebUiBuiltInKeywords.groovy:2687)
at com.kms.katalon.core.webui.keyword.WebUiBuiltInKeywords$authenticate$0.call(Unknown Source)
at Pranaam_Launch.run(Pranaam_Launch:19)
at com.kms.katalon.core.main.ScriptEngine.run(ScriptEngine.java:194)
at com.kms.katalon.core.main.ScriptEngine.runScriptAsRawText(ScriptEngine.java:119)
at com.kms.katalon.core.main.TestCaseExecutor.runScript(TestCaseExecutor.java:337)
at com.kms.katalon.core.main.TestCaseExecutor.doExecute(TestCaseExecutor.java:328)
at com.kms.katalon.core.main.TestCaseExecutor.processExecutionPhase(TestCaseExecutor.java:307)
at com.kms.katalon.core.main.TestCaseExecutor.accessMainPhase(TestCaseExecutor.java:299)
at com.kms.katalon.core.main.TestCaseExecutor.execute(TestCaseExecutor.java:233)
at com.kms.katalon.core.main.TestCaseMain.runTestCase(TestCaseMain.java:114)
at com.kms.katalon.core.main.TestCaseMain.runTestCase(TestCaseMain.java:105)
at com.kms.katalon.core.main.TestCaseMain$runTestCase$0.call(Unknown Source)
at TempTestCase1563970317090.run(TempTestCase1563970317090.groovy:21)
Caused by: java.lang.Exception: Unsupported platform (only support Windows)
at com.kms.katalon.core.webui.keyword.builtin.AuthenticateKeyword$_authenticate_closure1.doCall(AuthenticateKeyword.groovy:54)
at com.kms.katalon.core.webui.keyword.builtin.AuthenticateKeyword$_authenticate_closure1.call(AuthenticateKeyword.groovy)
at com.kms.katalon.core.webui.keyword.internal.WebUIKeywordMain.runKeyword(WebUIKeywordMain.groovy:20)
… 17 more

maybe the keyword is not supported on linux i have never used it in linux so i can’t tell you for sure
try this way:
WebUI.navigateToUrl(‘https://usernam:password@URL’)
so for your example :
WebUI.navigateToUrl(‘atlas:hydra@URL’)

1 Like

nopes its not working for me.
unexpected token: @ @ line 19, column 33.

@musibul.khan Is it working fine in Windows environment?

WebUI.openBrowser(’’)
WebUI.authenticate(‘https://test.com/’, ‘domainName%5cUSERNAME’, ‘password’, 60, FailureHandling.OPTIONAL)