feat: Complete Woles Framework v1.0 with enterprise-grade UI
- Add comprehensive error handling system with custom error pages - Implement professional enterprise-style design with Tailwind CSS - Create modular HMVC architecture with clean separation of concerns - Add security features: CSRF protection, XSS filtering, Argon2ID hashing - Include CLI tools for development workflow - Add error reporting dashboard with system monitoring - Implement responsive design with consistent slate color scheme - Replace all emoji icons with professional SVG icons - Add comprehensive test suite with PHPUnit - Include database migrations and seeders - Add proper exception handling with fallback pages - Implement template engine with custom syntax support - Add helper functions and facades for clean code - Include proper logging and debugging capabilities
This commit is contained in:
74
app/Core/Facades/Security.php
Normal file
74
app/Core/Facades/Security.php
Normal file
@@ -0,0 +1,74 @@
|
||||
<?php
|
||||
|
||||
namespace App\Core\Facades;
|
||||
|
||||
/**
|
||||
* NovaCore Security Facade
|
||||
* Static access to security services
|
||||
*/
|
||||
class Security
|
||||
{
|
||||
/**
|
||||
* Get security instance
|
||||
*/
|
||||
public static function instance(): \App\Core\Security
|
||||
{
|
||||
return app('security');
|
||||
}
|
||||
|
||||
/**
|
||||
* Generate CSRF token
|
||||
*/
|
||||
public static function generateCsrfToken(): string
|
||||
{
|
||||
return self::instance()->generateCsrfToken();
|
||||
}
|
||||
|
||||
/**
|
||||
* Verify CSRF token
|
||||
*/
|
||||
public static function verifyCsrfToken(string $token): bool
|
||||
{
|
||||
return self::instance()->verifyCsrfToken($token);
|
||||
}
|
||||
|
||||
/**
|
||||
* Sanitize string input
|
||||
*/
|
||||
public static function sanitizeString(string $input): string
|
||||
{
|
||||
return self::instance()->sanitizeString($input);
|
||||
}
|
||||
|
||||
/**
|
||||
* Encrypt data
|
||||
*/
|
||||
public static function encrypt(string $data): string
|
||||
{
|
||||
return self::instance()->encrypt($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* Decrypt data
|
||||
*/
|
||||
public static function decrypt(string $encryptedData): string
|
||||
{
|
||||
return self::instance()->decrypt($encryptedData);
|
||||
}
|
||||
|
||||
/**
|
||||
* Hash password
|
||||
*/
|
||||
public static function hashPassword(string $password): string
|
||||
{
|
||||
return self::instance()->hashPassword($password);
|
||||
}
|
||||
|
||||
/**
|
||||
* Verify password
|
||||
*/
|
||||
public static function verifyPassword(string $password, string $hash): bool
|
||||
{
|
||||
return self::instance()->verifyPassword($password, $hash);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user