Shelling to EXE not named EXE
Author |
Message |
Rick Raisle #1 / 10
|
 Shelling to EXE not named EXE
In order to help prevent my users from finding an EXE and running it, when I instead want them to run another EXE first, I've found that I can make a Starter.exe, which shortcuts point to, and then have it Shell and run another program, named MainProgram, which is an exe, but /without/ the .exe extension. We're using WindowsXP, and this normally runs without a hitch. On one PC, though, errors were produced. Experimenting, I found that naming the program back to MainProgram.exe, and shelling to that name instead, fixed the error. I found it a bit funny (but useful) that VB can Shell out to run an EXE that Windows will not run directly (without the .exe). I now find it funnier that while this usually works, it sometimes does not, on apparently very similar PCs. Has anyone else had experience in shelling to an EXE that does not have the .exe extension? If so, what were your experiences? Do you think this will vary from OS to OS? -- Regards, Rick Raisley heavymetal-A-T-bellsouth-D-O-T-net
|
Sun, 29 May 2011 23:22:26 GMT |
|
 |
Jim Mac #2 / 10
|
 Shelling to EXE not named EXE
Quote:
> In order to help prevent my users from finding an EXE and running > it, when I instead want them to run another EXE first, I've found > that I can make a Starter.exe, which shortcuts point to, and then > have it Shell and run another program, named MainProgram, which is > an exe, but /without/ the .exe extension. We're using WindowsXP, > and this normally runs without a hitch. On one PC, though, errors > were produced. Experimenting, I found that naming the program back > to MainProgram.exe, and shelling to that name instead, fixed the > error. > I found it a bit funny (but useful) that VB can Shell out to run an > EXE that Windows will not run directly (without the .exe). I now > find it funnier that while this usually works, it sometimes does > not, on apparently very similar PCs. > Has anyone else had experience in shelling to an EXE that does not > have the .exe extension? If so, what were your experiences? Do you > think this will vary from OS to OS?
Show some code. -- Jim
|
Sun, 29 May 2011 23:54:24 GMT |
|
 |
Kevin Provanc #3 / 10
|
 Shelling to EXE not named EXE
In short, I don't do it as it's more trouble than it's worth.
| In order to help prevent my users from finding an EXE and running it, when I | instead want them to run another EXE first, I've found that I can make a | Starter.exe, which shortcuts point to, and then have it Shell and run | another program, named MainProgram, which is an exe, but /without/ the .exe | extension. We're using WindowsXP, and this normally runs without a hitch. On | one PC, though, errors were produced. Experimenting, I found that naming the | program back to MainProgram.exe, and shelling to that name instead, fixed | the error. | | I found it a bit funny (but useful) that VB can Shell out to run an EXE that | Windows will not run directly (without the .exe). I now find it funnier that | while this usually works, it sometimes does not, on apparently very similar | PCs. | | Has anyone else had experience in shelling to an EXE that does not have the | .exe extension? If so, what were your experiences? Do you think this will | vary from OS to OS? | | -- | Regards, | | Rick Raisley | heavymetal-A-T-bellsouth-D-O-T-net | |
|
Mon, 30 May 2011 00:17:44 GMT |
|
 |
Eduard #4 / 10
|
 Shelling to EXE not named EXE
You could place all the auxiliary exe's without changing their extensions in a folder, for example named bin, and leave only the main exe in the main folder. Besides that, you could shell the auxiliary exe's with a command line parameter, for example 1. Then, if the parameter is missing it is because the user has run it from the Windows Explorer, then exit that program. "Rick Raisley" <heavymetal-A-T-bellsouth-D-O-Tnet> escribi en el mensaje
Quote: > In order to help prevent my users from finding an EXE and running it, when > I instead want them to run another EXE first, I've found that I can make a > Starter.exe, which shortcuts point to, and then have it Shell and run > another program, named MainProgram, which is an exe, but /without/ the > .exe extension. We're using WindowsXP, and this normally runs without a > hitch. On one PC, though, errors were produced. Experimenting, I found > that naming the program back to MainProgram.exe, and shelling to that name > instead, fixed the error. > I found it a bit funny (but useful) that VB can Shell out to run an EXE > that Windows will not run directly (without the .exe). I now find it > funnier that while this usually works, it sometimes does not, on > apparently very similar PCs. > Has anyone else had experience in shelling to an EXE that does not have > the .exe extension? If so, what were your experiences? Do you think this > will vary from OS to OS? > -- > Regards, > Rick Raisley > heavymetal-A-T-bellsouth-D-O-T-net
|
Mon, 30 May 2011 00:26:12 GMT |
|
 |
Norm #5 / 10
|
 Shelling to EXE not named EXE
Rick, I do something similar, but right before running I copy the program and rename the copy with the exe extension and when finished running, I delete the copy. This avoids the exe problem, but does not leave a copy for anyone else to run. Norm Quote:
> You could place all the auxiliary exe's without changing their extensions in > a folder, for example named bin, and leave only the main exe in the main > folder. > Besides that, you could shell the auxiliary exe's with a command line > parameter, for example 1. Then, if the parameter is missing it is because > the user has run it from the Windows Explorer, then exit that program. > "Rick Raisley" <heavymetal-A-T-bellsouth-D-O-Tnet> escribi en el mensaje
> > In order to help prevent my users from finding an EXE and running it, when > > I instead want them to run another EXE first, I've found that I can make a > > Starter.exe, which shortcuts point to, and then have it Shell and run > > another program, named MainProgram, which is an exe, but /without/ the > > .exe extension. We're using WindowsXP, and this normally runs without a > > hitch. On one PC, though, errors were produced. Experimenting, I found > > that naming the program back to MainProgram.exe, and shelling to that name > > instead, fixed the error. > > I found it a bit funny (but useful) that VB can Shell out to run an EXE > > that Windows will not run directly (without the .exe). I now find it > > funnier that while this usually works, it sometimes does not, on > > apparently very similar PCs. > > Has anyone else had experience in shelling to an EXE that does not have > > the .exe extension? If so, what were your experiences? Do you think this > > will vary from OS to OS? > > -- > > Regards, > > Rick Raisley > > heavymetal-A-T-bellsouth-D-O-T-net
|
Mon, 30 May 2011 02:55:22 GMT |
|
 |
Tinke #6 / 10
|
 Shelling to EXE not named EXE
If you wish to hide something away out of sight, these words of wisdom from Kevin on alternate data streams last year seem most useful Quote:
> http://www.microsoft.com/technet/sysinternals/FileAndDisk/Streams.mspx > My favourite way to hide data on my box when I don't want things to be > found. I also use it for tagging extra info to a file for one of my > programs. It's worked out quite well so far.
Regards Tinker
Quote: > In order to help prevent my users from finding an EXE and running it, when > I instead want them to run another EXE first, I've found that I can make a > Starter.exe, which shortcuts point to, and then have it Shell and run > another program, named MainProgram, which is an exe, but /without/ the > .exe extension. We're using WindowsXP, and this normally runs without a > hitch. On one PC, though, errors were produced. Experimenting, I found > that naming the program back to MainProgram.exe, and shelling to that name > instead, fixed the error. > I found it a bit funny (but useful) that VB can Shell out to run an EXE > that Windows will not run directly (without the .exe). I now find it > funnier that while this usually works, it sometimes does not, on > apparently very similar PCs. > Has anyone else had experience in shelling to an EXE that does not have > the .exe extension? If so, what were your experiences? Do you think this > will vary from OS to OS? > -- > Regards, > Rick Raisley > heavymetal-A-T-bellsouth-D-O-T-net
|
Mon, 30 May 2011 04:07:24 GMT |
|
 |
expv #7 / 10
|
 Shelling to EXE not named EXE
Quote:
> You could place all the auxiliary exe's without changing their extensions > in a folder, for example named bin, and leave only the main exe in the > main folder. > Besides that, you could shell the auxiliary exe's with a command line > parameter, for example 1. Then, if the parameter is missing it is because > the user has run it from the Windows Explorer, then exit that program.
Add my vote for the command line approach, and it's easy to implement: Public Sub Main() If LCase(Command()) = "/doit" Then Form1.Show End if End Sub
|
Mon, 30 May 2011 04:08:54 GMT |
|
 |
Kevin Provanc #8 / 10
|
 Shelling to EXE not named EXE
If you really want to be crafty, run your exe from a stream of the system32 folder. That's how the last wanna be hacker putz tried to get me. <eg>
| In order to help prevent my users from finding an EXE and running it, when I | instead want them to run another EXE first, I've found that I can make a | Starter.exe, which shortcuts point to, and then have it Shell and run | another program, named MainProgram, which is an exe, but /without/ the .exe | extension. We're using WindowsXP, and this normally runs without a hitch. On | one PC, though, errors were produced. Experimenting, I found that naming the | program back to MainProgram.exe, and shelling to that name instead, fixed | the error. | | I found it a bit funny (but useful) that VB can Shell out to run an EXE that | Windows will not run directly (without the .exe). I now find it funnier that | while this usually works, it sometimes does not, on apparently very similar | PCs. | | Has anyone else had experience in shelling to an EXE that does not have the | .exe extension? If so, what were your experiences? Do you think this will | vary from OS to OS? | | -- | Regards, | | Rick Raisley | heavymetal-A-T-bellsouth-D-O-T-net | |
|
Mon, 30 May 2011 04:18:38 GMT |
|
 |
Rick Raisle #9 / 10
|
 Shelling to EXE not named EXE
I appreciate everyone's ideas about how to get around the problem (like using a parameter to run the main program, that if absent, simply exits). But I was mostly interested in if anyone had experienced, or knew of, any problems associated with running program files that did not have the EXE extensions. Naturally, their icons are not shown in Windows Explorer, but I wouldn't have expected any problems running them (once I found out that Shell would actually run them without a complaint). But having seen at least a couple problems, attributable completely to the program the Shell called NOT having an .exe extension, has made me step back from it. -- Regards, Rick Raisley heavymetal-A-T-bellsouth-D-O-T-net
Quote: > In order to help prevent my users from finding an EXE and running it, when > I instead want them to run another EXE first, I've found that I can make a > Starter.exe, which shortcuts point to, and then have it Shell and run > another program, named MainProgram, which is an exe, but /without/ the > .exe extension. We're using WindowsXP, and this normally runs without a > hitch. On one PC, though, errors were produced. Experimenting, I found > that naming the program back to MainProgram.exe, and shelling to that name > instead, fixed the error. > I found it a bit funny (but useful) that VB can Shell out to run an EXE > that Windows will not run directly (without the .exe). I now find it > funnier that while this usually works, it sometimes does not, on > apparently very similar PCs. > Has anyone else had experience in shelling to an EXE that does not have > the .exe extension? If so, what were your experiences? Do you think this > will vary from OS to OS? > -- > Regards, > Rick Raisley > heavymetal-A-T-bellsouth-D-O-T-net
|
Mon, 30 May 2011 05:09:12 GMT |
|
 |
Karl E. Peterso #10 / 10
|
 Shelling to EXE not named EXE
Quote:
> But I was mostly interested in if anyone had experienced, or knew of, any > problems associated with running program files that did not have the EXE > extensions. Naturally, their icons are not shown in Windows Explorer, but I > wouldn't have expected any problems running them (once I found out that > Shell would actually run them without a complaint). But having seen at least > a couple problems, attributable completely to the program the Shell called > NOT having an .exe extension, has made me step back from it.
Probably a smart move. To me, this is one of those, "Huh, shoulda known", things. Sounds like someone set a security setting somewhere that limits what extensions Windows should consider to be executable. I can actually empathize a bit with this urge, unlike many net.nazi control efforts. -- .NET: It's About Trust! http://vfred.mvps.org
|
Mon, 30 May 2011 05:22:27 GMT |
|
|
|