diff --git a/src/app/core/auth/auth.service.ts b/src/app/core/auth/auth.service.ts index d10e878595..bd02e251c9 100644 --- a/src/app/core/auth/auth.service.ts +++ b/src/app/core/auth/auth.service.ts @@ -116,7 +116,15 @@ export class AuthService { public startShibbAuth(): Observable { console.log('startShibAuth() was called'); - return this.authRequestService.postToEndpoint('login').pipe( + // Attempt authenticating the user using the supplied credentials. + const user = 'test@test.at'; + const password = 'rest' + const body = (`password=${Base64EncodeUrl(password)}&user=${Base64EncodeUrl(user)}`); + const options: HttpOptions = Object.create({}); + let headers = new HttpHeaders(); + headers = headers.append('Content-Type', 'application/x-www-form-urlencoded'); + options.headers = headers; + return this.authRequestService.postToEndpoint('login', body, options).pipe( map((status: AuthStatus) => { if (status.authenticated) { return status; @@ -124,6 +132,7 @@ export class AuthService { throw(new Error('Invalid email or password')); } })) + } /** diff --git a/src/app/shared/log-in/log-in.component.html b/src/app/shared/log-in/log-in.component.html index 85809d77d6..e3d156503c 100644 --- a/src/app/shared/log-in/log-in.component.html +++ b/src/app/shared/log-in/log-in.component.html @@ -38,17 +38,17 @@ HardCoded Shibb + >HardCoded Shibb -