debian-mirror-gitlab/vendor/gems/omniauth-salesforce
2023-05-27 22:25:52 +05:30
..
lib New upstream version 15.4.2+ds1 2022-10-11 01:57:18 +05:30
spec New upstream version 15.4.2+ds1 2022-10-11 01:57:18 +05:30
.gitlab-ci.yml New upstream version 15.4.2+ds1 2022-10-11 01:57:18 +05:30
Gemfile New upstream version 15.4.2+ds1 2022-10-11 01:57:18 +05:30
Gemfile.lock New upstream version 15.4.2+ds1 2022-10-11 01:57:18 +05:30
Guardfile New upstream version 15.4.2+ds1 2022-10-11 01:57:18 +05:30
LICENSE.md New upstream version 15.4.2+ds1 2022-10-11 01:57:18 +05:30
omniauth-salesforce.gemspec New upstream version 15.4.2+ds1 2022-10-11 01:57:18 +05:30
Rakefile New upstream version 15.4.2+ds1 2022-10-11 01:57:18 +05:30
README.md New upstream version 15.10.7+ds1 2023-05-27 22:25:52 +05:30

omniauth-salesforce

This is fork of omniauth-salesforce to support:

  1. OmniAuth v1 and v2. OmniAuth v2 disables GET requests by default and defaults to POST. GitLab already has patched v1 to use POST, but other dependencies need to be updated: https://gitlab.com/gitlab-org/gitlab/-/issues/30073.

There is active discussion with the gem owner (via email) about adding some GitLab employees as gem authors so tha they can push changes. If that happens, the updated/canonical gem should be used in favor of this vendored fork.

OmniAuth Strategy for salesforce.com.

Note: This is a fork of the original project and is now the main repository for the omniauth-salesforce gem for consumption within GitLab.

Basic Usage

require "sinatra"
require "omniauth"
require "omniauth-salesforce"

class MyApplication < Sinatra::Base
  use Rack::Session
  use OmniAuth::Builder do
    provider :salesforce, ENV['SALESFORCE_KEY'], ENV['SALESFORCE_SECRET']
  end
end

Including other sites

use OmniAuth::Builder do
    provider :salesforce, 
             ENV['SALESFORCE_KEY'], 
             ENV['SALESFORCE_SECRET']
    provider OmniAuth::Strategies::SalesforceSandbox, 
             ENV['SALESFORCE_SANDBOX_KEY'], 
             ENV['SALESFORCE_SANDBOX_SECRET']
    provider OmniAuth::Strategies::SalesforcePreRelease, 
             ENV['SALESFORCE_PRERELEASE_KEY'], 
             ENV['SALESFORCE_PRERELEASE_SECRET']
    provider OmniAuth::Strategies::DatabaseDotCom, 
             ENV['DATABASE_DOT_COM_KEY'], 
             ENV['DATABASE_DOT_COM_SECRET']
end

Resources