Skip to content

Commit

Permalink
Removes console loggers
Browse files Browse the repository at this point in the history
Signed-off-by: Darshit Chanpura <dchanp@amazon.com>
  • Loading branch information
DarshitChanpura committed Mar 21, 2024
1 parent 573c715 commit b9b9911
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 5 deletions.
3 changes: 1 addition & 2 deletions common/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@
* permissions and limitations under the License.
*/

import { randomString } from '@hapi/cryptiles';

export const PLUGIN_ID = 'opensearchDashboardsSecurity';
export const PLUGIN_NAME = 'security-dashboards-plugin';

Expand All @@ -38,6 +36,7 @@ export const SAML_AUTH_LOGIN_WITH_FRAGMENT = '/auth/saml/captureUrlFragment';
export const ANONYMOUS_AUTH_LOGIN = '/auth/anonymous';
export const AUTH_REQUEST_TYPE_HEADER = 'auth_request_type';
export const SAML_AUTH_REQUEST_TYPE = 'saml';
export const OPEN_ID_AUTH_REQUEST_TYPE = 'openid';

export const OPENID_AUTH_LOGOUT = '/auth/openid/logout';
export const SAML_AUTH_LOGOUT = '/auth/saml/logout';
Expand Down
1 change: 0 additions & 1 deletion server/auth/types/authentication_type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,6 @@ export abstract class AuthenticationType implements IAuthenticationType {
const authHeaders = {};
let cookie: SecuritySessionCookie | null | undefined;
let authInfo: any | undefined;

// if this is an REST API call, suppose the request includes necessary auth header
// see https://www.elastic.co/guide/en/opensearch-dashboards/master/using-api.html
if (this.requestIncludesAuthInfo(request)) {
Expand Down
3 changes: 2 additions & 1 deletion server/auth/types/openid/routes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ import {
AUTH_RESPONSE_TYPE,
OPENID_AUTH_LOGOUT,
LOGIN_PAGE_URI,
OPEN_ID_AUTH_REQUEST_TYPE,
} from '../../../../common';

import {
Expand Down Expand Up @@ -189,7 +190,7 @@ export class OpenIdAuthRoutes {
request,
this.openIdAuthConfig.authHeaderName as string,
`Bearer ${tokenResponse.idToken}`,
undefined
OPEN_ID_AUTH_REQUEST_TYPE
);

// set to cookie
Expand Down
1 change: 0 additions & 1 deletion server/auth/types/saml/routes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,6 @@ export class SamlAuthRoutes {
`${this.coreSetup.http.basePath.serverBasePath}/app/opensearch-dashboards`;
redirectHash = cookie.saml?.redirectHash || false;
}
console.log(requestId);
if (!requestId) {
return response.badRequest({
body: 'Invalid requestId',
Expand Down

0 comments on commit b9b9911

Please sign in to comment.