Security News
Maven Central Adds Sigstore Signature Validation
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.
A Python package for integrating hCaptcha, a popular captcha service, into various applications for enhanced security and user verification.
hcaptcha is a Python module (unofficial) that provides an easy-to-use interface for verifying hcaptcha responses using the hcaptcha verification API.
You can install hcaptcha using pip:
pip install hcaptcha
To use hcaptcha, you'll need an hcaptcha secret key for your site. You can get one by signing up for an account at hcaptcha website.
from hcaptcha.hcaptcha import HCaptchaVerifier, HCaptchaVerificationError
import asyncio
# Initialize the verifier with your hcaptcha secret key
verifier = HCaptchaVerifier(your_hcaptcha_secret_key)
# Verify an hcaptcha response
# You can use await instead of asyncio.run if you are in a async function
try:
is_valid = asyncio.run(verifier.verify(user_response_token))
if is_valid:
print("Captcha verified successfully.")
else:
print("Captcha verification failed.")
except HCaptchaVerificationError as e:
print(f"Verification failed with error: {str(e)}")
Documentation for hcaptcha is available here
If you find a bug or have a feature request, please open an issue on GitHub.
hcaptcha is distributed under the MIT License. See LICENSE for more information.
FAQs
A Python package for integrating hCaptcha, a popular captcha service, into various applications for enhanced security and user verification.
We found that hcaptcha demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.
Security News
CISOs are racing to adopt AI for cybersecurity, but hurdles in budgets and governance may leave some falling behind in the fight against cyber threats.
Research
Security News
Socket researchers uncovered a backdoored typosquat of BoltDB in the Go ecosystem, exploiting Go Module Proxy caching to persist undetected for years.