Run whitesource/mend scan via CLI: error: 5001 - User is not allowed to perform this action

1.2k Views Asked by At

I have an access to the whitesource/mend server and I have installed & configured whithesource-CLI according to this documentation

Install ws

Configure: ws configure

Enter API URL, api key, user key, etc

When I run ws scan -u, I'm receiving the following error:

ws scan -u
Initializing:

error: 5001 - User is not allowed to perform this action

I've tried to update default product value in /path/to/.ws/config/settings.json and also tried different key/value pairs like product-key and product-token but still seeing same error as above

However, when I use the same user key and run scan via jar wss-unified-agent.jar command the scan run looks good

java -jar /path/to/wss-unified-agent.jar -apiKey xxxxx -userKey xxxxx -productToken xxxxx -c /path/to/wss-unified-agent.config

Could someone advise or help me troubleshoot further ?

1

There are 1 best solutions below

0
On

Go to Mend server -> Login with your user -> Go to Home -> User Profile -> There you have one section for User Keys, generate user key there and use that user key while running the scan.

This should resolve your issue.