[
https://issues.apache.org/jira/browse/JCLOUDS-289?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
David Skinner updated JCLOUDS-289:
----------------------------------
Summary: GCE - Credentials Identifier (registered apps) (was: GCE - )
> GCE - Credentials Identifier (registered apps)
> ----------------------------------------------
>
> Key: JCLOUDS-289
> URL: https://issues.apache.org/jira/browse/JCLOUDS-289
> Project: jclouds
> Issue Type: New Feature
> Components: jclouds-labs-google
> Affects Versions: 1.7.0
> Reporter: David Skinner
> Labels: patch
> Fix For: 1.7.0
>
> Original Estimate: 24h
> Remaining Estimate: 24h
>
> Identifier format is incorrectly parsed from context credentials.
> When creating a registered app user the identifier is given in the form of:
> <projectid>-<registered-app-id>@developer.gserviceaccount.com
> GCE provider expects format
> <projectid>@developer.gserviceaccount.com
> OAuth correctly authenticates with the registered app identifier, but
> requests must be made using only the project id. The projectid is currently
> parsed with a split on '@'
> This should be modified to correctly parse the projectid from registered app
> identifiers.
> A quick hack to get past this issue. This should be made to support both
> forms of identifier.
> @@ -104,7 +104,7 @@ public class GoogleComputeEngineHttpApiModule extends
> HttpApiModule<GoogleComput
> checkState(in.identity.indexOf("@") != 1,
> "identity should be in
> [email protected] format");
>
> - Project project =
> api.getProjectApi().get(Iterables.get(Splitter.on("@").split(in.identity),
> 0));
> + Project project =
> api.getProjectApi().get(Iterables.get(Splitter.on("-").split(in.identity),
> 0));
> return project.getName();
> }
> }, creds), seconds, TimeUnit.SECONDS);
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira