ic-captcha
ic-captcha is a library that generating CAPTCHAs with given random bytes for the Internet Computer.
It is inspired by captcha-rs.

Usage
See examples and the API documentation for more.
Using mode method
| CaptchaBuilder::mode | Captcha Preview |
|---|---|
| mode(0): dark on light | ![]() |
| mode(1): colorful on light | ![]() |
| mode(2): colorful on dark | ![]() |
Using complexity method
| CaptchaBuilder::complexity | Captcha Preview |
|---|---|
| complexity(1) | ![]() |
| complexity(5) | ![]() |
| complexity(10) | ![]() |
Using compression
| Captcha::to_base64 | Captcha Preview |
|---|---|
| to_base64(10): 1.49KB | ![]() |
| to_base64(40): 2.68KB | ![]() |
| to_base64(80): 5.21KB | ![]() |
Example
Add the following dependency to the Cargo.toml file:
[]
= "1.0"
And then get started in main.rs:
use CaptchaBuilder;
License
Copyright © 2024-present LDC Labs.
ldclabs/ic-captcha is licensed under either of Apache License, Version
2.0.








