Rename url to public_cert_url and use app url for realm
Errietta Kostala [Wed, 21 Jan 2015 16:55:52 +0000 (16:55 +0000)]
lib/stemmaweb/Authentication/Credential/Google.pm
root/src/auth/login.tt
stemmaweb.conf

index 07a3c5f..056082b 100644 (file)
@@ -90,7 +90,7 @@ Decoded JSON object containing certificates.
 sub retrieve_certs {
     my ($self, $url) = @_;
 
-    $url ||= ( $self->{_app}->config->{'Authentication::Credential::Google'}->{url} || 'https://www.googleapis.com/oauth2/v1/certs' );
+    $url ||= ( $self->{_app}->config->{'Authentication::Credential::Google'}->{public_cert_url} || 'https://www.googleapis.com/oauth2/v1/certs' );
     return decode_json(get($url));
 }
 
index 1d1a6c2..fd60478 100644 (file)
@@ -86,7 +86,7 @@ $(document).ready(function() {
                        data-cookiepolicy="single_host_origin"
                        data-requestvisibleactions="http://schema.org/AddAction"
                        data-scope="https://www.googleapis.com/auth/plus.profile.emails.read"
-                       data-openidrealm="http://sherlock.scsys.co.uk:3000/"
+                       data-openidrealm="[% c.uri_for('/') %]"
                        >
                        </span>
                </span>
index 0425d7b..8857908 100644 (file)
@@ -11,5 +11,5 @@ name = stemmaweb
     dsn dbi:SQLite:dbname=db/traditions.db
 </Model>
 <Authentication::Credential::Google>
-    url https://www.googleapis.com/oauth2/v1/certs
+    public_cert_url https://www.googleapis.com/oauth2/v1/certs
 </Authentication::Credential::Google>