stable

Clone or download

Read-only

Access keys can be created with a scope 'write:git_repository'

For now, this scope does nothing but ultimately with it users will be able to do Git operations. However, with an access key having only a scope allowing to do Git operations it is not possible to use the REST APIs. To test, you can use the REST endpoint POST /access_keys Part of story #14023: access Git repositories with a personal access key Change-Id: Id8ed873f30fc828f7230d92b7723614bd09638a5

Modified Files

Name
M plugins/git/db/uninstall.sql +1 −0 Go to diff View file
A plugins/git/include/User/AccessKey/Scope/GitRepositoryAccessKeyScope.php +98 −0 Go to diff View file
M plugins/git/include/gitPlugin.php +13 −0 Go to diff View file
A plugins/git/phpunit/User/AccessKey/Scope/GitRepositoryAccessKeyScopeTest.php +49 −0 Go to diff View file
M plugins/git/site-content/fr_FR/LC_MESSAGES/tuleap-git.po +6 −0 Go to diff View file
M src/common/REST/UserManager.class.php +15 −3 Go to diff View file
M src/common/User/AccessKey/AccessKeyCreationController.php +1 −4 Go to diff View file
A src/common/User/AccessKey/AccessKeyDoesNotHaveRequiredScopeException.php +39 −0 Go to diff View file
M src/common/User/AccessKey/AccessKeyVerifier.php +32 −6 Go to diff View file
M src/common/User/AccessKey/REST/AccessKeyResource.php +6 −2 Go to diff View file
M src/common/User/AccessKey/Scope/AccessKeyScope.php +8 −1 Go to diff View file
A src/common/User/AccessKey/Scope/AccessKeyScopeBuilderCollector.php +48 −0 Go to diff View file
A src/common/User/AccessKey/Scope/AccessKeyScopeBuilderFromClassNames.php +59 −0 Go to diff View file
A src/common/User/AccessKey/Scope/AggregateAccessKeyScopeBuilder.php +69 −0 Go to diff View file
R src/common/User/AccessKey/Scope/CoreAccessKeyScopeBuilder.php Go to diff View file
M src/common/User/AccessKey/Scope/RESTAccessKeyScope.php +17 −3 Go to diff View file
M src/common/User/REST/v1/UserResource.php +9 −2 Go to diff View file
M src/composer.json +2 −1 Go to diff View file
M src/www/account/index.php +9 −2 Go to diff View file
M tests/phpunit/common/User/AccessKey/AccessKeyVerifierTest.php +82 −21 Go to diff View file
A tests/phpunit/common/User/AccessKey/Scope/AccessKeyScopeBuilderCollectorTest.php +60 −0 Go to diff View file
A tests/phpunit/common/User/AccessKey/Scope/AccessKeyScopeBuilderFromClassNamesTest.php +114 −0 Go to diff View file
A tests/phpunit/common/User/AccessKey/Scope/AccessKeyScopeTestCase.php +59 −0 Go to diff View file
A tests/phpunit/common/User/AccessKey/Scope/AccessKeyScopeThrowOnActualMethodCall.php +51 −0 Go to diff View file
A tests/phpunit/common/User/AccessKey/Scope/AggregateAccessKeyScopeBuilderTest.php +91 −0 Go to diff View file
A tests/phpunit/common/User/AccessKey/Scope/CoreAccessKeyScopeBuilderFactoryTest.php +36 −0 Go to diff View file
D tests/phpunit/common/User/AccessKey/Scope/CoreAccessKeyScopeBuilderTest.php +0 −56 Go to diff View file
M tests/phpunit/common/User/AccessKey/Scope/RESTAccessKeyScopeTest.php +14 −14 Go to diff View file