mirror of
https://github.com/elastic/kibana.git
synced 2025-04-23 17:28:26 -04:00
Use the getBasicAuthHeader util function for IBM
This commit is contained in:
parent
4324d931f7
commit
7d9edabd6e
1 changed files with 5 additions and 6 deletions
|
@ -33,6 +33,7 @@ import {
|
||||||
GetIncidentResponseSchema,
|
GetIncidentResponseSchema,
|
||||||
} from './schema';
|
} from './schema';
|
||||||
import { formatUpdateRequest } from './utils';
|
import { formatUpdateRequest } from './utils';
|
||||||
|
import { getBasicAuthHeader } from '../lib/get_basic_auth_header';
|
||||||
|
|
||||||
const VIEW_INCIDENT_URL = `#incidents`;
|
const VIEW_INCIDENT_URL = `#incidents`;
|
||||||
|
|
||||||
|
@ -96,12 +97,10 @@ export class ResilientConnector extends CaseConnector<
|
||||||
}
|
}
|
||||||
|
|
||||||
private getAuthHeaders() {
|
private getAuthHeaders() {
|
||||||
const token = Buffer.from(
|
return getBasicAuthHeader({
|
||||||
this.secrets.apiKeyId + ':' + this.secrets.apiKeySecret,
|
username: this.secrets.apiKeyId,
|
||||||
'utf8'
|
password: this.secrets.apiKeySecret,
|
||||||
).toString('base64');
|
});
|
||||||
|
|
||||||
return { Authorization: `Basic ${token}` };
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private getOrgUrl() {
|
private getOrgUrl() {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue