mirror of
https://github.com/bitwarden/server
synced 2025-12-18 09:13:19 +00:00
set cors policies to only allow web vault origin (#787)
* set cors policy to only allow web vault * vault cors policy service
This commit is contained in:
@@ -102,7 +102,7 @@ namespace Bit.Notifications
|
||||
app.UseRouting();
|
||||
|
||||
// Add Cors
|
||||
app.UseCors(policy => policy.SetIsOriginAllowed(h => true)
|
||||
app.UseCors(policy => policy.SetIsOriginAllowed(o => o == globalSettings.BaseServiceUri.Vault)
|
||||
.AllowAnyMethod().AllowAnyHeader().AllowCredentials());
|
||||
|
||||
// Add authentication to the request pipeline.
|
||||
|
||||
Reference in New Issue
Block a user