A vulnerability has been found in SourceCodester Simple Doctors Appointment System up to 1.0. This issue affects some unknown processing of the file /doctors_appointment/admin/ajax.php?action=save_category. Such manipulation of the argument img leads to unrestricted upload. The attack may be performed from remote. The exploit has been disclosed to the public and may be used.
CVE-2026-5181 is a medium-severity unrestricted file upload vulnerability in SourceCodester Simple Doctors Appointment System v1.0 affecting the admin AJAX endpoint. An unauthenticated attacker can upload arbitrary files by manipulating the 'img' parameter, potentially leading to remote code execution. No patch is currently available, and the vulnerability has been publicly disclosed.
IMMEDIATE ACTIONS:
1. Identify all instances of SourceCodester Simple Doctors Appointment System v1.0 in your environment
2. Disable or restrict access to /doctors_appointment/admin/ajax.php endpoint immediately
3. Implement network-level access controls (WAF rules) to block requests to the vulnerable endpoint
4. Review access logs for suspicious file upload attempts to the admin AJAX endpoint
PATCHING GUIDANCE:
1. Contact SourceCodester for patch availability or security updates
2. If no patch is available, consider migrating to alternative appointment management systems with active security support
3. Implement input validation and file type restrictions at the application level if source code access is available
COMPENSATING CONTROLS:
1. Deploy Web Application Firewall (WAF) rules to block file uploads with suspicious extensions (.php, .exe, .jsp, etc.)
2. Implement strict file upload validation: whitelist allowed file types (jpg, png only), verify MIME types server-side
3. Store uploaded files outside web root directory
4. Disable script execution in upload directories via .htaccess or web server configuration
5. Implement authentication checks on the ajax.php endpoint
6. Monitor upload directory for suspicious files and execute permissions
DETECTION RULES:
1. Alert on POST requests to /doctors_appointment/admin/ajax.php?action=save_category
2. Monitor for file uploads with executable extensions in appointment system directories
3. Track failed authentication attempts to admin endpoints
4. Log and alert on unusual file types in upload directories
الإجراءات الفورية:
1. تحديد جميع نسخ SourceCodester Simple Doctors Appointment System v1.0 في بيئتك
2. تعطيل أو تقييد الوصول إلى نقطة نهاية /doctors_appointment/admin/ajax.php فوراً
3. تطبيق عناصر تحكم الوصول على مستوى الشبكة (قواعد WAF) لحجب الطلبات إلى النقطة الضعيفة
4. مراجعة سجلات الوصول للكشف عن محاولات تحميل ملفات مريبة
إرشادات التصحيح:
1. التواصل مع SourceCodester للحصول على تحديثات الأمان
2. إذا لم يكن هناك تصحيح متاح، فكر في الهجرة إلى أنظمة بديلة
3. تطبيق التحقق من صحة المدخلات إذا كان لديك وصول إلى الكود المصدري
عناصر التحكم البديلة:
1. نشر قواعد WAF لحجب تحميل الملفات بامتدادات مريبة
2. تطبيق التحقق الصارم من تحميل الملفات: قائمة بيضاء للأنواع المسموحة فقط
3. تخزين الملفات المحملة خارج دليل الويب
4. تعطيل تنفيذ البرامج النصية في أدلة التحميل
5. تطبيق فحوصات المصادقة على نقطة نهاية ajax.php
6. مراقبة دليل التحميل للملفات المريبة
قواعد الكشف:
1. تنبيهات على طلبات POST إلى النقطة الضعيفة
2. مراقبة تحميل الملفات بامتدادات قابلة للتنفيذ
3. تتبع محاولات المصادقة الفاشلة
4. تسجيل وتنبيهات على أنواع الملفات غير العادية