MacOS error code -8058
Most of these codes are defined in the MacErrors.h header file. It might be that you need Xcode installed to have that header file on your system, so you can look it up online here:

https://opensource.apple.com/source/CarbonHeaders/CarbonHeaders-18.1/MacErrors.h

It lists a huge number of error codes with a short explanation.

Some error codes are not defined in this header file, but instead in other, similar header files for various subsystems. For example AppKitErrors.h, FoundationErrors.h, CoreDataErrors.h, etc.

Unfortunately your error code -8058 is not defined in MacErrors.h.