Click here to Skip to main content
15,886,963 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more:
I have no any idea on creating a gui program that locks an exe file with given password by user, and when user tries to open that exe app, a form should appear and ask for the password to open that exe app for user, no matter the exe file's name or location changes, it should be always locked. The analogy of that gui program is here ExeLock - Lock & Password Protect any Program on Your PC[^]

Please help me!

What I have tried:

I've asked for it from the software engineers who work at Google, Facebook. But they could not provide me, the exact guidance to build that kind of gui program. As far as I know it requires so much significant knowledge to do that
Posted
Updated 28-Feb-24 22:25pm
Comments
PIEBALDconsult 29-Feb-24 11:17am    
What if I copy/rename the EXE?
It seems to be an impossible goal. Not worth worrying about.
The EXE would have to protect itself; I see no other way.

Or, are you actually trying to push ExeLock because you wrote it and think it's great? It probably truly is kaka.

If you have no experience of creating such a program then it would probably take many months to create your own version. And since the Exelock program already offers this feature, I suggest you use that.
 
Share this answer
 
From the context, I understand that we are talking about Windows EXE programs that are to be protected with a password regardless of their location and computer.

This would result in the following requirements:
1. creating password protection for Windows EXE-programs with a GUI-based program

Some questions arise that are not yet clear:
- Where should the password be stored?
- Should the password be changeable?
- Should both 32 and 64 bit programs be protected?

2. when the protected program is started, a GUI-based form should be displayed that only allows the program to be started if the correct password has been entered.

One possibility would be to convert the exe file into hex code with a tool and to start this image in a launcher via system calls.

So you need at least one program that contains the launcher and the image and queries and checks the password. A second GUI program that conveniently automates the creation of the starter would be nice for reasons of convenience, but is not necessary for the time being.

A technical solution for a launcher was mentioned here, for example:
https://www.codeproject.com/Answers/5377359/Problems-with-converting-runpe-Cplusplus-to-vb6
(or in the original: https://github.com/Zer0Mem0ry/RunPE/blob/master/RunPE.cpp)
The function RunPortableExecutable() realizes the start of an exe file converted into hex code.

Note: If you store the password in the starter, you would have to protect it and it would be difficult to change.

An interesting project, but as Richard has already indicated, it requires some knowledge and time.

For the implementation of the (two) GUI programs, the free community edition of Visual-Studio or any C or C++ compiler that can generate a Windows program with WinMain() would suffice.
 
Share this answer
 
v2
Comments
Uzbek Tv yangiliklari 4-Mar-24 7:39am    
What kind of knowledge and experience do i need to do that?
merano99 4-Mar-24 17:58pm    
Successful implementation would require good C or C++ knowledge and an understanding of Windows system calls. In other words, knowledge of how to connect an input field and the proposed function to the required program.
To implement that you need to have the base program which performs an encryption your exe with the given password and create primary executable - let's call this application "Creator". In this application you specify the password and select an exe file to create the resulted exe. Another program which we call "Host" will be executed at start instead of encrypted program, it just popup the window for the entering password and use that password to decrypt the primary executable and then start it as the new process. The encrypted data can be stored as extra data as the tail of the Host application, as this application has always the same size it knows the start reading position of itself from the disk. The host application can be stored in the Creator resources and used from there to create protected executable - just read it from there write to the resulted file and then append the encrypted tail.
That is the basic implementation it is possible to have many extra things to make it more complex, but what I mention is enough to start coding :)

Regards,
Maxim
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900