Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 8 additions & 9 deletions .github/workflows/build-and-publish-beta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,27 +9,26 @@ jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
uses: actions/setup-node@v4
with:
node-version: 13.x
- run: npm install
node-version: 22.x
- run: npm ci
- run: npm test
env:
CI: true
- run: npm run browser
publish:
needs: test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 13.x
node-version: 22.x
registry-url: https://registry.npmjs.org/
- run: npm config set package-lock false
- run: npm install
- run: npm ci
- run: |
npm config set //registry.npmjs.org/:_authToken=$NODE_AUTH_TOKEN
npm config set scope "@meeco"
Expand Down
17 changes: 8 additions & 9 deletions .github/workflows/build-and-publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,27 +10,26 @@ jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
uses: actions/setup-node@v4
with:
node-version: 13.x
- run: npm install
node-version: 22.x
- run: npm ci
- run: npm test
env:
CI: true
- run: npm run browser
publish:
needs: test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 13.x
node-version: 22.x
registry-url: https://registry.npmjs.org/
- run: npm config set package-lock false
- run: npm install
- run: npm ci
- run: |
npm config set //registry.npmjs.org/:_authToken=$NODE_AUTH_TOKEN
npm config set scope "@meeco"
Expand Down
9 changes: 4 additions & 5 deletions .github/workflows/build-and-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,17 +8,16 @@ jobs:

strategy:
matrix:
node-version: [10.x, 13.x]
node-version: [22.x]

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- run: npm install
- run: npm ci
- run: npm test
env:
CI: true
- run: npm run browser
- run: npm pack
4 changes: 1 addition & 3 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
node_modules
# Parcel
.cache/
dist/
.rts2_cache*/
coverage/
junit.xml
coverage/
4 changes: 2 additions & 2 deletions .npmignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@ src/
demo/
test/
coverage/
junit.xml

.rts2*

karma.conf.js
jest.config.js
vite.config.ts
tsconfig.json
tslint.json
eslint.config.mjs
Jenkinsfile

dist/demo
Expand Down
1 change: 1 addition & 0 deletions .nvmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
22
3 changes: 2 additions & 1 deletion .prettierrc
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,6 @@
"tabWidth": 2,
"useTabs": false,
"singleQuote": true,
"printWidth": 100
"printWidth": 100,
"trailingComma": "es5"
}
14 changes: 14 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# Changelog

## 3.0.0 (13.02.2026)

- **BREAKING**: Minimum Node.js version raised from 12.4 to 22
- Upgrade TypeScript 3.9 → 5.9
- Replace bili/rollup build with dual CJS + ESM tsc output
- Upgrade node-forge 0.10.0 → 1.3.x
- Upgrade bson 4 → 7, yaml 1 → 2, buffer 5 → 6
- Replace Jest + ts-jest with Vitest (native TypeScript support via Vite)
- Upgrade Prettier 2 → 3
- Replace TSLint (deprecated) with ESLint 9 flat config
- Remove Karma browser test runner (deprecated since Apr 2023, no longer maintained; all crypto logic uses node-forge which is pure JS — Vitest covers all code paths)
- Update GitHub Actions to v4, Node 22
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ TypeScript version of [Cryppo](https://github.com/Meeco/cryppo) allowing easy en
- `npm install`
- `npm start`

Will run the project in `demo/` using parcel. Visit [http://localhost:1234](http://localhost:1234) to show.
Will run the project in `demo/` using Vite. Visit [http://localhost:5173](http://localhost:5173) to show.

## Encrypting Data (Symmetric Key Encryption)

Expand Down
13 changes: 5 additions & 8 deletions demo/encryption_with_derived_key.html
Original file line number Diff line number Diff line change
@@ -1,12 +1,9 @@
<html>
<head>
<link rel="stylesheet" href="./styles.scss" />
</head>
<body>
<ul class="nav">
<li><a href="/">Passphrase</a></li>
<li><a href="/encryption_with_generated_key.html">Key</a></li>
<li><a href="/encryption_with_signature.html">RSA</a></li>
<li><a href="/demo/encryption_with_derived_key.html">Passphrase</a></li>
<li><a href="/demo/encryption_with_generated_key.html">Key</a></li>
<li><a href="/demo/encryption_with_signature.html">RSA</a></li>
</ul>
<h1 class="center">Encryption With Derived Key</h1>
<fieldset>
Expand Down Expand Up @@ -52,7 +49,7 @@ <h1 class="center">Encryption With Derived Key</h1>
<textarea id="decryptTextOutput" placeholder="Decrypted text will output here"></textarea>
</fieldset>

<div style="text-align: right; padding: 2rem;">
<div style="text-align: right; padding: 2rem">
<p>
<label for="serializationVersionSelection">Serialization Format:</label>

Expand All @@ -63,6 +60,6 @@ <h1 class="center">Encryption With Derived Key</h1>
</p>
</div>

<script src="./encryption_with_derived_key.ts"></script>
<script type="module" src="./encryption_with_derived_key.ts"></script>
</body>
</html>
1 change: 1 addition & 0 deletions demo/encryption_with_derived_key.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import './styles.css';
import { decryptWithKeyDerivedFromString, encryptWithKeyDerivedFromString } from '../src/index';
import { CipherStrategy } from '../src/strategies';
import {
Expand Down
13 changes: 5 additions & 8 deletions demo/encryption_with_generated_key.html
Original file line number Diff line number Diff line change
@@ -1,12 +1,9 @@
<html>
<head>
<link rel="stylesheet" href="./styles.scss" />
</head>
<body>
<ul class="nav">
<li><a href="/">Passphrase</a></li>
<li><a href="/encryption_with_generated_key.html">Key</a></li>
<li><a href="/encryption_with_signature.html">RSA</a></li>
<li><a href="/demo/encryption_with_derived_key.html">Passphrase</a></li>
<li><a href="/demo/encryption_with_generated_key.html">Key</a></li>
<li><a href="/demo/encryption_with_signature.html">RSA</a></li>
</ul>
<h1 class="center">Encryption With Generated Key</h1>
<fieldset>
Expand Down Expand Up @@ -96,7 +93,7 @@ <h1 class="center">Encryption With Generated Key</h1>
<textarea id="decryptTextOutput" placeholder="Decrypted text will output here"></textarea>
</fieldset>

<div style="text-align: right; padding: 2rem;">
<div style="text-align: right; padding: 2rem">
<p>
<label for="serializationVersionSelection">Serialization Format:</label>

Expand All @@ -107,6 +104,6 @@ <h1 class="center">Encryption With Generated Key</h1>
</p>
</div>

<script src="./encryption_with_generated_key.ts"></script>
<script type="module" src="./encryption_with_generated_key.ts"></script>
</body>
</html>
1 change: 1 addition & 0 deletions demo/encryption_with_generated_key.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import './styles.css';
import { decryptWithKey, encryptWithGeneratedKey, encryptWithKey } from '../src/index';
import { CipherStrategy } from '../src/strategies';
import {
Expand Down
13 changes: 5 additions & 8 deletions demo/encryption_with_signature.html
Original file line number Diff line number Diff line change
@@ -1,12 +1,9 @@
<html>
<head>
<link rel="stylesheet" href="./styles.scss" />
</head>
<body>
<ul class="nav">
<li><a href="/">Passphrase</a></li>
<li><a href="/encryption_with_generated_key.html">Key</a></li>
<li><a href="/encryption_with_signature.html">RSA</a></li>
<li><a href="/demo/encryption_with_derived_key.html">Passphrase</a></li>
<li><a href="/demo/encryption_with_generated_key.html">Key</a></li>
<li><a href="/demo/encryption_with_signature.html">RSA</a></li>
</ul>

<h1 class="center">Encryption With RSA Signature</h1>
Expand Down Expand Up @@ -42,7 +39,7 @@ <h1 class="center">Encryption With RSA Signature</h1>
<textarea id="decryptTextOutput" placeholder="Decrypted text will output here"></textarea>
</fieldset>

<div style="text-align: right; padding: 2rem; display: none;">
<div style="text-align: right; padding: 2rem; display: none">
<p>
<label for="serializationVersionSelection">Serialization Format:</label>

Expand All @@ -53,6 +50,6 @@ <h1 class="center">Encryption With RSA Signature</h1>
</p>
</div>

<script src="./encryption_with_signature.ts"></script>
<script type="module" src="./encryption_with_signature.ts"></script>
</body>
</html>
1 change: 1 addition & 0 deletions demo/encryption_with_signature.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import './styles.css';
import {
decryptSerializedWithPrivateKey,
loadRsaSignature,
Expand Down
File renamed without changes.
18 changes: 18 additions & 0 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
import eslint from '@eslint/js';
import tseslint from 'typescript-eslint';
import eslintConfigPrettier from 'eslint-config-prettier';

export default tseslint.config(
eslint.configs.recommended,
...tseslint.configs.recommended,
eslintConfigPrettier,
{
rules: {
'@typescript-eslint/no-empty-function': 'off',
'@typescript-eslint/no-explicit-any': 'off',
'@typescript-eslint/no-unused-vars': ['error', { argsIgnorePattern: '^_' }],
'no-irregular-whitespace': 'off',
},
},
{ ignores: ['demo/**', 'dist/**', 'node_modules/**', 'jest.config.js'] }
);
9 changes: 0 additions & 9 deletions jest.config.js

This file was deleted.

76 changes: 0 additions & 76 deletions karma.conf.js

This file was deleted.

Loading