Update regex parsing of response URI (#830)

* Update regex that extracts the response code from the response URI to avoid potentially generating a bad request to OneDrive, leading to a 'AADSTS9002313: Invalid request. Request is malformed or invalid.' response. With thanks to @zfil for fix.
This commit is contained in:
abraunegg 2020-03-21 07:20:19 +11:00 committed by GitHub
parent edd365d21b
commit 896a4676f5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -225,7 +225,7 @@ final class OneDriveApi
}
}
// match the authorization code
auto c = matchFirst(response, r"(?:[\?&]code=)([\w\d-]+)");
auto c = matchFirst(response, r"(?:[\?&]code=)([\w\d-.]+)");
if (c.empty) {
log.log("Invalid uri");
return false;