airavata-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From scnakand...@apache.org
Subject [36/50] [abbrv] airavata git commit: Add security-check to profile-service apis - user, tenant
Date Wed, 05 Apr 2017 19:11:00 GMT
http://git-wip-us.apache.org/repos/asf/airavata/blob/aa0358c1/thrift-interface-descriptions/service-cpis/profile-service/profile-tenant/profile-tenant-cpi.thrift
----------------------------------------------------------------------
diff --git a/thrift-interface-descriptions/service-cpis/profile-service/profile-tenant/profile-tenant-cpi.thrift
b/thrift-interface-descriptions/service-cpis/profile-service/profile-tenant/profile-tenant-cpi.thrift
index 7b90f4a..c0bc371 100644
--- a/thrift-interface-descriptions/service-cpis/profile-service/profile-tenant/profile-tenant-cpi.thrift
+++ b/thrift-interface-descriptions/service-cpis/profile-service/profile-tenant/profile-tenant-cpi.thrift
@@ -23,6 +23,8 @@
  *
 */
 
+include "../../../airavata-apis/airavata_errors.thrift"
+include "../../../airavata-apis/security_model.thrift"
 include "../../../data-models/experiment-catalog-models/workspace_model.thrift"
 include "profile_tenant_cpi_errors.thrift"
 
@@ -33,24 +35,36 @@ const string TENANT_PROFILE_CPI_NAME = "TenantProfileService"
 
 service TenantProfileService {
 
-    string getAPIVersion()
-                        throws (1: profile_tenant_cpi_errors.TenantProfileServiceException
tenantProfileException)
+    string getAPIVersion (1: required security_model.AuthzToken authzToken)
+                       throws (1: profile_tenant_cpi_errors.TenantProfileServiceException
tpe,
+                               2: airavata_errors.AuthorizationException ae)
 
-    string addGateway (1: required workspace_model.Gateway gateway)
-                        throws (1: profile_tenant_cpi_errors.TenantProfileServiceException
tenantProfileException)
+    string addGateway (1: required security_model.AuthzToken authzToken,
+                       2: required workspace_model.Gateway gateway)
+                    throws (1: profile_tenant_cpi_errors.TenantProfileServiceException tpe,
+                            2: airavata_errors.AuthorizationException ae)
 
-    bool updateGateway(1: required workspace_model.Gateway updatedGateway)
-                        throws (1: profile_tenant_cpi_errors.TenantProfileServiceException
tenantProfileException)
+    bool updateGateway (1: required security_model.AuthzToken authzToken,
+                        2: required workspace_model.Gateway updatedGateway)
+                     throws (1: profile_tenant_cpi_errors.TenantProfileServiceException tpe,
+                             2: airavata_errors.AuthorizationException ae)
 
-    workspace_model.Gateway getGateway (1: required string gatewayId)
-                        throws (1: profile_tenant_cpi_errors.TenantProfileServiceException
tenantProfileException)
+    workspace_model.Gateway getGateway (1: required security_model.AuthzToken authzToken,
+                                        2: required string gatewayId)
+                                     throws (1: profile_tenant_cpi_errors.TenantProfileServiceException
tpe,
+                                             2: airavata_errors.AuthorizationException ae)
 
-    bool deleteGateway(1: required string gatewayId)
-                        throws (1: profile_tenant_cpi_errors.TenantProfileServiceException
tenantProfileException)
+    bool deleteGateway (1: required security_model.AuthzToken authzToken,
+                        2: required string gatewayId)
+                     throws (1: profile_tenant_cpi_errors.TenantProfileServiceException tpe,
+                             2: airavata_errors.AuthorizationException ae)
 
-    list<workspace_model.Gateway> getAllGateways()
-                        throws (1: profile_tenant_cpi_errors.TenantProfileServiceException
tenantProfileException)
+    list<workspace_model.Gateway> getAllGateways (1: required security_model.AuthzToken
authzToken)
+                                               throws (1: profile_tenant_cpi_errors.TenantProfileServiceException
tpe,
+                                                       2: airavata_errors.AuthorizationException
ae)
 
-    bool isGatewayExist(1: required string gatewayId)
-                        throws (1: profile_tenant_cpi_errors.TenantProfileServiceException
tenantProfileException)
+    bool isGatewayExist (1: required security_model.AuthzToken authzToken,
+                         2: required string gatewayId)
+                      throws (1: profile_tenant_cpi_errors.TenantProfileServiceException
tpe,
+                              2: airavata_errors.AuthorizationException ae)
 }
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/airavata/blob/aa0358c1/thrift-interface-descriptions/service-cpis/profile-service/profile-user/profile-user-cpi.thrift
----------------------------------------------------------------------
diff --git a/thrift-interface-descriptions/service-cpis/profile-service/profile-user/profile-user-cpi.thrift
b/thrift-interface-descriptions/service-cpis/profile-service/profile-user/profile-user-cpi.thrift
index a5e1571..f4f5de3 100644
--- a/thrift-interface-descriptions/service-cpis/profile-service/profile-user/profile-user-cpi.thrift
+++ b/thrift-interface-descriptions/service-cpis/profile-service/profile-user/profile-user-cpi.thrift
@@ -23,6 +23,8 @@
  *
 */
 
+include "../../../airavata-apis/airavata_errors.thrift"
+include "../../../airavata-apis/security_model.thrift"
 include "../../../data-models/user-group-models/user_profile_model.thrift"
 include "profile_user_cpi_errors.thrift"
 
@@ -34,25 +36,45 @@ const string USER_PROFILE_CPI_NAME = "UserProfileService"
 
 service UserProfileService {
 
-  string addUserProfile (1: required user_profile_model.UserProfile userProfile)
-                        throws (1:profile_user_cpi_errors.UserProfileServiceException userProfileException);
+  string addUserProfile (1: required security_model.AuthzToken authzToken,
+                         2: required user_profile_model.UserProfile userProfile)
+                      throws (1: profile_user_cpi_errors.UserProfileServiceException upe,
+                              2: airavata_errors.AuthorizationException ae);
 
-  bool updateUserProfile (1: required user_profile_model.UserProfile userProfile)
-                          throws (1:profile_user_cpi_errors.UserProfileServiceException userProfileException);
+  bool updateUserProfile (1: required security_model.AuthzToken authzToken,
+                          2: required user_profile_model.UserProfile userProfile)
+                       throws (1: profile_user_cpi_errors.UserProfileServiceException upe,
+                               2: airavata_errors.AuthorizationException ae);
 
-  user_profile_model.UserProfile getUserProfileById(1: required string userId, 2: required
string gatewayId)
-                                                throws (1:profile_user_cpi_errors.UserProfileServiceException
userProfileException);
+  user_profile_model.UserProfile getUserProfileById (1: required security_model.AuthzToken
authzToken,
+                                                     2: required string userId,
+                                                     3: required string gatewayId)
+                                                  throws (1: profile_user_cpi_errors.UserProfileServiceException
upe,
+                                                          2: airavata_errors.AuthorizationException
ae);
 
-  bool deleteUserProfile(1: required string userId, 2: required string gatewayId)
-                                                  throws (1:profile_user_cpi_errors.UserProfileServiceException
userProfileException);
+  bool deleteUserProfile (1: required security_model.AuthzToken authzToken,
+                          2: required string userId,
+                          3: required string gatewayId)
+                       throws (1: profile_user_cpi_errors.UserProfileServiceException upe,
+                               2: airavata_errors.AuthorizationException ae);
 
-  list<user_profile_model.UserProfile> getAllUserProfilesInGateway (1: required string
gatewayId, 2: required i32 offset, 3: required i32 limit)
-                          throws (1:profile_user_cpi_errors.UserProfileServiceException userProfileException);
+  list<user_profile_model.UserProfile> getAllUserProfilesInGateway (1: required security_model.AuthzToken
authzToken,
+                                                                    2: required string gatewayId,
+                                                                    3: required i32 offset,
+                                                                    4: required i32 limit)
+                                                                 throws (1: profile_user_cpi_errors.UserProfileServiceException
upe,
+                                                                         2: airavata_errors.AuthorizationException
ae);
 
- user_profile_model.UserProfile getUserProfileByName(1: required string userName, 2: required
string gatewayId)
-                                                throws (1:profile_user_cpi_errors.UserProfileServiceException
userProfileException);
+ user_profile_model.UserProfile getUserProfileByName (1: required security_model.AuthzToken
authzToken,
+                                                      2: required string userName,
+                                                      3: required string gatewayId)
+                                                   throws (1: profile_user_cpi_errors.UserProfileServiceException
upe,
+                                                           2: airavata_errors.AuthorizationException
ae);
 
-   bool doesUserExist(1: required string userName, 2: required string gatewayId)
-                                                   throws (1:profile_user_cpi_errors.UserProfileServiceException
userProfileException);
+ bool doesUserExist (1: required security_model.AuthzToken authzToken,
+                     2: required string userName,
+                     3: required string gatewayId)
+                  throws (1: profile_user_cpi_errors.UserProfileServiceException upe,
+                          2: airavata_errors.AuthorizationException ae);
 
 }
\ No newline at end of file


Mime
View raw message