Skip to content
This repository has been archived by the owner on Oct 20, 2024. It is now read-only.

Commit

Permalink
javascript: Initial
Browse files Browse the repository at this point in the history
  • Loading branch information
M3DZIK committed Sep 26, 2023
1 parent beee028 commit 5cb9e7d
Show file tree
Hide file tree
Showing 14 changed files with 4,374 additions and 0 deletions.
1 change: 1 addition & 0 deletions java/src/main/java/dev/medzik/libcrypto/Aes.java
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ public final class Aes {
* @param type AES type to use
* @param key secret key to use for encryption
* @param clearBytes clear bytes to encrypt (UTF-8)
* @return Encrypted cipher (hex encoded)
*/
public static String encrypt(AesType type, byte[] key, byte[] clearBytes) throws InvalidKeyException, IllegalBlockSizeException, BadPaddingException {
// generate random IV
Expand Down
2 changes: 2 additions & 0 deletions javascript/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
node_modules/
lib/
4 changes: 4 additions & 0 deletions javascript/.npmignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
src/

/jest.config.js
/tsconfig.json
5 changes: 5 additions & 0 deletions javascript/jest.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
/** @type {import('ts-jest').JestConfigWithTsJest} */
module.exports = {
preset: 'ts-jest',
testEnvironment: 'node',
};
Loading

0 comments on commit 5cb9e7d

Please sign in to comment.