Security
Last updated: April 2025
🛡️ Fatora is built with security-first principles to protect your business data and ensure ZATCA compliance.
🔐
Encrypted Passwords
All passwords are stored as bcrypt hashes with cost factor 12 — never readable, never logged.
🔒
HTTPS Only
All data in transit is protected by TLS encryption. Plain HTTP access is automatically redirected.
🚫
Login Protection
After 5 failed login attempts, accounts are locked for 15 minutes to prevent brute-force attacks.
🧩
CSRF Protection
Every form submission is protected by cryptographic tokens to prevent cross-site request forgery.
📁
Safe File Uploads
Uploaded logos are validated by MIME type using finfo — not just extension — before being accepted.
⏱️
Session Timeouts
User sessions automatically expire after 2 hours of inactivity to reduce unauthorized access risk.
⭐ ZATCA PHASE 2
Self-Upgrade Path to ZATCA Phase 2
Fatora includes a built-in upgrade path to ZATCA Phase 2 (Clearance). Users can activate Phase 2 integration directly from their account settings — no manual intervention required. Phase 2 generates cryptographically signed XML invoices, submits them to ZATCA's Fatoora portal for real-time clearance, and returns a compliant stamped copy. Your credentials and certificates are stored securely and never exposed to third parties.
Security Headers
Every page served by Fatora includes hardened HTTP security headers:
- X-Frame-Options: DENY — prevents clickjacking attacks.
- X-Content-Type-Options: nosniff — prevents MIME sniffing.
- Content-Security-Policy — restricts resource loading to trusted sources.
- Strict-Transport-Security — enforces HTTPS-only access.
- Referrer-Policy: strict-origin — limits referrer information leakage.
Database Security
All database queries use prepared statements with parameterized inputs, eliminating SQL injection vulnerabilities. Sensitive fields like passwords, VAT numbers, and session tokens are never logged or exposed in error messages.
Responsible Disclosure
If you discover a security vulnerability in Fatora, please report it responsibly to iKHENZ IT Solutions via ikhenz.com. We appreciate responsible disclosure and will address confirmed vulnerabilities promptly.
الأمان
آخر تحديث: أبريل 2025
🛡️ فاتورة مبني وفق مبدأ الأمان أولاً لحماية بيانات شركتك وضمان الامتثال لمتطلبات الزكاة.
🔐
كلمات مرور مشفرة
جميع كلمات المرور مخزنة كـ bcrypt hash بدرجة تعقيد 12 — لا يمكن قراءتها أو تسجيلها.
🔒
HTTPS فقط
جميع البيانات أثناء النقل محمية بتشفير TLS. يتم إعادة توجيه HTTP العادي تلقائياً.
🚫
حماية تسجيل الدخول
بعد 5 محاولات فاشلة، يتم قفل الحساب 15 دقيقة لمنع هجمات القوة الغاشمة.
🧩
حماية CSRF
كل طلب نموذج محمي برموز تشفيرية لمنع هجمات طلبات المواقع المشتركة.
📁
رفع ملفات آمن
الشعارات المرفوعة تُتحقق منها بنوع MIME باستخدام finfo — وليس الامتداد فقط — قبل القبول.
⏱️
انتهاء الجلسة
تنتهي جلسات المستخدم تلقائياً بعد ساعتين من الخمول لتقليل مخاطر الوصول غير المصرح.
⭐ المرحلة الثانية من الزكاة
ترقية ذاتية للمرحلة الثانية من الزكاة
يتضمن فاتورة مساراً مدمجاً للترقية إلى المرحلة الثانية من الزكاة (المقاصة). يمكن للمستخدمين تفعيل تكامل المرحلة الثانية مباشرةً من إعدادات حساباتهم — دون الحاجة إلى تدخل يدوي. تُولِّد المرحلة الثانية فواتير XML موقعة تشفيرياً، وترسلها إلى بوابة فاتورة الخاصة بهيئة الزكاة للمقاصة الفورية، وتُعيد نسخة ختمية متوافقة. يتم تخزين بيانات الاعتماد والشهادات بشكل آمن ولا تُكشف لأطراف ثالثة.
ترويسات الأمان
كل صفحة يقدمها فاتورة تتضمن ترويسات HTTP الأمنية المُحكمة:
- X-Frame-Options: DENY — يمنع هجمات النقر الخادع.
- X-Content-Type-Options: nosniff — يمنع تخمين نوع MIME.
- Content-Security-Policy — يقيد تحميل الموارد على المصادر الموثوقة.
- Strict-Transport-Security — يفرض الوصول عبر HTTPS فقط.
- Referrer-Policy: strict-origin — يحد من تسرب معلومات المرجع.
أمان قاعدة البيانات
جميع استعلامات قاعدة البيانات تستخدم Prepared Statements مع مدخلات ذات معاملات، مما يُلغي ثغرات حقن SQL. الحقول الحساسة ككلمات المرور وأرقام الضريبة ورموز الجلسات لا تُسجَّل أو تُكشف في رسائل الخطأ.
الإفصاح المسؤول
إذا اكتشفت ثغرة أمنية في فاتورة، يرجى الإبلاغ عنها بمسؤولية إلى iKHENZ IT Solutions عبر ikhenz.com. نُقدّر الإفصاح المسؤول وسنعالج الثغرات المؤكدة بسرعة.