[shotwell/shotwell-0.30] authenticator: Fix google and flickr authenticator
- From: Jens Georg <jensgeorg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [shotwell/shotwell-0.30] authenticator: Fix google and flickr authenticator
- Date: Tue, 13 Nov 2018 18:29:27 +0000 (UTC)
commit b918b3739c3b2b5f13f0eabaa71cb5b23ef92405
Author: Jens Georg <mail jensge org>
Date: Tue Nov 13 19:27:34 2018 +0100
authenticator: Fix google and flickr authenticator
There is probably an issue with webkit or how we are using webkit since
the custom scheme is registered, but out call-back is not called.
Fixes #80
plugins/authenticator/shotwell/FlickrPublishingAuthenticator.vala | 3 ++-
plugins/authenticator/shotwell/GoogleAuthenticator.vala | 3 ++-
2 files changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/plugins/authenticator/shotwell/FlickrPublishingAuthenticator.vala
b/plugins/authenticator/shotwell/FlickrPublishingAuthenticator.vala
index 97629ed0..c26f89c3 100644
--- a/plugins/authenticator/shotwell/FlickrPublishingAuthenticator.vala
+++ b/plugins/authenticator/shotwell/FlickrPublishingAuthenticator.vala
@@ -55,7 +55,8 @@ namespace Publishing.Authenticator.Shotwell.Flickr {
public override void on_page_load() {
var uri = new Soup.URI(get_view().get_uri());
if (uri.scheme == "shotwell-auth" && this.auth_code == null) {
- this.error();
+ var form_data = Soup.Form.decode (uri.query);
+ this.auth_code = form_data.lookup("oauth_verifier");
}
if (this.auth_code != null) {
diff --git a/plugins/authenticator/shotwell/GoogleAuthenticator.vala
b/plugins/authenticator/shotwell/GoogleAuthenticator.vala
index f561197c..75d8f37f 100644
--- a/plugins/authenticator/shotwell/GoogleAuthenticator.vala
+++ b/plugins/authenticator/shotwell/GoogleAuthenticator.vala
@@ -23,7 +23,8 @@ namespace Publishing.Authenticator.Shotwell.Google {
public override void on_page_load() {
var uri = new Soup.URI(get_view().get_uri());
if (uri.scheme == REVERSE_CLIENT_ID && this.auth_code == null) {
- this.error();
+ var form_data = Soup.Form.decode (uri.query);
+ this.auth_code = form_data.lookup("code");
}
if (this.auth_code != null) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]