Hello community,
here is the log from the commit of package rubygem-omniauth-google-oauth2 for
openSUSE:Factory checked in at 2018-02-16 21:43:36
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/rubygem-omniauth-google-oauth2 (Old)
and /work/SRC/openSUSE:Factory/.rubygem-omniauth-google-oauth2.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "rubygem-omniauth-google-oauth2"
Fri Feb 16 21:43:36 2018 rev:2 rq:576991 version:0.5.3
Changes:
--------
---
/work/SRC/openSUSE:Factory/rubygem-omniauth-google-oauth2/rubygem-omniauth-google-oauth2.changes
2018-02-15 13:24:47.525532559 +0100
+++
/work/SRC/openSUSE:Factory/.rubygem-omniauth-google-oauth2.new/rubygem-omniauth-google-oauth2.changes
2018-02-16 21:43:38.793307316 +0100
@@ -1,0 +2,22 @@
+Thu Feb 8 06:16:49 UTC 2018 - [email protected]
+
+- updated to version 0.5.3
+ see installed CHANGELOG.md
+
+ ## 0.5.3 - 2018-01-25
+
+ ### Added
+ - Added support for the JWT 2.x gem.
+ - Now fully qualifies the `JWT` class to prevent conflicts with the
`Omniauth::JWT` strategy.
+
+ ### Deprecated
+ - Nothing.
+
+ ### Removed
+ - Removed the `multijson` dependency.
+ - Support for versions of `omniauth-oauth2` < 1.5.
+
+ ### Fixed
+ - Nothing.
+
+-------------------------------------------------------------------
Old:
----
omniauth-google-oauth2-0.5.2.gem
New:
----
omniauth-google-oauth2-0.5.3.gem
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ rubygem-omniauth-google-oauth2.spec ++++++
--- /var/tmp/diff_new_pack.OIoonp/_old 2018-02-16 21:43:39.369286544 +0100
+++ /var/tmp/diff_new_pack.OIoonp/_new 2018-02-16 21:43:39.373286399 +0100
@@ -1,7 +1,7 @@
#
# spec file for package rubygem-omniauth-google-oauth2
#
-# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -24,16 +24,16 @@
#
Name: rubygem-omniauth-google-oauth2
-Version: 0.5.2
+Version: 0.5.3
Release: 0
%define mod_name omniauth-google-oauth2
%define mod_full_name %{mod_name}-%{version}
BuildRoot: %{_tmppath}/%{name}-%{version}-build
-BuildRequires: %{ruby >= 2.0}
+BuildRequires: %{ruby >= 2.1}
BuildRequires: %{rubygem gem2rpm}
BuildRequires: ruby-macros >= 5
Url: https://github.com/zquestz/omniauth-google-oauth2
-Source: http://rubygems.org/gems/%{mod_full_name}.gem
+Source: https://rubygems.org/gems/%{mod_full_name}.gem
Source1: gem2rpm.yml
Summary: A Google OAuth2 strategy for OmniAuth 1.x
License: MIT
++++++ omniauth-google-oauth2-0.5.2.gem -> omniauth-google-oauth2-0.5.3.gem
++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/.rubocop.yml new/.rubocop.yml
--- old/.rubocop.yml 2017-07-31 00:05:17.000000000 +0200
+++ new/.rubocop.yml 2018-01-26 08:47:26.000000000 +0100
@@ -14,7 +14,10 @@
Enabled: false
Metrics/PerceivedComplexity:
Enabled: false
-Style/FileName:
+Naming:
Enabled: false
Style/MutableConstant:
- Enabled: false
\ No newline at end of file
+ Enabled: false
+Gemspec/RequiredRubyVersion:
+ Enabled: false
+
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/CHANGELOG.md new/CHANGELOG.md
--- old/CHANGELOG.md 2017-07-31 00:05:17.000000000 +0200
+++ new/CHANGELOG.md 2018-01-26 08:47:26.000000000 +0100
@@ -1,6 +1,22 @@
# Changelog
All notable changes to this project will be documented in this file.
+## 0.5.3 - 2018-01-25
+
+### Added
+- Added support for the JWT 2.x gem.
+- Now fully qualifies the `JWT` class to prevent conflicts with the
`Omniauth::JWT` strategy.
+
+### Deprecated
+- Nothing.
+
+### Removed
+- Removed the `multijson` dependency.
+- Support for versions of `omniauth-oauth2` < 1.5.
+
+### Fixed
+- Nothing.
+
## 0.5.2 - 2017-07-30
### Added
Binary files old/checksums.yaml.gz and new/checksums.yaml.gz differ
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/examples/Gemfile new/examples/Gemfile
--- old/examples/Gemfile 2017-07-31 00:05:17.000000000 +0200
+++ new/examples/Gemfile 2018-01-26 08:47:26.000000000 +0100
@@ -3,4 +3,5 @@
source 'https://rubygems.org'
gem 'omniauth-google-oauth2', '~> 0.5'
+gem 'rubocop'
gem 'sinatra', '~> 1.4'
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/examples/config.ru new/examples/config.ru
--- old/examples/config.ru 2017-07-31 00:05:17.000000000 +0200
+++ new/examples/config.ru 2018-01-26 08:47:26.000000000 +0100
@@ -85,7 +85,7 @@
content_type 'text/plain'
begin
request.env['omniauth.auth'].to_hash.inspect
- rescue
+ rescue StandardError
'No Data'
end
end
@@ -94,7 +94,7 @@
content_type 'text/plain'
begin
request.env['omniauth.auth'].to_hash.inspect
- rescue
+ rescue StandardError
'No Data'
end
end
@@ -103,7 +103,7 @@
content_type 'text/plain'
begin
request.env['omniauth.auth'].to_hash.inspect
- rescue
+ rescue StandardError
'No Data'
end
end
@@ -114,8 +114,7 @@
use OmniAuth::Builder do
# For additional provider examples please look at 'omni_auth.rb'
# The key provider_ignores_state is only for AJAX flows. It is not
recommended for normal logins.
- # Also, verify_iss is disabled because google now returns an unpredictable
value for iss.
- provider :google_oauth2, ENV['GOOGLE_KEY'], ENV['GOOGLE_SECRET'],
verify_iss: false, access_type: 'offline', prompt: 'consent',
provider_ignores_state: true, scope: 'email,profile,calendar'
+ provider :google_oauth2, ENV['GOOGLE_KEY'], ENV['GOOGLE_SECRET'],
access_type: 'offline', prompt: 'consent', provider_ignores_state: true, scope:
'email,profile,calendar'
end
run App.new
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/lib/omniauth/google_oauth2/version.rb
new/lib/omniauth/google_oauth2/version.rb
--- old/lib/omniauth/google_oauth2/version.rb 2017-07-31 00:05:17.000000000
+0200
+++ new/lib/omniauth/google_oauth2/version.rb 2018-01-26 08:47:26.000000000
+0100
@@ -2,6 +2,6 @@
module OmniAuth
module GoogleOauth2
- VERSION = '0.5.2'
+ VERSION = '0.5.3'
end
end
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/lib/omniauth/strategies/google_oauth2.rb
new/lib/omniauth/strategies/google_oauth2.rb
--- old/lib/omniauth/strategies/google_oauth2.rb 2017-07-31
00:05:17.000000000 +0200
+++ new/lib/omniauth/strategies/google_oauth2.rb 2018-01-26
08:47:26.000000000 +0100
@@ -1,6 +1,5 @@
# frozen_string_literal: true
-require 'multi_json'
require 'jwt'
require 'omniauth/strategies/oauth2'
require 'uri'
@@ -60,7 +59,7 @@
hash = {}
hash[:id_token] = access_token['id_token']
if !options[:skip_jwt] && !access_token['id_token'].nil?
- hash[:id_info] = JWT.decode(
+ hash[:id_info] = ::JWT.decode(
access_token['id_token'], nil, false, verify_iss:
options.verify_iss,
iss: 'accounts.google.com',
verify_aud: true,
@@ -206,7 +205,7 @@
options.hd = options.hd.call if options.hd.is_a? Proc
allowed_hosted_domains = Array(options.hd)
- raise CallbackError.new(:invalid_hd, 'Invalid Hosted Domain') unless
allowed_hosted_domains.include? @raw_info['hd']
+ raise CallbackError.new(:invalid_hd, 'Invalid Hosted Domain') unless
allowed_hosted_domains.include?(@raw_info['hd']) || options.hd == '*'
true
end
end
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/metadata new/metadata
--- old/metadata 2017-07-31 00:05:17.000000000 +0200
+++ new/metadata 2018-01-26 08:47:26.000000000 +0100
@@ -1,7 +1,7 @@
--- !ruby/object:Gem::Specification
name: omniauth-google-oauth2
version: !ruby/object:Gem::Version
- version: 0.5.2
+ version: 0.5.3
platform: ruby
authors:
- Josh Ellithorpe
@@ -9,64 +9,64 @@
autorequire:
bindir: bin
cert_chain: []
-date: 2017-07-30 00:00:00.000000000 Z
+date: 2018-01-26 00:00:00.000000000 Z
dependencies:
- !ruby/object:Gem::Dependency
- name: omniauth
+ name: jwt
requirement: !ruby/object:Gem::Requirement
requirements:
- - ">="
- !ruby/object:Gem::Version
- version: 1.1.1
+ version: '1.5'
type: :runtime
prerelease: false
version_requirements: !ruby/object:Gem::Requirement
requirements:
- - ">="
- !ruby/object:Gem::Version
- version: 1.1.1
+ version: '1.5'
- !ruby/object:Gem::Dependency
- name: omniauth-oauth2
+ name: omniauth
requirement: !ruby/object:Gem::Requirement
requirements:
- - ">="
- !ruby/object:Gem::Version
- version: 1.3.1
+ version: 1.1.1
type: :runtime
prerelease: false
version_requirements: !ruby/object:Gem::Requirement
requirements:
- - ">="
- !ruby/object:Gem::Version
- version: 1.3.1
+ version: 1.1.1
- !ruby/object:Gem::Dependency
- name: jwt
+ name: omniauth-oauth2
requirement: !ruby/object:Gem::Requirement
requirements:
- - - "~>"
+ - - ">="
- !ruby/object:Gem::Version
version: '1.5'
type: :runtime
prerelease: false
version_requirements: !ruby/object:Gem::Requirement
requirements:
- - - "~>"
+ - - ">="
- !ruby/object:Gem::Version
version: '1.5'
- !ruby/object:Gem::Dependency
- name: multi_json
+ name: rake
requirement: !ruby/object:Gem::Requirement
requirements:
- - "~>"
- !ruby/object:Gem::Version
- version: '1.3'
- type: :runtime
+ version: '12.0'
+ type: :development
prerelease: false
version_requirements: !ruby/object:Gem::Requirement
requirements:
- - "~>"
- !ruby/object:Gem::Version
- version: '1.3'
+ version: '12.0'
- !ruby/object:Gem::Dependency
name: rspec
requirement: !ruby/object:Gem::Requirement
@@ -82,20 +82,6 @@
- !ruby/object:Gem::Version
version: '3.6'
- !ruby/object:Gem::Dependency
- name: rake
- requirement: !ruby/object:Gem::Requirement
- requirements:
- - - "~>"
- - !ruby/object:Gem::Version
- version: '12.0'
- type: :development
- prerelease: false
- version_requirements: !ruby/object:Gem::Requirement
- requirements:
- - - "~>"
- - !ruby/object:Gem::Version
- version: '12.0'
-- !ruby/object:Gem::Dependency
name: rubocop
requirement: !ruby/object:Gem::Requirement
requirements:
@@ -147,7 +133,7 @@
requirements:
- - ">="
- !ruby/object:Gem::Version
- version: '2.0'
+ version: '2.1'
required_rubygems_version: !ruby/object:Gem::Requirement
requirements:
- - ">="
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/omniauth-google-oauth2.gemspec
new/omniauth-google-oauth2.gemspec
--- old/omniauth-google-oauth2.gemspec 2017-07-31 00:05:17.000000000 +0200
+++ new/omniauth-google-oauth2.gemspec 2018-01-26 08:47:26.000000000 +0100
@@ -1,4 +1,3 @@
-# -*- encoding: utf-8 -*-
# frozen_string_literal: true
require File.expand_path(
@@ -19,14 +18,13 @@
gem.files = `git ls-files`.split("\n")
gem.require_paths = ['lib']
- gem.required_ruby_version = '>= 2.0'
+ gem.required_ruby_version = '>= 2.1'
+ gem.add_runtime_dependency 'jwt', '>= 1.5'
gem.add_runtime_dependency 'omniauth', '>= 1.1.1'
- gem.add_runtime_dependency 'omniauth-oauth2', '>= 1.3.1'
- gem.add_runtime_dependency 'jwt', '~> 1.5'
- gem.add_runtime_dependency 'multi_json', '~> 1.3'
+ gem.add_runtime_dependency 'omniauth-oauth2', '>= 1.5'
- gem.add_development_dependency 'rspec', '~> 3.6'
gem.add_development_dependency 'rake', '~> 12.0'
+ gem.add_development_dependency 'rspec', '~> 3.6'
gem.add_development_dependency 'rubocop', '~> 0.49'
end
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/spec/omniauth/strategies/google_oauth2_spec.rb
new/spec/omniauth/strategies/google_oauth2_spec.rb
--- old/spec/omniauth/strategies/google_oauth2_spec.rb 2017-07-31
00:05:17.000000000 +0200
+++ new/spec/omniauth/strategies/google_oauth2_spec.rb 2018-01-26
08:47:26.000000000 +0100
@@ -1,6 +1,7 @@
# frozen_string_literal: true
require 'spec_helper'
+require 'json'
require 'omniauth-google-oauth2'
describe OmniAuth::Strategies::GoogleOauth2 do
@@ -123,6 +124,11 @@
@options = { hd: nil }
expect(subject.authorize_params['hd']).to eq(nil)
end
+
+ it 'should set the hd parameter to * if set (only allows G Suite
emails)' do
+ @options = { hd: '*' }
+ expect(subject.authorize_params['hd']).to eq('*')
+ end
end
describe 'login_hint' do
@@ -600,7 +606,7 @@
builder.adapter :test do |stub|
stub.get('/oauth2/v3/tokeninfo?access_token=invalid_iss_token') do
[200, { 'Content-Type' => 'application/json; charset=UTF-8' },
- MultiJson.encode(
+ JSON.dump(
aud: '000000000000.apps.googleusercontent.com',
sub: '123456789',
email_verified: 'true',
@@ -630,7 +636,7 @@
builder.request :url_encoded
builder.adapter :test do |stub|
stub.get('/oauth2/v3/tokeninfo?access_token=valid_access_token') do
- [200, { 'Content-Type' => 'application/json; charset=UTF-8' },
MultiJson.encode(
+ [200, { 'Content-Type' => 'application/json; charset=UTF-8' },
JSON.dump(
aud: '000000000000.apps.googleusercontent.com',
sub: '123456789',
email_verified: 'true',
@@ -641,7 +647,7 @@
)]
end
stub.get('/oauth2/v3/tokeninfo?access_token=invalid_access_token') do
- [400, { 'Content-Type' => 'application/json; charset=UTF-8' },
MultiJson.encode(error_description: 'Invalid Value')]
+ [400, { 'Content-Type' => 'application/json; charset=UTF-8' },
JSON.dump(error_description: 'Invalid Value')]
end
end
end
@@ -674,7 +680,7 @@
builder.request :url_encoded
builder.adapter :test do |stub|
stub.get('/plus/v1/people/me/openIdConnect') do
- [200, { 'Content-Type' => 'application/json; charset=UTF-8' },
MultiJson.encode(
+ [200, { 'Content-Type' => 'application/json; charset=UTF-8' },
JSON.dump(
hd: 'example.com'
)]
end
@@ -689,7 +695,7 @@
builder.request :url_encoded
builder.adapter :test do |stub|
stub.get('/plus/v1/people/me/openIdConnect') do
- [200, { 'Content-Type' => 'application/json; charset=UTF-8' },
MultiJson.encode({})]
+ [200, { 'Content-Type' => 'application/json; charset=UTF-8' },
JSON.dump({})]
end
end
end