/
fr1n1ss
/
PasswordManager
Обзор
Документация
Войти
/
fr1n1ss
/
PasswordManager
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
PasswordManagerAPI/Entities/AuditLog.cs
24 строки
747 B
Dmitry Kiselyov
expanded security settings, sessions, audit logs, and dev network access
11 апр 2026, 16:17
11 апр 2026, 16:17
a9bd710
Код
Авторство
О чём код?
using Microsoft.EntityFrameworkCore; using System.ComponentModel.DataAnnotations; namespace PasswordManagerAPI.Entities { [PrimaryKey(nameof(Id))] [Index(nameof(UserId), nameof(CreatedAt))] public class AuditLog { public long Id { get; set; } public int? UserId { get; set; } public Guid? SessionId { get; set; } [Required] [MaxLength(100)] public string Action { get; set; } = string.Empty; [MaxLength(2000)] public string? Details { get; set; } [MaxLength(128)] public string? IpAddress { get; set; } [MaxLength(512)] public string? UserAgent { get; set; } public DateTime CreatedAt { get; set; } = DateTime.UtcNow; } }