-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathAuthenticationService.cpp
More file actions
37 lines (31 loc) · 913 Bytes
/
AuthenticationService.cpp
File metadata and controls
37 lines (31 loc) · 913 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#include "AuthenticationService.h"
#include<bits/stdc++.h>
using namespace std;
AuthenticationService::AuthenticationService()
{
// Init authentication service
}
bool AuthenticationService::googleAuth(const string& token)
{
return validateToken(token);
}
bool AuthenticationService::facebookAuth(const string& token)
{
return validateToken(token);
}
bool AuthenticationService::emailAuth(const string& email, const string& password)
{
return validateEmailCredentials(email, password);
}
bool AuthenticationService::validateToken(const string& token)
{
//Validation of OAuth token (Google/Facebook)
cout<<"Validating token: "<<token<<endl;
return true;
}
bool AuthenticationService::validateEmailCredentials(const string& email, const string& password)
{
// Logic to validate email and password
cout<<"Validating email: "<<email<<" and password."<<endl;
return true;
}