mirror of
https://github.com/elastic/kibana.git
synced 2025-06-28 11:05:39 -04:00
[Security Solution] response action entity_id number -> string (#135037)
This commit is contained in:
parent
61b5349d95
commit
acfd0517a2
4 changed files with 6 additions and 6 deletions
|
@ -213,7 +213,7 @@ describe('actions schemas', () => {
|
|||
KillOrSuspendProcessRequestSchema.body.validate({
|
||||
endpoint_ids: ['ABC-XYZ-000'],
|
||||
parameters: {
|
||||
entity_id: 5678,
|
||||
entity_id: 'abc123',
|
||||
},
|
||||
});
|
||||
}).not.toThrow();
|
||||
|
@ -225,7 +225,7 @@ describe('actions schemas', () => {
|
|||
endpoint_ids: ['ABC-XYZ-000'],
|
||||
parameters: {
|
||||
pid: 1234,
|
||||
entity_id: 5678,
|
||||
entity_id: 'abc123',
|
||||
},
|
||||
});
|
||||
}).toThrow();
|
||||
|
|
|
@ -27,7 +27,7 @@ export const KillOrSuspendProcessRequestSchema = {
|
|||
...BaseActionRequestSchema,
|
||||
parameters: schema.oneOf([
|
||||
schema.object({ pid: schema.number({ min: 1 }) }),
|
||||
schema.object({ entity_id: schema.number({ min: 1 }) }),
|
||||
schema.object({ entity_id: schema.string({ minLength: 1 }) }),
|
||||
]),
|
||||
}),
|
||||
};
|
||||
|
|
|
@ -87,7 +87,7 @@ interface ResponseActionParametersWithPid {
|
|||
|
||||
interface ResponseActionParametersWithEntityId {
|
||||
pid?: never;
|
||||
entity_id: number;
|
||||
entity_id: string;
|
||||
}
|
||||
|
||||
export type ResponseActionParametersWithPidOrEntityId =
|
||||
|
|
|
@ -94,12 +94,12 @@ export default function ({ getService }: FtrProviderContext) {
|
|||
{
|
||||
method: 'post',
|
||||
path: KILL_PROCESS_ROUTE,
|
||||
body: { endpoint_ids: ['one'], parameters: { entity_id: 1234 } },
|
||||
body: { endpoint_ids: ['one'], parameters: { entity_id: 'abc123' } },
|
||||
},
|
||||
{
|
||||
method: 'post',
|
||||
path: SUSPEND_PROCESS_ROUTE,
|
||||
body: { endpoint_ids: ['one'], parameters: { entity_id: 1234 } },
|
||||
body: { endpoint_ids: ['one'], parameters: { entity_id: 'abc123' } },
|
||||
},
|
||||
];
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue