Azure / Azure/azure-cli

Wrong api version used for enabling atp with the azure-cli on a storage account in China tenant

Open
#18,828 2 comments 0 reactions 0 assignees View on GitHub
act-codegen-extensibility-squad Security Service Attention
Dominant language
Python
Stars
4.6k
Forks
3.5k
Avg merge
3d 2h
Merged PRs (30d)
60

Description

### **This is autogenerated. Please review and update as needed.**

## Describe the bug
Wrong api version used for enabling atp with the azure-cli on a storage account in China tenant.

**Command Name**
`az security atp storage update`

**Errors:**
```
No registered resource provider found for location 'chinaeast2' and API version '2019-01-01' for type 'storageAccounts'. The supported api-versions are '2021-06-01, 2021-05-01, 2021-04-01, 2021-02-01, 2021-01-01, 2020-08-01-preview, 2019-06-01, 2019-04-01, 2018-11-01, 2018-07-01, 2018-03-01-preview, 2018-02-01, 2017-10-01, 2017-06-01, 2016-12-01, 2016-07-01, 2016-05-01, 2016-01-01, 2015-06-15, 2015-05-01-preview'. The supported locations are 'chinanorth, chinaeast, chinanorth2, chinaeast2'.

```

## To Reproduce:
Steps to reproduce the behavior. Note that argument values have been redacted, as they may contain sensitive information.

- Login to a subscription in a china tenant
- `az security atp storage update --is-enabled {} --resource-group {} --storage-account {}`

## Expected Behavior
Advanced threat protection is enabled on the specified storage account.

## Environment Summary
```
macOS-10.15.7-x86_64-i386-64bit
Python 3.8.11
Installer: HOMEBREW

azure-cli 2.26.0

Extensions:
azure-devops 0.18.0
support 1.0.2
account 0.2.1

```
## Additional Context

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.