diff options
author | Sebastian <sebasjm@gmail.com> | 2022-01-16 17:54:48 -0300 |
---|---|---|
committer | Sebastian <sebasjm@gmail.com> | 2022-01-16 17:55:01 -0300 |
commit | bc817a638d4ddfff0d5f05b51453c6ca790b24ec (patch) | |
tree | ef6d62b503a163f7738ce37785b3c38ff48abb76 /packages/taler-wallet-webextension/src/serviceWorkerCryptoWorkerFactory.ts | |
parent | f8ae2671c176e293843525c4fc5dd4a33653fd10 (diff) | |
download | wallet-core-bc817a638d4ddfff0d5f05b51453c6ca790b24ec.tar.xz |
#7120 manifest v3: first iteration working
new permission needed: scripting
chrome.browserAction -> chrome.action
webRequestBlocking is not possible anymore
chrome.extension.getUrl -> chrome.runtime.getUrl
new serviceWorkerHttpLib: using fetch
new serviceWorkerCryptoWorkerFactory: using syncCryptoImpl
few other minor changes
still missing some other changes like migrating setTimeout to chrome.alarms api
Diffstat (limited to 'packages/taler-wallet-webextension/src/serviceWorkerCryptoWorkerFactory.ts')
-rw-r--r-- | packages/taler-wallet-webextension/src/serviceWorkerCryptoWorkerFactory.ts | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/packages/taler-wallet-webextension/src/serviceWorkerCryptoWorkerFactory.ts b/packages/taler-wallet-webextension/src/serviceWorkerCryptoWorkerFactory.ts new file mode 100644 index 000000000..6084ebae1 --- /dev/null +++ b/packages/taler-wallet-webextension/src/serviceWorkerCryptoWorkerFactory.ts @@ -0,0 +1,36 @@ +/* + This file is part of TALER + (C) 2016 GNUnet e.V. + + TALER is free software; you can redistribute it and/or modify it under the + terms of the GNU General Public License as published by the Free Software + Foundation; either version 3, or (at your option) any later version. + + TALER is distributed in the hope that it will be useful, but WITHOUT ANY + WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR + A PARTICULAR PURPOSE. See the GNU General Public License for more details. + + You should have received a copy of the GNU General Public License along with + TALER; see the file COPYING. If not, see <http://www.gnu.org/licenses/> + */ + +/** + * API to access the Taler crypto worker thread. + * @author Florian Dold + */ + +import { + CryptoWorker, + CryptoWorkerFactory, + SynchronousCryptoWorker, +} from "@gnu-taler/taler-wallet-core"; + +export class SynchronousCryptoWorkerFactory implements CryptoWorkerFactory { + startWorker(): CryptoWorker { + return new SynchronousCryptoWorker(); + } + + getConcurrency(): number { + return 1; + } +} |