This is the initial commit for the CODEX_ADK project, a full-stack AI agent management platform featuring: BACKEND (ASP.NET Core 8.0): - CQRS architecture with 6 commands and 7 queries - 16 API endpoints (all working and tested) - PostgreSQL database with 5 entities - AES-256 encryption for API keys - FluentValidation on all commands - Rate limiting and CORS configured - OpenAPI/Swagger documentation - Docker Compose setup (PostgreSQL + Ollama) FRONTEND (Flutter 3.x): - Dark theme with Svrnty branding - Collapsible sidebar navigation - CQRS API client with Result<T> error handling - Type-safe endpoints from OpenAPI schema - Multi-platform support (Web, iOS, Android, macOS, Linux, Windows) DOCUMENTATION: - Comprehensive API reference - Architecture documentation - Development guidelines for Claude Code - API integration guides - context-claude.md project overview Status: Backend ready (Grade A-), Frontend integration pending 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
25 lines
938 B
C#
25 lines
938 B
C#
namespace Codex.Dal.Services;
|
|
|
|
/// <summary>
|
|
/// Service for encrypting and decrypting sensitive data (API keys, tokens, etc.).
|
|
/// Uses AES-256 encryption with random IVs for security.
|
|
/// </summary>
|
|
public interface IEncryptionService
|
|
{
|
|
/// <summary>
|
|
/// Encrypts plain text using AES-256 encryption.
|
|
/// The IV is randomly generated and prepended to the ciphertext.
|
|
/// </summary>
|
|
/// <param name="plainText">The text to encrypt</param>
|
|
/// <returns>Base64-encoded encrypted data (IV + ciphertext)</returns>
|
|
string Encrypt(string plainText);
|
|
|
|
/// <summary>
|
|
/// Decrypts encrypted text that was encrypted using the Encrypt method.
|
|
/// Extracts the IV from the beginning of the encrypted data.
|
|
/// </summary>
|
|
/// <param name="encryptedText">Base64-encoded encrypted data (IV + ciphertext)</param>
|
|
/// <returns>Decrypted plain text</returns>
|
|
string Decrypt(string encryptedText);
|
|
}
|