AnsweredAssumed Answered

Quick Report Template secure webmap

Question asked by goriliukasbuxton on Jan 3, 2020
Latest reply on Jan 3, 2020 by goriliukasbuxton

Hello, Added this code to the RefineLocationPage.qml to be able to use secure webmap's, it works with username and password part, but it does not work with token part. why?

Connections {
                target: AuthenticationManager // singleton instance
                onAuthenticationChallenge: {
                    console.log("LG-authentication challenge for", challenge.requestUrl)
                    var user = rot13(app.settings.value("username",""))
                    var password = rot13(app.settings.value("password",""));
                    var token = app.settings.value("token","");
                    if (challenge.authenticationChallengeType === Enums.AuthenticationChallengeTypeUsernamePassword) {

                        /*var credential = ArcGISRuntimeEnvironment.createObject("Credential", {
                                                                                   username: user,
                                                                                   password: password

                        var credential = ArcGISRuntimeEnvironment.createObject("Credential", {
                                                                               "token": token
                        //credential.token = app.token


Thank you,