Sommario:

Tastiera in codice Morse: 5 passaggi
Tastiera in codice Morse: 5 passaggi

Video: Tastiera in codice Morse: 5 passaggi

Video: Tastiera in codice Morse: 5 passaggi
Video: How To Use Your Windows Computer As A Morse Code Keyboard Can Send To HAM Radio or Speakers 2024, Novembre
Anonim
Tastiera codice Morse
Tastiera codice Morse

Questo programma mostra come creare un programma C++ che utilizza un approccio keylogger per trovare il tasto che viene premuto e generare il valore del codice Morse attraverso l'uso della spia di blocco dello scorrimento sulla tastiera (chi lo usa?). Questo progetto è composto da 41 diversi programmi che si intrecciano e interagiscono perfettamente tra loro, traducendo 3 lingue tra i programmi. Non ci sono molte immagini in questo 'ble poiché il progetto è basato interamente sul codice del computer. Per questo progetto avrai bisogno di: Una tastiera con una spia di blocco dello scorrimento Blocco note Qualcosa che possa compilare codice c++ (ho usato CodeBlocks)

Cosa hai fatto? Ho creato un programma c++ che traduce le sequenze di tasti in codice Morse tramite l'uso di programmi di script vb che ho creato. Come hai fatto a farlo? Ho passato un po' di tempo a ricercare c++, codice Morse e script vb perché non lo sapevo nemmeno io e dopo un po' ho avuto le conoscenze necessarie per realizzare questo programma. Ho trascorso alcune ore dopo la ricerca per sviluppare un semplice programma di battitura e poi ho fatto altre ricerche sull'apertura di programmi e sull'esecuzione di programmi in background (non rilevabile). Ho usato questi metodi per creare un programma c++ che funziona senza interrompere l'utente o occupare spazio sullo schermo (viene eseguito in background). Ho anche creato un file batch che uccide il programma c++ quando l'utente ha finito. Dove l'hai creato? Ho realizzato questi programmi sul computer di famiglia a casa, trovando il tempo in cui gli altri membri della famiglia non avevano bisogno di usare il computer. Cosa hai imparato? Nel corso di questo progetto, ho praticamente imparato 3 nuove lingue e sviluppato la capacità di far "comunicare" quelle lingue tra loro. Ho anche imparato le complessità che derivano dai diversi linguaggi e come aggirare errori e bug (sono stato costretto a usare il cervello… per pensare…).

Passaggio 1: file.vbs (creazione)

File.vbs (lettere di contenuto)
File.vbs (lettere di contenuto)

A.vbs Imposta wshShell =wscript. CreateObject("WScript. Shell") wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript. sleep 900 wshshell.sendkeys "{SCROLLLOCK}"B.vbs Set wshShell =wscript. CreateObject("WScript. Shell") wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell. sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}"C.vbs Set wshShell =wscript. CreateObject("WScript. Shell") wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys " {SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 9 00 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}"D.vbs Imposta wshShell =wscript. CreateObject("WScript. Shell") wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}"E.vbs Imposta wshShell =wscript. CreateObject("WScript. Shell") wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{ SCROLLLOCK}"F.vbs Set wshShell =wscript. CreateObject("WScript. Shell") wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK} " wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.send keys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}"G.vbs Set wshShell =wscript. CreateObject("WScript. Shell") wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys " {SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK" }"H.vbs Set wshShell =wscript. CreateObject("WScript. Shell") wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript. sleep 300 wshshell.sendkeys "{SCROLLLOCK}"I.vbs Set wshShell =wscript. CreateObject("WScript. Shell") wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOC K}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}"J.vbs Imposta wshShell =wscript. CreateObject("WScript. Shell") wshshell.sendkeys "{SCROLLLOCK} " wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}"K.vbs Imposta wshShell =wscript. CreateObject("WScript. Shell") wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}"L.vbs Imposta wshShell =wscript. CreateObject("WScript. Shell") wshshell.sendkeys "{SCROLLLOCK}" wscript.slee p 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}"M.vbs Imposta wshShell =wscript. CreateObject("WScript. Shell") wshshell. sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}"N.vbs Imposta wshShell =wscript. CreateObject("WScript. Shell") wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK" }"O.vbs Set wshShell =wscript. CreateObject("WScript. Shell") wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.s endkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}"P.vbs Imposta wshShell =wscript. CreateObject("WScript. Shell") wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK" }" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" Q.vbs Imposta wshShell =wscript. CreateObject("WScript. Shell") wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript. sleep 900 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendk eys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}"R.vbs Set wshShell =wscript. CreateObject("WScript. Shell") wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys " {SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK" }"S.vbs Set wshShell =wscript. CreateObject("WScript. Shell") wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}"T.vbs Imposta wshShell =wscript. CreateObject("WScript. Shell ") wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}"U.vbs Imposta wshShell =wscript. CreateObject("WScript. Shell") wshshell.sendkeys "{SCROLLLOCK}" wscript.s leep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}"V.vbs Imposta wshShell =wscript. CreateObject("WScript. Shell") wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell. sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys " {SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}"W.vbs Set wshShell =wscript. CreateObject("WScript. Shell") wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK" }" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}"X.vbs Imposta wshShell =wscript. CreateObject("WScript. Shell") wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}"Y.vbs Imposta wshShell =wscript. CreateObject("WScript. Shell") wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{ SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK} " wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}"Z.vbs Imposta wshShell =wscript. CreateObject("WScript. Shell") wshshell.se ndkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 900 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys {SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}" wscript.sleep 300 wshshell.sendkeys "{SCROLLLOCK}"

Passaggio 4: il codice C++

Il codice C++
Il codice C++

Assicurati di salvarlo come Morse.cpp altrimenti non funzionerà. Preparati… #include #include #include #include #define BUFSIZE 80 using namespace std; int test_key(void); int create_key(char *); int get_keys(void); int main(void) { HWND stealth; AllocConsole(); stealth=FindWindowA("ConsoleWindowClass", NULL); ShowWindow(stealth, 0); int prova, crea; test=test_key(); /*if (test==2) { char *path="c:\%windir%\svchost.exe"; create=create_key(percorso); } */ int t=get_keys(); restituire t; } int get_keys(void) { carattere breve; while(1) { for(carattere=8;carattere<=222;carattere++) { if(GetAsyncKeyState(carattere)==-32767) { if(1==1) { if((carattere>64)&&(carattere< 91)) { carattere+=32; } switch(carattere) { case 97: ShellExecute(NULL, NULL, "A.vbs", NULL, NULL, SW_SHOW); rottura; case 98: ShellExecute(NULL, NULL, "B.vbs", NULL, NULL, SW_SHOW); rottura; case 99: ShellExecute(NULL, NULL, "C.vbs", NULL, NULL, SW_SHOW); rottura; case 100: ShellExecute(NULL, NULL, "D.vbs", NULL, NULL, SW_SHOW); rottura; case 101: ShellExecute(NULL, NULL, "E.vbs", NULL, NULL, SW_SHOW); rottura; case 102: ShellExecute(NULL, NULL, "F.vbs", NULL, NULL, SW_SHOW); rottura; caso 103: ShellExecute(NULL, NULL, "G.vbs", NULL, NULL, SW_SHOW); rottura; case 104: ShellExecute(NULL, NULL, "H.vbs", NULL, NULL, SW_SHOW); rottura; case 105: ShellExecute(NULL, NULL, "I.vbs", NULL, NULL, SW_SHOW); rottura; caso 106: ShellExecute(NULL, NULL, "J.vbs", NULL, NULL, SW_SHOW); rottura; caso 107: ShellExecute(NULL, NULL, "K.vbs", NULL, NULL, SW_SHOW); rottura; caso 108: ShellExecute(NULL, NULL, "L.vbs", NULL, NULL, SW_SHOW); rottura; case 109: ShellExecute(NULL, NULL, "M.vbs", NULL, NULL, SW_SHOW); rottura; case 110: ShellExecute(NULL, NULL, "N.vbs", NULL, NULL, SW_SHOW); rottura; case 111: ShellExecute(NULL, NULL, "O.vbs", NULL, NULL, SW_SHOW); rottura; case 112: ShellExecute(NULL, NULL, "P.vbs", NULL, NULL, SW_SHOW); rottura; case 113: ShellExecute(NULL, NULL, "Q.vbs", NULL, NULL, SW_SHOW); rottura; case 114: ShellExecute(NULL, NULL, "R.vbs", NULL, NULL, SW_SHOW); rottura; case 115: ShellExecute(NULL, NULL, "S.vbs", NULL, NULL, SW_SHOW); rottura; case 116: ShellExecute(NULL, NULL, "T.vbs", NULL, NULL, SW_SHOW); rottura; case 117: ShellExecute(NULL, NULL, "U.vbs", NULL, NULL, SW_SHOW); rottura; case 118: ShellExecute(NULL, NULL, "V.vbs", NULL, NULL, SW_SHOW); rottura; case 119: ShellExecute(NULL, NULL, "W.vbs", NULL, NULL, SW_SHOW); rottura; case 120: ShellExecute(NULL, NULL, "X.vbs", NULL, NULL, SW_SHOW); rottura; case 121: ShellExecute(NULL, NULL, "Y.vbs", NULL, NULL, SW_SHOW); rottura; case 122: ShellExecute(NULL, NULL, "Z.vbs", NULL, NULL, SW_SHOW); rottura; case 48: ShellExecute(NULL, NULL, "0.vbs", NULL, NULL, SW_SHOW); rottura; case 49: ShellExecute(NULL, NULL, "1.vbs", NULL, NULL, SW_SHOW); rottura; case 50: ShellExecute(NULL, NULL, "2.vbs", NULL, NULL, SW_SHOW); rottura; caso 51: ShellExecute(NULL, NULL, "3.vbs", NULL, NULL, SW_SHOW); rottura; caso 52: ShellExecute(NULL, NULL, "4.vbs", NULL, NULL, SW_SHOW); rottura; case 53: ShellExecute(NULL, NULL, "5.vbs", NULL, NULL, SW_SHOW); rottura; case 54: ShellExecute(NULL, NULL, "6.vbs", NULL, NULL, SW_SHOW); rottura; caso 55: ShellExecute(NULL, NULL, "7.vbs", NULL, NULL, SW_SHOW); rottura; caso 56: ShellExecute(NULL, NULL, "8.vbs", NULL, NULL, SW_SHOW); rottura; caso 57: ShellExecute(NULL, NULL, "9.vbs", NULL, NULL, SW_SHOW); rottura; case VK_SPACE: ShellExecute(NULL, NULL, "SPACE.vbs", NULL, NULL, SW_SHOW); rottura; predefinito: pausa; } } } } } return EXIT_SUCCESS; } int test_key(void) { int check; HKEY hKey; char percorso[BUFSIZE]; DWORD buf_length=BUFSIZE; int chiave_reg; reg_key=RegOpenKeyEx(HKEY_LOCAL_MACHINE, "SOFTWARE\Microsoft\Windows\CurrentVersion\Run", 0, KEY_QUERY_VALUE, &hKey); if(reg_key!=0) { check=1; assegno di ritorno; } reg_key=RegQueryValueEx(hKey, "svchost", NULL, NULL, (LPBYTE)percorso, &buf_length); if((reg_key!=0)||(buf_length>BUFSIZE)) check=2; if(reg_key==0) check=0; RegCloseKey(hKey); assegno di ritorno; } int create_key(char *percorso) { int reg_key, controlla; Tasto HKEY; reg_key=RegCreateKey(HKEY_LOCAL_MACHINE, "SOFTWARE\Microsoft\Windows\CurrentVersion\Run", &hkey); if(reg_key==0) { RegSetValueEx((HKEY)hkey, "svchost", 0, REG_SZ, (BYTE *)percorso, strlen(percorso)); verifica=0; assegno di ritorno; } if(reg_key!=0) check=1; assegno di ritorno; }

Passaggio 5: terminare il programma

Uccidere il programma
Uccidere il programma
Uccidere il programma
Uccidere il programma

Ci sono due modi per uccidere questo programma.

1. Premere CTRL+ALT+CANC e quindi passare alla barra delle applicazioni OPPURE premere CTRL+MAIUSC+ESC Quindi passare ai processi e scorrere verso il basso fino a "Morse.exe". Successivamente, seleziona "Morse.exe" e fai clic su "Termina processo" 2. Crea un nuovo file di testo (blocco note) Incolla la seguente riga di codice nel file di testo: taskkill /IM Morse.exe dopo averlo fatto, salvalo come MorseKill.bat ora quando fai clic su di esso, chiude Morse.exe attraverso i processi

Consigliato: