Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Azure Storage Key Detector plugin #359

Merged
merged 4 commits into from
Nov 12, 2020
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions tests/plugins/azure_storage_key_test.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
import pytest

from detect_secrets.plugins.azure_storage_key import AzureStorageKeyDetector


class AzureStorageKeyDetector:

@pytest.mark.parametrize(
'payload, should_flag',
[
(
'AccountKey=lJzRc1YdHaAA2KCNJJ1tkYwF/+mKK6Ygw0NGe170Xu592euJv2wYUtBlV8z+qnlcNQSnIYVTkLWntUO1F8j8rQ==',
True,
),
],
)
def test_analyze(self, payload, should_flag):
logic = AzureStorageKeyDetector()
output = logic.analyze_line(payload, 1, 'mock_filename')
DariuszPorowski marked this conversation as resolved.
Show resolved Hide resolved
assert output