Skip to content

Cannot show attestation policy #4120

Closed
Closed

Description

@michael2m

Describe the bug

Command Name
az attestation policy show Extension Name: attestation. Version: 0.2.0.

Errors:

The command failed with an unexpected error. Here is the traceback:
It is required that you pass in a value for the "algorithms" argument when calling decode().
Traceback (most recent call last):
  File "/usr/local/Cellar/azure-cli/2.30.0_1/libexec/lib/python3.10/site-packages/knack/cli.py", line 231, in invoke
    cmd_result = self.invocation.execute(args)
  File "/usr/local/Cellar/azure-cli/2.30.0_1/libexec/lib/python3.10/site-packages/azure/cli/core/commands/__init__.py", line 657, in execute
    raise ex
  File "/usr/local/Cellar/azure-cli/2.30.0_1/libexec/lib/python3.10/site-packages/azure/cli/core/commands/__init__.py", line 720, in _run_jobs_serially
    results.append(self._run_job(expanded_arg, cmd_copy))
  File "/usr/local/Cellar/azure-cli/2.30.0_1/libexec/lib/python3.10/site-packages/azure/cli/core/commands/__init__.py", line 691, in _run_job
    result = cmd_copy(params)
  File "/usr/local/Cellar/azure-cli/2.30.0_1/libexec/lib/python3.10/site-packages/azure/cli/core/commands/__init__.py", line 328, in __call__
    return self.handler(*args, **kwargs)
  File "/usr/local/Cellar/azure-cli/2.30.0_1/libexec/lib/python3.10/site-packages/azure/cli/core/commands/command_operation.py", line 363, in handler
    show_exception_handler(ex)
  File "/usr/local/Cellar/azure-cli/2.30.0_1/libexec/lib/python3.10/site-packages/azure/cli/core/commands/arm.py", line 429, in show_exception_handler
    raise ex
  File "/usr/local/Cellar/azure-cli/2.30.0_1/libexec/lib/python3.10/site-packages/azure/cli/core/commands/command_operation.py", line 361, in handler
    return op(**command_args)
  File "/Users/michaelmeijer/.azure/cliextensions/attestation/azext_attestation/manual/custom.py", line 191, in get_policy
    policy = jwt.decode(token, verify=False).get('x-ms-policy', '')
  File "/usr/local/Cellar/azure-cli/2.30.0_1/libexec/lib/python3.10/site-packages/jwt/api_jwt.py", line 119, in decode
    decoded = self.decode_complete(jwt, key, algorithms, options, **kwargs)
  File "/usr/local/Cellar/azure-cli/2.30.0_1/libexec/lib/python3.10/site-packages/jwt/api_jwt.py", line 86, in decode_complete
    raise DecodeError(
jwt.exceptions.DecodeError: It is required that you pass in a value for the "algorithms" argument when calling decode().

To Reproduce:

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

  • Put any pre-requisite steps here...
  • az attestation policy show -g {} -n {} --attestation-type SGX-IntelSDK

Expected Behavior

Environment Summary

macOS-12.0.1-x86_64-i386-64bit, Darwin 21.1.0
Python 3.10.0
Installer: HOMEBREW

azure-cli 2.30.0

Extensions:
attestation 0.2.0

Additional Context

Activity

  1. ghost added
    needs-triageThis is a new issue that needs to be triaged to the appropriate team.
    on Nov 17, 2021
  2. ghost added
    questionThe issue doesn't require a change to the product in order to be resolved. Most issues start as that
    on Nov 17, 2021
  3. ghost added
    customer-reportedIssues that are reported by GitHub users external to the Azure organization.
    on Nov 17, 2021
  4. ghost removed
    needs-triageThis is a new issue that needs to be triaged to the appropriate team.
    on Nov 17, 2021
  5. removed
    questionThe issue doesn't require a change to the product in order to be resolved. Most issues start as that
    on Nov 17, 2021
  6. yonzhan commented on Nov 17, 2021

    @yonzhan
    Collaborator

    route to service team

  7. added a commit that references this issue on Jul 7, 2022
  8. jsntcy commented on Jul 12, 2022

    @jsntcy
    Member

    Michael2M (@michael2m), please upgrade to 0.2.1 to see this issue is resolved.

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

Metadata

Metadata

Labels

AttestationService AttentionThis issue is responsible by Azure service team.customer-reportedIssues that are reported by GitHub users external to the Azure organization.

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions