forked from flipperdevices/flipperzero-firmware
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[FL-3037, FL-3038, FL-3039] File format docs: RFID, iButton, BadUSB (f…
…lipperdevices#2177) Co-authored-by: あく <[email protected]>
- Loading branch information
Showing
3 changed files
with
166 additions
and
0 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 |
---|---|---|
@@ -0,0 +1,92 @@ | ||
# Command syntax | ||
BadUsb app uses extended Duckyscript syntax. It is compatible with classic USB Rubber Ducky 1.0 scripts, but provides some additional commands and features, such as custom USB ID, ALT+Numpad input method, SYSRQ command and more fuctional keys. | ||
# Script file format | ||
BadUsb app can execute only text scrips from .txt files, no compilation is required. Both `\n` and `\r\n` line endings are supported. Empty lines are allowed. You can use spaces ore tabs for line indentation. | ||
# Command set | ||
## Comment line | ||
Just a single comment line. All text after REM command will be ignored by interpreter | ||
|Command|Parameters|Notes| | ||
|-|-|-| | ||
|REM|Comment text|| | ||
|
||
## Delay | ||
Pause script execution by defined time | ||
|Command|Parameters|Notes| | ||
|-|-|-| | ||
|DELAY|Delay value in ms|Single delay| | ||
|DEFAULT_DELAY|Delay value in ms|Add delay before every next command| | ||
|DEFAULTDELAY|Delay value in ms|Same as DEFAULT_DELAY| | ||
|
||
## Special keys | ||
|Command|Notes| | ||
|-|-| | ||
|DOWNARROW / DOWN|| | ||
|LEFTARROW / LEFT|| | ||
|RIGHTARROW / RIGHT|| | ||
|UPARROW / UP|| | ||
|ENTER|| | ||
|DELETE|| | ||
|BACKSPACE|| | ||
|END|| | ||
|HOME|| | ||
|ESCAPE / ESC|| | ||
|INSERT|| | ||
|PAGEUP|| | ||
|PAGEDOWN|| | ||
|CAPSLOCK|| | ||
|NUMLOCK|| | ||
|SCROLLLOCK|| | ||
|PRINTSCREEN|| | ||
|BREAK|Pause/Break key| | ||
|PAUSE|Pause/Break key| | ||
|SPACE|| | ||
|TAB|| | ||
|MENU|Context menu key| | ||
|APP|Same as MENU| | ||
|Fx|F1-F12 keys| | ||
|
||
## Modifier keys | ||
Can be combined with special key command or single character | ||
|Command|Notes| | ||
|-|-| | ||
|CONTROL / CTRL|| | ||
|SHIFT|| | ||
|ALT|| | ||
|WINDOWS / GUI|| | ||
|CTRL-ALT|CTRL+ALT| | ||
|CTRL-SHIFT|CTRL+SHIFT| | ||
|ALT-SHIFT|ALT+SHIFT| | ||
|ALT-GUI|ALT+WIN| | ||
|GUI-SHIFT|WIN+SHIFT| | ||
## String | ||
|Command|Parameters|Notes| | ||
|-|-|-| | ||
|STRING|Text string|Print text string| | ||
## Repeat | ||
|Command|Parameters|Notes| | ||
|-|-|-| | ||
|REPEAT|Number of additional repeats|Repeat previous command| | ||
## ALT+Numpad input | ||
On Windows and some Linux systems you can print character by pressing ALT key and entering its code on numpad | ||
|Command|Parameters|Notes| | ||
|-|-|-| | ||
|ALTCHAR|Character code|Print single character| | ||
|ALTSTRING|Text string|Print text string using ALT+Numpad method| | ||
|ALTCODE|Text string|Same as ALTSTRING, presents in some Duckyscript implementations| | ||
## SysRq | ||
Send [SysRq command](https://en.wikipedia.org/wiki/Magic_SysRq_key) | ||
|Command|Parameters|Notes| | ||
|-|-|-| | ||
|SYSRQ|Single character|| | ||
## USB device ID | ||
You can set custom ID of Flipper USB HID device. ID command should be in the **first line** of script, it is executed before script run. | ||
|
||
|Command|Parameters|Notes| | ||
|-|-|-| | ||
|ID|VID:PID Manufacturer:Product|| | ||
|
||
Example: | ||
`ID 1234:abcd Flipper Devices:Flipper Zero` | ||
|
||
VID and PID are hex codes and are mandatory, Manufacturer and Product are text strings and are optional. | ||
|
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,47 @@ | ||
# LF RFID key file format | ||
|
||
## Example | ||
``` | ||
Filetype: Flipper RFID key | ||
Version: 1 | ||
Key type: EM4100 | ||
Data: 01 23 45 67 89 | ||
``` | ||
## Description | ||
|
||
Filename extension: `.rfid` | ||
|
||
The file stores single RFID key of type defined by `Key type` parameter | ||
|
||
### Version history | ||
|
||
1. Initial version. | ||
|
||
### Format fields | ||
|
||
|Name|Description| | ||
|-|-| | ||
|Key type|Key protocol type| | ||
|Data|Key data (HEX values)| | ||
|
||
### Supported key types | ||
|
||
|Type|Full name| | ||
|-|-| | ||
|EM4100|EM-Micro EM4100| | ||
|H10301|HID H10301| | ||
|Idteck|IDTECK| | ||
|Indala26|Motorola Indala26| | ||
|IOProxXSF|Kantech IOProxXSF| | ||
|AWID|AWID| | ||
|FDX-A|FECAVA FDX-A| | ||
|FDX-B|ISO FDX-B| | ||
|HIDProx|Generic HIDProx| | ||
|HIDExt|Generic HIDExt| | ||
|Pyramid|Farpointe Pyramid| | ||
|Viking|Viking| | ||
|Jablotron|Jablotron| | ||
|Paradox|Paradox| | ||
|PAC/Stanley|PAC/Stanley| | ||
|Keri|Keri| | ||
|Gallagher|Gallagher| |
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,27 @@ | ||
# iButton key file format | ||
|
||
## Example | ||
``` | ||
Filetype: Flipper iButton key | ||
Version: 1 | ||
# Key type can be Cyfral, Dallas or Metakom | ||
Key type: Dallas | ||
# Data size for Cyfral is 2, for Metakom is 4, for Dallas is 8 | ||
Data: 12 34 56 78 9A BC DE F0 | ||
``` | ||
## Description | ||
|
||
Filename extension: `.ibtn` | ||
|
||
The file stores single iButton key of type defined by `Key type` parameter | ||
|
||
### Version history | ||
|
||
1. Initial version. | ||
|
||
### Format fields | ||
|
||
|Name|Description| | ||
|-|-| | ||
|Key type|Currently supported: Cyfral, Dallas, Metakom| | ||
|Data|Key data (HEX values)| |