-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Redirection without hitting the "My Applications" landing page? #46
Comments
Agreed, this should be fixable in the flow manager somehow. It will only occur upon first login, if the kombit user isn't already signed in, but It's still undesired behavior. |
Maybe this? https://goauthentik.io/docs/flow/context/#redirect-string (I havent checked with the current flow, what the url is set to) |
That sounds absolutely spot on, good find. Will check to see if can make an easy fix. |
this may have been a bug. I just tested on a newer image with a home brewed RubySAML service provider. After being redirected to AK and signing in, I get send directly back to my simple Ruby app, without seing the my application |
Although, this example uses the SAML Provider, and not the OIDC provider that might have caused the redirect to the My Applications page. I will test with the OIDC provider instead. |
|
Unfortunately not, for that we would need a SAML IdP mock servce. In this case I made a very simple SAML Service provider, which logged in using an Authentik SAML Provider. I'll gladly share though. require 'onelogin/ruby-saml'
require 'sinatra'
enable :sessions
OneLogin::RubySaml::Logging.logger = Logger.new 'ruby-saml.log'
WEBrick::HTTPRequest.const_set("MAX_URI_LENGTH", 10240)
def saml_settings
idp_metadata_parser = OneLogin::RubySaml::IdpMetadataParser.new
validate_cert = true
settings = idp_metadata_parser.parse_remote(
"<saml_idp_metadata_url>",
validate_cert,
)
settings.assertion_consumer_service_url = "<host>/saml/acs"
settings.sp_entity_id = "<host>/saml/metadata"
return settings
end
get '/' do
if session[:nameid]
return '<p>Welcome <b>' + session[:nameid] + '</b>!</p>'
else
redirect '/saml/login'
end
end
get '/saml/metadata' do
meta = OneLogin::RubySaml::Metadata.new
content_type 'text/xml'
meta.generate saml_settings
end
get '/saml/login' do
request = OneLogin::RubySaml::Authrequest.new
redir_url = request.create saml_settings
redirect redir_url
end
get '/test/authnrequest' do
request = OneLogin::RubySaml::Authrequest.new
content_type 'text/xml'
return request.create_authentication_xml_doc(saml_settings).to_s
end
post '/saml/acs' do
response = OneLogin::RubySaml::Response.new(params[:SAMLResponse], :settings => saml_settings)
if response.is_valid?
session[:nameid] = response.nameid
session[:attributes] = response.attributes
puts "\nAttributes in Assertion:"
session[:attributes].each do
|key, value| puts "#{key} => '#{value[0]}'"
end
puts ""
# Login.
redirect '/'
else
authorize_failure
end
end
|
Has this been tested and verified as a misconfiguration in the flow? Does it need more work? |
Need to test again with newest Authentik release build |
When you sign in to e.g. Zulip via the zulip test url, you end up in the "My applications" landing page inside Authentik.
The expected behaviour would be to end up directly in the app you tried to acces via the url. The choice between the different enrolled apps is just confusing to a simple user just wanting SSO to Zulip or Nextcloud.
The text was updated successfully, but these errors were encountered: