Comments (3)
Hi guys! I make it in browserify.
here is what have I done.
browserify ./dist/CryptLib.js --standalone CryptLib -o CryptLib.browser.js
Then you can load the CryptLib.browser.js in your html.
<script src="./dist/CryptLib.browser.js" charset="utf-8"></script>
<script>
var _crypt = new CryptLib();
plainText = 'This is the text to be encrypted';
// 16 bytes = 128 bit
iv = _crypt.generateRandomIV(16);
//32 bytes = 256 bits
key = _crypt.getHashSha256('my secret key', 32),
cypherText = _crypt.encrypt(plainText, key, iv);
console.log('iv = %s', iv);
console.log('key = %s', key);
console.log('Cypher text = %s', cypherText);
console.log('Plain text = %s', _crypt.decrypt(cypherText, key, iv));
</script>
from cross-platform-aes-encryption.
+1
from cross-platform-aes-encryption.
+1
from cross-platform-aes-encryption.
Related Issues (20)
- Encrypt in java and Decrypt in IOS - Not working HOT 1
- Decryption result getting null in IOS
- Encryption in c# is broken if string to encode contains non English characters (with fix)
- iOS Swift Problem HOT 2
- encryption and decryption error when I encrypt a long string with C#
- Not working in IOS. Please check before using. HOT 2
- How to implement encryption and decryption in PHP? HOT 1
- Encrypted string in C# and Decryption IOS vise versa not working
- Facing problem while decryption in iphone5
- Cancelled issue reporter's mistake
- string decryption failed in c# which encrypted in objective c
- Android encryption and decryption facing issue
- The key is not correctly converted to hex string in iOS 13 beta
- Add authentication
- How can i use it in Swift 5 or 4 HOT 1
- .Net Support
- Unable to decrypt my encrypted data. HOT 2
- Refactor - c#, android and web
- Request for a feature in Golang
- Cut big Sentence after Decrypt
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cross-platform-aes-encryption.