Skip to content
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

Use default phabricator api key to query public revisions #6

Merged
merged 1 commit into from
Jun 7, 2017

Conversation

purelogiq
Copy link
Contributor

After a long talk with our security folks, we came to a conclusion that having every user of Lando (1000+) enter their Phabricator API keys would be a possible security risk, even if stored in a secure cookie.

This patch allows Lando to use 1 key that it owns itself to query for public revisions on behalf of users. If the user does provide an api key, that key will be used instead, which allows users who have access to secure revisions to only input their API key when needed.

@purelogiq purelogiq requested a review from mars-f June 7, 2017 16:25
@@ -34,7 +34,7 @@ paths:
type: string
description: |
A Phabricator Conduit API key to use to get the revision.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you add a sentence here to say that, if this value is left out, a key only capable of working with public revisions will be used instead?

@@ -5,11 +5,13 @@
Revision API
See the OpenAPI Specification for this API in the spec/swagger.yml file.
"""
import os
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The os module isn't used in the rest of the patch - an unused import?

@purelogiq purelogiq force-pushed the plq/optional-api-key branch 2 times, most recently from 476abc2 to b1fe868 Compare June 7, 2017 17:30
After a long talk with our security folks, we came to a conclusion that
having every user of Lando (1000+) enter their Phabricator API keys would
be a possible security risk, even if stored in a secure cookie.

This patch allows Lando to use 1 key that it owns itself to query for
public revisions on behalf of users. If the user does provide an api key,
that key will be used instead, which allows users who have access to secure
revisions to only input their API key when needed.
@purelogiq purelogiq force-pushed the plq/optional-api-key branch from b1fe868 to f795b4a Compare June 7, 2017 17:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants