-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
137 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,6 @@ | ||
builddir | ||
build | ||
*.lnk | ||
*.ico | ||
*.jpg | ||
generator.ps1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
# LNK File Builder | ||
Programmatically build a LNK file (shortcut file) that executes certain powershell script. Built mainly for spearphishing red-team engagement, with cpp and meson. | ||
|
||
> Disclaimer: | ||
> I, the creator of this program, has no responsibility for whatever you do with this tool. This tool was made solely for training and demonstration. Do anything at your own risk. | ||
## Building / Installation | ||
|
||
You can either build this tool from the source code with meson, or just simply downloading the precompiled binary. This tool currently only support 64 bit windows environment and I have no intention to support any other environment. | ||
|
||
### Building From Source | ||
Make sure you have meson installed, its easier to use meson rather than gcc or visual studio but you can choose anything you desire. | ||
|
||
``` | ||
git clone https://github.com/idfp/lnk-builder | ||
cd lnk-builder/ | ||
``` | ||
Build the project first before compiling it again with meson. | ||
``` | ||
meson build | ||
cd build | ||
meson compile | ||
``` | ||
If everything went smooth, you'll get an executable named `lnkbuilder.exe`. | ||
|
||
### Precompiled Binary | ||
I planned to put it in release page, for now just clone the repo and use `lnkbuilder.exe` in root folder of this project. | ||
|
||
``` | ||
git clone https://github.com/idfp/lnk-builder | ||
cd lnk-builder/ | ||
lnkbuilder.exe | ||
``` | ||
|
||
## Usage | ||
```ruby | ||
Usage: lnkbuilder.exe [Options] | ||
Options: | ||
--description / -d set description for lnk file. | ||
--payload / -p payload to be executed, must be powershell script. | ||
--file / -f get payload from ps1 file. | ||
--icon / -i icon to be used. | ||
--output / -o name of output files, should ends with .lnk | ||
|
||
Example: lnkbuilder.exe --payload "Start-Process notepad.exe" -o notepad.lnk | ||
``` |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters