mirror of
https://github.com/whoswhip/Sharpbin.git
synced 2026-12-05 18:48:41 +00:00
fix: multiple vulnerabilities
This commit is contained in:
@@ -276,7 +276,9 @@ namespace SharpbinV3.Server
|
||||
|
||||
builder.Services.AddCors(o =>
|
||||
{
|
||||
o.AddDefaultPolicy(p => p.WithOrigins("http://localhost:5173").AllowAnyHeader().AllowAnyMethod());
|
||||
var allowedOrigins =
|
||||
builder.Configuration.GetSection(nameof(AppSettings.AllowedCorsOrigins)).Get<string[]>() ?? ["http://localhost:5173"];
|
||||
o.AddDefaultPolicy(p => p.WithOrigins(allowedOrigins).AllowAnyHeader().AllowAnyMethod());
|
||||
});
|
||||
|
||||
builder
|
||||
|
||||
Reference in New Issue
Block a user