You might try googling decryptedFommand. That should find you several posts going back some years.
This is malicious. Nobody would need to do this for any legitimate purpose.
The first few lines just find out stuff about your system. Then it decrypts (with openssl) a concealed command, which it then runs in the background using eval, with nohup, hiding all output, and removing the terminal you started it from.
One version of the commandArgs decrypted text downloads a MacOS .dmg (Disk Image File, similar to a .iso), installs it, and runs it. But this is a generic attack method -- the URL of the download can be changed to suit the hacker and the architecture. Also, the payload can be removed to prevent anybody finding out what it was they installed.
Only the last two commands do something real.
Put an echo in front of them to show what they do (instead of doing it), and remove the redirections to /dev/null!
If you try to save this code on the mac running AVG, the results are:
If you then google for this code, you will get:
"Bundlore" is an installer which bundles legitimate applications with offers for additional third party applications that may be unwanted by the user. Such third party applications are typically installed onto users’ computers by default, but may include an option to ‘opt-out’ during or after the installation process.