diff --git a/.gitignore b/.gitignore
index 8fdb9ae..01e899a 100644
--- a/.gitignore
+++ b/.gitignore
@@ -54,4 +54,6 @@ TestResult.xml
nunit-*.xml
# DB
-*.db
\ No newline at end of file
+*.db
+
+appsettings.json
\ No newline at end of file
diff --git a/.idea/.idea.Abyss/.idea/workspace.xml b/.idea/.idea.Abyss/.idea/workspace.xml
index 76d8d2c..f586bdd 100644
--- a/.idea/.idea.Abyss/.idea/workspace.xml
+++ b/.idea/.idea.Abyss/.idea/workspace.xml
@@ -10,18 +10,10 @@
-
-
-
-
-
-
-
-
-
-
-
+
+
+
@@ -51,6 +43,7 @@
+
{
"associatedIndex": 3
}
@@ -65,6 +58,8 @@
".NET Project.AbyssCli.executor": "Run",
"ASKED_SHARE_PROJECT_CONFIGURATION_FILES": "true",
"ModuleVcsDetector.initialDetectionPerformed": "true",
+ "Publish to folder.Publish Abyss to folder x86.executor": "Run",
+ "Publish to folder.Publish Abyss to folder.executor": "Run",
"RunOnceActivity.ShowReadmeOnStart": "true",
"RunOnceActivity.TerminalTabsStorage.copyFrom.TerminalArrangementManager.252": "true",
"RunOnceActivity.git.unshallow": "true",
@@ -81,6 +76,22 @@
}
}]]>
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -146,13 +157,16 @@
1755877836092
-
+
+
+
+
diff --git a/Abyss/Components/Controllers/Media/VideoController.cs b/Abyss/Components/Controllers/Media/VideoController.cs
index fe44dff..13cc10b 100644
--- a/Abyss/Components/Controllers/Media/VideoController.cs
+++ b/Abyss/Components/Controllers/Media/VideoController.cs
@@ -90,5 +90,16 @@ public class VideoController(ILogger logger, ResourceService rs
return PhysicalFile(d, "video/mp4", enableRangeProcessing: true);
}
+ [HttpGet("{klass}/{id}/nv")]
+ public async Task Nv(string klass, string id, string token)
+ {
+ var d = Helpers.SafePathCombine(VideoFolder, [klass, id, "video.a.mp4"]);
+ if (d == null) return StatusCode(403, new { message = "403 Denied" });
+
+ var r = await rs.Get(d, token, Ip);
+ if (!r) return StatusCode(403, new { message = "403 Denied" });
+ return PhysicalFile(d, "video/mp4", enableRangeProcessing: true);
+ }
+
private string Ip => HttpContext.Connection.RemoteIpAddress?.ToString() ?? "127.0.0.1";
}
\ No newline at end of file
diff --git a/Abyss/Program.cs b/Abyss/Program.cs
index cb80f89..01d9fcc 100644
--- a/Abyss/Program.cs
+++ b/Abyss/Program.cs
@@ -45,7 +45,7 @@ public class Program
app.MapOpenApi();
}
- // app.UseHttpsRedirection();
+ app.UseHttpsRedirection();
app.UseAuthorization();
app.MapStaticAssets();
diff --git a/Abyss/appsettings.json b/Abyss/appsettings.json
deleted file mode 100644
index 10f68b8..0000000
--- a/Abyss/appsettings.json
+++ /dev/null
@@ -1,9 +0,0 @@
-{
- "Logging": {
- "LogLevel": {
- "Default": "Information",
- "Microsoft.AspNetCore": "Warning"
- }
- },
- "AllowedHosts": "*"
-}