Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/konstantinullrich/hashcash
A hashcash proof of work implementation for Dart and Flutter
https://github.com/konstantinullrich/hashcash
dart-package dartlang flutter flutter-package hashcash proof-of-work
Last synced: about 1 month ago
JSON representation
A hashcash proof of work implementation for Dart and Flutter
- Host: GitHub
- URL: https://github.com/konstantinullrich/hashcash
- Owner: konstantinullrich
- License: mit
- Created: 2020-01-22T09:49:55.000Z (almost 5 years ago)
- Default Branch: trunk
- Last Pushed: 2023-12-09T09:56:18.000Z (11 months ago)
- Last Synced: 2024-09-28T16:20:41.560Z (about 2 months ago)
- Topics: dart-package, dartlang, flutter, flutter-package, hashcash, proof-of-work
- Language: Dart
- Homepage: https://pub.dev/packages/hashcash_dart
- Size: 30.3 KB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# Hashcash
Hashcash is a proof-of-work algorithm, which has been used as a denial-of-service counter measure technique in a
number of systems.A hashcash stamp constitutes a proof-of-work which takes a parameterizable amount of work to compute for the sender.
The recipient (and indeed anyone as it is publicly auditable) can verify received hashcash stamps efficiently.
Hashcash was invented by [Adam Back][cypherspace] in [1997][papers]At this point it is most widely used as the [bitcoin][bitcoin] mining function.
The email anti-spam tool, like the proof-of-work algorithm, is also called hashcash and is used to create stamps to
attach to mail to add a micro-cost to sending mail to deter spamming. The main use of the hashcash stamp is as a
white-listing hint to help hashcash users avoid losing email due to content based and blacklist based anti-spam systems.Hashcash source code includes a library form, and also the algorithm is extremely simple to code from scratch with the
availability of a hash library. Verification can be done by a human eye (count leading 0s) even with availability of
common preinstalled command line tools such as sha1sum. The algorithm works with a cryptographic hash, such as SHA1,
SHA256 or coming SHA3 that exhibits 2nd-preimage resistance. Note that 2nd-preimage resistance is a stronger hash
property than the collision resistance property.## Usage
A simple example:
```dart
import 'package:hashcash/hashcash_dart.dart';main() {
var stamp = Hashcash.mint('[email protected]');
var checked = Hashcash.check(stamp, resource: '[email protected]');
}
```## Features and bugs
Please file feature requests and bugs at the [issue tracker][tracker].
[cypherspace]: http://www.cypherspace.org/adam/
[papers]: http://hashcash.org/papers/
[bitcoin]: https://bitcoin.it/
[tracker]: https://github.com/konstantinullrich/hashcash/issues