Project

General

Profile

Defect #8399 » 8399_redmine_fix_openid.patch

Antoine Beaupré, 2012-01-28 21:59

View differences:

app/controllers/account_controller.rb (copie de travail)
21 21
  
22 22
  # prevents login action to be filtered by check_if_login_required application scope filter
23 23
  skip_before_filter :check_if_login_required
24
  # prevents login action to be checked for tokens, as we don't send it to openid
25
  skip_before_filter :verify_authenticity_token
24 26

  
25 27
  # Login request and validation
26 28
  def login
......
194 196
            account_pending
195 197
          end
196 198
        end
199
      else
200
        logger.warn "OpenID authentication failed for '#{params[:username]}' from #{request.remote_ip} at #{Time.now.utc}"
201
        flash.now[:error] = "OpenID login failed with '#{result.message}' '#{registration}"
197 202
      end
198 203
    end
199 204
  end
vendor/plugins/open_id_authentication/lib/open_id_authentication.rb (copie de travail)
172 172
      when OpenID::Consumer::CANCEL
173 173
        yield Result[:canceled], identity_url, nil
174 174
      when OpenID::Consumer::FAILURE
175
        yield Result[:failed], identity_url, nil
175
        yield Result[:failed], identity_url, open_id_response.message
176 176
      when OpenID::Consumer::SETUP_NEEDED
177 177
        yield Result[:setup_needed], open_id_response.setup_url, nil
178 178
      end
    (1-1/1)