Sha256: f01dc84e3efa67b0cd3a95321f2df37e7eba23a128559d6795615382734a2388

Contents?: true

Size: 591 Bytes

Versions: 11

Compression:

Stored size: 591 Bytes

Contents

require 'omniauth/openid'

module OmniAuth
  module Strategies
    class GoogleApps < OmniAuth::Strategies::OpenID
      def initialize(app, store = nil, options = {}, &block)
        options[:name] ||= 'google_apps'
        super(app, store, options, &block)
      end

      def get_identifier
        OmniAuth::Form.build(:title => 'Google Apps Authentication') do
          label_field('Google Apps Domain', 'domain')
          input_field('url', 'domain')
        end.to_response
      end

      def identifier
        options[:domain] || request['domain']
      end
    end
  end
end

Version data entries

11 entries across 11 versions & 3 rubygems

Version Path
omniauth-openid-1.0.0 lib/omniauth/strategies/google_apps.rb
omniauth-openid-1.0.0.rc2 lib/omniauth/strategies/google_apps.rb
omniauth-openid-1.0.0.rc1 lib/omniauth/strategies/google_apps.rb
omniauth-openid-1.0.0.beta1 lib/omniauth/strategies/google_apps.rb
oa-openid-0.3.2 lib/omniauth/strategies/google_apps.rb
oa-openid-0.3.0 lib/omniauth/strategies/google_apps.rb
oa-openid-0.3.0.rc3 lib/omniauth/strategies/google_apps.rb
omniauth-0.2.6 oa-openid/lib/omniauth/strategies/google_apps.rb
oa-openid-0.2.6 lib/omniauth/strategies/google_apps.rb
omniauth-0.2.5 oa-openid/lib/omniauth/strategies/google_apps.rb
oa-openid-0.2.5 lib/omniauth/strategies/google_apps.rb