SShortSingh.
Back to feed

How to verify drand randomness beacons in your app using 30 lines of code

0
·69 views

Developers building agents that rely on random numbers often use HTTP relay APIs, but these relays cannot be independently trusted to deliver unaltered data. The drand project, operated by the League of Entropy, publishes a public randomness beacon every three seconds using BLS signatures, allowing anyone to verify results offline with a pinned public key. By fetching the same round directly from drand's own endpoint and comparing it against the relay's response, developers can confirm the beacon has not been tampered with or replayed. A small code example using the drand-client npm package demonstrates how to perform this cross-verification in under 30 lines. The approach reduces reliance on relay trust and enables reproducible, auditable random sampling for use cases like reviewer selection, tie-breaking, or raffles.

Read the full story at DEV Community

This is an AI-generated summary. ShortSingh links to the original source for the complete article.

Discussion (0)

Log in to join the discussion and vote.

Log in

Related stories

0
ProgrammingDEV Community ·

Muse Tool Lets Users Read Full X Posts and Threads From a Link

A new connector called x_thread, distributed through the nyanshiba/muse-tan GitHub repository under an MIT license, allows Muse to read the full contents of X posts, threads, and long-form articles when given a URL. It works without the official X API, FxTwitter, a browser, or any credentials, relying instead on an unofficial syndication endpoint and public page HTML. The tool is read-only, free to use, and implemented in a single Python file that sends only GET requests to two hosts. The author notes that alternatives such as the paid official API, browser-based reading, mirror services, and manual copying each have drawbacks for this purpose. Users are advised to review the code of any third-party connector before installing it.

0
ProgrammingDEV Community ·

Tips for making a white-label AI developer portal usable for new visitors

White-label developer portals often fail not because the API is broken but because new users cannot figure out what the site offers or what to do first. The article argues that branding, navigation, and pricing clarity are product design decisions rather than cosmetic ones. It recommends a concise, concrete value promise, and logos that remain legible at small sizes. It also advises testing the full sign-in and redirect path in a private browser window, since admin sessions can hide real first-time user problems. Finally, it covers custom domain setup, including a CNAME record pointing to platform-proxy.acedata.cloud.

0
ProgrammingDEV Community ·

Google Play Console 2026 Sign-Up: Key Steps From Account Type to Verification

Registering for the Google Play Console in 2026 involves several stages, including choosing an account type, verifying identity, paying a one-time $25 fee, completing profile details, and passing a 14-day testing requirement for new accounts. Developers must decide between a personal account, which requires government ID and typically verifies within a few days, and an organization account, which needs a D-U-N-S number and business documents and can take weeks. Small errors such as mismatched legal names or entity details are a common cause of verification failure and can restart the review process. Organizations are advised to request a D-U-N-S number early, since its issuance can take up to 30 days. The guide walks through each stage in sequence so applicants can complete setup without rework.

0
ProgrammingDEV Community ·

Five Cognitive Distortions That Distort How Workers Read Performance Reviews

Performance review season often triggers negative thinking patterns, according to an article on DEV Community drawing on cognitive behavioral therapy. The piece identifies five common distortions, including mind reading, catastrophizing, labeling, and all-or-nothing thinking, that lead employees to misread routine manager comments. It suggests practical CBT techniques, such as weighing alternative interpretations and testing predictions against evidence. The author argues that feedback addresses specific behaviors rather than a person's overall worth. The guidance is aimed at helping employees approach reviews with a more balanced and realistic perspective.