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
CAPI shouldn't allow users to create apps with routes matching CF service subdomains #568
Comments
|
We have created an issue in Pivotal Tracker to manage this. You can view the current status of your issue at: https://www.pivotaltracker.com/story/show/116208645. |
|
@djvdorp thank you for the report. we strongly advise separating the app serving domain from the system domain so that creating routes on the system domain is not enabled for non-admin users. i will talk with @nebhale @dieucao @SocalNick about this. |
|
CAPI just added support to allow an administrator to blacklist/whitelist the private domains via the rules defined by PublicSuffix.org |
|
@fraenkel I think we want to keep these concerns separate, the reserved private domains feature aims to block a user from creating private domains like |
|
The ideal solution would be to require the This change would likely affect a large number of existing Cloud Foundry deployments so I will be seeking feedback on the cf-dev@cloudfoundry.org mailing list. |
|
We will address with this story: https://www.pivotaltracker.com/story/show/117250971 Re-open if you have any other questions or concerns. |
Today we stumbled upon a very interesting bug within CAPI, which I spoke about with @nebhale on the CloudFoundry (Open Source) Slack.
We were experiencing HTTP 404 errors approximately ~50% of the time when connecting to the UAA via the CF CLI. We also had similar errors with one of our internal services using the cf-java-client, which gave us errors such as
Error requesting access token.Turns out that one of our users has created an app with route
login.ourdomain.ext, and that caused this behaviour. Since you can have multiple apps with the same domain bound on it, CF is nicely load-balancing traffic to the 'real'login.ourdomain.ext(the UAA) and the user's app, which makes this fail the ~50% of the time my CF CLI orcf-java-clienthits the user's app instead of the actual UAA.In our case, the user was not a malicious user, but it would be pretty straight forward to inject a “Yes Always” application that listens on the same route as the UAA, which would then catch/receive UAA (OAuth) tokens.
In the case of the
cf-java-client(and also the CF CLI) I think it makes sense they don't block this kind of behaviour, as they will just act as a pure passthrough for anything you request. However, I believe that CF should block the ability to use the same route as the UAA though for security reasons.In a default (stock) CF-release installation, we believe this should (probably) at least be blocked for these CF service subdomains, if this has not already been done:
We think that this might be a CAPI (security) issue. @nebhale will also ask @jbayer about this in person.
The text was updated successfully, but these errors were encountered: