omniauth-aai 0.5.2 → 0.6.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.DS_Store +0 -0
- data/.rspec +2 -0
- data/Gemfile +1 -1
- data/Gemfile.lock +153 -123
- data/LICENSE.txt +21 -0
- data/README.md +8 -33
- data/lib/.DS_Store +0 -0
- data/lib/generators/aai/setup_generator.rb +44 -0
- data/lib/generators/aai/templates/migration.rb +18 -2
- data/lib/generators/aai/templates/omniauth.rb +18 -6
- data/lib/generators/aai/templates/session_controller.rb +6 -8
- data/lib/generators/aai/templates/user.rb +25 -9
- data/lib/omniauth-aai.rb +2 -1
- data/lib/omniauth-aai/version.rb +1 -1
- data/lib/omniauth/has_current_user.rb +57 -0
- data/lib/omniauth/strategies/aai.rb +117 -88
- data/omniauth-aai.gemspec +23 -17
- data/spec/example_rails3_app/.DS_Store +0 -0
- data/spec/{example_rails_app → example_rails3_app}/.gitignore +0 -0
- data/spec/{example_rails_app → example_rails3_app}/Gemfile +2 -4
- data/spec/example_rails3_app/Gemfile.lock +123 -0
- data/spec/{example_rails_app → example_rails3_app}/Rakefile +0 -0
- data/spec/{example_rails_app → example_rails3_app}/app/assets/images/rails.png +0 -0
- data/spec/{example_rails_app → example_rails3_app}/app/assets/javascripts/application.js +0 -0
- data/spec/{example_rails_app → example_rails3_app}/app/assets/javascripts/welcome.js.coffee +0 -0
- data/spec/{example_rails_app → example_rails3_app}/app/assets/stylesheets/application.css +0 -0
- data/spec/{example_rails_app → example_rails3_app}/app/assets/stylesheets/welcome.css.scss +0 -0
- data/spec/{example_rails_app → example_rails3_app}/app/controllers/application_controller.rb +0 -0
- data/spec/{example_rails_app → example_rails3_app}/app/controllers/welcome_controller.rb +4 -2
- data/spec/{example_rails_app → example_rails3_app}/app/helpers/application_helper.rb +0 -0
- data/spec/{example_rails_app → example_rails3_app}/app/helpers/welcome_helper.rb +0 -0
- data/spec/{example_rails_app → example_rails3_app}/app/mailers/.gitkeep +0 -0
- data/spec/{example_rails_app → example_rails3_app}/app/models/.gitkeep +0 -0
- data/spec/example_rails3_app/app/views/.DS_Store +0 -0
- data/spec/{example_rails_app → example_rails3_app}/app/views/layouts/application.html.erb +0 -0
- data/spec/{example_rails_app → example_rails3_app}/app/views/welcome/index.html.erb +0 -0
- data/spec/{example_rails_app → example_rails3_app}/app/views/welcome/protected.html.erb +0 -0
- data/spec/{example_rails_app → example_rails3_app}/change_application_controller.rb +0 -0
- data/spec/{example_rails_app → example_rails3_app}/config.ru +0 -0
- data/spec/{example_rails_app → example_rails3_app}/config/application.rb +1 -6
- data/spec/{example_rails_app → example_rails3_app}/config/boot.rb +0 -0
- data/spec/{example_rails_app → example_rails3_app}/config/database.yml +0 -0
- data/spec/{example_rails_app → example_rails3_app}/config/environment.rb +0 -0
- data/spec/{example_rails_app → example_rails3_app}/config/environments/development.rb +1 -6
- data/spec/{example_rails_app → example_rails3_app}/config/environments/production.rb +0 -3
- data/spec/{example_rails_app → example_rails3_app}/config/environments/test.rb +2 -3
- data/spec/{example_rails_app → example_rails3_app}/config/initializers/backtrace_silencers.rb +0 -0
- data/spec/{example_rails_app → example_rails3_app}/config/initializers/inflections.rb +0 -0
- data/spec/{example_rails_app → example_rails3_app}/config/initializers/mime_types.rb +0 -0
- data/spec/{example_rails_app → example_rails3_app}/config/initializers/secret_token.rb +1 -0
- data/spec/{example_rails_app → example_rails3_app}/config/initializers/session_store.rb +0 -0
- data/spec/{example_rails_app → example_rails3_app}/config/initializers/wrap_parameters.rb +0 -0
- data/spec/{example_rails_app → example_rails3_app}/config/locales/en.yml +0 -0
- data/spec/{example_rails_app → example_rails3_app}/config/routes.rb +2 -2
- data/spec/example_rails3_app/db/development.sqlite3 +0 -0
- data/spec/example_rails3_app/db/schema.rb +16 -0
- data/spec/{example_rails_app → example_rails3_app}/db/seeds.rb +0 -0
- data/spec/example_rails3_app/db/test.sqlite3 +0 -0
- data/spec/{example_rails_app → example_rails3_app}/doc/README_FOR_APP +0 -0
- data/spec/{example_rails_app → example_rails3_app}/lib/assets/.gitkeep +0 -0
- data/spec/{example_rails_app → example_rails3_app}/lib/tasks/.gitkeep +0 -0
- data/spec/{example_rails_app → example_rails3_app}/log/.gitkeep +0 -0
- data/spec/example_rails3_app/log/development.log +741 -0
- data/spec/example_rails3_app/log/test.log +24 -0
- data/spec/{example_rails_app → example_rails3_app}/public/404.html +0 -0
- data/spec/{example_rails_app → example_rails3_app}/public/422.html +0 -0
- data/spec/{example_rails_app → example_rails3_app}/public/500.html +0 -0
- data/spec/{example_rails_app → example_rails3_app}/public/favicon.ico +0 -0
- data/spec/{example_rails_app → example_rails3_app}/public/robots.txt +0 -0
- data/spec/{example_rails_app → example_rails3_app}/script/rails +0 -0
- data/spec/{example_rails_app → example_rails3_app}/test/fixtures/.gitkeep +0 -0
- data/spec/{example_rails_app → example_rails3_app}/test/functional/.gitkeep +0 -0
- data/spec/{example_rails_app → example_rails3_app}/test/functional/welcome_controller_test.rb +0 -0
- data/spec/{example_rails_app → example_rails3_app}/test/integration/.gitkeep +0 -0
- data/spec/{example_rails_app → example_rails3_app}/test/performance/browsing_test.rb +0 -0
- data/spec/{example_rails_app → example_rails3_app}/test/test_helper.rb +0 -0
- data/spec/{example_rails_app → example_rails3_app}/test/unit/.gitkeep +0 -0
- data/spec/{example_rails_app → example_rails3_app}/test/unit/helpers/welcome_helper_test.rb +0 -0
- data/spec/example_rails3_app/tmp/cache/assets/C26/690/sprockets%2F93708cb34051f3000884905e8669d74a +0 -0
- data/spec/example_rails3_app/tmp/cache/assets/C30/B40/sprockets%2Ff006fa583c943775b96596827195b022 +0 -0
- data/spec/example_rails3_app/tmp/cache/assets/C5C/B50/sprockets%2F7a556208881f6d893d11269bf2a09158 +0 -0
- data/spec/example_rails3_app/tmp/cache/assets/C83/640/sprockets%2F3233432f81669b9bd10ef726c526d348 +0 -0
- data/spec/example_rails3_app/tmp/cache/assets/CD0/AB0/sprockets%2F2211190fb757d05874e2b25fc37a31ad +0 -0
- data/spec/example_rails3_app/tmp/cache/assets/CD8/370/sprockets%2F357970feca3ac29060c1e3861e2c0953 +0 -0
- data/spec/example_rails3_app/tmp/cache/assets/CE2/AD0/sprockets%2Fbd71546009ab5e606b3f27b4c6a79856 +0 -0
- data/spec/example_rails3_app/tmp/cache/assets/D14/000/sprockets%2Fffd7643b7c429e23bdb2281097a5e096 +0 -0
- data/spec/example_rails3_app/tmp/cache/assets/D32/A10/sprockets%2F13fe41fee1fe35b49d145bcc06610705 +0 -0
- data/spec/example_rails3_app/tmp/cache/assets/D4E/1B0/sprockets%2Ff7cbd26ba1d28d48de824f0e94586655 +0 -0
- data/spec/example_rails3_app/tmp/cache/assets/D5A/EA0/sprockets%2Fd771ace226fc8215a3572e0aa35bb0d6 +0 -0
- data/spec/example_rails3_app/tmp/cache/assets/D5E/170/sprockets%2F2f2229c70dcf195564d4d0fd6a12ac1a +0 -0
- data/spec/example_rails3_app/tmp/cache/assets/DDC/400/sprockets%2Fcffd775d018f68ce5dba1ee0d951a994 +0 -0
- data/spec/example_rails3_app/tmp/cache/assets/E04/890/sprockets%2F2f5173deea6c795b8fdde723bb4b63af +0 -0
- data/spec/example_rails3_app/tmp/cache/assets/E29/9D0/sprockets%2Fea5ba88ffb1f831008ba38ed70bd8cfa +0 -0
- data/spec/example_rails3_app/tmp/cache/assets/E3F/0C0/sprockets%2F9addc9febe49c19a6eee9360f156afe3 +0 -0
- data/spec/{example_rails_app → example_rails3_app}/vendor/assets/javascripts/.gitkeep +0 -0
- data/spec/{example_rails_app → example_rails3_app}/vendor/assets/stylesheets/.gitkeep +0 -0
- data/spec/{example_rails_app → example_rails3_app}/vendor/plugins/.gitkeep +0 -0
- data/spec/example_rails4_app/.gitignore +17 -0
- data/spec/example_rails4_app/Gemfile +46 -0
- data/spec/example_rails4_app/Gemfile.lock +171 -0
- data/spec/example_rails4_app/README.rdoc +28 -0
- data/spec/example_rails4_app/Rakefile +6 -0
- data/spec/example_rails4_app/app/assets/images/.keep +0 -0
- data/spec/example_rails4_app/app/assets/javascripts/application.js +16 -0
- data/spec/example_rails4_app/app/assets/stylesheets/application.css +15 -0
- data/spec/example_rails4_app/app/controllers/application_controller.rb +4 -0
- data/spec/example_rails4_app/app/controllers/concerns/.keep +0 -0
- data/spec/example_rails4_app/app/controllers/session_controller.rb +38 -0
- data/spec/example_rails4_app/app/controllers/welcome_controller.rb +11 -0
- data/spec/example_rails4_app/app/helpers/application_helper.rb +2 -0
- data/spec/example_rails4_app/app/mailers/.keep +0 -0
- data/spec/example_rails4_app/app/models/.keep +0 -0
- data/spec/example_rails4_app/app/models/concerns/.keep +0 -0
- data/spec/example_rails4_app/app/models/user.rb +57 -0
- data/spec/example_rails4_app/app/views/.DS_Store +0 -0
- data/spec/example_rails4_app/app/views/layouts/application.html.erb +14 -0
- data/spec/example_rails4_app/app/views/welcome/index.html.erb +3 -0
- data/spec/example_rails4_app/app/views/welcome/protected.html.erb +2 -0
- data/spec/example_rails4_app/bin/bundle +3 -0
- data/spec/example_rails4_app/bin/rails +8 -0
- data/spec/example_rails4_app/bin/rake +8 -0
- data/spec/example_rails4_app/bin/setup +29 -0
- data/spec/example_rails4_app/bin/spring +15 -0
- data/spec/example_rails4_app/config.ru +4 -0
- data/spec/example_rails4_app/config/application.rb +26 -0
- data/spec/example_rails4_app/config/boot.rb +3 -0
- data/spec/example_rails4_app/config/database.yml +25 -0
- data/spec/example_rails4_app/config/environment.rb +5 -0
- data/spec/example_rails4_app/config/environments/development.rb +41 -0
- data/spec/example_rails4_app/config/environments/production.rb +79 -0
- data/spec/example_rails4_app/config/environments/test.rb +42 -0
- data/spec/example_rails4_app/config/initializers/assets.rb +11 -0
- data/spec/example_rails4_app/config/initializers/backtrace_silencers.rb +7 -0
- data/spec/example_rails4_app/config/initializers/cookies_serializer.rb +3 -0
- data/spec/example_rails4_app/config/initializers/filter_parameter_logging.rb +4 -0
- data/spec/example_rails4_app/config/initializers/inflections.rb +16 -0
- data/spec/example_rails4_app/config/initializers/mime_types.rb +4 -0
- data/spec/example_rails4_app/config/initializers/omniauth.rb +23 -0
- data/spec/example_rails4_app/config/initializers/session_store.rb +3 -0
- data/spec/example_rails4_app/config/initializers/wrap_parameters.rb +14 -0
- data/spec/example_rails4_app/config/locales/en.yml +23 -0
- data/spec/example_rails4_app/config/routes.rb +10 -0
- data/spec/example_rails4_app/config/secrets.yml +22 -0
- data/spec/example_rails4_app/db/development.sqlite3 +0 -0
- data/spec/example_rails4_app/db/migrate/20150528142303_aai_create_user.rb +20 -0
- data/spec/example_rails4_app/db/migrate/20150609094544_create_aai_user.rb +26 -0
- data/spec/example_rails4_app/db/schema.rb +33 -0
- data/spec/example_rails4_app/db/seeds.rb +7 -0
- data/spec/example_rails4_app/lib/assets/.keep +0 -0
- data/spec/example_rails4_app/lib/tasks/.keep +0 -0
- data/spec/example_rails4_app/log/.keep +0 -0
- data/spec/example_rails4_app/log/development.log +7189 -0
- data/spec/example_rails4_app/log/test.log +0 -0
- data/spec/example_rails4_app/public/404.html +67 -0
- data/spec/example_rails4_app/public/422.html +67 -0
- data/spec/example_rails4_app/public/500.html +66 -0
- data/spec/example_rails4_app/public/favicon.ico +0 -0
- data/spec/example_rails4_app/public/robots.txt +5 -0
- data/spec/example_rails4_app/test/controllers/.keep +0 -0
- data/spec/example_rails4_app/test/fixtures/.keep +0 -0
- data/spec/example_rails4_app/test/helpers/.keep +0 -0
- data/spec/example_rails4_app/test/integration/.keep +0 -0
- data/spec/example_rails4_app/test/mailers/.keep +0 -0
- data/spec/example_rails4_app/test/models/.keep +0 -0
- data/spec/example_rails4_app/test/test_helper.rb +10 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/1s_XCxu5Ta3ZrQVnXIYvLyRMXFQo20cDx9dOl2Z2iF8.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/29DyBLYZiyJ3FlvLIMPsG2-7J8nAW42idLjWLEVdB_k.cache +0 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/3QbXCZJvxomnkCnjUWHuRcr1GygZ_h2BHAvxwpDe8_s.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/4DpD3QisvkI9coAiaW5J81R3QEdauKikO3Gh5M8mwWo.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/6NLgJvQ8d_2Hvs_dsIe78tpsALlFUB02E_yBe-2E5cA.cache +0 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/6jHw85RU0ldd0Q9aN-7rANpT7g1-koNDbSenv-m7smI.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/7BAbDbQvvxI5tyXDU4FFEVqkskvwpwBb-Okv_3k7m_A.cache +0 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/9wp0IZ0iih5-OpulhDQiwTcivSJ1B0NGGT3E0QqfUvY.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/BNSnmei4pmTUWNUSAxEsb0MthlP4aMS69DOMLpxnO1w.cache +0 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/CuDbyYCWFI80xf5TcM_YGo4vs7XDrDT2uGZbXL1CNlU.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/E7vUl62-SGsQ8YapPcF158Pt1JkBL-9rifcB_9dP8Dk.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/Gb8DbxW8LZBtcLvB3DaLNTXt5D0MNezSV797OaoPY9Q.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/GgQIx53L-9pWadlFfRd5NlAqwNFKf7DLPkPnsnQ7bNk.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/GjsYHKbT8fxMeVlnpmarx6Xi-_Ph0QMuk1BHoU4JDrQ.cache +2 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/H4FEyyRC4IJsChOdu1cf9NDgg8w6J1YBVNHaKN92h9o.cache +0 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/If5Lvqrq1tySO8vBUqp2xvRY_mnDfGebBxBP2mxZbZY.cache +0 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/IoT_x37i_0kSKYgLgbJR5-i6lvuoyNhOt9FSw-yILiQ.cache +0 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/JUseOAL-WHjhDijGjAaXwOvZEJUVhMs_jFSMbXunViY.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/KJcDzapXqjQsiil8Z8og8g_9qX88kXR8p3pMopsauA8.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/KZpDQ14WKjcnWnLxlL99qFCd6ARfk0MsdegUfI30RMk.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/KZxCQPT4Q2wX3rHnJZcFGWZPTtq7oNH9llxBAALh43s.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/LgV_5lRim8CeylWertau64VwyRxtI51id8BtgIok58g.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/Nt-6pBlTra27ZPWSp2yTZSKBAePHJHgDlIoxWTgF9i8.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/PHhC5vQizTPXEkJAiD_q9ESL7UlJW-l8Ua2aoWOhv_o.cache +0 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/QRU43JksZxXfCsqux8aCe2yyWueGiamUDi18N8gDA1Q.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/RECBJfTHjk7obOczR_QxMkSagYRkmidf_ZawDoZTR8A.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/RanHbvC55zjJip0GoEuKsXCXGiMAnd9n7zr67BIqBSw.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/S5179qXMIYo2z-pYHnXOtD2IYoz5ac8moYSK7pNt7m8.cache +2 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/SO9WJ6f1sF18HRfzSmwkLdVZZwRBNz1DxAaYtGbOTrE.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/SPlj-pwirc-AB3GMeOqDR5gSAiu3j6C7QnAZfGmE9_I.cache +0 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/TGEldewczDNL-pNPKYkePKZe3ySFo2sisfkbnD19W4s.cache +2 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/TdlxPZJxUr_7HWj7CrC81yJyV0-40_Ogqo_1NTaEoIU.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/TowmqkMiUGEwvy7lnHQ_88ROBl0yb2D4yH0ugiNjvfA.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/Tp7wu_U3u6gFUnDoUHA40bWXyFOSSxNiXK6XPRwYmYU.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/TqgWeb7o7Z23teWSLaSdF-f3_8aYzRVbBVZhQUHuZVc.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/VOp0pIv_pTt1jyD5JQn5Ee721CyQFQTGdnz4ODw38i4.cache +0 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/W8O66kikznV0XXIhsnH-3dHWm24NyxyK2BbzZvEssto.cache +0 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/YLGfTegl3aFlYlDF7dfyQ5OuL6B6D3l-mcGVqtWnVQ8.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/YngNHAn-McYDpn3H2vj5Cfs7jvy6y0xXgV2lm-QqytU.cache +0 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/_J-JFAM5KZ8G3xUcVV9ht5vdsdH3wHg737JhiRTNl30.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/apXOQCHHr7toaELV0vOhGpGHp0qsm15GmPpb-6SA6GI.cache +0 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/c5jVOyypWys4L2Hoyc4U84gCAJg3tGepalH4_wvPjag.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/c8Xfpa8RSionpn-Hbvc5pDqvktT2tZDhvRCrUD1V_Oo.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/cihMJr_YPzjx-OxZT97hhVuVpY1rkTjbZmXFd8XHCaU.cache +3 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/dHMPXPs1sOQ-fiWIOHBlX15A53Jm0CIPz2F_hNdtS3M.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/e99bn4nHgVDcocbTGKcEmDNK9c_hXbgX6QjCJFCZHJM.cache +0 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/fLv1zUMqDQeVn2AWONn1mWotZV-MKGL2VWCOWalnPkg.cache +0 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/fWQJziLu4L1W29En3opeg-1CsjRQBWmvxu9pCs4bXj8.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/gLKErIDcQk5SB5QrsCeFTLyCw5500orRLwYeVdZdKMc.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/gr63R85vyTqHHJZQ-17HzBTVQzxNIG5ioLBJIG7ylUI.cache +0 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/h94CfaFE7uxKkjg9ok-t1VaNrmPtIlflckdFHhn8HQs.cache +0 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/hE4vknoiDD4JODeZCrqVQJsqIprogjXMLmC8OwA_Jr0.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/hS0tOwqtQJaZQ94vExFzOIkbAuInPL-qbhJ_ehyAIdA.cache +0 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/jRTlxo8OfNbF2UFI9yARZfikVm2L6tckGljgpdPKJAE.cache +0 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/jWzKY7vp1V-gp2DIoaBUf6FHlXy64u51evJE2HTEmHw.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/qzBkjnl32lQWbp5TzPSAUL1ai7Di46nMpBx4F7m6x5s.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/r77JGKq0Pw_xiSzw2prNjqaAF6alyTiTyCsdnbipthY.cache +0 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/rJ0exYcGrKT54S-78fIu6vNCgQs3mDufsDxQ14gI_8E.cache +0 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/rx80cSLfrwi0ZB09RMu0y303mn2cqY0n-HVvX4OZSvg.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/t86ZINxINr8OvlNbaSMwdIJCEKNwBO6brBig2BlQM14.cache +0 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/tXvI8895yJKqfChNv65cTiwS7lytvZHFz1fXzFbzVeM.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/ueBgJWdtY_h7B_DpJgfhaB1zK-p3TTKWfXHuoog1ee0.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/umu0vtYbA7uPY--szPF2GZOzRsafL6YLGkxCLx52t0c.cache +3 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/wRYMTVh2J03EQY8OmShoXFHM5q_wkCsogrHuAv8CR6g.cache +1 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/xSK_JYmeNOLhG9YlWG_YGYarb8YLyIeMXHahwRIyhZY.cache +0 -0
- data/spec/example_rails4_app/tmp/cache/assets/development/sprockets/v3.0/yLpEexUzUtWqrKQPCErdaCnJUUkxgSLIOShi9XNRKlM.cache +0 -0
- data/spec/example_rails4_app/vendor/assets/javascripts/.keep +0 -0
- data/spec/example_rails4_app/vendor/assets/stylesheets/.keep +0 -0
- data/spec/omniauth/has_current_user_spec.rb +9 -0
- data/spec/omniauth/strategies/aai_spec.rb +83 -20
- data/spec/omniauth/strategies/brute_force_spec.rb +6 -6
- data/spec/spec_helper.rb +12 -6
- data/spec/support/omniauth_macros.rb +13 -0
- metadata +486 -195
- data/lib/action_controller/has_current_user.rb +0 -44
- data/lib/generators/aai/install_generator.rb +0 -41
- data/omniauth-aai-0.3.gem +0 -0
- data/omniauth-aai-0.4.gem +0 -0
- data/omniauth-aai-0.5.1.gem +0 -0
@@ -0,0 +1,24 @@
|
|
1
|
+
Started GET "/" for 127.0.0.1 at 2014-09-29 16:00:55 +0200
|
2
|
+
Processing by WelcomeController#index as HTML
|
3
|
+
Rendered welcome/index.html.erb within layouts/application (5.7ms)
|
4
|
+
Completed 500 Internal Server Error in 10ms
|
5
|
+
[1m[36m (7.2ms)[0m [1mCREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL) [0m
|
6
|
+
[1m[35m (1.0ms)[0m CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
|
7
|
+
[1m[36m (0.1ms)[0m [1mSELECT version FROM "schema_migrations"[0m
|
8
|
+
[1m[35m (0.7ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('0')
|
9
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
10
|
+
[1m[35m (0.1ms)[0m begin transaction
|
11
|
+
--------------------------------------------
|
12
|
+
WelcomeControllerTest: test_should_get_index
|
13
|
+
--------------------------------------------
|
14
|
+
Processing by WelcomeController#index as HTML
|
15
|
+
Rendered welcome/index.html.erb within layouts/application (7.6ms)
|
16
|
+
Completed 500 Internal Server Error in 14ms
|
17
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
18
|
+
[1m[35m (0.1ms)[0m begin transaction
|
19
|
+
------------------------------------------------
|
20
|
+
WelcomeControllerTest: test_should_get_protected
|
21
|
+
------------------------------------------------
|
22
|
+
Processing by WelcomeController#protected as HTML
|
23
|
+
Completed 500 Internal Server Error in 1ms
|
24
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
data/spec/{example_rails_app → example_rails3_app}/test/functional/welcome_controller_test.rb
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
data/spec/example_rails3_app/tmp/cache/assets/C26/690/sprockets%2F93708cb34051f3000884905e8669d74a
ADDED
Binary file
|
data/spec/example_rails3_app/tmp/cache/assets/C30/B40/sprockets%2Ff006fa583c943775b96596827195b022
ADDED
Binary file
|
data/spec/example_rails3_app/tmp/cache/assets/C5C/B50/sprockets%2F7a556208881f6d893d11269bf2a09158
ADDED
Binary file
|
data/spec/example_rails3_app/tmp/cache/assets/C83/640/sprockets%2F3233432f81669b9bd10ef726c526d348
ADDED
Binary file
|
data/spec/example_rails3_app/tmp/cache/assets/CD0/AB0/sprockets%2F2211190fb757d05874e2b25fc37a31ad
ADDED
Binary file
|
data/spec/example_rails3_app/tmp/cache/assets/CD8/370/sprockets%2F357970feca3ac29060c1e3861e2c0953
ADDED
Binary file
|
data/spec/example_rails3_app/tmp/cache/assets/CE2/AD0/sprockets%2Fbd71546009ab5e606b3f27b4c6a79856
ADDED
Binary file
|
data/spec/example_rails3_app/tmp/cache/assets/D14/000/sprockets%2Fffd7643b7c429e23bdb2281097a5e096
ADDED
Binary file
|
data/spec/example_rails3_app/tmp/cache/assets/D32/A10/sprockets%2F13fe41fee1fe35b49d145bcc06610705
ADDED
Binary file
|
data/spec/example_rails3_app/tmp/cache/assets/D4E/1B0/sprockets%2Ff7cbd26ba1d28d48de824f0e94586655
ADDED
Binary file
|
data/spec/example_rails3_app/tmp/cache/assets/D5A/EA0/sprockets%2Fd771ace226fc8215a3572e0aa35bb0d6
ADDED
Binary file
|
data/spec/example_rails3_app/tmp/cache/assets/D5E/170/sprockets%2F2f2229c70dcf195564d4d0fd6a12ac1a
ADDED
Binary file
|
data/spec/example_rails3_app/tmp/cache/assets/DDC/400/sprockets%2Fcffd775d018f68ce5dba1ee0d951a994
ADDED
Binary file
|
data/spec/example_rails3_app/tmp/cache/assets/E04/890/sprockets%2F2f5173deea6c795b8fdde723bb4b63af
ADDED
Binary file
|
data/spec/example_rails3_app/tmp/cache/assets/E29/9D0/sprockets%2Fea5ba88ffb1f831008ba38ed70bd8cfa
ADDED
Binary file
|
data/spec/example_rails3_app/tmp/cache/assets/E3F/0C0/sprockets%2F9addc9febe49c19a6eee9360f156afe3
ADDED
Binary file
|
File without changes
|
File without changes
|
File without changes
|
@@ -0,0 +1,17 @@
|
|
1
|
+
# See https://help.github.com/articles/ignoring-files for more about ignoring files.
|
2
|
+
#
|
3
|
+
# If you find yourself ignoring temporary files generated by your text editor
|
4
|
+
# or operating system, you probably want to add a global ignore instead:
|
5
|
+
# git config --global core.excludesfile '~/.gitignore_global'
|
6
|
+
|
7
|
+
# Ignore bundler config.
|
8
|
+
/.bundle
|
9
|
+
|
10
|
+
# Ignore the default SQLite database.
|
11
|
+
/db/*.sqlite3
|
12
|
+
/db/*.sqlite3-journal
|
13
|
+
|
14
|
+
# Ignore all logfiles and tempfiles.
|
15
|
+
/log/*
|
16
|
+
!/log/.keep
|
17
|
+
/tmp
|
@@ -0,0 +1,46 @@
|
|
1
|
+
source 'https://rubygems.org'
|
2
|
+
|
3
|
+
gem 'omniauth-aai', path: "../../../omniauth-aai"
|
4
|
+
|
5
|
+
# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
|
6
|
+
gem 'rails', '4.2.1'
|
7
|
+
# Use sqlite3 as the database for Active Record
|
8
|
+
gem 'sqlite3'
|
9
|
+
# Use SCSS for stylesheets
|
10
|
+
gem 'sass-rails', '~> 5.0'
|
11
|
+
# Use Uglifier as compressor for JavaScript assets
|
12
|
+
gem 'uglifier', '>= 1.3.0'
|
13
|
+
# Use CoffeeScript for .coffee assets and views
|
14
|
+
gem 'coffee-rails', '~> 4.1.0'
|
15
|
+
# See https://github.com/rails/execjs#readme for more supported runtimes
|
16
|
+
# gem 'therubyracer', platforms: :ruby
|
17
|
+
|
18
|
+
# Use jquery as the JavaScript library
|
19
|
+
gem 'jquery-rails'
|
20
|
+
# Turbolinks makes following links in your web application faster. Read more: https://github.com/rails/turbolinks
|
21
|
+
gem 'turbolinks'
|
22
|
+
# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
|
23
|
+
gem 'jbuilder', '~> 2.0'
|
24
|
+
# bundle exec rake doc:rails generates the API under doc/api.
|
25
|
+
gem 'sdoc', '~> 0.4.0', group: :doc
|
26
|
+
|
27
|
+
# Use ActiveModel has_secure_password
|
28
|
+
# gem 'bcrypt', '~> 3.1.7'
|
29
|
+
|
30
|
+
# Use Unicorn as the app server
|
31
|
+
# gem 'unicorn'
|
32
|
+
|
33
|
+
# Use Capistrano for deployment
|
34
|
+
# gem 'capistrano-rails', group: :development
|
35
|
+
|
36
|
+
group :development, :test do
|
37
|
+
# Call 'byebug' anywhere in the code to stop execution and get a debugger console
|
38
|
+
gem 'byebug'
|
39
|
+
|
40
|
+
# Access an IRB console on exception pages or by using <%= console %> in views
|
41
|
+
gem 'web-console', '~> 2.0'
|
42
|
+
|
43
|
+
# Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring
|
44
|
+
gem 'spring'
|
45
|
+
end
|
46
|
+
|
@@ -0,0 +1,171 @@
|
|
1
|
+
PATH
|
2
|
+
remote: ../../../omniauth-aai
|
3
|
+
specs:
|
4
|
+
omniauth-aai (0.6.2)
|
5
|
+
omniauth-shibboleth (~> 1.2)
|
6
|
+
|
7
|
+
GEM
|
8
|
+
remote: https://rubygems.org/
|
9
|
+
specs:
|
10
|
+
actionmailer (4.2.1)
|
11
|
+
actionpack (= 4.2.1)
|
12
|
+
actionview (= 4.2.1)
|
13
|
+
activejob (= 4.2.1)
|
14
|
+
mail (~> 2.5, >= 2.5.4)
|
15
|
+
rails-dom-testing (~> 1.0, >= 1.0.5)
|
16
|
+
actionpack (4.2.1)
|
17
|
+
actionview (= 4.2.1)
|
18
|
+
activesupport (= 4.2.1)
|
19
|
+
rack (~> 1.6)
|
20
|
+
rack-test (~> 0.6.2)
|
21
|
+
rails-dom-testing (~> 1.0, >= 1.0.5)
|
22
|
+
rails-html-sanitizer (~> 1.0, >= 1.0.1)
|
23
|
+
actionview (4.2.1)
|
24
|
+
activesupport (= 4.2.1)
|
25
|
+
builder (~> 3.1)
|
26
|
+
erubis (~> 2.7.0)
|
27
|
+
rails-dom-testing (~> 1.0, >= 1.0.5)
|
28
|
+
rails-html-sanitizer (~> 1.0, >= 1.0.1)
|
29
|
+
activejob (4.2.1)
|
30
|
+
activesupport (= 4.2.1)
|
31
|
+
globalid (>= 0.3.0)
|
32
|
+
activemodel (4.2.1)
|
33
|
+
activesupport (= 4.2.1)
|
34
|
+
builder (~> 3.1)
|
35
|
+
activerecord (4.2.1)
|
36
|
+
activemodel (= 4.2.1)
|
37
|
+
activesupport (= 4.2.1)
|
38
|
+
arel (~> 6.0)
|
39
|
+
activesupport (4.2.1)
|
40
|
+
i18n (~> 0.7)
|
41
|
+
json (~> 1.7, >= 1.7.7)
|
42
|
+
minitest (~> 5.1)
|
43
|
+
thread_safe (~> 0.3, >= 0.3.4)
|
44
|
+
tzinfo (~> 1.1)
|
45
|
+
arel (6.0.0)
|
46
|
+
binding_of_caller (0.7.2)
|
47
|
+
debug_inspector (>= 0.0.1)
|
48
|
+
builder (3.2.2)
|
49
|
+
byebug (5.0.0)
|
50
|
+
columnize (= 0.9.0)
|
51
|
+
coffee-rails (4.1.0)
|
52
|
+
coffee-script (>= 2.2.0)
|
53
|
+
railties (>= 4.0.0, < 5.0)
|
54
|
+
coffee-script (2.4.1)
|
55
|
+
coffee-script-source
|
56
|
+
execjs
|
57
|
+
coffee-script-source (1.9.1.1)
|
58
|
+
columnize (0.9.0)
|
59
|
+
debug_inspector (0.0.2)
|
60
|
+
erubis (2.7.0)
|
61
|
+
execjs (2.5.2)
|
62
|
+
globalid (0.3.5)
|
63
|
+
activesupport (>= 4.1.0)
|
64
|
+
hashie (3.4.2)
|
65
|
+
i18n (0.7.0)
|
66
|
+
jbuilder (2.2.16)
|
67
|
+
activesupport (>= 3.0.0, < 5)
|
68
|
+
multi_json (~> 1.2)
|
69
|
+
jquery-rails (4.0.3)
|
70
|
+
rails-dom-testing (~> 1.0)
|
71
|
+
railties (>= 4.2.0)
|
72
|
+
thor (>= 0.14, < 2.0)
|
73
|
+
json (1.8.2)
|
74
|
+
loofah (2.0.2)
|
75
|
+
nokogiri (>= 1.5.9)
|
76
|
+
mail (2.6.3)
|
77
|
+
mime-types (>= 1.16, < 3)
|
78
|
+
mime-types (2.6.1)
|
79
|
+
mini_portile (0.6.2)
|
80
|
+
minitest (5.7.0)
|
81
|
+
multi_json (1.11.0)
|
82
|
+
nokogiri (1.6.6.2)
|
83
|
+
mini_portile (~> 0.6.0)
|
84
|
+
omniauth (1.2.2)
|
85
|
+
hashie (>= 1.2, < 4)
|
86
|
+
rack (~> 1.0)
|
87
|
+
omniauth-shibboleth (1.2.0)
|
88
|
+
omniauth (>= 1.0.0)
|
89
|
+
rack (1.6.1)
|
90
|
+
rack-test (0.6.3)
|
91
|
+
rack (>= 1.0)
|
92
|
+
rails (4.2.1)
|
93
|
+
actionmailer (= 4.2.1)
|
94
|
+
actionpack (= 4.2.1)
|
95
|
+
actionview (= 4.2.1)
|
96
|
+
activejob (= 4.2.1)
|
97
|
+
activemodel (= 4.2.1)
|
98
|
+
activerecord (= 4.2.1)
|
99
|
+
activesupport (= 4.2.1)
|
100
|
+
bundler (>= 1.3.0, < 2.0)
|
101
|
+
railties (= 4.2.1)
|
102
|
+
sprockets-rails
|
103
|
+
rails-deprecated_sanitizer (1.0.3)
|
104
|
+
activesupport (>= 4.2.0.alpha)
|
105
|
+
rails-dom-testing (1.0.6)
|
106
|
+
activesupport (>= 4.2.0.beta, < 5.0)
|
107
|
+
nokogiri (~> 1.6.0)
|
108
|
+
rails-deprecated_sanitizer (>= 1.0.1)
|
109
|
+
rails-html-sanitizer (1.0.2)
|
110
|
+
loofah (~> 2.0)
|
111
|
+
railties (4.2.1)
|
112
|
+
actionpack (= 4.2.1)
|
113
|
+
activesupport (= 4.2.1)
|
114
|
+
rake (>= 0.8.7)
|
115
|
+
thor (>= 0.18.1, < 2.0)
|
116
|
+
rake (10.4.2)
|
117
|
+
rdoc (4.2.0)
|
118
|
+
sass (3.4.14)
|
119
|
+
sass-rails (5.0.3)
|
120
|
+
railties (>= 4.0.0, < 5.0)
|
121
|
+
sass (~> 3.1)
|
122
|
+
sprockets (>= 2.8, < 4.0)
|
123
|
+
sprockets-rails (>= 2.0, < 4.0)
|
124
|
+
tilt (~> 1.1)
|
125
|
+
sdoc (0.4.1)
|
126
|
+
json (~> 1.7, >= 1.7.7)
|
127
|
+
rdoc (~> 4.0)
|
128
|
+
spring (1.3.6)
|
129
|
+
sprockets (3.1.0)
|
130
|
+
rack (~> 1.0)
|
131
|
+
sprockets-rails (2.3.1)
|
132
|
+
actionpack (>= 3.0)
|
133
|
+
activesupport (>= 3.0)
|
134
|
+
sprockets (>= 2.8, < 4.0)
|
135
|
+
sqlite3 (1.3.10)
|
136
|
+
thor (0.19.1)
|
137
|
+
thread_safe (0.3.5)
|
138
|
+
tilt (1.4.1)
|
139
|
+
turbolinks (2.5.3)
|
140
|
+
coffee-rails
|
141
|
+
tzinfo (1.2.2)
|
142
|
+
thread_safe (~> 0.1)
|
143
|
+
uglifier (2.7.1)
|
144
|
+
execjs (>= 0.3.0)
|
145
|
+
json (>= 1.8.0)
|
146
|
+
web-console (2.1.2)
|
147
|
+
activemodel (>= 4.0)
|
148
|
+
binding_of_caller (>= 0.7.2)
|
149
|
+
railties (>= 4.0)
|
150
|
+
sprockets-rails (>= 2.0, < 4.0)
|
151
|
+
|
152
|
+
PLATFORMS
|
153
|
+
ruby
|
154
|
+
|
155
|
+
DEPENDENCIES
|
156
|
+
byebug
|
157
|
+
coffee-rails (~> 4.1.0)
|
158
|
+
jbuilder (~> 2.0)
|
159
|
+
jquery-rails
|
160
|
+
omniauth-aai!
|
161
|
+
rails (= 4.2.1)
|
162
|
+
sass-rails (~> 5.0)
|
163
|
+
sdoc (~> 0.4.0)
|
164
|
+
spring
|
165
|
+
sqlite3
|
166
|
+
turbolinks
|
167
|
+
uglifier (>= 1.3.0)
|
168
|
+
web-console (~> 2.0)
|
169
|
+
|
170
|
+
BUNDLED WITH
|
171
|
+
1.10.3
|
@@ -0,0 +1,28 @@
|
|
1
|
+
== README
|
2
|
+
|
3
|
+
This README would normally document whatever steps are necessary to get the
|
4
|
+
application up and running.
|
5
|
+
|
6
|
+
Things you may want to cover:
|
7
|
+
|
8
|
+
* Ruby version
|
9
|
+
|
10
|
+
* System dependencies
|
11
|
+
|
12
|
+
* Configuration
|
13
|
+
|
14
|
+
* Database creation
|
15
|
+
|
16
|
+
* Database initialization
|
17
|
+
|
18
|
+
* How to run the test suite
|
19
|
+
|
20
|
+
* Services (job queues, cache servers, search engines, etc.)
|
21
|
+
|
22
|
+
* Deployment instructions
|
23
|
+
|
24
|
+
* ...
|
25
|
+
|
26
|
+
|
27
|
+
Please feel free to use a different markup language if you do not plan to run
|
28
|
+
<tt>rake doc:app</tt>.
|
File without changes
|
@@ -0,0 +1,16 @@
|
|
1
|
+
// This is a manifest file that'll be compiled into application.js, which will include all the files
|
2
|
+
// listed below.
|
3
|
+
//
|
4
|
+
// Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,
|
5
|
+
// or any plugin's vendor/assets/javascripts directory can be referenced here using a relative path.
|
6
|
+
//
|
7
|
+
// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
|
8
|
+
// compiled file.
|
9
|
+
//
|
10
|
+
// Read Sprockets README (https://github.com/rails/sprockets#sprockets-directives) for details
|
11
|
+
// about supported directives.
|
12
|
+
//
|
13
|
+
//= require jquery
|
14
|
+
//= require jquery_ujs
|
15
|
+
//= require turbolinks
|
16
|
+
//= require_tree .
|
@@ -0,0 +1,15 @@
|
|
1
|
+
/*
|
2
|
+
* This is a manifest file that'll be compiled into application.css, which will include all the files
|
3
|
+
* listed below.
|
4
|
+
*
|
5
|
+
* Any CSS and SCSS file within this directory, lib/assets/stylesheets, vendor/assets/stylesheets,
|
6
|
+
* or any plugin's vendor/assets/stylesheets directory can be referenced here using a relative path.
|
7
|
+
*
|
8
|
+
* You're free to add application-wide styles to this file and they'll appear at the bottom of the
|
9
|
+
* compiled file so the styles you add here take precedence over styles defined in any styles
|
10
|
+
* defined in the other CSS/SCSS files in this directory. It is generally better to create a new
|
11
|
+
* file per style scope.
|
12
|
+
*
|
13
|
+
*= require_tree .
|
14
|
+
*= require_self
|
15
|
+
*/
|
File without changes
|
@@ -0,0 +1,38 @@
|
|
1
|
+
class SessionController < ApplicationController
|
2
|
+
|
3
|
+
skip_before_filter :verify_authenticity_token, only: :create, if: Rails.env.development?
|
4
|
+
|
5
|
+
def create
|
6
|
+
|
7
|
+
<% if options[:persist] %>
|
8
|
+
self.current_user = User.update_or_create_with_omniauth_aai(auth_hash)
|
9
|
+
<% else %>
|
10
|
+
user = User.new
|
11
|
+
user.uid = auth_hash[:uid]
|
12
|
+
user.aai = auth_hash
|
13
|
+
self.current_user = user
|
14
|
+
<% end %>
|
15
|
+
|
16
|
+
flash[:notice] = "Login successful"
|
17
|
+
|
18
|
+
redirect_to(session.delete( :return_to ) || root_path)
|
19
|
+
end
|
20
|
+
|
21
|
+
def failure
|
22
|
+
flash[:error] = "Login failed"
|
23
|
+
redirect_to(root_path)
|
24
|
+
end
|
25
|
+
|
26
|
+
def destroy
|
27
|
+
self.current_user = nil
|
28
|
+
flash[:notice] = "Logout successful"
|
29
|
+
redirect_to(root_path)
|
30
|
+
end
|
31
|
+
|
32
|
+
private
|
33
|
+
|
34
|
+
def auth_hash
|
35
|
+
request.env['omniauth.auth']
|
36
|
+
end
|
37
|
+
|
38
|
+
end
|