This commit is contained in:
Lucio Lelii 2016-09-30 09:20:29 +00:00
parent 44968e867a
commit 0d7dbe67a5
8 changed files with 66 additions and 57 deletions

View File

@ -1 +0,0 @@

View File

@ -1,6 +1 @@
gCube System - License
------------------------------------------------------------
The gCube/gCore software is licensed as Free Open Source software conveying to the EUPL (http://ec.europa.eu/idabc/eupl).
The software and documentation is provided by its authors/distributors "as is" and no expressed or
implied warranty is given for its use, quality or fitness for a particular case.
${gcube.license}

View File

@ -1 +0,0 @@
* Lucio Lelii (lucio.lelii@isti.cnr.it), CNR, Italy

View File

@ -1,38 +1,59 @@
The gCube System - ${name}
----------------------
--------------------------------------------------
This work has been partially supported by the following European projects: DILIGENT (FP6-2003-IST-2), D4Science (FP7-INFRA-2007-1.2.2),
D4Science-II (FP7-INFRA-2008-1.2.2), iMarine (FP7-INFRASTRUCTURES-2011-2), and EUBrazilOpenBio (FP7-ICT-2011-EU-Brazil).
Authors
-------
* Lucio Lelii (lucio.lelii@isti.cnr.it), CNR, Italy
Version and Release Date
------------------------
${version}
Description
-----------
${description}
${gcube.description}
${gcube.funding}
Version
--------------------------------------------------
${version} (${buildDate})
Please see the file named "changelog.xml" in this directory for the release notes.
Authors
--------------------------------------------------
* Lucio Lelii (lucio.lelii-AT-isti.cnr.it), CNR, Italy
Maintainers
--------------------------------------------------
* Lucio Lelii (lucio.lelii-AT-isti.cnr.it), CNR, Italy
Download information
--------------------
--------------------------------------------------
Source code is available from SVN:
${scm.url}
Binaries can be downloaded from:
Binaries can be downloaded from the gCube website:
${gcube.website}
Installation
--------------------------------------------------
Installation documentation is available on-line in the gCube Wiki:
${gcube.wikiRoot}
Documentation
-------------
Documentation is available on-line from the Projects Documentation Wiki:
https://gcube.wiki.gcube-system.org/gcube/index.php/....
--------------------------------------------------
Documentation is available on-line in the gCube Wiki:
${gcube.wikiRoot}
Support
--------------------------------------------------
Bugs and support requests can be reported in the gCube issue tracking tool:
${gcube.issueTracking}
Licensing
---------
--------------------------------------------------
This software is licensed under the terms you may find in the file named "LICENSE" in this directory.

View File

@ -2,4 +2,7 @@
<Changeset component="authorization-client-1.0.0" date="2015-05-18">
<Change>First Release</Change>
</Changeset>
<Changeset component="authorization-client-2.0.0" date="2016-09-30">
<Change>moving to auth2</Change>
</Changeset>
</ReleaseNotes>

View File

@ -15,8 +15,6 @@
<includes>
<include>README</include>
<include>LICENSE</include>
<include>INSTALL</include>
<include>MAINTAINERS</include>
<include>changelog.xml</include>
</includes>
<fileMode>755</fileMode>
@ -33,10 +31,5 @@
<source>target/${build.finalName}.jar</source>
<outputDirectory>/${artifactId}</outputDirectory>
</file>
<file>
<source>${distroDirectory}/svnpath.txt</source>
<outputDirectory>/${artifactId}</outputDirectory>
<filtered>true</filtered>
</file>
</files>
</assembly>

View File

@ -1 +0,0 @@
${scm.url}

View File

@ -20,28 +20,28 @@ public class CallTest {
@Test
public void resolveNodeToken() throws Exception{
System.out.println(resolveToken("46311827-6000-480a-8f75-01b7943d490b")); //81caac0f-8a0d-4923-9312-7ff0eb3f2d5e|98187548"));
System.out.println(resolveToken("36501a0d-a205-4bf1-87ad-4c7185faa0d6")); //81caac0f-8a0d-4923-9312-7ff0eb3f2d5e|98187548"));
}
@Test
public void requestNodeToken() throws Exception {
String token = authorizationService().requestActivation(new ContainerInfo("ckan-d-d4s.d4science.org",80), "/gcube/devNext/NextNext");
String token = authorizationService().requestActivation(new ContainerInfo("node11.d.d4science.research-infrastructures.eu",8080), "/gcube/devNext/NextNext");
System.out.println(token);
}
@Test
public void addPolicy() throws Exception {
SecurityTokenProvider.instance.set(requestTestToken("/gcube/devsec/devVRE"));
SecurityTokenProvider.instance.set(requestTestToken("/gcube/devNext/NextNext"));
List<Policy> policies = new ArrayList<Policy>();
policies.add(new User2ServicePolicy("/gcube/devsec/devVRE", new ServiceAccess(), Users.one("lucio.lelii"), Action.ACCESS ));
policies.add(new User2ServicePolicy("/gcube/devNext/NextNext", new ServiceAccess(), Users.one("lucio.lelii"), Action.ACCESS ));
authorizationService().addPolicies(policies);
}
@Test
public void getPolicies() throws Exception{
SecurityTokenProvider.instance.set(requestTestToken("/gcube/devNext"));
List<Policy> policies = authorizationService().getPolicies("/gcube/devNext");
SecurityTokenProvider.instance.set(requestTestToken("/gcube/devNext/NextNext"));
List<Policy> policies = authorizationService().getPolicies("/gcube/devsec/devVRE");
System.out.println(policies);
}
@ -57,7 +57,7 @@ public class CallTest {
@Test
public void createKey() throws Exception {
String token = requestTestToken("/gcube/devNext");
String token = requestTestToken("/gcube/devNext/NextNext");
SecurityTokenProvider.instance.set(token);
String key = authorizationService().generateApiKey("TEST");
System.out.println("key : "+key);
@ -75,7 +75,7 @@ public class CallTest {
@Test
public void createTestToken() throws Exception {
System.out.println(requestTestToken("/gcube/devNext"));
System.out.println(requestTestToken("/gcube/devNext/NextNext"));
}
private String requestTestToken(String context) throws Exception{