Skip to content

mertyeter/dotnetkonf25

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

dotnetkonf25

This repository contains two main projects:

  • LlmAttackSimulator: A library for simulating and analyzing various attack scenarios against LLM-based applications.
  • LlmSecDemo: An ASP.NET Core demo application showcasing security best practices and attack detection for LLM-powered APIs.

Project Structure

dotnetkonf25.sln
src/
  LlmAttackSimulator/
    AttackScenario.cs
    AttackSimulator.cs
    IAttackSimulator.cs
    Program.cs
    ...
  LlmSecDemo/
    appsettings.json
    Program.cs
    Helpers/
    Interfaces/
    Middleware/
    Models/
    Services/
    logs/

Getting Started

Prerequisites

Build and Run

  1. Restore dependencies:

    dotnet restore
  2. Build the solution:

    dotnet build
  3. Run the demo application:

    dotnet run --project src/LlmSecDemo/LlmSecDemo.csproj
  4. The API will be available at http://localhost:5022.

API Endpoints

  • POST /api/login - Authenticate and receive a JWT token.
  • GET /api/account/profile - Get the authenticated user's profile.

Security Features

  • Attack detection and logging (e.g., SQL injection, XSS, SSRF, LFI, XXE, Command Injection)
  • Input validation and sanitization
  • JWT-based authentication

Logs

Application logs, including detected attacks, are stored in src/LlmSecDemo/logs/.

License

This project is licensed under the MIT License.


For more details, see the source code in each project directory.

About

No description, website, or topics provided.

Resources

License

Stars

4 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages