SourceCodester Online Eyewear Shop 1.0 POST Request oews/classes/Users.php registration firstname/middlename/lastname/email/contact cross site scripting
CVSS Punteggio Meta Temp | Exploit Prezzo Attuale (≈) | Punteggio di interesse CTI |
---|---|---|
5.3 | $0-$5k | 0.00 |
Un punto critico di livello problematico è stato rilevato in SourceCodester Online Eyewear Shop 1.0. Interessato da questa vulnerabilità è la funzione registration
del file oews/classes/Users.php del componente POST Request Handler. Attraverso l'influenza del parametro firstname/middlename/lastname/email/contact
di un input sconosciuto per mezzo di una vulerabilità di classe cross site scripting. Non sono ancora conosciuti gli effetti esatti di un attacco con sussesso.
La vulnerabilità è stata pubblicata in data 07/02/2023 da Pierfrancesco Conti da Cyber Partners (non definito). Questo punto di criticità è identificato come CVE-2023-0732. I dettagli tecnici e un metodo di utilizzo sono conosciuti. La ragione di questa vulnerabilità è questa parte di codice:
function registration(){ if(!empty($_POST['password'])) $_POST['password'] = md5($_POST['password']); else unset($_POST['password']); extract($_POST); $main_field = ['firstname', 'middlename', 'lastname', 'gender', 'contact', 'email', 'status', 'password']; $data = ""; $check = $this->conn->query("SELECT * FROM `customer_list` where email = '{$email}' ".($id > 0 ? " and id!='{$id}'" : "")." ")->num_rows; if($check > 0){ $resp['status'] = 'failed'; $resp['msg'] = 'Email already exists.'; return json_encode($resp); } foreach($_POST as $k => $v){ $v = $this->conn->real_escape_string($v); if(in_array($k, $main_field)){ if(!empty($data)) $data .= ", "; $data .= " `{$k}` = '{$v}' "; } } if(empty($id)){ $sql = "INSERT INTO `customer_list` set {$data} "; }else{ $sql = "UPDATE `customer_list` set {$data} where id = '{$id}' "; } $save = $this->conn->query($sql); if($save){ $uid = !empty($id) ? $id : $this->conn->insert_id; $resp['status'] = 'success'; $resp['uid'] = $uid; if(!empty($id)) $resp['msg'] = 'User Details has been updated successfully'; else $resp['msg'] = 'Your Account has been created successfully'; if(!empty($_FILES['img']['tmp_name'])){ if(!is_dir(base_app."uploads/customers")) mkdir(base_app."uploads/customers"); $ext = pathinfo($_FILES['img']['name'], PATHINFO_EXTENSION); $fname = "uploads/customers/$uid.png"; $accept = array('image/jpeg','image/png'); if(!in_array($_FILES['img']['type'],$accept)){ $resp['msg'] = "Image file type is invalid"; } if($_FILES['img']['type'] == 'image/jpeg') $uploadfile = imagecreatefromjpeg($_FILES['img']['tmp_name']); elseif($_FILES['img']['type'] == 'image/png') $uploadfile = imagecreatefrompng($_FILES['img']['tmp_name']); if(!$uploadfile){ $resp['msg'] = "Image is invalid"; } $temp = imagescale($uploadfile,200,200); if(is_file(base_app.$fname)) unlink(base_app.$fname); $upload =imagepng($temp,base_app.$fname); if($upload){ $this->conn->query("UPDATE `customer_list` set `avatar` = CONCAT('{$fname}', '?v=',unix_timestamp(CURRENT_TIMESTAMP)) where id = '{$uid}'"); } imagedestroy($temp); } if(!empty($uid) && $this->settings->userdata('login_type') != 1){ $user = $this->conn->query("SELECT * FROM `customer_list` where id = '{$uid}' "); if($user->num_rows > 0){ $res = $user->fetch_array(); foreach($res as $k => $v){ if(!is_numeric($k) && $k != 'password'){ $this->settings->set_userdata($k, $v); } } $this->settings->set_userdata('login_type', '2'); } } }else{ $resp['status'] = 'failed'; $resp['msg'] = $this->conn->error; $resp['sql'] = $sql; } if($resp['status'] == 'success' && isset($resp['msg'])) $this->settings->set_flashdata('success', $resp['msg']); return json_encode($resp); }
È stato dichiarato come proof-of-concept. Cercando inurl:oews/classes/Users.php è possibile trovare obiettivi vulnerabili con Google Hacking.
Informazioni riguardo una possibile contromisura non sono al momento disponibili. Si suggerisce di sostituire il prodotto con uno equivalente.
Prodotto
Fornitore
Nome
Versione
Licenza
CPE 2.3
CPE 2.2
CVSSv4
VulDB CVSS-B Score: 🔍VulDB CVSS-BT Score: 🔍
VulDB Vettore: 🔍
VulDB Affidabilità: 🔍
CVSSv3
VulDB Punteggio meta-base: 5.5VulDB Punteggio Meta Temp: 5.3
VulDB Punteggio di base: 3.5
VulDB Punteggio temporaneo: 3.2
VulDB Vettore: 🔍
VulDB Affidabilità: 🔍
Researcher Punteggio di base: 9.0
Researcher Vettore: 🔍
NVD Punteggio di base: 6.1
NVD Vettore: 🔍
CNA Punteggio di base: 3.5
CNA Vettore (VulDB): 🔍
CVSSv2
AV | AC | Au | C | I | A |
---|---|---|---|---|---|
💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
Vettore | Complessità | Autenticazione | Riservatezza | Integrità | Disponibilità |
---|---|---|---|---|---|
sbloccare | sbloccare | sbloccare | sbloccare | sbloccare | sbloccare |
sbloccare | sbloccare | sbloccare | sbloccare | sbloccare | sbloccare |
sbloccare | sbloccare | sbloccare | sbloccare | sbloccare | sbloccare |
VulDB Punteggio di base: 🔍
VulDB Punteggio temporaneo: 🔍
VulDB Affidabilità: 🔍
Researcher Punteggio di base: 🔍
NVD Punteggio di base: 🔍
Exploiting
Classe: Cross site scriptingCWE: CWE-79 / CWE-74 / CWE-707
CAPEC: 🔍
ATT&CK: 🔍
Locale: No
Remoto: Si
Disponibilità: 🔍
Stato: Proof-of-Concept
Google Hack: 🔍
EPSS Score: 🔍
EPSS Percentile: 🔍
Previsione dei prezzi: 🔍
Preventivo attuale: 🔍
0-Day | sbloccare | sbloccare | sbloccare | sbloccare |
---|---|---|---|---|
Oggi | sbloccare | sbloccare | sbloccare | sbloccare |
Intelligence Sulle Minacce
Interesse: 🔍Attori Attivi: 🔍
Gruppi APT attivi: 🔍
Contromisure
Raccomandazione: nessuna contromisura conosciutaStato: 🔍
0 giorni di tempo: 🔍
Sequenza temporale
07/02/2023 🔍07/02/2023 🔍
07/02/2023 🔍
06/03/2023 🔍
Fonti
Riceratore: Pierfrancesco ContiOrganizzazione: Cyber Partners
Stato: Non definito
CVE: CVE-2023-0732 (🔍)
scip Labs: https://www.scip.ch/en/?labs.20161013
Voce
Data di creazione: 07/02/2023 21:04Aggiornamenti: 06/03/2023 11:07
I cambiamenti: 07/02/2023 21:04 (39), 08/02/2023 14:11 (8), 08/02/2023 14:12 (15), 08/02/2023 14:15 (4), 06/03/2023 11:01 (2), 06/03/2023 11:07 (28)
Completa: 🔍
Inviato: CP_offensive_team
Committer: CP_offensive_team
Cache ID: 3:F84:103
Submit
Accettato
- Submit #85725: SourceCodester Online Eyewear Shop 1.0 Cross-Site Scripting (di CP_offensive_team)
Duplicate
- Submit #147891: SQL injection exists for the online-eyewear-shop CMS User.php id parameter (di SSL_Seven_Security Lab_WangZhiQiang_ZhangYing)
Ancora nessun commento. Le Lingue: it + en.
Effettua il login per commentare.