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

Older version of setup tool and setuptool dist-info getting flagged by S360 and other scans #25682

Closed
ronitshaw1993 opened this issue Mar 4, 2023 · 9 comments · Fixed by #25703
Assignees
Labels
Azure CLI Team The command of the issue is owned by Azure CLI team Core CLI core infrastructure customer-reported Issues that are reported by GitHub users external to the Azure organization. question The issue doesn't require a change to the product in order to be resolved. Most issues start as that
Milestone

Comments

@ronitshaw1993
Copy link

ronitshaw1993 commented Mar 4, 2023

image

An older version of setup tools is installed in the latest release version of az cli == 2.45.0.
image

I have noticed that in dev the version is upgraded, but not sure when the release will happen.
image

### Our deployments are getting flagged. Let us know if there is a way around this before the next release as the setup tools inside the usr/lib/az is getting flagged, so installing an updated version overall is not helping.

@ghost ghost added the customer-reported Issues that are reported by GitHub users external to the Azure organization. label Mar 4, 2023
@yonzhan yonzhan added Core CLI core infrastructure Azure CLI Team The command of the issue is owned by Azure CLI team question The issue doesn't require a change to the product in order to be resolved. Most issues start as that labels Mar 4, 2023
@yonzhan yonzhan added this to the Backlog milestone Mar 4, 2023
@yonzhan
Copy link
Collaborator

yonzhan commented Mar 4, 2023

@bebound for awareness

@jiasli
Copy link
Member

jiasli commented Mar 6, 2023

Per my understanding, requirements.txt is only used azdev setup. @ronitshaw1993, are you using azdev setup in your pipelines?

@bebound
Copy link
Contributor

bebound commented Mar 6, 2023

We use default setuptools bundled with Python.
Workaround:
/opt/az/bin/python3 -m pip install -U setuptools

@ronitshaw1993
Copy link
Author

@jiasli
This is how I'm installing az cli in my mariner python3.9 base image.
image

@ronitshaw1993
Copy link
Author

@bebound I guess that needs to be updated.
As I'm not able to find the python bin specifically installed by az cli.

root [ / ]# find / -name python3.9
/usr/lib/python3.9
/usr/lib/az/lib/python3.9
/usr/bin/python3.9

This is the location /usr/lib/az/lib/python3.9 where S360 and other scans are flagging for vulnerability and an older version of setup tools exist.

Would be happy to go on a quick call as well.

@ronitshaw1993
Copy link
Author

image

@bebound
Copy link
Contributor

bebound commented Mar 7, 2023

PYTHONPATH="/lib64/az/lib/python3.9/site-packages" python3.9 -m pip install -U setuptools

On Mariner, CLI uses the standard python3.9 with a special PYTHONPATH.

@ronitshaw1993
Copy link
Author

PYTHONPATH="/lib64/az/lib/python3.9/site-packages" python3.9 -m pip install -U setuptools

On Mariner, CLI uses the standard python3.9 with a special PYTHONPATH.

Sure, thanks for the reply. This is helpful.

Any leads on when the next az cli release is planned for? With maybe the fix?

@bebound
Copy link
Contributor

bebound commented Mar 9, 2023

2.47 will be released on April 4.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Azure CLI Team The command of the issue is owned by Azure CLI team Core CLI core infrastructure customer-reported Issues that are reported by GitHub users external to the Azure organization. question The issue doesn't require a change to the product in order to be resolved. Most issues start as that
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants