Add User as a manager to SecurityTeam
Parameter name | Data type | Description |
---|---|---|
securityTeam | int | id of SecurityTeam to add manager (member) to |
user | int | id of User to be added as a manager (member) of SecurityTeam |
Thrown exception | Description |
---|---|
InternalErrorException | When unspecified error occur. See exception param message for explanation. |
PrivilegeException | When caller is not allowed to call this method. Result may vary based on caller identity and provided parameter values. |
RpcException | Wrong usage of API (wrong url, missing param etc.). See exception params message and type for explanation. |
Return type | Description |
---|---|
void |
Example URL
https://[hostname]/krb/rpc/json/securityTeamsManager/addAdmin
Example params
{ "securityTeam" : 42 , "user" : 59 }
Example response
null
Add group as a manager to SecurityTeam
Parameter name | Data type | Description |
---|---|---|
securityTeam | int | id of SecurityTeam to add manager (member) to |
group | int | id of Group to be added as a manager (member) of SecurityTeam |
Thrown exception | Description |
---|---|
InternalErrorException | When unspecified error occur. See exception param message for explanation. |
PrivilegeException | When caller is not allowed to call this method. Result may vary based on caller identity and provided parameter values. |
RpcException | Wrong usage of API (wrong url, missing param etc.). See exception params message and type for explanation. |
Return type | Description |
---|---|
void |
Example URL
https://[hostname]/krb/rpc/json/securityTeamsManager/addAdmin
Example params
{ "securityTeam" : 10 , "group" : 88 }
Example response
null
Add user to blacklist of given SecurityTeam
Parameter name | Data type | Description |
---|---|---|
securityTeam | int | id of SecurityTeam to add user to blacklist |
user | int | id of User to be added to blacklist of SecurityTeam |
Thrown exception | Description |
---|---|
InternalErrorException | When unspecified error occur. See exception param message for explanation. |
PrivilegeException | When caller is not allowed to call this method. Result may vary based on caller identity and provided parameter values. |
RpcException | Wrong usage of API (wrong url, missing param etc.). See exception params message and type for explanation. |
Return type | Description |
---|---|
void |
Example URL
https://[hostname]/krb/rpc/json/securityTeamsManager/addUserToBlacklist
Example params
{ "securityTeam" : 36 , "user" : 23 }
Example response
null
Create SecurityTeam. SecurityTeam object must contain name which must match [-_a-zA-z0-9.]+ and not be longer than 128 characters. Parameter description is optional. Other parameters are ignored.
Parameter name | Data type | Description |
---|---|---|
securityTeam | SecurityTeam | Security team to create |
Thrown exception | Description |
---|---|
InternalErrorException | When unspecified error occur. See exception param message for explanation. |
PrivilegeException | When caller is not allowed to call this method. Result may vary based on caller identity and provided parameter values. |
RpcException | Wrong usage of API (wrong url, missing param etc.). See exception params message and type for explanation. |
SecurityTeamExistsException | When name of SecurityTeam is not unique. |
Return type | Description |
---|---|
SecurityTeam | Newly create SecurityTeam with id set. |
Example URL
https://[hostname]/krb/rpc/json/securityTeamsManager/createSecurityTeam
Example params
{ "securityTeam" : { "name" : "My_new_security-team2" } }
Example response
{ "id" : 924 , "name" : "CSIRT" , "description" : "My CSIRT" }
Create SecurityTeam.
Parameter name | Data type | Description |
---|---|---|
name | String | name which must match [-_a-zA-z0-9.]+ and not be longer than 128 characters. |
description | String | description |
Thrown exception | Description |
---|---|
InternalErrorException | When unspecified error occur. See exception param message for explanation. |
PrivilegeException | When caller is not allowed to call this method. Result may vary based on caller identity and provided parameter values. |
RpcException | Wrong usage of API (wrong url, missing param etc.). See exception params message and type for explanation. |
SecurityTeamExistsException | When name of SecurityTeam is not unique. |
Return type | Description |
---|---|
SecurityTeam | Newly create SecurityTeam with id set. |
Example URL
https://[hostname]/krb/rpc/json/securityTeamsManager/createSecurityTeam
Example params
{ "name" : "My_new_security-team2" , "description" : "text" }
Example response
{ "id" : 924 , "name" : "CSIRT" , "description" : "My CSIRT" }
Delete SecurityTeam by its id
. If force is true
team is deleted even if it has some users on blacklist or is assigned to some facility.
Parameter name | Data type | Description |
---|---|---|
securityTeam | int | Security team id |
force | boolean | true if force delete |
Thrown exception | Description |
---|---|
InternalErrorException | When unspecified error occur. See exception param message for explanation. |
PrivilegeException | When caller is not allowed to call this method. Result may vary based on caller identity and provided parameter values. |
RpcException | Wrong usage of API (wrong url, missing param etc.). See exception params message and type for explanation. |
Return type | Description |
---|---|
void |
Example URL
https://[hostname]/krb/rpc/json/securityTeamsManager/deleteSecurityTeam
Example params
{ "securityTeam" : 34 , "force" : true }
Example response
null
Delete SecurityTeam by its id
. If team has any users on blacklist or is assigned some facility, it is not deleted.
Parameter name | Data type | Description |
---|---|---|
securityTeam | int | Security team id |
Thrown exception | Description |
---|---|
InternalErrorException | When unspecified error occur. See exception param message for explanation. |
PrivilegeException | When caller is not allowed to call this method. Result may vary based on caller identity and provided parameter values. |
RpcException | Wrong usage of API (wrong url, missing param etc.). See exception params message and type for explanation. |
Return type | Description |
---|---|
void |
Example URL
https://[hostname]/krb/rpc/json/securityTeamsManager/deleteSecurityTeam
Example params
{ "securityTeam" : 10 }
Example response
null
Get all SecurityTeam groups of admins.
Parameter name | Data type | Description |
---|---|---|
securityTeam | int | SecurityTeam id |
Thrown exception | Description |
---|---|
InternalErrorException | When unspecified error occur. See exception param message for explanation. |
PrivilegeException | When caller is not allowed to call this method. Result may vary based on caller identity and provided parameter values. |
RpcException | Wrong usage of API (wrong url, missing param etc.). See exception params message and type for explanation. |
Return type | Description |
---|---|
List<Group> | admins |
Example URL
https://[hostname]/krb/rpc/json/securityTeamsManager/getAdminGroups
Example params
{ "securityTeam" : 11 }
Example response
[ { "id" : 1061 , "name" : "My group" , "shortName" : "My group" , "description" : "My testing group" , "parentGroupId" : null , "voId" : 201 , "uuid" : "31e1014b-e994-4cb2-b238-e32aeef87670" , "beanName" : "Group" } , {...} , {...} ]
Get all managers (members) of SecurityTeam by its id
.
Parameter name | Data type | Description |
---|---|---|
securityTeam | int | Security team id |
Thrown exception | Description |
---|---|
InternalErrorException | When unspecified error occur. See exception param message for explanation. |
PrivilegeException | When caller is not allowed to call this method. Result may vary based on caller identity and provided parameter values. |
RpcException | Wrong usage of API (wrong url, missing param etc.). See exception params message and type for explanation. |
Return type | Description |
---|---|
List<User> | List of Users who are managers (members) of specified SecurityTeam. |
Example URL
https://[hostname]/krb/rpc/json/securityTeamsManager/getAdmins
Example params
{ "securityTeam" : 75 }
Example response
[ { "firstName" : "Some" , "lastName" : "Body" , "middleName" : null , "titleBefore" : "Mgr." , "titleAfter" : null , "serviceUser" : false , "sponsoredUser" : false , "specificUser" : false , "majorSpecificType" : "NORMAL" , "id" : 34 , "uuid" : "5e5a02dd-f991-4706-a428-69c3ea6c5ce8" , "beanName" : "User" } , {...} , {...} ]
Get managers of SecurityTeam by its id
.
Parameter name | Data type | Description |
---|---|---|
securityTeam | int | Security team id |
onlyDirectAdmins | boolean | if true, get only direct SecurityTeam administrators (if false, get both direct and indirect) |
Thrown exception | Description |
---|---|
InternalErrorException | When unspecified error occur. See exception param message for explanation. |
PrivilegeException | When caller is not allowed to call this method. Result may vary based on caller identity and provided parameter values. |
RpcException | Wrong usage of API (wrong url, missing param etc.). See exception params message and type for explanation. |
Return type | Description |
---|---|
List<User> | List of Users who are managers (members) of specified SecurityTeam. |
Example URL
https://[hostname]/krb/rpc/json/securityTeamsManager/getAdmins
Example params
{ "securityTeam" : 72 , "onlyDirectAdmins" : true }
Example response
[ { "firstName" : "Some" , "lastName" : "Body" , "middleName" : null , "titleBefore" : "Mgr." , "titleAfter" : null , "serviceUser" : false , "sponsoredUser" : false , "specificUser" : false , "majorSpecificType" : "NORMAL" , "id" : 34 , "uuid" : "5e5a02dd-f991-4706-a428-69c3ea6c5ce8" , "beanName" : "User" } , {...} , {...} ]
List all SecurityTeams in Perun.
Thrown exception | Description |
---|---|
InternalErrorException | When unspecified error occur. See exception param message for explanation. |
PrivilegeException | When caller is not allowed to call this method. Result may vary based on caller identity and provided parameter values. |
RpcException | Wrong usage of API (wrong url, missing param etc.). See exception params message and type for explanation. |
Return type | Description |
---|---|
List<SecurityTeam> | List of all security teams. |
Example URL
https://[hostname]/krb/rpc/json/securityTeamsManager/getAllSecurityTeams
Example response
[ { "id" : 924 , "name" : "CSIRT" , "description" : "My CSIRT" } , {...} , {...} ]
Get blacklisted users on selected Facility. List is a union of all blacklists of SecurityTeams assigned to selected Facility.
Parameter name | Data type | Description |
---|---|---|
facility | int | id of Facility to get blacklist for |
Thrown exception | Description |
---|---|
InternalErrorException | When unspecified error occur. See exception param message for explanation. |
PrivilegeException | When caller is not allowed to call this method. Result may vary based on caller identity and provided parameter values. |
RpcException | Wrong usage of API (wrong url, missing param etc.). See exception params message and type for explanation. |
Return type | Description |
---|---|
List<User> | List of users blacklisted on selected facility. |
Example URL
https://[hostname]/krb/rpc/json/securityTeamsManager/getBlacklist
Example params
{ "facility" : 73 }
Example response
[ { "firstName" : "Some" , "lastName" : "Body" , "middleName" : null , "titleBefore" : "Mgr." , "titleAfter" : null , "serviceUser" : false , "sponsoredUser" : false , "specificUser" : false , "majorSpecificType" : "NORMAL" , "id" : 34 , "uuid" : "5e5a02dd-f991-4706-a428-69c3ea6c5ce8" , "beanName" : "User" } , {...} , {...} ]
Get users blacklisted by selected SecurityTeam.
Parameter name | Data type | Description |
---|---|---|
securityTeam | int | id of SecurityTeam to get blacklist for |
Thrown exception | Description |
---|---|
InternalErrorException | When unspecified error occur. See exception param message for explanation. |
PrivilegeException | When caller is not allowed to call this method. Result may vary based on caller identity and provided parameter values. |
RpcException | Wrong usage of API (wrong url, missing param etc.). See exception params message and type for explanation. |
Return type | Description |
---|---|
List<User> | Blacklisted users |
Example URL
https://[hostname]/krb/rpc/json/securityTeamsManager/getBlacklist
Example params
{ "securityTeam" : 17 }
Example response
[ { "firstName" : "Some" , "lastName" : "Body" , "middleName" : null , "titleBefore" : "Mgr." , "titleAfter" : null , "serviceUser" : false , "sponsoredUser" : false , "specificUser" : false , "majorSpecificType" : "NORMAL" , "id" : 34 , "uuid" : "5e5a02dd-f991-4706-a428-69c3ea6c5ce8" , "beanName" : "User" } , {...} , {...} ]
Get blacklisted users on selected Facility. List consists of Pairs. Left is a item from union of all blacklists of SecurityTeams assigned to selected Facility and right item is a description why the user is on the blacklist.
Parameter name | Data type | Description |
---|---|---|
facility | int | id of Facility to get blacklist for |
Thrown exception | Description |
---|---|
InternalErrorException | When unspecified error occur. See exception param message for explanation. |
PrivilegeException | When caller is not allowed to call this method. Result may vary based on caller identity and provided parameter values. |
RpcException | Wrong usage of API (wrong url, missing param etc.). See exception params message and type for explanation. |
Return type | Description |
---|---|
List<Pair<User,String>> | List of users blacklisted on selected facility. |
Example URL
https://[hostname]/krb/rpc/json/securityTeamsManager/getBlacklistWithDescription
Example params
{ "facility" : 70 }
Example response
[ { "left" : { "firstName" : "Some" , "lastName" : "Body" , "middleName" : null , "titleBefore" : "Mgr." , "titleAfter" : null , "serviceUser" : false , "sponsoredUser" : false , "specificUser" : false , "majorSpecificType" : "NORMAL" , "id" : 34 , "uuid" : "5e5a02dd-f991-4706-a428-69c3ea6c5ce8" , "beanName" : "User" } , "right" : "Some reason" } , {...} , {...} ]
Get users blacklisted by selected SecurityTeam with a description why the users are on the blacklist.
Parameter name | Data type | Description |
---|---|---|
securityTeam | int | id of SecurityTeam to get blacklist for |
Thrown exception | Description |
---|---|
InternalErrorException | When unspecified error occur. See exception param message for explanation. |
PrivilegeException | When caller is not allowed to call this method. Result may vary based on caller identity and provided parameter values. |
RpcException | Wrong usage of API (wrong url, missing param etc.). See exception params message and type for explanation. |
Return type | Description |
---|---|
List<Pair<User,String>> | Blacklisted users with description |
Example URL
https://[hostname]/krb/rpc/json/securityTeamsManager/getBlacklistWithDescription
Example params
{ "securityTeam" : 35 }
Example response
[ { "left" : { "firstName" : "Some" , "lastName" : "Body" , "middleName" : null , "titleBefore" : "Mgr." , "titleAfter" : null , "serviceUser" : false , "sponsoredUser" : false , "specificUser" : false , "majorSpecificType" : "NORMAL" , "id" : 34 , "uuid" : "5e5a02dd-f991-4706-a428-69c3ea6c5ce8" , "beanName" : "User" } , "right" : "Some reason" } , {...} , {...} ]
Get existing SecurityTeam by id
.
Parameter name | Data type | Description |
---|---|---|
id | int | Security team id |
Thrown exception | Description |
---|---|
InternalErrorException | When unspecified error occur. See exception param message for explanation. |
PrivilegeException | When caller is not allowed to call this method. Result may vary based on caller identity and provided parameter values. |
RpcException | Wrong usage of API (wrong url, missing param etc.). See exception params message and type for explanation. |
Return type | Description |
---|---|
SecurityTeam | Team with given id |
Example URL
https://[hostname]/krb/rpc/json/securityTeamsManager/getSecurityTeamById
Example params
{ "id" : 79 }
Example response
{ "id" : 924 , "name" : "CSIRT" , "description" : "My CSIRT" }
List SecurityTeams your are member of or all for PerunAdmin.
Thrown exception | Description |
---|---|
InternalErrorException | When unspecified error occur. See exception param message for explanation. |
PrivilegeException | When caller is not allowed to call this method. Result may vary based on caller identity and provided parameter values. |
RpcException | Wrong usage of API (wrong url, missing param etc.). See exception params message and type for explanation. |
Return type | Description |
---|---|
List<SecurityTeam> | List of your security teams. |
Example URL
https://[hostname]/krb/rpc/json/securityTeamsManager/getSecurityTeams
Example response
[ { "id" : 924 , "name" : "CSIRT" , "description" : "My CSIRT" } , {...} , {...} ]
Remove User as a manager from SecurityTeam.
Parameter name | Data type | Description |
---|---|---|
securityTeam | int | id of SecurityTeam to remove manager (member) from |
user | int | id of User to be removed as a manager (member) of SecurityTeam |
Thrown exception | Description |
---|---|
InternalErrorException | When unspecified error occur. See exception param message for explanation. |
PrivilegeException | When caller is not allowed to call this method. Result may vary based on caller identity and provided parameter values. |
RpcException | Wrong usage of API (wrong url, missing param etc.). See exception params message and type for explanation. |
Return type | Description |
---|---|
void |
Example URL
https://[hostname]/krb/rpc/json/securityTeamsManager/removeAdmin
Example params
{ "securityTeam" : 88 , "user" : 28 }
Example response
null
Remove group as a manager from SecurityTeam.
Parameter name | Data type | Description |
---|---|---|
securityTeam | int | id of SecurityTeam to remove manager (member) from |
group | int | id of Group to be removed as a manager (member) of SecurityTeam |
Thrown exception | Description |
---|---|
InternalErrorException | When unspecified error occur. See exception param message for explanation. |
PrivilegeException | When caller is not allowed to call this method. Result may vary based on caller identity and provided parameter values. |
RpcException | Wrong usage of API (wrong url, missing param etc.). See exception params message and type for explanation. |
Return type | Description |
---|---|
void |
Example URL
https://[hostname]/krb/rpc/json/securityTeamsManager/removeAdmin
Example params
{ "securityTeam" : 20 , "group" : 44 }
Example response
null
Remove user from blacklist of given SecurityTeam
Parameter name | Data type | Description |
---|---|---|
securityTeam | int | id of SecurityTeam to remove user from blacklist |
user | int | id of User to be removed from blacklist of SecurityTeam |
Thrown exception | Description |
---|---|
InternalErrorException | When unspecified error occur. See exception param message for explanation. |
PrivilegeException | When caller is not allowed to call this method. Result may vary based on caller identity and provided parameter values. |
RpcException | Wrong usage of API (wrong url, missing param etc.). See exception params message and type for explanation. |
Return type | Description |
---|---|
void |
Example URL
https://[hostname]/krb/rpc/json/securityTeamsManager/removeUserFromBlacklist
Example params
{ "securityTeam" : 91 , "user" : 82 }
Example response
null
Update existing SecurityTeam name and description by teams id
. Name must be <= 128 and must be unique.
Parameter name | Data type | Description |
---|---|---|
securityTeam | SecurityTeam | Security team id |
Thrown exception | Description |
---|---|
InternalErrorException | When unspecified error occur. See exception param message for explanation. |
PrivilegeException | When caller is not allowed to call this method. Result may vary based on caller identity and provided parameter values. |
RpcException | Wrong usage of API (wrong url, missing param etc.). See exception params message and type for explanation. |
SecurityTeamExistsException | When new name of security team is not unique. |
SecurityTeamNotExistsException | When id of a team doesn't exists in Perun. |
Return type | Description |
---|---|
SecurityTeam | Team with updated values |
Example URL
https://[hostname]/krb/rpc/json/securityTeamsManager/updateSecurityTeam
Example params
{ "securityTeam" : { "id" : 924 , "name" : "CSIRT" , "description" : "My CSIRT" } }
Example response
{ "id" : 924 , "name" : "CSIRT" , "description" : "My CSIRT" }