A small utility library for crypto. It declares a class names CryptoUtils
which can replace the one in package:crypto
. It includes the few methods this class provides.
I created this library because I had a bunch of crypto-related utility functions that I used across different projects and wanted to avoid code duplication.
If you have other crypto-related code you don't want to duplicate, feel free to include it and file a PR.
Currently it includes:
CryptoUtils
from package:crypto
Hash
and several fixed-sized hash classes, Hash128
, Hash160
, Hash256
, Hash512
Add this to your package's pubspec.yaml file:
dependencies:
cryptoutils: ^0.4.0
You can install packages from the command line:
with pub:
$ pub get
with Flutter:
$ flutter packages get
Alternatively, your editor might support pub get
or flutter packages get
.
Check the docs for your editor to learn more.
Now in your Dart code, you can use:
import 'package:cryptoutils/cryptoutils.dart';
Version | Uploaded | Documentation | Archive |
---|---|---|---|
0.4.0 | Dec 19, 2018 |
|
|
0.3.0 | Jan 31, 2018 |
|
|
0.2.1 | Apr 12, 2016 |
|
|
0.2.0+2 | Dec 21, 2015 |
|
|
0.2.0+1 | Dec 15, 2015 |
|
|
0.2.0 | Dec 15, 2015 |
|
|
0.1.10 | Jun 10, 2015 |
|
|
0.1.9 | Oct 28, 2014 |
|
|
0.1.8 | Oct 8, 2014 |
|
|
0.1.7 | Oct 1, 2014 |
|
|
Popularity:
Describes how popular the package is relative to other packages.
[more]
|
73
|
Health:
Code health derived from static analysis.
[more]
|
99
|
Maintenance:
Reflects how tidy and up-to-date the package is.
[more]
|
70
|
Overall:
Weighted score of the above.
[more]
|
80
|
We analyzed this package on Feb 14, 2019, and provided a score, details, and suggestions below. Analysis was completed with status completed using:
Detected platforms: Flutter, web, other
No platform restriction found in primary library
package:cryptoutils/cryptoutils.dart
.
Fix lib/encoding/base64.dart
. (-0.50 points)
Analysis of lib/encoding/base64.dart
reported 1 hint:
line 445 col 14: The method '_divmod256' isn't used.
Fix lib/utils.dart
. (-0.50 points)
Analysis of lib/utils.dart
reported 1 hint:
line 80 col 22: Use isEmpty instead of length
Format lib/hash.dart
.
Run dartfmt
to format lib/hash.dart
.
The package description is too short. (-20 points)
Add more detail to the description
field of pubspec.yaml
. Use 60 to 180 characters to describe the package, what it does, and its target use case.
Maintain an example. (-10 points)
Create a short demo in the example/
directory to show how to use this package.
Common filename patterns include main.dart
, example.dart
, and cryptoutils.dart
. Packages with multiple examples should provide example/README.md
.
For more information see the pub package layout conventions.
Package | Constraint | Resolved | Available |
---|---|---|---|
Direct dependencies | |||
Dart SDK | >=2.0.0 <3.0.0 | ||
collection | >=1.1.1 <2.0.0 | 1.14.11 | |
Dev dependencies | |||
test | any |