i still have the problem that i want to parse and create windows shortcuts (.lnk). I know it gives one Library for that problem https://github.com/forensicmatt/RustyLnk but this Library only export to json and i have problems to read the code. I cannot snip the code that reads lnks byte for byte.
At the moment i use an wrapper for an PowerShell Script that uses:
$shell = New-Object -comObject WScript.Shell; $lnk = $shell.CreateShortcut($shortcut); $lnk.TargetPath = "$commandName"; $lnk.Arguments = "-start"; $lnk.IconLocation = $app.Icon; $lnk.Save();
I give an cmd the parameters and this command bypass the policy and take the parametes to this PowerShell Script. Creepy but functional:).
But i want a pure rust solution for that problem.
My first question, can i use/access the com-object in rust that i can replicate the powershell script in rust?
Knows anybody a page where i have an doc about windows shortcuts,lnks? And what’s the best way to go for my problem in pure rust, is it possible in pure rust?