Skip to content
This repository was archived by the owner on Jan 15, 2025. It is now read-only.

[#174469249] no false positives for connection string syntax#2

Open
pp-ps wants to merge 1 commit into
masterfrom
174469249-azure-connection-string
Open

[#174469249] no false positives for connection string syntax#2
pp-ps wants to merge 1 commit into
masterfrom
174469249-azure-connection-string

Conversation

@pp-ps

@pp-ps pp-ps commented Aug 31, 2020

Copy link
Copy Markdown
Contributor

No description provided.

@pp-ps pp-ps requested a review from balanza August 31, 2020 08:17
@balanza balanza changed the title no false positives for connection string syntax [#174469249] no false positives for connection string syntax Sep 7, 2020
Comment thread providers/commons
# Azure Storage Account Access Key (so far they have this format)
# alternatively we can grep for endpoint suffixes like core.windows.net
[A-Za-z0-9+\/]{86}==
AccountKey=[A-Za-z0-9+\/=]{88};

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this weakens the test a lot. Consider the following environment config:

COSMOSDB_KEY=TEST3bpK0eC/LMP8FtweEFJysEPJZe4sVJX0zQla3ec/MNUFKklsyW3GrTwoJ3EbXnneSzS3ghwz6czDXYqxeU==
COSMOSDB_NAME=dbname
CUSTOMCONNSTR_COSMOSDB_KEY=AccountEndpoint=$COSMOSDB_URI;AccountKey=$COSMOSDB_KEY;

The new regex doesn't catch it although this is valid code (actually, that's my own configuration 😬 ).

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants