From 011d86417d9cfa829facfd240e17feb438928f96 Mon Sep 17 00:00:00 2001
From: Cy Okeke <cokeke@bitwarden.com>
Date: Wed, 12 Mar 2025 10:21:32 +0100
Subject: [PATCH] Add the phishing domain controller

---
 .../Controllers/PhishingDomainsController.cs    | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)
 create mode 100644 src/Api/Controllers/PhishingDomainsController.cs

diff --git a/src/Api/Controllers/PhishingDomainsController.cs b/src/Api/Controllers/PhishingDomainsController.cs
new file mode 100644
index 0000000000..433db97ccc
--- /dev/null
+++ b/src/Api/Controllers/PhishingDomainsController.cs
@@ -0,0 +1,17 @@
+using Bit.Core.Repositories;
+using Microsoft.AspNetCore.Authorization;
+using Microsoft.AspNetCore.Mvc;
+
+namespace Bit.Api.Controllers;
+
+[Route("phishing-domains")]
+[Authorize("Application")]
+public class PhishingDomainsController(IPhishingDomainRepository phishingDomainRepository) : Controller
+{
+    [HttpGet]
+    public async Task<ActionResult<ICollection<string>>> GetPhishingDomainsAsync()
+    {
+        var domains = await phishingDomainRepository.GetActivePhishingDomainsAsync();
+        return Ok(domains);
+    }
+}