mirror of
https://github.com/Azure/cosmos-explorer.git
synced 2025-12-20 09:20:16 +00:00
Users/bogercraig/endpointvalidation (#1554)
* Adding example endpoint with trailing forward slash. * Move backend and ARM endpoint validation to configContext for initialization from config.json. * Added debugging script and attempts to relocate endpoint validation list. * Move default endpoint list to endpoint validation code and allow falling back to the default list during unit tests if configContext is not initialized. * Remove leftover debugger statements. * Remove test debug script in package.json for debugging unit tests in browser. * Run prettier on modified files. * Overwriting with package.json from master. * Overwriting with version from master. * Remove test ARM endpoint. * Replace ternary operator with || for more concise arguments per Victor's feedback. --------- Co-authored-by: Craig Boger <craig.boger@microsoft.com>
This commit is contained in:
@@ -38,7 +38,7 @@ function validateEndpointInternal(
|
||||
return valid;
|
||||
}
|
||||
|
||||
export const allowedArmEndpoints: ReadonlyArray<string> = [
|
||||
export const defaultAllowedArmEndpoints: ReadonlyArray<string> = [
|
||||
"https://management.azure.com",
|
||||
"https://management.usgovcloudapi.net",
|
||||
"https://management.chinacloudapi.cn",
|
||||
@@ -46,7 +46,7 @@ export const allowedArmEndpoints: ReadonlyArray<string> = [
|
||||
|
||||
export const allowedAadEndpoints: ReadonlyArray<string> = ["https://login.microsoftonline.com/"];
|
||||
|
||||
export const allowedBackendEndpoints: ReadonlyArray<string> = [
|
||||
export const defaultAllowedBackendEndpoints: ReadonlyArray<string> = [
|
||||
"https://main.documentdb.ext.azure.com",
|
||||
"https://main.documentdb.ext.azure.cn",
|
||||
"https://main.documentdb.ext.azure.us",
|
||||
|
||||
Reference in New Issue
Block a user