Assigned Credential
3 min
Search SAPM Account ID
GET
http://{{hostname}}/aioc-rest-web/rest/assignedCredential/search
csharp
var client = new RestClient("http://{{hostname}}/aioc-rest-web/rest/assignedCredential/search?sapmAccountId=566585");
client.Timeout = -1;
var request = new RestRequest(Method.GET);
request.AddHeader("Content-Type", "application/json");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);curl
curl --location -g --request GET 'http://{{hostname}}/aioc-rest-web/rest/assignedCredential/search?sapmAccountId=566585' \
--header 'Content-Type: application/json'javascript
var settings = {
"url": "http://{{hostname}}/aioc-rest-web/rest/assignedCredential/search?sapmAccountId=566585",
"method": "GET",
"timeout": 0,
"headers": {
"Content-Type": "application/json"
},
};
$.ajax(settings).done(function (response) {
console.log(response);
});200
[
{
"dbId": 4979851,
"assignedCredentialUser": {
"id": "25e53f47-ce66-4df2-9abc-6961dc668264",
"eid": "admin",
"personelId": null,
"name": "Administrator",
"passwordAlgorithm": null,
"password": "f0b33b0821f883caf74c8d855c2ea996",
"email": "[email protected]",
"surname": "Administrator",
"internal": true,
"properties": {
"ubaThreshold": "50"
},
"groups": [
"DEFAULT_GROUP_SYSYEM_USERS",
"DEFAULT_GROUP_SYSYEM_ADMINS"
],
"managerGroups": [
"DEFAULT_GROUP_SYSYEM_ADMINS"
],
"lastLogin": 1606086958775,
"lastLoginIp": "0:0:0:0:0:0:0:1",
"groupPropertyKey4Search": null,
"groupPropertyValue4Search": null,
"recordLimit4Search": null,
"passwordDirty": false,
"passwordAutoGenerated": false,
"filterFunctionName": null,
"filterMembershipUserId": null,
"filterManagerId": null,
"filterEidList": null,
"filterManagerOfUserId": null,
"tempUser": false,
"tempUserStartTime": null,
"tempUserEndTime": null,
"phoneNumber": null,
"forceChangePasswordOnNextLogin": false,
"lockReason": null,
"unlockOnPasswordChanged": false,
"unlockTime": null,
"externalDirectorySource": null,
"userPropertyKey4Search": null,
"userPropertyValue4Search": null,
"locked": false
},
"credentialSource": "SAPM",
"sapmAccount": {
"dbId": 566585,
"device": {
"dbId": 1,
"id": "127.0.0.1",
"name": "127.0.0.1",
"accessProtocol": "SSHv2",
"managementIp": "127.0.0.1",
"elementType": {
"dbId": 203638,
"elementTypeId": "sc_proxy",
"elementTypeName": "SC PROXY",
"vendor": null,
"category": null,
"elementTypeProperties": []
},
"discoveryTime": 1530205124000,
"properties": {
"hostname": "127.0.0.1",
"pseudoDevice": "true"
},
"deviceGroups": [
"dg.sc_proxy"
],
"availability": null,
"currentMaintenanceWindow": null,
"interfaceName": null,
"nameManagementIp": "127.0.0.1-127.0.0.1",
"regionName": null,
"filterRecordLimit": null,
"filterSearchPhrase": null,
"filterGroupId": null,
"filterRoleGroupIds": null,
"filterOnlyUnassignedDevices": null,
"pseudoDevice": true,
"portNum": null,
"domainController": null,
"discoverySource": null
},
"config": {
"configId": -9077,
"name": "Linux",
"description": "Linux",
"strategy": "SSH",
"properties": {
"new.user.found.action": "LOG",
"username.parser": "(.*?):.*",
"change.password.command.template": "passwd\\n${oldPassword}\\n${newPassword}\\n${newPassword}\\nlogout",
"user.list.command": "cat /etc/passwd"
},
"exactMatch4Search": false,
"recordLimit4Search": null
},
"changePeriod": 28800,
"username": "kron1",
"password": "0E4PzY2ByShg26PoZSbfJA==",
"previousPassword": "3HxMdrxt1OlKI/cBlhei5g==",
"lastChangeTime": 1604823540077,
"nextChangeTime": 1606551540077,
"nextChangeTimeStart4Search": null,
"nextChangeTimeEnd4Search": null,
"passwordSeenStatus": "UNSEEN",
"validationStatus": "VALID",
"changeStatus": null,
"lastAttemptStatus": true,
"masterAccountId": null,
"permissions": {},
"identicalSapmAccounts": [],
"recordLimit4Search": null,
"validationStatus4Search": null,
"checkPermission4Search": true,
"exactMatch4Search": false,
"acceptedSapmConfigList": null,
"masterAccountId4Search": null,
"searchOnlyMasterAccounts": false,
"searchOnlyOwnRegion": false,
"deviceIp4Search": null,
"secondPartSeenUsername": null,
"firstPartSeenUsername": null,
"errorMessage": null,
"successful": true,
"changePeriodFormatted": "20d 00h 00m"
},
"secretDataVault": null,
"device": null,
"deviceGroup": null,
"recordLimit4Search": null
},
{
"dbId": 7268915,
"assignedCredentialUser": {
"id": "65646c8a-21f1-4f6e-8a3e-50f89c54ad39",
"eid": "test",
"personelId": null,
"name": "test",
"passwordAlgorithm": "MD5",
"password": "996b67f0bb66b6c87ed4b9d880c00501",
"email": "[email protected]",
"surname": "test",
"internal": true,
"properties": {
"ubaThreshold": "50"
},
"groups": [
"DEFAULT_GROUP_SYSYEM_USERS"
],
"managerGroups": [],
"lastLogin": null,
"lastLoginIp": null,
"groupPropertyKey4Search": null,
"groupPropertyValue4Search": null,
"recordLimit4Search": null,
"passwordDirty": false,
"passwordAutoGenerated": false,
"filterFunctionName": null,
"filterMembershipUserId": null,
"filterManagerId": null,
"filterEidList": null,
"filterManagerOfUserId": null,
"tempUser": false,
"tempUserStartTime": null,
"tempUserEndTime": null,
"phoneNumber": null,
"forceChangePasswordOnNextLogin": false,
"lockReason": null,
"unlockOnPasswordChanged": false,
"unlockTime": null,
"externalDirectorySource": null,
"userPropertyKey4Search": null,
"userPropertyValue4Search": null,
"locked": false
},
"credentialSource": "SAPM",
"sapmAccount": {
"dbId": 566585,
"device": {
"dbId": 1,
"id": "127.0.0.1",
"name": "127.0.0.1",
"accessProtocol": "SSHv2",
"managementIp": "127.0.0.1",
"elementType": {
"dbId": 203638,
"elementTypeId": "sc_proxy",
"elementTypeName": "SC PROXY",
"vendor": null,
"category": null,
"elementTypeProperties": []
},
"discoveryTime": 1530205124000,
"properties": {
"hostname": "127.0.0.1",
"pseudoDevice": "true"
},
"deviceGroups": [
"dg.sc_proxy"
],
"availability": null,
"currentMaintenanceWindow": null,
"interfaceName": null,
"nameManagementIp": "127.0.0.1-127.0.0.1",
"regionName": null,
"filterRecordLimit": null,
"filterSearchPhrase": null,
"filterGroupId": null,
"filterRoleGroupIds": null,
"filterOnlyUnassignedDevices": null,
"pseudoDevice": true,
"portNum": null,
"domainController": null,
"discoverySource": null
},
"config": {
"configId": -9077,
"name": "Linux",
"description": "Linux",
"strategy": "SSH",
"properties": {
"new.user.found.action": "LOG",
"username.parser": "(.*?):.*",
"change.password.command.template": "passwd\\n${oldPassword}\\n${newPassword}\\n${newPassword}\\nlogout",
"user.list.command": "cat /etc/passwd"
},
"exactMatch4Search": false,
"recordLimit4Search": null
},
"changePeriod": 28800,
"username": "kron1",
"password": "0E4PzY2ByShg26PoZSbfJA==",
"previousPassword": "3HxMdrxt1OlKI/cBlhei5g==",
"lastChangeTime": 1604823540077,
"nextChangeTime": 1606551540077,
"nextChangeTimeStart4Search": null,
"nextChangeTimeEnd4Search": null,
"passwordSeenStatus": "UNSEEN",
"validationStatus": "VALID",
"changeStatus": null,
"lastAttemptStatus": true,
"masterAccountId": null,
"permissions": {},
"identicalSapmAccounts": [],
"recordLimit4Search": null,
"validationStatus4Search": null,
"checkPermission4Search": true,
"exactMatch4Search": false,
"acceptedSapmConfigList": null,
"masterAccountId4Search": null,
"searchOnlyMasterAccounts": false,
"searchOnlyOwnRegion": false,
"deviceIp4Search": null,
"secondPartSeenUsername": null,
"firstPartSeenUsername": null,
"errorMessage": null,
"successful": true,
"changePeriodFormatted": "20d 00h 00m"
},
"secretDataVault": null,
"device": null,
"deviceGroup": null,
"recordLimit4Search": null
}
]400
You cannot search the SAPM and Secret Vault Data at the same time.Search By User Id and Cred. Source
GET
http://{{hostname}}/aioc-rest-web/rest/assignedCredential/search?userId=68f84f67-3ad2-47c3-80cd-dda69fd327e3&source=SECRET_DATA_VAULT
csharp
var client = new RestClient("http://{{hostname}}/aioc-rest-web/rest/assignedCredential/search?userId=68f84f67-3ad2-47c3-80cd-dda69fd327e3&source=SECRET_DATA_VAULT");
client.Timeout = -1;
var request = new RestRequest(Method.GET);
request.AddHeader("Content-Type", "application/json");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);curl
curl --location -g --request GET 'http://{{hostname}}/aioc-rest-web/rest/assignedCredential/search?userId=68f84f67-3ad2-47c3-80cd-dda69fd327e3&source=SECRET_DATA_VAULT' \
--header 'Content-Type: application/json'javascript
var settings = {
"url": "http://{{hostname}}/aioc-rest-web/rest/assignedCredential/search?userId=68f84f67-3ad2-47c3-80cd-dda69fd327e3&source=SECRET_DATA_VAULT",
"method": "GET",
"timeout": 0,
"headers": {
"Content-Type": "application/json"
},
};
$.ajax(settings).done(function (response) {
console.log(response);
});200
[
{
"dbId": 1777540,
"assignedCredentialUser": {
"id": "68f84f67-3ad2-47c3-80cd-dda69fd327e3",
"eid": "test",
"personelId": "1",
"name": "test",
"passwordAlgorithm": "MD5",
"password": "c4ca4238a0b923820dcc509a6f75849b",
"email": "[email protected]",
"surname": "test",
"internal": true,
"properties": {
"ubaThreshold": "50"
},
"groups": [
"DEFAULT_GROUP_SYSYEM_USERS",
"5a91c44f-30fc-450c-b913-ce5437f33f33"
],
"managerGroups": [
"5a91c44f-30fc-450c-b913-ce5437f33f33"
],
"lastLogin": 1605091187945,
"lastLoginIp": "10.xx.xx.xx",
"groupPropertyKey4Search": null,
"groupPropertyValue4Search": null,
"recordLimit4Search": null,
"passwordDirty": false,
"passwordAutoGenerated": false,
"filterFunctionName": null,
"filterMembershipUserId": null,
"filterManagerId": null,
"filterEidList": null,
"filterManagerOfUserId": null,
"tempUser": false,
"tempUserStartTime": null,
"tempUserEndTime": null,
"phoneNumber": null,
"forceChangePasswordOnNextLogin": false,
"lockReason": null,
"unlockOnPasswordChanged": false,
"unlockTime": null,
"externalDirectorySource": null,
"userPropertyKey4Search": null,
"userPropertyValue4Search": null,
"locked": false
},
"credentialSource": "SECRET_DATA_VAULT",
"sapmAccount": null,
"secretDataVault": {
"dbId": 1777537,
"name": "windows",
"description": null,
"type": "USER_CREDENTIAL",
"ipAddress": "10.xx.xx.xx",
"secretData": "oOWJqvoUIvVvZIdzeAtKeQ==",
"secretData2": null,
"permissions": {},
"userCreate": "admin",
"username": "sercan",
"errorMessage": null,
"successful": true,
"privateType": "NO",
"userPermissionLevel": null
},
"device": {
"dbId": 510313,
"id": "4eef1637-1dee-429d-92f0-860b8193bde5",
"name": "windows-test",
"accessProtocol": "RDP",
"managementIp": "10.xx.xx.xx",
"elementType": {
"dbId": -123,
"elementTypeId": "windows",
"elementTypeName": "Windows",
"vendor": null,
"category": null,
"elementTypeProperties": []
},
"discoveryTime": 1581502986745,
"properties": {
"remoteDesktop.server-layout": "tr-tr-qwerty",
"remoteDesktop.security": "any",
"pseudoDevice": "true",
"remoteDesktop.enable-printing": "true",
"remoteDesktop.enable-drive": "true",
"remoteDesktop.ignore-cert": "true"
},
"deviceGroups": [
"99a7a80d-cf62-440f-a9eb-3e99eb0539bc"
],
"availability": null,
"currentMaintenanceWindow": null,
"interfaceName": null,
"nameManagementIp": "windows-test-10.xx.xx.xx",
"regionName": null,
"filterRecordLimit": null,
"filterSearchPhrase": null,
"filterGroupId": null,
"filterRoleGroupIds": null,
"filterOnlyUnassignedDevices": null,
"pseudoDevice": true,
"portNum": null,
"domainController": null,
"discoverySource": null
},
"deviceGroup": null,
"recordLimit4Search": null
}
]400
You cannot search the SAPM and Secret Vault Data at the same time.
Search By User Id and Secret Data Vault Id - Device or Device Group Id
GET
http://{{hostname}}/aioc-rest-web/rest/assignedCredential/search?secretVaultId=1777537&userId=65646c8a-21f1-4f6e-8a3e-50f89c54ad39&deviceOrDeviceGroupId=4eef1637-1dee-429d-92f0-860b8193bde5
csharp
var client = new RestClient("http://{{hostname}}/aioc-rest-web/rest/assignedCredential/search?secretVaultId=1777537&userId=65646c8a-21f1-4f6e-8a3e-50f89c54ad39&deviceOrDeviceGroupId=4eef1637-1dee-429d-92f0-860b8193bde5");
client.Timeout = -1;
var request = new RestRequest(Method.GET);
request.AddHeader("Content-Type", "application/json");
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);curl
curl --location -g --request GET 'http://{{hostname}}/aioc-rest-web/rest/assignedCredential/search?secretVaultId=1777537&userId=65646c8a-21f1-4f6e-8a3e-50f89c54ad39&deviceOrDeviceGroupId=4eef1637-1dee-429d-92f0-860b8193bde5' \
--header 'Content-Type: application/json'javascript
var settings = {
"url": "http://{{hostname}}/aioc-rest-web/rest/assignedCredential/search?secretVaultId=1777537&userId=65646c8a-21f1-4f6e-8a3e-50f89c54ad39&deviceOrDeviceGroupId=4eef1637-1dee-429d-92f0-860b8193bde5",
"method": "GET",
"timeout": 0,
"headers": {
"Content-Type": "application/json"
},
};
$.ajax(settings).done(function (response) {
console.log(response);
});200
[
{
"dbId": 7268971,
"assignedCredentialUser": {
"id": "65646c8a-21f1-4f6e-8a3e-50f89c54ad39",
"eid": "test",
"personelId": null,
"name": "test",
"passwordAlgorithm": "MD5",
"password": "996b67f0bb66b6c87ed4b9d880c00501",
"email": "[email protected]",
"surname": "test",
"internal": true,
"properties": {
"ubaThreshold": "50"
},
"groups": [
"DEFAULT_GROUP_SYSYEM_USERS"
],
"managerGroups": [],
"lastLogin": null,
"lastLoginIp": null,
"groupPropertyKey4Search": null,
"groupPropertyValue4Search": null,
"recordLimit4Search": null,
"passwordDirty": false,
"passwordAutoGenerated": false,
"filterFunctionName": null,
"filterMembershipUserId": null,
"filterManagerId": null,
"filterEidList": null,
"filterManagerOfUserId": null,
"tempUser": false,
"tempUserStartTime": null,
"tempUserEndTime": null,
"phoneNumber": null,
"forceChangePasswordOnNextLogin": false,
"lockReason": null,
"unlockOnPasswordChanged": false,
"unlockTime": null,
"externalDirectorySource": null,
"userPropertyKey4Search": null,
"userPropertyValue4Search": null,
"locked": false
},
"credentialSource": "SECRET_DATA_VAULT",
"sapmAccount": null,
"secretDataVault": {
"dbId": 1777537,
"name": "windows",
"description": null,
"type": "USER_CREDENTIAL",
"ipAddress": "10.xx.xx.xx",
"secretData": "oOWJqvoUIvVvZIdzeAtKeQ==",
"secretData2": null,
"permissions": {},
"userCreate": "admin",
"username": "test",
"errorMessage": null,
"successful": true,
"privateType": "NO",
"userPermissionLevel": null
},
"device": null,
"deviceGroup": null,
"recordLimit4Search": null
}
]
Delete
POST
http://{{hostname}}/aioc-rest-web/rest/assignedCredential/delete?id=7383274
csharp
var client = new RestClient("http://{{hostname}}/aioc-rest-web/rest/assignedCredential/delete?id=7383274");
client.Timeout = -1;
var request = new RestRequest(Method.POST);
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n \"dbId\": 7268922,\n \"assignedCredentialUser\": {\n \"id\": \"65646c8a-21f1-4f6e-8a3e-50f89c54ad39\",\n \"eid\": \"test\",\n \"personelId\": null,\n \"name\": \"test\",\n \"passwordAlgorithm\": \"MD5\",\n \"password\": \"996b67f0bb66b6c87ed4b9d880c00501\",\n \"email\": \"[email protected]\",\n \"surname\": \"test\",\n \"internal\": true,\n \"properties\": {\n \"ubaThreshold\": \"50\"\n },\n \"groups\": [\n \"DEFAULT_GROUP_SYSYEM_USERS\"\n ],\n \"managerGroups\": [],\n \"lastLogin\": null,\n \"lastLoginIp\": null,\n \"groupPropertyKey4Search\": null,\n \"groupPropertyValue4Search\": null,\n \"recordLimit4Search\": null,\n \"passwordDirty\": false,\n \"passwordAutoGenerated\": false,\n \"filterFunctionName\": null,\n \"filterMembershipUserId\": null,\n \"filterManagerId\": null,\n \"filterEidList\": null,\n \"filterManagerOfUserId\": null,\n \"tempUser\": false,\n \"tempUserStartTime\": null,\n \"tempUserEndTime\": null,\n \"lockReason\": null,\n \"unlockOnPasswordChanged\": false,\n \"unlockTime\": null,\n \"externalDirectorySource\": null,\n \"userPropertyKey4Search\": null,\n \"userPropertyValue4Search\": null,\n \"phoneNumber\": null,\n \"forceChangePasswordOnNextLogin\": false,\n \"locked\": false\n },\n \"credentialSource\": \"SECRET_DATA_VAULT\",\n \"sapmAccount\": null,\n \"secretDataVault\": {\n \"dbId\": 1777537,\n \"name\": \"windows_test\",\n \"description\": null,\n \"type\": \"USER_CREDENTIAL\",\n \"ipAddress\": \"10.xx.xx.xx\",\n \"secretData\": \"oOWJqvoUIvVvZIdzeAtKeQ==\",\n \"secretData2\": null,\n \"permissions\": {},\n \"userCreate\": \"admin\",\n \"username\": \"test\",\n \"errorMessage\": null,\n \"successful\": true,\n \"privateType\": \"NO\",\n \"userPermissionLevel\": null\n },\n \"deviceGroup\": null,\n \"recordLimit4Search\": null\n }", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);curl
curl --location -g --request POST 'http://{{hostname}}/aioc-rest-web/rest/assignedCredential/delete?id=7383274' \
--header 'Content-Type: application/json' \
--data-raw '{
"dbId": 7268922,
"assignedCredentialUser": {
"id": "65646c8a-21f1-4f6e-8a3e-50f89c54ad39",
"eid": "test",
"personelId": null,
"name": "test",
"passwordAlgorithm": "MD5",
"password": "996b67f0bb66b6c87ed4b9d880c00501",
"email": "[email protected]",
"surname": "test",
"internal": true,
"properties": {
"ubaThreshold": "50"
},
"groups": [
"DEFAULT_GROUP_SYSYEM_USERS"
],
"managerGroups": [],
"lastLogin": null,
"lastLoginIp": null,
"groupPropertyKey4Search": null,
"groupPropertyValue4Search": null,
"recordLimit4Search": null,
"passwordDirty": false,
"passwordAutoGenerated": false,
"filterFunctionName": null,
"filterMembershipUserId": null,
"filterManagerId": null,
"filterEidList": null,
"filterManagerOfUserId": null,
"tempUser": false,
"tempUserStartTime": null,
"tempUserEndTime": null,
"lockReason": null,
"unlockOnPasswordChanged": false,
"unlockTime": null,
"externalDirectorySource": null,
"userPropertyKey4Search": null,
"userPropertyValue4Search": null,
"phoneNumber": null,
"forceChangePasswordOnNextLogin": false,
"locked": false
},
"credentialSource": "SECRET_DATA_VAULT",
"sapmAccount": null,
"secretDataVault": {
"dbId": 1777537,
"name": "windows",
"description": null,
"type": "USER_CREDENTIAL",
"ipAddress": "10.xx.xx.xx",
"secretData": "oOWJqvoUIvVvZIdzeAtKeQ==",
"secretData2": null,
"permissions": {},
"userCreate": "admin",
"username": "test",
"errorMessage": null,
"successful": true,
"privateType": "NO",
"userPermissionLevel": null
},
"deviceGroup": null,
"recordLimit4Search": null
}'javascript
var settings = {
"url": "http://{{hostname}}/aioc-rest-web/rest/assignedCredential/delete?id=7383274",
"method": "POST",
"timeout": 0,
"headers": {
"Content-Type": "application/json"
},
"data": JSON.stringify({"dbId":7268922,"assignedCredentialUser":{"id":"65646c8a-21f1-4f6e-8a3e-50f89c54ad39","eid":"test","personelId":null,"name":"test","passwordAlgorithm":"MD5","password":"996b67f0bb66b6c87ed4b9d880c00501","email":"[email protected]","surname":"test","internal":true,"properties":{"ubaThreshold":"50"},"groups":["DEFAULT_GROUP_SYSYEM_USERS"],"managerGroups":[],"lastLogin":null,"lastLoginIp":null,"groupPropertyKey4Search":null,"groupPropertyValue4Search":null,"recordLimit4Search":null,"passwordDirty":false,"passwordAutoGenerated":false,"filterFunctionName":null,"filterMembershipUserId":null,"filterManagerId":null,"filterEidList":null,"filterManagerOfUserId":null,"tempUser":false,"tempUserStartTime":null,"tempUserEndTime":null,"lockReason":null,"unlockOnPasswordChanged":false,"unlockTime":null,"externalDirectorySource":null,"userPropertyKey4Search":null,"userPropertyValue4Search":null,"phoneNumber":null,"forceChangePasswordOnNextLogin":false,"locked":false},"credentialSource":"SECRET_DATA_VAULT","sapmAccount":null,"secretDataVault":{"dbId":1777537,"name":"windows_test","description":null,"type":"USER_CREDENTIAL","ipAddress":"10.xx.xx.xx","secretData":"oOWJqvoUIvVvZIdzeAtKeQ==","secretData2":null,"permissions":{},"userCreate":"admin","username":"test","errorMessage":null,"successful":true,"privateType":"NO","userPermissionLevel":null},"deviceGroup":null,"recordLimit4Search":null}),
};
$.ajax(settings).done(function (response) {
console.log(response);
});200
{
"dbId": 7268915,
"assignedCredentialUser": {
"id": "65646c8a-21f1-4f6e-8a3e-50f89c54ad39",
"eid": "test",
"personelId": null,
"name": "test",
"passwordAlgorithm": "MD5",
"password": "996b67f0bb66b6c87ed4b9d880c00501",
"email": "[email protected]",
"surname": "test",
"internal": true,
"properties": {
"ubaThreshold": "50"
},
"groups": [
"DEFAULT_GROUP_SYSYEM_USERS"
],
"managerGroups": [],
"lastLogin": null,
"lastLoginIp": null,
"groupPropertyKey4Search": null,
"groupPropertyValue4Search": null,
"recordLimit4Search": null,
"passwordDirty": false,
"passwordAutoGenerated": false,
"filterFunctionName": null,
"filterMembershipUserId": null,
"filterManagerId": null,
"filterEidList": null,
"filterManagerOfUserId": null,
"tempUser": false,
"tempUserStartTime": null,
"tempUserEndTime": null,
"phoneNumber": null,
"forceChangePasswordOnNextLogin": false,
"lockReason": null,
"unlockOnPasswordChanged": false,
"unlockTime": null,
"externalDirectorySource": null,
"userPropertyKey4Search": null,
"userPropertyValue4Search": null,
"locked": false
},
"credentialSource": "SAPM",
"sapmAccount": {
"dbId": 566585,
"device": {
"dbId": 1,
"id": "127.0.0.1",
"name": "127.0.0.1",
"accessProtocol": "SSHv2",
"managementIp": "127.0.0.1",
"elementType": {
"dbId": 203638,
"elementTypeId": "sc_proxy",
"elementTypeName": "SC PROXY",
"vendor": null,
"category": null,
"elementTypeProperties": []
},
"discoveryTime": 1530205124000,
"properties": {
"hostname": "127.0.0.1",
"pseudoDevice": "true"
},
"deviceGroups": [
"dg.sc_proxy"
],
"availability": null,
"currentMaintenanceWindow": null,
"interfaceName": null,
"nameManagementIp": "127.0.0.1-127.0.0.1",
"regionName": null,
"filterRecordLimit": null,
"filterSearchPhrase": null,
"filterGroupId": null,
"filterRoleGroupIds": null,
"filterOnlyUnassignedDevices": null,
"pseudoDevice": true,
"domainController": null,
"portNum": null,
"discoverySource": null
},
"config": {
"configId": -9077,
"name": "Linux",
"description": "Linux",
"strategy": "SSH",
"properties": {
"new.user.found.action": "LOG",
"username.parser": "(.*?):.*",
"change.password.command.template": "passwd\\n${oldPassword}\\n${newPassword}\\n${newPassword}\\nlogout",
"user.list.command": "cat /etc/passwd"
},
"exactMatch4Search": false,
"recordLimit4Search": null
},
"changePeriod": 28800,
"username": "kron1",
"password": "0E4PzY2ByShg26PoZSbfJA==",
"previousPassword": "3HxMdrxt1OlKI/cBlhei5g==",
"lastChangeTime": 1604823540077,
"nextChangeTime": 1606551540077,
"nextChangeTimeStart4Search": null,
"nextChangeTimeEnd4Search": null,
"passwordSeenStatus": "UNSEEN",
"validationStatus": "VALID",
"changeStatus": null,
"lastAttemptStatus": true,
"masterAccountId": null,
"permissions": {},
"identicalSapmAccounts": [],
"recordLimit4Search": null,
"validationStatus4Search": null,
"checkPermission4Search": true,
"exactMatch4Search": false,
"acceptedSapmConfigList": null,
"masterAccountId4Search": null,
"searchOnlyMasterAccounts": false,
"searchOnlyOwnRegion": false,
"deviceIp4Search": null,
"secondPartSeenUsername": null,
"firstPartSeenUsername": null,
"errorMessage": null,
"successful": true,
"changePeriodFormatted": "20d 00h 00m"
},
"secretDataVault": null,
"device": null,
"deviceGroup": null,
"recordLimit4Search": null
}400
There is no assigned credential with this id.
Save SAPM
POST
http://{{hostname}}/aioc-rest-web/rest/assignedCredential/save
csharp
var client = new RestClient("http://{{hostname}}/aioc-rest-web/rest/assignedCredential/save");
client.Timeout = -1;
var request = new RestRequest(Method.POST);
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n \"credentialSource\": \"SAPM\",\n \"userId\": \"65646c8a-21f1-4f6e-8a3e-50f89c54ad39\",\n \"id\": \"566585\"\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);curl
curl --location -g --request POST 'http://{{hostname}}/aioc-rest-web/rest/assignedCredential/save' \
--header 'Content-Type: application/json' \
--data-raw '{
"credentialSource": "SAPM",
"userId": "65646c8a-21f1-4f6e-8a3e-50f89c54ad39",
"id": "566585"
}'javascript
var settings = {
"url": "http://{{hostname}}/aioc-rest-web/rest/assignedCredential/save",
"method": "POST",
"timeout": 0,
"headers": {
"Content-Type": "application/json"
},
"data": JSON.stringify({"credentialSource":"SAPM","userId":"65646c8a-21f1-4f6e-8a3e-50f89c54ad39","id":"566585"}),
};
$.ajax(settings).done(function (response) {
console.log(response);
});200
{
"dbId": 7371984,
"assignedCredentialUser": {
"id": "65646c8a-21f1-4f6e-8a3e-50f89c54ad39",
"eid": "test",
"personelId": null,
"name": "test",
"passwordAlgorithm": "MD5",
"password": "996b67f0bb66b6c87ed4b9d880c00501",
"email": "[email protected]",
"surname": "test",
"internal": true,
"properties": {
"ubaThreshold": "50"
},
"groups": [
"DEFAULT_GROUP_SYSYEM_USERS"
],
"managerGroups": [],
"lastLogin": null,
"lastLoginIp": null,
"groupPropertyKey4Search": null,
"groupPropertyValue4Search": null,
"recordLimit4Search": null,
"passwordDirty": false,
"passwordAutoGenerated": false,
"filterFunctionName": null,
"filterMembershipUserId": null,
"filterManagerId": null,
"filterEidList": null,
"filterManagerOfUserId": null,
"tempUser": false,
"tempUserStartTime": null,
"tempUserEndTime": null,
"phoneNumber": null,
"forceChangePasswordOnNextLogin": false,
"lockReason": null,
"unlockOnPasswordChanged": false,
"unlockTime": null,
"externalDirectorySource": null,
"userPropertyKey4Search": null,
"userPropertyValue4Search": null,
"locked": false
},
"credentialSource": "SAPM",
"sapmAccount": {
"dbId": 566585,
"device": {
"dbId": 1,
"id": "127.0.0.1",
"name": "127.0.0.1",
"accessProtocol": "SSHv2",
"managementIp": "127.0.0.1",
"elementType": {
"dbId": 203638,
"elementTypeId": "sc_proxy",
"elementTypeName": "SC PROXY",
"vendor": null,
"category": null,
"elementTypeProperties": []
},
"discoveryTime": 1530205124000,
"properties": {
"hostname": "127.0.0.1",
"pseudoDevice": "true"
},
"deviceGroups": [
"dg.sc_proxy"
],
"availability": null,
"currentMaintenanceWindow": null,
"interfaceName": null,
"nameManagementIp": "127.0.0.1-127.0.0.1",
"regionName": null,
"filterRecordLimit": null,
"filterSearchPhrase": null,
"filterGroupId": null,
"filterRoleGroupIds": null,
"filterOnlyUnassignedDevices": null,
"pseudoDevice": true,
"domainController": null,
"portNum": null,
"discoverySource": null
},
"config": {
"configId": -9077,
"name": "Linux",
"description": "Linux",
"strategy": "SSH",
"properties": {
"new.user.found.action": "LOG",
"username.parser": "(.*?):.*",
"change.password.command.template": "passwd\\n${oldPassword}\\n${newPassword}\\n${newPassword}\\nlogout",
"user.list.command": "cat /etc/passwd"
},
"exactMatch4Search": false,
"recordLimit4Search": null
},
"changePeriod": 28800,
"username": "kron1",
"password": "0E4PzY2ByShg26PoZSbfJA==",
"previousPassword": "3HxMdrxt1OlKI/cBlhei5g==",
"lastChangeTime": 1604823540077,
"nextChangeTime": 1606551540077,
"nextChangeTimeStart4Search": null,
"nextChangeTimeEnd4Search": null,
"passwordSeenStatus": "UNSEEN",
"validationStatus": "VALID",
"changeStatus": null,
"lastAttemptStatus": true,
"masterAccountId": null,
"permissions": {},
"identicalSapmAccounts": [],
"recordLimit4Search": null,
"validationStatus4Search": null,
"checkPermission4Search": true,
"exactMatch4Search": false,
"acceptedSapmConfigList": null,
"masterAccountId4Search": null,
"searchOnlyMasterAccounts": false,
"searchOnlyOwnRegion": false,
"deviceIp4Search": null,
"secondPartSeenUsername": null,
"firstPartSeenUsername": null,
"errorMessage": null,
"successful": true,
"changePeriodFormatted": "20d 00h 00m"
},
"secretDataVault": null,
"device": null,
"deviceGroup": null,
"recordLimit4Search": null
}400
not found id 65646c8a-21f1-4f6e-8a3e-50f8
Save Secret Data Vault
POST
http://{{hostname}}/aioc-rest-web/rest/assignedCredential/save
csharp
var client = new RestClient("http://{{hostname}}/aioc-rest-web/rest/assignedCredential/save");
client.Timeout = -1;
var request = new RestRequest(Method.POST);
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n \"credentialSource\": \"SECRET_DATA_VAULT\",\n \"userId\": \"65646c8a-21f1-4f6e-8a3e-50f89c54ad39\",\n \"id\": \"1777537\",\n \"deviceOrDeviceGroupId\": \"4eef1637-1dee-429d-92f0-860b8193bde5\"\n \n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);curl
curl --location -g --request POST 'http://{{hostname}}/aioc-rest-web/rest/assignedCredential/save' \
--header 'Content-Type: application/json' \
--data-raw '{
"credentialSource": "SECRET_DATA_VAULT",
"userId": "65646c8a-21f1-4f6e-8a3e-50f89c54ad39",
"id": "1777537",
"deviceOrDeviceGroupId": "4eef1637-1dee-429d-92f0-860b8193bde5"
}'javascript
var settings = {
"url": "http://{{hostname}}/aioc-rest-web/rest/assignedCredential/save",
"method": "POST",
"timeout": 0,
"headers": {
"Content-Type": "application/json"
},
"data": JSON.stringify({"credentialSource":"SECRET_DATA_VAULT","userId":"65646c8a-21f1-4f6e-8a3e-50f89c54ad39","id":"1777537","deviceOrDeviceGroupId":"4eef1637-1dee-429d-92f0-860b8193bde5"}),
};
$.ajax(settings).done(function (response) {
console.log(response);
});200
{
"dbId": 7383274,
"assignedCredentialUser": {
"id": "65646c8a-21f1-4f6e-8a3e-50f89c54ad39",
"eid": "test",
"personelId": null,
"name": "test",
"passwordAlgorithm": "MD5",
"password": "996b67f0bb66b6c87ed4b9d880c00501",
"email": "[email protected]",
"surname": "test",
"internal": true,
"properties": {
"ubaThreshold": "50"
},
"groups": [
"DEFAULT_GROUP_SYSYEM_USERS"
],
"managerGroups": [],
"lastLogin": null,
"lastLoginIp": null,
"groupPropertyKey4Search": null,
"groupPropertyValue4Search": null,
"recordLimit4Search": null,
"passwordDirty": false,
"passwordAutoGenerated": false,
"filterFunctionName": null,
"filterMembershipUserId": null,
"filterManagerId": null,
"filterEidList": null,
"filterManagerOfUserId": null,
"tempUser": false,
"tempUserStartTime": null,
"tempUserEndTime": null,
"unlockTime": null,
"externalDirectorySource": null,
"userPropertyKey4Search": null,
"userPropertyValue4Search": null,
"unlockOnPasswordChanged": false,
"phoneNumber": null,
"forceChangePasswordOnNextLogin": false,
"lockReason": null,
"locked": false
},
"credentialSource": "SECRET_DATA_VAULT",
"sapmAccount": null,
"secretDataVault": {
"dbId": 1777537,
"name": "windows_test",
"description": null,
"type": "USER_CREDENTIAL",
"ipAddress": "10.xx.xx.xx",
"secretData": "oOWJqvoUIvVvZIdzeAtKeQ==",
"secretData2": null,
"permissions": {},
"userCreate": "admin",
"username": "test",
"errorMessage": null,
"successful": true,
"privateType": "NO",
"userPermissionLevel": null
},
"device": null,
"deviceGroup": null,
"recordLimit4Search": null
}400
SapmAccount account not found by id 1777537