canokeys / canokey-web-console Goto Github PK
View Code? Open in Web Editor NEWWeb console for Canokeys
Web console for Canokeys
Supported browsers:
Recent Chrome/Chromium, Edge, and Opera
Users that try to use other browsers should be prompted to switch their browsers.
Canokeys info:
Model: CanoKey ES (STM32)
Firmware Version: v2.2-12-gd2813250-dirty-O (forked version: https://github.com/tao-harald/canokey-stm32/tree/nucleo )
System: Windows and Arch Linux
It seems that the problem is caused by src/Oath.js#L76 wich doesn't work as expected:
function isOldProtocol(firmwareVersion) {
return firmwareVersion < "1.5";
}
Error appears on Chrome, Opera when trying to connect to the device
Ubuntu 23.04. Latest Kernel 6.4.0-060400-generic from Canonical
Removed the device and reinserted and then could be accessed.
the key is encoded with base32, which should accept lowercase. But it didn't
Could not load canokey in web console.
webauthn and openpgp card works
$ gpg --card-status
Reader ...........: Canokeys Canokey [OpenPGP PIV OATH] (123456) 00 00
Application ID ...: D276000124010304F1D0657539600000
Application type .: OpenPGP
Version ..........: 3.4
Manufacturer .....: unknown
Serial number ....: 65753960
Name of cardholder: [未设定]
Language prefs ...: [未设定]
Salutation .......:
URL of public key : [未设定]
Login data .......: [未设定]
Signature PIN ....: 强制Key attributes ...: rsa2048 rsa2048 rsa2048
Max. PIN lengths .: 64 64 64
PIN retry counter : 3 0 3
Signature counter : 0
Signature key ....: [none]
Encryption key....: [none]
Authentication key: [none]
General key info..: [none]
Operating System: Debian GNU/Linux 12
KDE Plasma Version: 5.27.5
KDE Frameworks Version: 5.103.0
Qt Version: 5.15.8
Kernel Version: 6.1.0-13-amd64 (64-bit)
Graphics Platform: X11
Processors: 12 × Intel® Core™ i5-10400F CPU @ 2.90GHz
Memory: 15.5 GiB of RAM
Graphics Processor: NVIDIA GeForce GTX 1650/PCIe/SSE2
Manufacturer: ASUS
$ cmake --version
cmake version 3.25.1
CMake suite maintained and supported by Kitware (kitware.com/cmake).
$ arm-none-eabi-gcc --version
arm-none-eabi-gcc (15:12.2.rel1-1) 12.2.1 20221205
Copyright (C) 2022 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
$ pcscd --version
pcsc-lite version 1.9.9.
Copyright (C) 1999-2002 by David Corcoran <[email protected]>.
Copyright (C) 2001-2022 by Ludovic Rousseau <[email protected]>.
Copyright (C) 2003-2004 by Damien Sauveron <[email protected]>.
Report bugs to <[email protected]>.
Enabled features: Linux x86_64-pc-linux-gnu libsystemd serial usb libudev usbdropdir=/usr/lib/pcsc/drivers ipcdir=/run/pcscd filter configdir=/etc/reader.conf.d
MAX_READERNAME: 128, PCSCLITE_MAX_READERS_CONTEXTS: 16
pcsc_scan
Info0: Canokeys Canokey [OpenPGP PIV OATH] (123456) 00 00
Sun Dec 10 12:46:23 2023
Reader 0: Canokeys Canokey [OpenPGP PIV OATH] (123456) 00 00
Event number: 4
Card state: Card inserted,
ATR: 3B F7 11 00 00 81 31 FE 65 43 61 6E 6F 6B 65 79 99
ATR: 3B F7 11 00 00 81 31 FE 65 43 61 6E 6F 6B 65 79 99
+ TS = 3B --> Direct Convention
+ T0 = F7, Y(1): 1111, K: 7 (historical bytes)
TA(1) = 11 --> Fi=372, Di=1, 372 cycles/ETU
10752 bits/s at 4 MHz, fMax for Fi = 5 MHz => 13440 bits/s
TB(1) = 00 --> VPP is not electrically connected
TC(1) = 00 --> Extra guard time: 0
TD(1) = 81 --> Y(i+1) = 1000, Protocol T = 1
-----
TD(2) = 31 --> Y(i+1) = 0011, Protocol T = 1
-----
TA(3) = FE --> IFSC: 254
TB(3) = 65 --> Block Waiting Integer: 6 - Character Waiting Integer: 5
+ Historical bytes: 43 61 6E 6F 6B 65 79
Category indicator byte: 43 (proprietary format)
+ TCK = 99 (correct checksum)
Possibly identified card (using /usr/share/pcsc/smartcard_list.txt):
3B F7 11 00 00 81 31 FE 65 43 61 6E 6F 6B 65 79 99
Canokey (Other)
http://canokeys.org/
Like Nordic nrf52840 dongle but have some different.
Bootloader Adafruit_nRF52_Bootloader Release 0.8.0 use dap link to flash bootloader
Same build and flash method with README.MD
The default openpgp admin pin is 8 bytes, and when i want to change the admin pin, it seems to need 24 bytes.
But actually it requires 48 bytes or the button won't click.
Temp workaround: manually convert it to uppercase by hand.
Send 0031010000
to the admin applet to retrieve the name as text. The response would be like 43616E6F6B6579204E4643205553422D41207265762E339000
.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.