As mentioned here, myth doesn't know what
@openzeppelin is and you have to map this to explicit path to the imported contract.
You need to specify path to
@openzeppelin contracts is presented to help myth replace
@openzeppelin string with original path and find them.
To do that you can create
.json file with remappings (e.g. in project root) with such content:
"remappings": [ "@openzeppelin/=/share/node_modules/@openzeppelin/" ]
*In my case absolut path starts with
/share/... as I use docker volume.
Add this file path as option
--solc-json /path/to/remappings/file.json to
Final command using docker looks like:
docker run -it -v $(pwd):/share mythril/myth analyze /share/Contract.sol --solc-json /share/remappings.json
(I runned docker container from project directory, but should works in your case too)
Final command without docker is almost the same:
myth analyze /path/to/Contract.sol --solc-json /path/to/remappings.json