Cov txheej txheem:
Video: Arduino TOTP Generator: 3 Cov Kauj Ruam
2024 Tus sau: John Day | [email protected]. Kawg hloov kho: 2024-01-30 09:26
Kev tshoov siab
Muaj ib tus phooj ywg nrog kev txaus siab hauv cryptography thiab kev nyab xeeb, Kuv xav tsim lub hnub yug zoo tshaj plaws tam sim no.
*Nov yog qhov haujlwm kuv tau ua hnub yug hnub no thiab tau tsim nyob rau hauv lub sijhawm txwv nruj (zam txim rau qhov ua tsis tau zoo)
NCO TSEG: Lub TOTP tiam uas tau siv hauv txoj haujlwm no tsim thiab siv 6 tus lej lej, tab sis vim yog kuv cov cuab yeej siv tam sim no, kuv tau xaiv txiav cov kab tom ntej 2 tus lej thiab tso saib thiab siv 4, sib cav (tab sis tsis zoo heev) txo qhov kev ruaj ntseg.
Cov Ntaub Ntawv Dav Dav
Txoj haujlwm no tsim cov cai tshiab txhua txhua 30 vib nas this siv tus yuam sij preshared thiab lub sijhawm tam sim no (uas tau khaws cia taug qab ntawm kev siv lub sijhawm ntsuas lub sijhawm tiag tiag) thiab nthuav tawm nws ntawm cov zaub thaum lub pob nyem. Cov ntaub ntawv siv feem ntau yuav yog ob qhov pov thawj raws li Lub Sijhawm Raws Li Ib Lub Sij Hawm Lo Lus (TOTP) thiab HMAC-based Ib Lub Sij Hawm Password (HOTP) rau kev lees paub tseeb.
TOTP yog txheej txheem txheej txheem uas suav nrog tus lej nkag mus ib zaug los ntawm kev qhia tus lej zais thiab lub sijhawm tam sim no. HTOP yog txheej txheem txheej txheem uas siv HMAC cov txheej txheem los tsim tus lej ib zaug.
Cov tuam txhab xws li Google, Microsoft, thiab Steam twb tau siv TOTP thev naus laus zis rau lawv ob qhov kev txheeb xyuas qhov tseeb
Nthuav nthuav Links
Kab lus piav qhia yuav ua li cas Google siv cov thev naus laus zis no los txheeb xyuas cov neeg siv-https://medium.com/@tilaklodha/google-authenticator-and-how-it-works-2933a4ece8c2
Kev siv JavaScript ntawm HOTP thiab TOTP uas yuav siv tau thaum tsim software siv txoj haujlwm no -
Crytographic library rau Arduino siv hauv txoj haujlwm no -
TOTP Ntawv -
Qib Kev Kws Paub
Cov Lus Qhia no yog rau cov neeg txaus siab uas txaus siab rau kev nyab xeeb thiab tej zaum yuav xav siv cov khoom siv kho vajtse zoo rau tiam ntawm lawv cov TOTP. Cov lus qhia no tau sau rau cov neeg tuaj saib uas twb nkag siab qhov pib ntawm kev txhais cov kab kos hluav taws xob thiab cov txheej txheem rudimentary, tab sis yog tias koj npaj rau qhov yooj yim ua raws li Cov Lus Qhia no raws nraim, tsis txhob txhawj xeeb yog tias koj tsis muaj kev paub dhau los, thiab xav tias dawb nug cov lus nug hauv lus! Tsis tas li ntawd, txoj haujlwm tuaj yeem nthuav rau cov tsim kev paub dhau los ib yam vim tias cov khoom kawg tsis yog tsuas yog ib qho zoo kom muaj nyob ib puag ncig (hauv kuv lub tswv yim), tab sis muaj peev xwm ntau rau kev nthuav dav thiab cov yam ntxwv tshiab yam tsis muaj teeb meem ntau.
Khoom siv
Cov ntaub ntawv:
- 1 x Arduino Nano (Amazon)
- 1x DS3231 AT24C32 Lub Sijhawm Tiag (RTC) Module (Amazon)
- 1x SH5461AS Common Cathode 4 tus lej 7-ntu (Amazon)
- 1x Pushbutton (Amazon)
- 1x 10k Resistor (Amazon)
- Yeem xaiv 1x 5x7cm PCB (Amazon)
- YUAV TSUM MUAJ Hlau rau soldering rau PCB
- XAUS 1 x Breadboard rau ntsuas (Amazon)
Kauj Ruam 1: Sib dhos thiab Xeem
Sib sau ua ke tag nrho cov khoom siv ntawm lub khob cij thiab xaim lawv raws li daim kab xev txuas nrog (Cov ntaub ntawv Fritzing nyob ntawm no).
Nco ntsoov tias koj tau teeb tsa Arduino IDE (nws tuaj yeem pom online yog tias koj tsis ua) thiab teeb tsa cov tsev qiv ntawv hauv qab no:
github.com/lucadentella/TOTP-Arduino
github.com/adafruit/RTClib
github.com/maniacbug/Cryptosuite
Rub tawm daim duab txuas (kuj tseem tuaj yeem nkag tau ntawm no: https://gist.github.com/shiv213/569f01a54988cb0207966be9a65cc5ab), thiab qhib nws siv Arduino IDE. Qhib qhov txuas no (https://www.lucadentella.it/OTP/) thiab sau ib lub npe hauv tus as khauj lub npe, thiab tus yuam sij zais cia (10 tus cim ntev) hauv daim teb hauv qab no, ua kom ntseeg tau khaws ob qho ntawm cov txiaj ntsig ntawd hauv qhov chaw nyab xeeb rau thaub qab. Luam cov ntsiab lus ntawm "Arduino HEX array:" teb, thiab hloov rov qab mus rau Arduino editor, hloov cov kab ntawm kab 25 (hmacKey) nrog qhov koj tau theej los ntawm lub xaib.
Tom qab kuaj xyuas txhua qhov txuas xov hlau, xyuas kom tseeb tias RTC module muaj cov npib ntawm tes hauv nws, thiab txuas Arduino rau koj lub khoos phis tawj siv lub USB mini qaum, thiab xa daim duab txuas nrog.
Tom qab rub tawm, thaum lub pob nyem, tus lej yuav tsum tshwm ntawm qhov screen. Yog tias koj rub tawm Google Daim Ntawv Pov Thawj Ua Haujlwm ntawm lub xov tooj ntawm tes thiab rov qab mus rau qhov chaw siv los tsim HEX array, luam theej tawm QR code lossis ntaus "Google Tus Kheej Tus Kheej Tus Kheej" rau hauv app, koj yuav tsum pom tus lej pom hauv lub app. Yog tias txhua yam ua haujlwm tau raug, thaum koj nias lub pob, 4 tus lej uas tso tawm yuav tsum phim thawj 4 ntawm tus lej tam sim no uas pom ntawm lub smartphone app. Yog tias qhov no tsis yog, nco ntsoov tias lub khoos phis tawj siv los tso cov lej Arduino tau teeb tsa rau UTC sijhawm thiab sim dua.
Kauj Ruam 2: Hloov mus rau PCB
Tom qab ua kom ntseeg tau tias txhua yam tau ua tiav, koj tuaj yeem xa cov khoom sib txuas mus rau PCB thiab sib dhos txhua yam ua ke txawm li cas los koj zoo li haum. Kuv tau txuas daim duab PCB ntxiv rau Fritzing cov ntaub ntawv (muaj nyob ntawm no). Nco ntsoov tias kuv tau muab txhua yam khoom tso rau saum lub rooj tsav xwm kom zoo nkauj, tab sis kuj tseem tuaj yeem teeb tsa hauv qab thiab tom qab ntawd muab ntim rau hauv qee yam ntawm cov vaj tsev kom ua kom huv dua. Kuv txiav thiab kub glued popsicle sticks xim nrog Sharpie mus rau ob sab ntawm PCB los tsim lub thawv me me rau chav nyob. Lwm txoj hauv kev xaiv yog txhawm rau txuas lub roj teeb 9-volt rau VIN thiab GND pins ntawm Arduino, ua rau nws ua haujlwm roj teeb.
Kauj ruam 3: Tiav lawm
Nov yog qhov kuv ua tiav lub tshuab hluav taws xob hloov tawm, yog tias koj ua raws thiab ua rau koj tus kheej, qhia nws hauv qab no!
Nco ntsoov pov npav Kuv Cov Lus Qhia rau kev sib tw STEM yog tias koj pom zoo, thiab tawm lus tawm/lus nug koj yuav muaj hauv qab no!
Pom zoo:
Hloov-Hloov Cov Khoom Ua Si: Cov Khoom Ua Si Cov Khoom Ua Si Ua Tau Zoo!: 7 Cov Kauj Ruam (nrog Duab)
Hloov-Hloov Cov Khoom Ua Si: Cov Khoom Siv Hluav Taws Xob Ua Tau Zoo!: Qho khoom ua si hloov pauv qhib txoj hauv kev tshiab thiab kev daws teeb meem kom tso cai rau menyuam yaus uas muaj lub cev muaj peev xwm txwv lossis kev xiam oos qhab kev loj hlob los cuam tshuam nrog cov khoom ua si ntawm nws tus kheej. Hauv ntau qhov xwm txheej, cov menyuam yaus uas xav tau cov khoom ua si hloov pauv tsis tuaj yeem nkag mus
Cov av noo noo Cov Lus Qhia Tswj Xyuas Internet Txuas Cov Dej Dej (ESP32 thiab Blynk): 5 Cov Kauj Ruam
Cov av noo noo Cov lus pom zoo Tswj Xyuas Internet Txuas Cov Dej Dej (ESP32 thiab Blynk): Tsis txhawj xeeb txog koj lub vaj lossis nroj tsuag thaum koj mus rau hnub so ntev, lossis tsis nco qab ywg dej koj cov nroj tsuag txhua hnub. Zoo ntawm no yog kev daws teeb meem Nws cov av ya raws tswj hwm thiab thoob ntiaj teb txuas nrog cov dej txau dej tswj los ntawm ESP32 ntawm software pem hauv ntej kuv
Ua Cov Phiaj Xwm Zoo Los Ntawm Cov Ntaub Ntawv Nyob Arduino (thiab Txuag Cov Ntaub Ntawv rau Excel): 3 Cov Kauj Ruam
Ua Cov Phiaj Xwm Zoo Los Ntawm Cov Ntaub Ntawv Nyob Arduino (thiab Txuag Cov Ntaub Ntawv rau Excel): Peb txhua tus nyiam ua si nrog peb tus lej L … cov ntsiab lus tau ntxiv thiab nws tsis tshwj xeeb rau lub qhov muag. Arduino IDE cov phiaj xwm tsis
Cov Ntawv Cim Hluav Taws Xob LED Taws Teeb Cov Neeg Hlau Cov Ntawv Cim - Cov Khoom Siv Soldering: 11 Kauj Ruam
Cov Khoom Siv Hluav Taws Xob LED Taws Teeb Cov Neeg Hlau Daim Npav - Cov Khoom Siv Soldering: Kab lus no tau txaus siab txhawb nqa los ntawm PCBWAY.PCBWAY ua cov qauv zoo PCBs rau tib neeg thoob plaws ntiaj teb. Sim nws rau koj tus kheej thiab tau txais 10 PCBs rau tsuas yog $ 5 ntawm PCBWAY nrog qhov ua tau zoo heev, Ua tsaug PCBWAY. Robadge#1 uas kuv tau tsim rau
Generator: Fidget Spinner Generator 3 hauv 1: 3 Cov Kauj Ruam
Generator: Fidget Spinner Generator 3 in 1: fidget spinner generator 3 in 1 - tam sim no koj tuaj yeem teeb tsa koj lub fidget spinner generator (peb xaiv) lub tshuab hluav taws xob me me siv 3 neodymium spheres thiab 3 neodymium discs (coj thiab cov hlau me me hlau tsawg) Nrhiav peb ON INSTAGRAM thiab pom hluav taws xob yooj yim