I have a desktop application and its installer project produces two files in the Release
folder: let's call them setup.exe
and setup.msi
.
In the post build event I sign the setup.msi
with a self signed certificate. Then my final installation batch is composed of three steps
- Adding user store certificate with a
start.cmd
(orstart.exe
) - Running the
setup.exe
. Notice that the important thing is that it shows a user account control for a verified author with my name and surname. - Removing (with a
stop.cmd
orstop.exe
) the certificate at point 1 for security reasons/best practices since it is self signed
Now I'm perfectly fine with this solution, I only wished to include the commands 1 and 3 inside the setup.exe
if it was possible in a standard way.
What I have tried to do is to define the start.exe
and stop.exe
as custom actions. In that case I only have the two files setup.exe
and setup.msi
but unfortunately I get an unkown publisher. I guess it is obviously because the custom actions go inside the .msi
and not in the setup.exe
. But I'm not an expert of installer projects so someone might suggest a better and standard solution.
Alternative approach
Is that something that I could much more easily do by switching to Inno Setup and maybe as suggested in this comment?