Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Cannot Signin to QuickBlox iOS 13

I am trying to Signin using QuickBlox SDK 2.17.1 with iOS 13 using below code

    let login = "saifan"
    let password = "quickblox"
    QBRequest.logIn(withUserLogin: login,
                    password: password,
                    successBlock: { [weak self] response, user in
                        guard let self = self else {
                            return
                        }

                        Print("Success")

        }, errorBlock: { [weak self] response in
           Print("Error")  
    })

this is working fine in iOS 12 but getting following error only in iOS 13

headers: {
    "Accept-Language" = "en;q=1";
    "Content-Type" = "application/x-www-form-urlencoded";
    "QB-OS" = "iOS 13.0";
    "QB-SDK" = "iOS 2.17.1";
    "QuickBlox-REST-API-Version" = "0.1.1";
    "User-Agent" = "QBNotification/1.0 (iPhone; iOS 13.0; Scale/3.00)";
}
parameters: {
    "application_id" = 78757;
    "auth_key" = "NV-TGg8hQVmG89J";
    nonce = 26;
    signature = "{length=20,bytes=0xe6fd00918cfeb553e6c480c04aea820ac79352f2}";
    timestamp = 1569924922;
    "user[login]" = saifan;
    "user[password]" = quickblox;
}
2019-10-01 15:45:22.577103+0530 QBNotification[8265:150576] [QBCore]: Response[2]
headers: {
    "Access-Control-Allow-Origin" = "*";
    "Cache-Control" = "no-cache";
    "Content-Type" = "application/json; charset=utf-8";
    Date = "Tue, 01 Oct 2019 10:15:22 GMT";
    Duration = "0.228091";
    Server = "nginx/1.14.2";
    "Set-Cookie" = "_mkra_ctxt=dd891e3f72202024ca77cfeba3e42c0d--422; path=/; max-age=5; HttpOnly; secure";
    Status = "422 Unprocessable Entity";
    "Strict-Transport-Security" = "max-age=31536000";
    "quickblox-rest-api-version" = "0.1.1";
    "x-content-type-options" = nosniff;
    "x-frame-options" = SAMEORIGIN;
    "x-request-id" = "f806042d-56a0-4d96-b584-82ad617295f0";
    "x-runtime" = "0.014180";
    "x-xss-protection" = "1; mode=block";
}
error: Request failed: client error (422)
reasons: {
    errors =     {
        base =         (
            "Unexpected signature"
        );
    };
}
like image 670
Saifan Nadaf Avatar asked Oct 01 '19 11:10

Saifan Nadaf


1 Answers

Please update your Quickblox sdk to the latest version (QuickBlox 2.17.4) if you are using Xcode 11. I was also facing the same issue. After the update the issue got fixed.

like image 179
varun v nair Avatar answered Sep 26 '22 23:09

varun v nair