├── l10n ├── .gitkeep ├── uz.json ├── kab.json ├── km.json ├── lo.json ├── ms_MY.json ├── ug.json ├── az.json ├── bn_BD.json ├── kn.json ├── ta.json ├── lb.json ├── km.js ├── lo.js ├── uz.js ├── kab.js ├── ms_MY.js ├── vi.json ├── az.js ├── id.json ├── ta.js ├── ug.js ├── bn_BD.js ├── eo.json ├── kn.js ├── lb.js ├── fa.json ├── nn_NO.json ├── vi.js ├── id.js ├── si.json ├── eo.js ├── fa.js ├── nn_NO.js ├── si.js ├── sr@latin.json ├── cy_GB.json ├── pt_PT.json ├── sr@latin.js ├── cy_GB.js ├── pt_PT.js ├── th.json ├── et_EE.json ├── mn.json ├── th.js ├── et_EE.js ├── mn.js ├── ar.json ├── oc.json ├── oc.js ├── ar.js ├── mk.json ├── ro.json ├── mk.js ├── ro.js ├── br.json ├── br.js ├── lv.json ├── lv.js ├── ast.json ├── ast.js ├── lt_LT.json ├── lt_LT.js ├── af.json ├── af.js ├── es_AR.json ├── sq.json ├── es_AR.js ├── sq.js ├── zh_CN.json ├── zh_CN.js ├── ka_GE.json ├── ka_GE.js ├── da.json ├── da.js ├── ko.json ├── ko.js ├── es_419.json ├── es_CL.json ├── es_CO.json ├── es_CR.json ├── es_DO.json ├── es_EC.json ├── es_GT.json ├── es_HN.json ├── es_MX.json ├── es_NI.json ├── es_PA.json ├── es_PE.json ├── es_PR.json ├── es_PY.json ├── es_SV.json ├── es_UY.json ├── es_419.js ├── es_CL.js ├── es_CO.js ├── es_CR.js ├── es_DO.js ├── es_EC.js ├── es_GT.js ├── es_HN.js ├── es_MX.js ├── es_NI.js ├── es_PA.js ├── es_PE.js ├── es_PR.js ├── es_PY.js ├── es_SV.js ├── es_UY.js ├── zh_HK.json ├── zh_HK.js ├── zh_TW.json ├── he.json ├── zh_TW.js ├── he.js ├── ja.json ├── sr.json ├── ja.js └── sr.js ├── AUTHORS.md ├── .babelrc ├── screenshots ├── settings.png └── challenge.png ├── krankerl.toml ├── templates ├── personal.php ├── challenge.php └── loginsetup.php ├── src ├── webpack.dev.js ├── webpack.prod.js ├── store.js ├── mixins │ └── Nextcloud.js ├── webpack.common.js ├── logger.js ├── webpack.test.js ├── main-login-setup.js ├── main-challenge.js ├── tests │ ├── setup.js │ └── components │ │ ├── Device.spec.js │ │ └── PersonalSettings.spec.js ├── services │ └── RegistrationService.js ├── main-settings.js └── components │ └── LoginSetup.vue ├── .gitignore ├── Makefile ├── .github ├── ISSUE_TEMPLATE │ ├── question.md │ ├── feature_request.md │ └── bug.md ├── workflows │ ├── dependabot-approve.yml │ └── static-analysis.yml └── dependabot.yml ├── appinfo ├── autoload.php ├── routes.php └── info.xml ├── nbproject ├── project.xml └── project.properties ├── .tx └── config ├── .nextcloudignore ├── .php_cs.dist ├── .scrutinizer.yml ├── tests ├── bootstrap.php ├── phpunit.xml ├── Unit │ ├── Event │ │ └── StateChangedTest.php │ └── Activity │ │ └── SettingTest.php └── psalm-baseline.xml ├── css └── style.css ├── .jshintrc ├── lib ├── Event │ ├── StateChanged.php │ └── DisabledByAdmin.php ├── Settings │ └── Personal.php ├── AppInfo │ └── Application.php ├── Provider │ └── U2FLoginProvider.php ├── Listener │ ├── StateChangeActivity.php │ └── StateChangeRegistryUpdater.php ├── Db │ ├── Registration.php │ └── RegistrationMapper.php ├── Activity │ └── Setting.php └── Controller │ └── SettingsController.php ├── img ├── app.svg └── app-dark.svg ├── psalm.xml ├── composer.json └── README.md /l10n/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /AUTHORS.md: -------------------------------------------------------------------------------- 1 | # Authors 2 | 3 | * Christoph Wurst: 4 | -------------------------------------------------------------------------------- /.babelrc: -------------------------------------------------------------------------------- 1 | { 2 | "env": { 3 | "test": { 4 | "plugins": ["istanbul"] 5 | } 6 | } 7 | } -------------------------------------------------------------------------------- /screenshots/settings.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nextcloud/twofactor_u2f/HEAD/screenshots/settings.png -------------------------------------------------------------------------------- /screenshots/challenge.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nextcloud/twofactor_u2f/HEAD/screenshots/challenge.png -------------------------------------------------------------------------------- /krankerl.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | before_cmds = [ 3 | "composer install --no-dev -o", 4 | "npm ci", 5 | "npm run build", 6 | ] 7 | -------------------------------------------------------------------------------- /l10n/uz.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Add" : "Add", 3 | "Remove" : "Remove" 4 | },"pluralForm" :"nplurals=1; plural=0;" 5 | } -------------------------------------------------------------------------------- /l10n/kab.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Add" : "Rnu", 3 | "Remove" : "Kkes" 4 | },"pluralForm" :"nplurals=2; plural=(n != 1);" 5 | } -------------------------------------------------------------------------------- /l10n/km.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Add" : "បញ្ចូល", 3 | "Remove" : "ដកចេញ" 4 | },"pluralForm" :"nplurals=1; plural=0;" 5 | } -------------------------------------------------------------------------------- /l10n/lo.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Add" : "ເພີ່ມ", 3 | "Remove" : "ຍ້າຍອອກ" 4 | },"pluralForm" :"nplurals=1; plural=0;" 5 | } -------------------------------------------------------------------------------- /l10n/ms_MY.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Add" : "Tambah", 3 | "Remove" : "Buang" 4 | },"pluralForm" :"nplurals=1; plural=0;" 5 | } -------------------------------------------------------------------------------- /l10n/ug.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Add" : "قوش", 3 | "Remove" : "چىقىرىۋەت" 4 | },"pluralForm" :"nplurals=2; plural=(n != 1);" 5 | } -------------------------------------------------------------------------------- /l10n/az.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Add" : "Əlavə etmək", 3 | "Remove" : "Sil" 4 | },"pluralForm" :"nplurals=2; plural=(n != 1);" 5 | } -------------------------------------------------------------------------------- /l10n/bn_BD.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Add" : "যোগ করুন", 3 | "Remove" : "অপসারণ" 4 | },"pluralForm" :"nplurals=2; plural=(n != 1);" 5 | } -------------------------------------------------------------------------------- /l10n/kn.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Add" : "ಸೇರಿಸಿ", 3 | "Remove" : "ತೆಗೆದುಹಾಕಿ" 4 | },"pluralForm" :"nplurals=2; plural=(n > 1);" 5 | } -------------------------------------------------------------------------------- /l10n/ta.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Add" : "சேர்க்க", 3 | "Remove" : "அகற்றுக" 4 | },"pluralForm" :"nplurals=2; plural=(n != 1);" 5 | } -------------------------------------------------------------------------------- /l10n/lb.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Add" : "Derbäimaachen", 3 | "Remove" : "Läschen" 4 | },"pluralForm" :"nplurals=2; plural=(n != 1);" 5 | } -------------------------------------------------------------------------------- /l10n/km.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Add" : "បញ្ចូល", 5 | "Remove" : "ដកចេញ" 6 | }, 7 | "nplurals=1; plural=0;"); 8 | -------------------------------------------------------------------------------- /l10n/lo.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Add" : "ເພີ່ມ", 5 | "Remove" : "ຍ້າຍອອກ" 6 | }, 7 | "nplurals=1; plural=0;"); 8 | -------------------------------------------------------------------------------- /l10n/uz.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Add" : "Add", 5 | "Remove" : "Remove" 6 | }, 7 | "nplurals=1; plural=0;"); 8 | -------------------------------------------------------------------------------- /l10n/kab.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Add" : "Rnu", 5 | "Remove" : "Kkes" 6 | }, 7 | "nplurals=2; plural=(n != 1);"); 8 | -------------------------------------------------------------------------------- /l10n/ms_MY.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Add" : "Tambah", 5 | "Remove" : "Buang" 6 | }, 7 | "nplurals=1; plural=0;"); 8 | -------------------------------------------------------------------------------- /l10n/vi.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Add" : "Thêm", 3 | "Retry" : "Thử lại", 4 | "Remove" : "Xóa" 5 | },"pluralForm" :"nplurals=1; plural=0;" 6 | } -------------------------------------------------------------------------------- /l10n/az.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Add" : "Əlavə etmək", 5 | "Remove" : "Sil" 6 | }, 7 | "nplurals=2; plural=(n != 1);"); 8 | -------------------------------------------------------------------------------- /l10n/id.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Add" : "Masukkan", 3 | "Retry" : "Ulangi", 4 | "Remove" : "Hapus" 5 | },"pluralForm" :"nplurals=1; plural=0;" 6 | } -------------------------------------------------------------------------------- /l10n/ta.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Add" : "சேர்க்க", 5 | "Remove" : "அகற்றுக" 6 | }, 7 | "nplurals=2; plural=(n != 1);"); 8 | -------------------------------------------------------------------------------- /l10n/ug.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Add" : "قوش", 5 | "Remove" : "چىقىرىۋەت" 6 | }, 7 | "nplurals=2; plural=(n != 1);"); 8 | -------------------------------------------------------------------------------- /templates/personal.php: -------------------------------------------------------------------------------- 1 | 5 | 6 |
7 | -------------------------------------------------------------------------------- /l10n/bn_BD.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Add" : "যোগ করুন", 5 | "Remove" : "অপসারণ" 6 | }, 7 | "nplurals=2; plural=(n != 1);"); 8 | -------------------------------------------------------------------------------- /l10n/eo.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Add" : "Aldoni", 3 | "Retry" : "Reprovi", 4 | "Remove" : "Forigi" 5 | },"pluralForm" :"nplurals=2; plural=(n != 1);" 6 | } -------------------------------------------------------------------------------- /l10n/kn.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Add" : "ಸೇರಿಸಿ", 5 | "Remove" : "ತೆಗೆದುಹಾಕಿ" 6 | }, 7 | "nplurals=2; plural=(n > 1);"); 8 | -------------------------------------------------------------------------------- /l10n/lb.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Add" : "Derbäimaachen", 5 | "Remove" : "Läschen" 6 | }, 7 | "nplurals=2; plural=(n != 1);"); 8 | -------------------------------------------------------------------------------- /l10n/fa.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Add" : "افزودن", 3 | "Retry" : "تلاش دوباره", 4 | "Remove" : "برداشتن" 5 | },"pluralForm" :"nplurals=2; plural=(n > 1);" 6 | } -------------------------------------------------------------------------------- /l10n/nn_NO.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Add" : "Legg til", 3 | "Retry" : "Forsøk att", 4 | "Remove" : "Fjern" 5 | },"pluralForm" :"nplurals=2; plural=(n != 1);" 6 | } -------------------------------------------------------------------------------- /l10n/vi.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Add" : "Thêm", 5 | "Retry" : "Thử lại", 6 | "Remove" : "Xóa" 7 | }, 8 | "nplurals=1; plural=0;"); 9 | -------------------------------------------------------------------------------- /l10n/id.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Add" : "Masukkan", 5 | "Retry" : "Ulangi", 6 | "Remove" : "Hapus" 7 | }, 8 | "nplurals=1; plural=0;"); 9 | -------------------------------------------------------------------------------- /l10n/si.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Add" : "එකතු කරන්න", 3 | "Retry" : "නැවත උත්සාහ කරන්න", 4 | "Remove" : "ඉවත් කරන්න" 5 | },"pluralForm" :"nplurals=2; plural=(n != 1);" 6 | } -------------------------------------------------------------------------------- /l10n/eo.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Add" : "Aldoni", 5 | "Retry" : "Reprovi", 6 | "Remove" : "Forigi" 7 | }, 8 | "nplurals=2; plural=(n != 1);"); 9 | -------------------------------------------------------------------------------- /l10n/fa.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Add" : "افزودن", 5 | "Retry" : "تلاش دوباره", 6 | "Remove" : "برداشتن" 7 | }, 8 | "nplurals=2; plural=(n > 1);"); 9 | -------------------------------------------------------------------------------- /l10n/nn_NO.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Add" : "Legg til", 5 | "Retry" : "Forsøk att", 6 | "Remove" : "Fjern" 7 | }, 8 | "nplurals=2; plural=(n != 1);"); 9 | -------------------------------------------------------------------------------- /l10n/si.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Add" : "එකතු කරන්න", 5 | "Retry" : "නැවත උත්සාහ කරන්න", 6 | "Remove" : "ඉවත් කරන්න" 7 | }, 8 | "nplurals=2; plural=(n != 1);"); 9 | -------------------------------------------------------------------------------- /l10n/sr@latin.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Add" : "Dodaj", 3 | "Remove" : "Ukloni" 4 | },"pluralForm" :"nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);" 5 | } -------------------------------------------------------------------------------- /src/webpack.dev.js: -------------------------------------------------------------------------------- 1 | const { merge } = require('webpack-merge'); 2 | const common = require('./webpack.common.js'); 3 | 4 | module.exports = merge(common, { 5 | mode: 'development', 6 | devtool: 'source-map', 7 | }) 8 | -------------------------------------------------------------------------------- /src/webpack.prod.js: -------------------------------------------------------------------------------- 1 | const { merge } = require('webpack-merge') 2 | const common = require('./webpack.common.js') 3 | 4 | module.exports = merge(common, { 5 | mode: 'production', 6 | devtool: 'source-map' 7 | }) 8 | -------------------------------------------------------------------------------- /l10n/cy_GB.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Add" : "Ychwanegu", 3 | "Retry" : "Ceisio eto", 4 | "Remove" : "Gwaredu" 5 | },"pluralForm" :"nplurals=4; plural=(n==1) ? 0 : (n==2) ? 1 : (n != 8 && n != 11) ? 2 : 3;" 6 | } -------------------------------------------------------------------------------- /l10n/pt_PT.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Add" : "Adicionar", 3 | "Retry" : "Repetir", 4 | "Remove" : "Remover" 5 | },"pluralForm" :"nplurals=3; plural=(n == 0 || n == 1) ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;" 6 | } -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | /js 3 | 4 | /coverage 5 | /.nyc_output 6 | /node_modules 7 | 8 | /nbproject/private/ 9 | /vendor 10 | composer.phar 11 | /.php_cs.cache 12 | 13 | /tests/clover*.xml 14 | /tests/.phpunit.result.cache 15 | -------------------------------------------------------------------------------- /Makefile: -------------------------------------------------------------------------------- 1 | # Makefile for building the project 2 | 3 | all: install 4 | 5 | clean: 6 | rm -rf vendor 7 | rm -rf node_modules 8 | rm -rf js/build 9 | 10 | install: 11 | composer install --dev 12 | npm install 13 | npm run build 14 | -------------------------------------------------------------------------------- /l10n/sr@latin.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Add" : "Dodaj", 5 | "Remove" : "Ukloni" 6 | }, 7 | "nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);"); 8 | -------------------------------------------------------------------------------- /l10n/cy_GB.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Add" : "Ychwanegu", 5 | "Retry" : "Ceisio eto", 6 | "Remove" : "Gwaredu" 7 | }, 8 | "nplurals=4; plural=(n==1) ? 0 : (n==2) ? 1 : (n != 8 && n != 11) ? 2 : 3;"); 9 | -------------------------------------------------------------------------------- /l10n/pt_PT.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Add" : "Adicionar", 5 | "Retry" : "Repetir", 6 | "Remove" : "Remover" 7 | }, 8 | "nplurals=3; plural=(n == 0 || n == 1) ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;"); 9 | -------------------------------------------------------------------------------- /l10n/th.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Name your device" : "ตั้งชื่ออุปกรณ์ของคุณ", 3 | "Add" : "เพิ่ม", 4 | "Adding your device …" : "กำลังเพิ่มอุปกรณ์ …", 5 | "Unnamed device" : "อุปกรณ์ไม่มีชื่อ", 6 | "Remove" : "ลบออก" 7 | },"pluralForm" :"nplurals=1; plural=0;" 8 | } -------------------------------------------------------------------------------- /l10n/et_EE.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "U2F device" : "U2F seade", 3 | "Add U2F device" : "Lisa U2F seade", 4 | "Add" : "Lisa", 5 | "Retry" : "Proovi uuesti", 6 | "Unnamed device" : "Nimetu seade", 7 | "Remove" : "Eemalda" 8 | },"pluralForm" :"nplurals=2; plural=(n != 1);" 9 | } -------------------------------------------------------------------------------- /l10n/mn.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "U2F device" : "U2F төхөөрөмж", 3 | "Add U2F device" : "U2F төхөөрөмж нэмэх", 4 | "Add" : "нэмэх", 5 | "Retry" : "Дахин оролдох", 6 | "Unnamed device" : "нэргүй төхөөрөммж", 7 | "Remove" : "Устгах" 8 | },"pluralForm" :"nplurals=2; plural=(n != 1);" 9 | } -------------------------------------------------------------------------------- /l10n/th.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Name your device" : "ตั้งชื่ออุปกรณ์ของคุณ", 5 | "Add" : "เพิ่ม", 6 | "Adding your device …" : "กำลังเพิ่มอุปกรณ์ …", 7 | "Unnamed device" : "อุปกรณ์ไม่มีชื่อ", 8 | "Remove" : "ลบออก" 9 | }, 10 | "nplurals=1; plural=0;"); 11 | -------------------------------------------------------------------------------- /l10n/et_EE.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "U2F device" : "U2F seade", 5 | "Add U2F device" : "Lisa U2F seade", 6 | "Add" : "Lisa", 7 | "Retry" : "Proovi uuesti", 8 | "Unnamed device" : "Nimetu seade", 9 | "Remove" : "Eemalda" 10 | }, 11 | "nplurals=2; plural=(n != 1);"); 12 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/question.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: 🙋 Question 3 | about: Do you have a question about the app? 4 | version: 0.1 5 | --- 6 | 7 | ### Question 8 | 9 | 10 | 11 | #### Summary 12 | 13 | 14 | -------------------------------------------------------------------------------- /l10n/mn.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "U2F device" : "U2F төхөөрөмж", 5 | "Add U2F device" : "U2F төхөөрөмж нэмэх", 6 | "Add" : "нэмэх", 7 | "Retry" : "Дахин оролдох", 8 | "Unnamed device" : "нэргүй төхөөрөммж", 9 | "Remove" : "Устгах" 10 | }, 11 | "nplurals=2; plural=(n != 1);"); 12 | -------------------------------------------------------------------------------- /templates/challenge.php: -------------------------------------------------------------------------------- 1 | 6 | 7 | 8 | 9 | 10 |
11 | -------------------------------------------------------------------------------- /appinfo/autoload.php: -------------------------------------------------------------------------------- 1 | 10 | * @copyright Christoph Wurst 2016 11 | */ 12 | require_once __DIR__ . '/../vendor/autoload.php'; 13 | -------------------------------------------------------------------------------- /nbproject/project.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | org.netbeans.modules.php.project 4 | 5 | 6 | twofactor_u2f 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/feature_request.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: 🚀 Feature Request 3 | about: You have a neat idea that should be implemented? 4 | version: 0.1 5 | --- 6 | 7 | ### Feature Request 8 | 9 | 10 | 11 | #### Summary 12 | 13 | 14 | -------------------------------------------------------------------------------- /.tx/config: -------------------------------------------------------------------------------- 1 | [main] 2 | host = https://www.transifex.com 3 | lang_map = hu_HU: hu, nb_NO: nb, sk_SK: sk, th_TH: th, ja_JP: ja, bg_BG: bg, cs_CZ: cs, fi_FI: fi 4 | 5 | [o:nextcloud:p:nextcloud:r:twofactor_u2f] 6 | file_filter = translationfiles//twofactor_u2f.po 7 | source_file = translationfiles/templates/twofactor_u2f.pot 8 | source_lang = en 9 | type = PO 10 | 11 | -------------------------------------------------------------------------------- /.github/workflows/dependabot-approve.yml: -------------------------------------------------------------------------------- 1 | name: Dependabot auto approve 2 | on: pull_request_target 3 | 4 | jobs: 5 | build: 6 | runs-on: ubuntu-latest 7 | steps: 8 | - uses: hmarr/auto-approve-action@v2.1.0 9 | if: github.actor == 'dependabot[bot]' || github.actor == 'dependabot-preview[bot]' 10 | with: 11 | github-token: "${{ secrets.GITHUB_TOKEN }}" 12 | -------------------------------------------------------------------------------- /.nextcloudignore: -------------------------------------------------------------------------------- 1 | /AUTHORS.md 2 | /build 3 | /.babelrc 4 | /.jshintrc 5 | /.git 6 | /.github 7 | /.gitignore 8 | /.nextcloudignore 9 | /.travis.yml 10 | /.tx 11 | /.scrutinizer.yml 12 | /CONTRIBUTING.md 13 | /composer.* 14 | /karma.conf.js 15 | /krankerl.toml 16 | /l10n/no-php 17 | /Makefile 18 | /nbproject 19 | /node_modules 20 | /package* 21 | /psalm.xml 22 | /screenshots 23 | /src 24 | /tests 25 | /vendor/bin 26 | -------------------------------------------------------------------------------- /.php_cs.dist: -------------------------------------------------------------------------------- 1 | getFinder() 12 | ->ignoreVCSIgnored(true) 13 | ->notPath('build') 14 | ->notPath('l10n') 15 | ->notPath('lib/Vendor') 16 | ->notPath('src') 17 | ->notPath('vendor') 18 | ->in(__DIR__); 19 | return $config; 20 | -------------------------------------------------------------------------------- /l10n/ar.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Name your device" : "اسم جهازك", 3 | "Add" : "إضافة", 4 | "Retry" : "أعد المحاولة", 5 | "An error occurred. Please try again." : "طرأ هناك خطأ. الرجاء إعادة المحاولة.", 6 | "Your browser does not support U2F." : "متصفحك لا يدعم U2F.", 7 | "Remove" : "حذف" 8 | },"pluralForm" :"nplurals=6; plural=n==0 ? 0 : n==1 ? 1 : n==2 ? 2 : n%100>=3 && n%100<=10 ? 3 : n%100>=11 && n%100<=99 ? 4 : 5;" 9 | } -------------------------------------------------------------------------------- /l10n/oc.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Name your device" : "Nommatz vòstre periferic", 3 | "Add" : "Apondre", 4 | "Adding your device …" : "Apondon del periferic…", 5 | "Retry" : "Tornar ensajar", 6 | "An error occurred. Please try again." : "Una error s'es producha. Mercé d'ensajar tornamai.", 7 | "Unnamed device" : "Periferic sens nom", 8 | "Remove" : "Suprimir" 9 | },"pluralForm" :"nplurals=2; plural=(n > 1);" 10 | } -------------------------------------------------------------------------------- /l10n/oc.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Name your device" : "Nommatz vòstre periferic", 5 | "Add" : "Apondre", 6 | "Adding your device …" : "Apondon del periferic…", 7 | "Retry" : "Tornar ensajar", 8 | "An error occurred. Please try again." : "Una error s'es producha. Mercé d'ensajar tornamai.", 9 | "Unnamed device" : "Periferic sens nom", 10 | "Remove" : "Suprimir" 11 | }, 12 | "nplurals=2; plural=(n > 1);"); 13 | -------------------------------------------------------------------------------- /.github/dependabot.yml: -------------------------------------------------------------------------------- 1 | version: 2 2 | updates: 3 | - package-ecosystem: npm 4 | directory: "/" 5 | schedule: 6 | interval: monthly 7 | time: "03:00" 8 | timezone: Europe/Paris 9 | open-pull-requests-limit: 0 10 | labels: 11 | - 3. to review 12 | - dependencies 13 | - package-ecosystem: composer 14 | directory: "/" 15 | schedule: 16 | interval: monthly 17 | time: "03:00" 18 | timezone: Europe/Paris 19 | open-pull-requests-limit: 0 20 | -------------------------------------------------------------------------------- /l10n/ar.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Name your device" : "اسم جهازك", 5 | "Add" : "إضافة", 6 | "Retry" : "أعد المحاولة", 7 | "An error occurred. Please try again." : "طرأ هناك خطأ. الرجاء إعادة المحاولة.", 8 | "Your browser does not support U2F." : "متصفحك لا يدعم U2F.", 9 | "Remove" : "حذف" 10 | }, 11 | "nplurals=6; plural=n==0 ? 0 : n==1 ? 1 : n==2 ? 2 : n%100>=3 && n%100<=10 ? 3 : n%100>=11 && n%100<=99 ? 4 : 5;"); 12 | -------------------------------------------------------------------------------- /.scrutinizer.yml: -------------------------------------------------------------------------------- 1 | build: 2 | nodes: 3 | analysis: 4 | tests: 5 | override: 6 | - php-scrutinizer-run --enable-security-analysis 7 | 8 | filter: 9 | excluded_paths: 10 | - 'js/tests/*' 11 | - 'vendor/*' 12 | - 'l10n/*' 13 | - 'tests/*' 14 | 15 | imports: 16 | - javascript 17 | - php 18 | 19 | tools: 20 | external_code_coverage: 21 | timeout: 600 # Timeout in seconds. 10 minutes 22 | runs: 1 23 | -------------------------------------------------------------------------------- /tests/bootstrap.php: -------------------------------------------------------------------------------- 1 | 9 | * @copyright Christoph Wurst 2016 10 | */ 11 | 12 | require_once __DIR__.'/../../../lib/base.php'; 13 | require_once __DIR__.'/../vendor/autoload.php'; 14 | 15 | OC::$loader->addValidRoot(OC::$SERVERROOT . '/tests'); 16 | OC_App::loadApp('twofactor_u2f'); 17 | -------------------------------------------------------------------------------- /css/style.css: -------------------------------------------------------------------------------- 1 | /** 2 | * Nextcloud - U2F 2FA 3 | * 4 | * This file is licensed under the Affero General Public License version 3 or 5 | * later. See the COPYING file. 6 | * 7 | * @author Christoph Wurst 8 | * @copyright Christoph Wurst 2016 9 | */ 10 | 11 | /** icons for personal page settings **/ 12 | .nav-icon-u2f-second-factor-auth, .icon-u2f-device { 13 | background-image: url('../img/app-dark.svg?v=1'); 14 | } 15 | 16 | #u2f-http-warning { 17 | color: var(--color-warning); 18 | } 19 | -------------------------------------------------------------------------------- /l10n/mk.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Name your device" : "Име на вашиот уред", 3 | "Add" : "Додади", 4 | "Adding your device …" : "Додавање на вашиот уред ...", 5 | "Retry" : "Обидете се повторно", 6 | "Unnamed device" : "Уреди без име", 7 | "Remove" : "Отстрани", 8 | "The following devices are configured for U2F second-factor authentication:" : "Следниве уреди се конфигурирани за дво-факторна авторизација U2F на вашата сметка:" 9 | },"pluralForm" :"nplurals=2; plural=(n % 10 == 1 && n % 100 != 11) ? 0 : 1;" 10 | } -------------------------------------------------------------------------------- /l10n/ro.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Name your device" : "Numiți dispozitivul dvs.", 3 | "Add" : "Adaugă", 4 | "Adding your device …" : "Adăugarea dispozitivului dvs ...", 5 | "An error occurred: {msg}" : "S-a produs o eroare: {msg}", 6 | "Retry" : "Reîncearcă", 7 | "An error occurred. Please try again." : "S-a produs o eroare. Vă rugăm să încercați din nou.", 8 | "Unnamed device" : "Dispozitiv fără nume", 9 | "Remove" : "Șterge" 10 | },"pluralForm" :"nplurals=3; plural=(n==1?0:(((n%100>19)||((n%100==0)&&(n!=0)))?2:1));" 11 | } -------------------------------------------------------------------------------- /l10n/mk.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Name your device" : "Име на вашиот уред", 5 | "Add" : "Додади", 6 | "Adding your device …" : "Додавање на вашиот уред ...", 7 | "Retry" : "Обидете се повторно", 8 | "Unnamed device" : "Уреди без име", 9 | "Remove" : "Отстрани", 10 | "The following devices are configured for U2F second-factor authentication:" : "Следниве уреди се конфигурирани за дво-факторна авторизација U2F на вашата сметка:" 11 | }, 12 | "nplurals=2; plural=(n % 10 == 1 && n % 100 != 11) ? 0 : 1;"); 13 | -------------------------------------------------------------------------------- /l10n/ro.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Name your device" : "Numiți dispozitivul dvs.", 5 | "Add" : "Adaugă", 6 | "Adding your device …" : "Adăugarea dispozitivului dvs ...", 7 | "An error occurred: {msg}" : "S-a produs o eroare: {msg}", 8 | "Retry" : "Reîncearcă", 9 | "An error occurred. Please try again." : "S-a produs o eroare. Vă rugăm să încercați din nou.", 10 | "Unnamed device" : "Dispozitiv fără nume", 11 | "Remove" : "Șterge" 12 | }, 13 | "nplurals=3; plural=(n==1?0:(((n%100>19)||((n%100==0)&&(n!=0)))?2:1));"); 14 | -------------------------------------------------------------------------------- /tests/phpunit.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | ../lib 6 | 7 | 8 | 9 | 10 | 11 | 12 | . 13 | 14 | 15 | -------------------------------------------------------------------------------- /.jshintrc: -------------------------------------------------------------------------------- 1 | { 2 | "camelcase": false, 3 | "eqeqeq": true, 4 | "immed": true, 5 | "latedef": false, 6 | "noarg": true, 7 | "nonbsp": true, 8 | "undef": true, 9 | "unused": true, 10 | "trailing": true, 11 | "maxparams": 5, 12 | "curly": true, 13 | "maxlen": 120, 14 | "indent": 4, 15 | "browser": true, 16 | "globals": { 17 | "t": true, 18 | "console": true, 19 | "it": true, 20 | "xit": true, 21 | "expect": true, 22 | "describe": true, 23 | "define": true, 24 | "beforeEach": true, 25 | "afterEach": true, 26 | "require": true 27 | }, 28 | "esversion": 6, 29 | "asi": true 30 | } 31 | -------------------------------------------------------------------------------- /l10n/br.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "Name your device" : "Anvit o ardivink", 3 | "Add" : "Ouzhpennañ", 4 | "Adding your device …" : "Ouehpennit ho ardivink ...", 5 | "Retry" : "Klaskit en dro", 6 | "Unnamed device" : "Ardivink hep anv", 7 | "Remove" : "Lemel" 8 | },"pluralForm" :"nplurals=5; plural=((n%10 == 1) && (n%100 != 11) && (n%100 !=71) && (n%100 !=91) ? 0 :(n%10 == 2) && (n%100 != 12) && (n%100 !=72) && (n%100 !=92) ? 1 :(n%10 ==3 || n%10==4 || n%10==9) && (n%100 < 10 || n% 100 > 19) && (n%100 < 70 || n%100 > 79) && (n%100 < 90 || n%100 > 99) ? 2 :(n != 0 && n % 1000000 == 0) ? 3 : 4);" 9 | } -------------------------------------------------------------------------------- /l10n/br.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "Name your device" : "Anvit o ardivink", 5 | "Add" : "Ouzhpennañ", 6 | "Adding your device …" : "Ouehpennit ho ardivink ...", 7 | "Retry" : "Klaskit en dro", 8 | "Unnamed device" : "Ardivink hep anv", 9 | "Remove" : "Lemel" 10 | }, 11 | "nplurals=5; plural=((n%10 == 1) && (n%100 != 11) && (n%100 !=71) && (n%100 !=91) ? 0 :(n%10 == 2) && (n%100 != 12) && (n%100 !=72) && (n%100 !=92) ? 1 :(n%10 ==3 || n%10==4 || n%10==9) && (n%100 < 10 || n% 100 > 19) && (n%100 < 70 || n%100 > 79) && (n%100 < 90 || n%100 > 99) ? 2 :(n != 0 && n % 1000000 == 0) ? 3 : 4);"); 12 | -------------------------------------------------------------------------------- /.github/workflows/static-analysis.yml: -------------------------------------------------------------------------------- 1 | name: Static analysis 2 | 3 | on: [pull_request] 4 | 5 | jobs: 6 | static-psalm-analysis: 7 | runs-on: ubuntu-latest 8 | strategy: 9 | matrix: 10 | ocp-version: [ 'v20.0.7', 'v21.0.0', 'dev-stable22', 'dev-stable23', 'dev-master' ] 11 | name: Nextcloud ${{ matrix.ocp-version }} 12 | steps: 13 | - name: Checkout 14 | uses: actions/checkout@master 15 | - name: Set up php 16 | uses: shivammathur/setup-php@master 17 | with: 18 | php-version: 7.4 19 | tools: composer:v1 20 | coverage: none 21 | - name: Install dependencies 22 | run: composer i 23 | - name: Install dependencies 24 | run: composer require --dev christophwurst/nextcloud:${{ matrix.ocp-version }} 25 | - name: Run coding standards check 26 | run: composer run psalm 27 | -------------------------------------------------------------------------------- /src/store.js: -------------------------------------------------------------------------------- 1 | import Vue from 'vue' 2 | import Vuex from 'vuex' 3 | 4 | import {removeRegistration} from './services/RegistrationService' 5 | 6 | Vue.use(Vuex) 7 | 8 | export const mutations = { 9 | addDevice (state, device) { 10 | state.devices.push(device) 11 | state.devices.sort((d1, d2) => d1.name.localeCompare(d2.name)) 12 | }, 13 | 14 | removeDevice (state, id) { 15 | state.devices = state.devices.filter(device => device.id !== id) 16 | } 17 | } 18 | 19 | export const actions = { 20 | removeDevice ({state, commit}, id) { 21 | const device = state.devices[id] 22 | 23 | commit('removeDevice', id) 24 | 25 | removeRegistration(id) 26 | .catch(err => { 27 | // Rollback 28 | commit('addDevice', device) 29 | 30 | throw err 31 | }) 32 | } 33 | } 34 | 35 | export const getters = {} 36 | 37 | export default new Vuex.Store({ 38 | strict: process.env.NODE_ENV !== 'production', 39 | state: { 40 | devices: [] 41 | }, 42 | getters, 43 | mutations, 44 | actions 45 | }) 46 | -------------------------------------------------------------------------------- /lib/Event/StateChanged.php: -------------------------------------------------------------------------------- 1 | 12 | * @copyright Christoph Wurst 2018 13 | */ 14 | 15 | namespace OCA\TwoFactorU2F\Event; 16 | 17 | use OCP\EventDispatcher\Event; 18 | use OCP\IUser; 19 | 20 | class StateChanged extends Event { 21 | 22 | /** @var IUser */ 23 | private $user; 24 | 25 | /** @var bool */ 26 | private $enabled; 27 | 28 | public function __construct(IUser $user, bool $enabled) { 29 | parent::__construct(); 30 | 31 | $this->user = $user; 32 | $this->enabled = $enabled; 33 | } 34 | 35 | /** 36 | * @return IUser 37 | */ 38 | public function getUser(): IUser { 39 | return $this->user; 40 | } 41 | 42 | /** 43 | * @return bool 44 | */ 45 | public function isEnabled(): bool { 46 | return $this->enabled; 47 | } 48 | } 49 | -------------------------------------------------------------------------------- /src/mixins/Nextcloud.js: -------------------------------------------------------------------------------- 1 | /* 2 | * @copyright 2018 Christoph Wurst 3 | * 4 | * @author 2018 Christoph Wurst 5 | * 6 | * @license GNU AGPL version 3 or any later version 7 | * 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU Affero General Public License as 10 | * published by the Free Software Foundation, either version 3 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU Affero General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU Affero General Public License 19 | * along with this program. If not, see . 20 | */ 21 | 22 | export default { 23 | methods: { 24 | t, 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /img/app.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /img/app-dark.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /tests/Unit/Event/StateChangedTest.php: -------------------------------------------------------------------------------- 1 | 12 | * @copyright Christoph Wurst 2018 13 | */ 14 | 15 | namespace OCA\TwoFactorU2F\Tests\Unit\Event; 16 | 17 | use OCA\TwoFactorU2F\Event\StateChanged; 18 | use OCP\IUser; 19 | use PHPUnit\Framework\TestCase; 20 | 21 | class StateChangedTest extends TestCase { 22 | public function testEnabledState() { 23 | $user = $this->createMock(IUser::class); 24 | 25 | $event = new StateChanged($user, true); 26 | 27 | $this->assertTrue($event->isEnabled()); 28 | $this->assertSame($user, $event->getUser()); 29 | } 30 | 31 | public function testDisabledState() { 32 | $user = $this->createMock(IUser::class); 33 | 34 | $event = new StateChanged($user, false); 35 | 36 | $this->assertFalse($event->isEnabled()); 37 | $this->assertSame($user, $event->getUser()); 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /l10n/lv.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "Esat pievienojis U2F aparatūras pilnvaras", 3 | "You removed an U2F hardware token" : "Jūs noņēmāt U2F aparatūras pilnvaras", 4 | "U2F device" : "U2F ierīce", 5 | "Authenticate with an U2F device" : "Autentifikācija ar U2F ierīci", 6 | "Please plug in your U2F device and press the device button to authorize." : "Lūdzu, pievienojiet U2F ierīci un nospiediet ierīces pogu, lai atļauj.", 7 | "Add" : "Pievienot", 8 | "Server error while trying to add U2F device" : "Servera kļūda, mēģinot pievienot U2F ierīci", 9 | "U2F device registration failed (error code {errorCode})" : "U2F ierīces reģistrācija neizdevās (kļūdas kods {errorCode})", 10 | "Server error while trying to complete U2F device registration" : "Servera kļūda mēģinot pabeigt U2F ierīces reģistrācija", 11 | "Retry" : "Mēģināt vēlreiz", 12 | "An error occurred. Please try again." : "Notika kļūda. Mēģini vēlreiz.", 13 | "Remove" : "Izņemt" 14 | },"pluralForm" :"nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n != 0 ? 1 : 2);" 15 | } -------------------------------------------------------------------------------- /templates/loginsetup.php: -------------------------------------------------------------------------------- 1 | 5 | * 6 | * @author 2019 Christoph Wurst 7 | * 8 | * @license GNU AGPL version 3 or any later version 9 | * 10 | * This program is free software: you can redistribute it and/or modify 11 | * it under the terms of the GNU Affero General Public License as 12 | * published by the Free Software Foundation, either version 3 of the 13 | * License, or (at your option) any later version. 14 | * 15 | * This program is distributed in the hope that it will be useful, 16 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 17 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18 | * GNU Affero General Public License for more details. 19 | * 20 | * You should have received a copy of the GNU Affero General Public License 21 | * along with this program. If not, see . 22 | */ 23 | 24 | script('twofactor_u2f', 'login-setup'); 25 | 26 | ?> 27 | 28 |
29 | -------------------------------------------------------------------------------- /l10n/lv.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "Esat pievienojis U2F aparatūras pilnvaras", 5 | "You removed an U2F hardware token" : "Jūs noņēmāt U2F aparatūras pilnvaras", 6 | "U2F device" : "U2F ierīce", 7 | "Authenticate with an U2F device" : "Autentifikācija ar U2F ierīci", 8 | "Please plug in your U2F device and press the device button to authorize." : "Lūdzu, pievienojiet U2F ierīci un nospiediet ierīces pogu, lai atļauj.", 9 | "Add" : "Pievienot", 10 | "Server error while trying to add U2F device" : "Servera kļūda, mēģinot pievienot U2F ierīci", 11 | "U2F device registration failed (error code {errorCode})" : "U2F ierīces reģistrācija neizdevās (kļūdas kods {errorCode})", 12 | "Server error while trying to complete U2F device registration" : "Servera kļūda mēģinot pabeigt U2F ierīces reģistrācija", 13 | "Retry" : "Mēģināt vēlreiz", 14 | "An error occurred. Please try again." : "Notika kļūda. Mēģini vēlreiz.", 15 | "Remove" : "Izņemt" 16 | }, 17 | "nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n != 0 ? 1 : 2);"); 18 | -------------------------------------------------------------------------------- /lib/Settings/Personal.php: -------------------------------------------------------------------------------- 1 | 7 | * 8 | * Two-factor U2F 9 | * 10 | * This code is free software: you can redistribute it and/or modify 11 | * it under the terms of the GNU Affero General Public License, version 3, 12 | * as published by the Free Software Foundation. 13 | * 14 | * This program is distributed in the hope that it will be useful, 15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 17 | * GNU Affero General Public License for more details. 18 | * 19 | * You should have received a copy of the GNU Affero General Public License, version 3, 20 | * along with this program. If not, see 21 | * 22 | */ 23 | 24 | namespace OCA\TwoFactorU2F\Settings; 25 | 26 | use OCP\Authentication\TwoFactorAuth\IPersonalProviderSettings; 27 | use OCP\Template; 28 | 29 | class Personal implements IPersonalProviderSettings { 30 | public function getBody(): Template { 31 | return new Template('twofactor_u2f', 'personal'); 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /l10n/ast.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "Amestesti un pase U2F de hardware", 3 | "You removed an U2F hardware token" : "Desaniciesti un pase U2F de hardware", 4 | "U2F device" : "Preséu U2F", 5 | "Authenticate with an U2F device" : "Autenticar con un preséu U2F", 6 | "Add U2F device" : "Amestar preséu U2F", 7 | "Please plug in your U2F device and press the device button to authorize." : "Coneuta'l to preséu U2F y primi nel botón del preséu p'autorizar, por favor.", 8 | "Add" : "Amestar", 9 | "Server error while trying to add U2F device" : "Fallu del sirvidor entrín se tentaba d'amestar el preséu U2F", 10 | "U2F device registration failed (error code {errorCode})" : "Falló'l rexistru del preséu U2F (códigu de fallu {errorCode})", 11 | "Server error while trying to complete U2F device registration" : "Fallu del sirvidor entrín se tentaba de completar el rexistru del preséu U2F", 12 | "Retry" : "Retentar", 13 | "An error occurred. Please try again." : "Asocedió un fallu. Volvi tentalo, por favor.", 14 | "Unnamed device" : "Preséu ensin nomar", 15 | "Remove" : "Desaniciar" 16 | },"pluralForm" :"nplurals=2; plural=(n != 1);" 17 | } -------------------------------------------------------------------------------- /nbproject/project.properties: -------------------------------------------------------------------------------- 1 | auxiliary.org-netbeans-modules-php-phpunit.bootstrap_2e_create_2e_tests=false 2 | auxiliary.org-netbeans-modules-php-phpunit.bootstrap_2e_enabled=false 3 | auxiliary.org-netbeans-modules-php-phpunit.bootstrap_2e_path= 4 | auxiliary.org-netbeans-modules-php-phpunit.configuration_2e_enabled=true 5 | auxiliary.org-netbeans-modules-php-phpunit.configuration_2e_path=tests/phpunit.xml 6 | auxiliary.org-netbeans-modules-php-phpunit.customSuite_2e_enabled=false 7 | auxiliary.org-netbeans-modules-php-phpunit.customSuite_2e_path= 8 | auxiliary.org-netbeans-modules-php-phpunit.phpUnit_2e_enabled=false 9 | auxiliary.org-netbeans-modules-php-phpunit.phpUnit_2e_path= 10 | auxiliary.org-netbeans-modules-php-phpunit.test_2e_groups_2e_ask=false 11 | auxiliary.org-netbeans-modules-php-phpunit.test_2e_run_2e_all=false 12 | auxiliary.org-netbeans-modules-php-phpunit.test_2e_run_2e_phpunit_2e_only=false 13 | file.reference.twofactor_u2f-tests=tests 14 | include.path=${php.global.include.path} 15 | php.version=PHP_70 16 | source.encoding=UTF-8 17 | src.dir=. 18 | tags.asp=false 19 | tags.short=false 20 | test.src.dir=${file.reference.twofactor_u2f-tests} 21 | testing.providers=PhpUnit 22 | web.root=. 23 | -------------------------------------------------------------------------------- /l10n/ast.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "Amestesti un pase U2F de hardware", 5 | "You removed an U2F hardware token" : "Desaniciesti un pase U2F de hardware", 6 | "U2F device" : "Preséu U2F", 7 | "Authenticate with an U2F device" : "Autenticar con un preséu U2F", 8 | "Add U2F device" : "Amestar preséu U2F", 9 | "Please plug in your U2F device and press the device button to authorize." : "Coneuta'l to preséu U2F y primi nel botón del preséu p'autorizar, por favor.", 10 | "Add" : "Amestar", 11 | "Server error while trying to add U2F device" : "Fallu del sirvidor entrín se tentaba d'amestar el preséu U2F", 12 | "U2F device registration failed (error code {errorCode})" : "Falló'l rexistru del preséu U2F (códigu de fallu {errorCode})", 13 | "Server error while trying to complete U2F device registration" : "Fallu del sirvidor entrín se tentaba de completar el rexistru del preséu U2F", 14 | "Retry" : "Retentar", 15 | "An error occurred. Please try again." : "Asocedió un fallu. Volvi tentalo, por favor.", 16 | "Unnamed device" : "Preséu ensin nomar", 17 | "Remove" : "Desaniciar" 18 | }, 19 | "nplurals=2; plural=(n != 1);"); 20 | -------------------------------------------------------------------------------- /lib/Event/DisabledByAdmin.php: -------------------------------------------------------------------------------- 1 | 7 | * 8 | * @author 2018 Christoph Wurst 9 | * 10 | * @license GNU AGPL version 3 or any later version 11 | * 12 | * This program is free software: you can redistribute it and/or modify 13 | * it under the terms of the GNU Affero General Public License as 14 | * published by the Free Software Foundation, either version 3 of the 15 | * License, or (at your option) any later version. 16 | * 17 | * This program is distributed in the hope that it will be useful, 18 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 19 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 20 | * GNU Affero General Public License for more details. 21 | * 22 | * You should have received a copy of the GNU Affero General Public License 23 | * along with this program. If not, see . 24 | */ 25 | 26 | namespace OCA\TwoFactorU2F\Event; 27 | 28 | use OCP\IUser; 29 | 30 | class DisabledByAdmin extends StateChanged { 31 | public function __construct(IUser $user) { 32 | parent::__construct($user, false); 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /src/webpack.common.js: -------------------------------------------------------------------------------- 1 | const path = require('path'); 2 | const { VueLoaderPlugin } = require('vue-loader'); 3 | 4 | module.exports = { 5 | entry: { 6 | challenge: path.join(__dirname, 'main-challenge.js'), 7 | 'login-setup': path.join(__dirname, 'main-login-setup.js'), 8 | settings: path.join(__dirname, 'main-settings.js'), 9 | }, 10 | output: { 11 | path: path.resolve(__dirname, '../js'), 12 | publicPath: '/js/', 13 | }, 14 | module: { 15 | rules: [ 16 | { 17 | test: /\.css$/, 18 | use: ['vue-style-loader', 'css-loader'] 19 | }, 20 | { 21 | test: /\.scss$/, 22 | use: ['vue-style-loader', 'css-loader', 'sass-loader'] 23 | }, 24 | { 25 | test: /\.vue$/, 26 | loader: 'vue-loader' 27 | }, 28 | { 29 | test: /\.js$/, 30 | loader: 'babel-loader', 31 | exclude: /node_modules/ 32 | }, 33 | { 34 | test: /\.(png|jpg|gif)$/, 35 | loader: 'file-loader', 36 | options: { 37 | name: '[name].[ext]?[hash]' 38 | } 39 | }, 40 | { 41 | test: /\.(svg)$/i, 42 | use: [ 43 | { 44 | loader: 'url-loader' 45 | } 46 | ] 47 | } 48 | ] 49 | }, 50 | plugins: [new VueLoaderPlugin()], 51 | resolve: { 52 | extensions: ['*', '.js', '.vue'] 53 | } 54 | }; -------------------------------------------------------------------------------- /src/logger.js: -------------------------------------------------------------------------------- 1 | /* 2 | * @copyright 2019 Christoph Wurst 3 | * 4 | * @author 2019 Christoph Wurst 5 | * 6 | * @license GNU AGPL version 3 or any later version 7 | * 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU Affero General Public License as 10 | * published by the Free Software Foundation, either version 3 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU Affero General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU Affero General Public License 19 | * along with this program. If not, see . 20 | */ 21 | 22 | import { getCurrentUser } from '@nextcloud/auth' 23 | import { getLoggerBuilder } from '@nextcloud/logger' 24 | 25 | const builder = getLoggerBuilder().setApp('twofactor_u2f') 26 | 27 | const user = getCurrentUser() 28 | if (user !== null) { 29 | builder.setUid(user.uid) 30 | } 31 | 32 | export default builder.build() 33 | -------------------------------------------------------------------------------- /psalm.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | -------------------------------------------------------------------------------- /l10n/lt_LT.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "Jūs pridėjote U2F aparatinės įrangos prieigos raktą", 3 | "You removed an U2F hardware token" : "Jūs pašalinote U2F aparatinės įrangos prieigos raktą", 4 | "U2F disabled by an admin" : "Administratorius išjungė U2F", 5 | "U2F device" : "U2F įrenginys", 6 | "Add U2F device" : "Pridėti U2F įrenginį", 7 | "Name your device" : "Pavadinkite savo įrenginį", 8 | "Add" : "Pridėti", 9 | "Adding your device …" : "Pridedamas jūsų įrenginys …", 10 | "Server error while trying to add U2F device" : "Serverio klaida, bandant pridėti U2F įrenginį", 11 | "U2F device registration failed (error code {errorCode})" : "U2F įrenginio registracija nepavyko (klaidos kodas {errorCode})", 12 | "An error occurred: {msg}" : "Įvyko klaida: {msg}", 13 | "Retry" : "Bandyti dar kartą", 14 | "An error occurred. Please try again." : "Įvyko klaida. Prašome bandyti dar kartą.", 15 | "Your browser does not support U2F." : "Jūsų naršyklė nepalaiko U2F.", 16 | "Unnamed device" : "Įrenginys be pavadinimo", 17 | "Remove" : "Šalinti" 18 | },"pluralForm" :"nplurals=4; plural=(n % 10 == 1 && (n % 100 > 19 || n % 100 < 11) ? 0 : (n % 10 >= 2 && n % 10 <=9) && (n % 100 > 19 || n % 100 < 11) ? 1 : n % 1 != 0 ? 2: 3);" 19 | } -------------------------------------------------------------------------------- /composer.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "christophwurst/twofactor_u2f", 3 | "description": "A two factor provider for U2F devices for Nextcloud", 4 | "type": "project", 5 | "license": "agplv3", 6 | "authors": [ 7 | { 8 | "name": "Christoph Wurst", 9 | "email": "christoph@winzerhof-wurst.at" 10 | } 11 | ], 12 | "require": { 13 | "php": ">=7.3.0", 14 | "yubico/u2flib-server": "^1.0.1" 15 | }, 16 | "require-dev": { 17 | "phpunit/phpunit": "^9.5.0", 18 | "roave/security-advisories": "dev-master", 19 | "nextcloud/coding-standard": "^0.5.0", 20 | "psalm/phar": "^4.3" 21 | }, 22 | "scripts": { 23 | "lint": "find . -name \\*.php -not -path './vendor/*' -print0 | xargs -0 -n1 php -l", 24 | "cs:check": "php-cs-fixer fix --dry-run --diff", 25 | "cs:fix": "php-cs-fixer fix", 26 | "psalm": "psalm.phar", 27 | "test": "phpunit -c tests/phpunit.xml", 28 | "test:acceptance": "phpunit -c tests/phpunit.xml tests/Acceptance", 29 | "test:unit": "phpunit -c tests/phpunit.xml tests/Unit", 30 | "test:acceptance:dev": "phpunit -c tests/phpunit.xml tests/Acceptance --no-coverage", 31 | "test:unit:dev": "phpunit -c tests/phpunit.xml tests/Unit --no-coverage" 32 | }, 33 | "config": { 34 | "optimize-autoloader": true, 35 | "classmap-authoritative": true, 36 | "platform": { 37 | "php": "7.4.0" 38 | } 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /l10n/lt_LT.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "Jūs pridėjote U2F aparatinės įrangos prieigos raktą", 5 | "You removed an U2F hardware token" : "Jūs pašalinote U2F aparatinės įrangos prieigos raktą", 6 | "U2F disabled by an admin" : "Administratorius išjungė U2F", 7 | "U2F device" : "U2F įrenginys", 8 | "Add U2F device" : "Pridėti U2F įrenginį", 9 | "Name your device" : "Pavadinkite savo įrenginį", 10 | "Add" : "Pridėti", 11 | "Adding your device …" : "Pridedamas jūsų įrenginys …", 12 | "Server error while trying to add U2F device" : "Serverio klaida, bandant pridėti U2F įrenginį", 13 | "U2F device registration failed (error code {errorCode})" : "U2F įrenginio registracija nepavyko (klaidos kodas {errorCode})", 14 | "An error occurred: {msg}" : "Įvyko klaida: {msg}", 15 | "Retry" : "Bandyti dar kartą", 16 | "An error occurred. Please try again." : "Įvyko klaida. Prašome bandyti dar kartą.", 17 | "Your browser does not support U2F." : "Jūsų naršyklė nepalaiko U2F.", 18 | "Unnamed device" : "Įrenginys be pavadinimo", 19 | "Remove" : "Šalinti" 20 | }, 21 | "nplurals=4; plural=(n % 10 == 1 && (n % 100 > 19 || n % 100 < 11) ? 0 : (n % 10 >= 2 && n % 10 <=9) && (n % 100 > 19 || n % 100 < 11) ? 1 : n % 1 != 0 ? 2: 3);"); 22 | -------------------------------------------------------------------------------- /appinfo/routes.php: -------------------------------------------------------------------------------- 1 | 5 | * 6 | * Two-factor TOTP 7 | * 8 | * This code is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU Affero General Public License, version 3, 10 | * as published by the Free Software Foundation. 11 | * 12 | * This program is distributed in the hope that it will be useful, 13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | * GNU Affero General Public License for more details. 16 | * 17 | * You should have received a copy of the GNU Affero General Public License, version 3, 18 | * along with this program. If not, see 19 | * 20 | */ 21 | return [ 22 | 'routes' => [ 23 | [ 24 | 'name' => 'settings#state', 25 | 'url' => '/settings/state', 26 | 'verb' => 'GET' 27 | ], 28 | [ 29 | 'name' => 'settings#startRegister', 30 | 'url' => '/settings/startregister', 31 | 'verb' => 'POST' 32 | ], 33 | [ 34 | 'name' => 'settings#finishRegister', 35 | 'url' => '/settings/finishregister', 36 | 'verb' => 'POST' 37 | ], 38 | [ 39 | 'name' => 'settings#remove', 40 | 'url' => '/settings/remove', 41 | 'verb' => 'POST' 42 | ], 43 | ] 44 | ]; 45 | -------------------------------------------------------------------------------- /l10n/af.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "U2F device" : "U2F-toestel", 3 | "Authenticate with an U2F device" : "Magtig met ’n U2F-toestel", 4 | "Add U2F device" : "Voeg U2F-toestel toe", 5 | "Please plug in your U2F device and press the device button to authorize." : "Prop asseblief u U2F-toestel in en druk die toestelknop om te magtig.", 6 | "Add" : "Voeg by", 7 | "U2F device is already registered (error code {errorCode})" : "U2F-toestel is reeds geregistreer (foutkode {errorCode})", 8 | "U2F device registration timeout reached (error code {errorCode})" : "U2F-toestelregistrasie het uitgetel (foutkode {errorCode})", 9 | "U2F device registration failed (error code {errorCode})" : "U2F-toestelregistrasie het misluk (foutkode {errorCode})", 10 | "Retry" : "Herprobeer", 11 | "An error occurred. Please try again." : "’n Fout het voorgekom. Probeer weer.", 12 | "Unnamed device" : "Onbenoemde toestel", 13 | "Remove" : "Verwyder", 14 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "Geen U2F-toestelle opgestel nie. U gebruik nie op die oomblik U2F as ’n tweede faktor nie.", 15 | "The following devices are configured for U2F second-factor authentication:" : "Die volgende toestelle is vir U2F-tweedefaktormagtiging opgestel:" 16 | },"pluralForm" :"nplurals=2; plural=(n != 1);" 17 | } -------------------------------------------------------------------------------- /lib/AppInfo/Application.php: -------------------------------------------------------------------------------- 1 | 12 | * @copyright Christoph Wurst 2018 13 | */ 14 | 15 | namespace OCA\TwoFactorU2F\AppInfo; 16 | 17 | use OCA\TwoFactorU2F\Event\DisabledByAdmin; 18 | use OCA\TwoFactorU2F\Event\StateChanged; 19 | use OCA\TwoFactorU2F\Listener\StateChangeActivity; 20 | use OCA\TwoFactorU2F\Listener\StateChangeRegistryUpdater; 21 | use OCP\AppFramework\App; 22 | use OCP\EventDispatcher\IEventDispatcher; 23 | 24 | class Application extends App { 25 | public const APP_ID = 'twofactor_u2f'; 26 | 27 | public function __construct(array $urlParams = []) { 28 | parent::__construct(self::APP_ID, $urlParams); 29 | 30 | $container = $this->getContainer(); 31 | 32 | /** @var IEventDispatcher $eventDispatcher */ 33 | $eventDispatcher = $container->query(IEventDispatcher::class); 34 | $eventDispatcher->addServiceListener(StateChanged::class, StateChangeActivity::class); 35 | $eventDispatcher->addServiceListener(StateChanged::class, StateChangeRegistryUpdater::class); 36 | $eventDispatcher->addServiceListener(DisabledByAdmin::class, StateChangeActivity::class); 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /src/webpack.test.js: -------------------------------------------------------------------------------- 1 | /* 2 | * @copyright 2018 Christoph Wurst 3 | * 4 | * @author 2018 Christoph Wurst 5 | * 6 | * @license GNU AGPL version 3 or any later version 7 | * 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU Affero General Public License as 10 | * published by the Free Software Foundation, either version 3 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU Affero General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU Affero General Public License 19 | * along with this program. If not, see . 20 | */ 21 | 22 | const { merge } = require('webpack-merge'); 23 | const nodeExternals = require('webpack-node-externals') 24 | const path = require('path'); 25 | 26 | const common = require('./webpack.common.js'); 27 | 28 | module.exports = merge(common, { 29 | mode: 'development', 30 | context: path.resolve(__dirname, 'src'), 31 | devtool: 'inline-cheap-module-source-map', 32 | externals: [nodeExternals()] 33 | }) 34 | -------------------------------------------------------------------------------- /src/main-login-setup.js: -------------------------------------------------------------------------------- 1 | /* 2 | * @copyright 2019 Christoph Wurst 3 | * 4 | * @author 2019 Christoph Wurst 5 | * 6 | * @license GNU AGPL version 3 or any later version 7 | * 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU Affero General Public License as 10 | * published by the Free Software Foundation, either version 3 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU Affero General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU Affero General Public License 19 | * along with this program. If not, see . 20 | */ 21 | 22 | import Vue from 'vue' 23 | 24 | import Nextcloud from './mixins/Nextcloud' 25 | import store from './store' 26 | 27 | Vue.mixin(Nextcloud) 28 | 29 | import LoginSetup from './components/LoginSetup' 30 | 31 | const View = Vue.extend(LoginSetup) 32 | new View({ 33 | propsData: { 34 | httpWarning: document.location.protocol !== 'https:', 35 | }, 36 | store, 37 | }).$mount('#twofactor-u2f-login-setup') 38 | -------------------------------------------------------------------------------- /l10n/af.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "U2F device" : "U2F-toestel", 5 | "Authenticate with an U2F device" : "Magtig met ’n U2F-toestel", 6 | "Add U2F device" : "Voeg U2F-toestel toe", 7 | "Please plug in your U2F device and press the device button to authorize." : "Prop asseblief u U2F-toestel in en druk die toestelknop om te magtig.", 8 | "Add" : "Voeg by", 9 | "U2F device is already registered (error code {errorCode})" : "U2F-toestel is reeds geregistreer (foutkode {errorCode})", 10 | "U2F device registration timeout reached (error code {errorCode})" : "U2F-toestelregistrasie het uitgetel (foutkode {errorCode})", 11 | "U2F device registration failed (error code {errorCode})" : "U2F-toestelregistrasie het misluk (foutkode {errorCode})", 12 | "Retry" : "Herprobeer", 13 | "An error occurred. Please try again." : "’n Fout het voorgekom. Probeer weer.", 14 | "Unnamed device" : "Onbenoemde toestel", 15 | "Remove" : "Verwyder", 16 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "Geen U2F-toestelle opgestel nie. U gebruik nie op die oomblik U2F as ’n tweede faktor nie.", 17 | "The following devices are configured for U2F second-factor authentication:" : "Die volgende toestelle is vir U2F-tweedefaktormagtiging opgestel:" 18 | }, 19 | "nplurals=2; plural=(n != 1);"); 20 | -------------------------------------------------------------------------------- /lib/Provider/U2FLoginProvider.php: -------------------------------------------------------------------------------- 1 | 7 | * 8 | * @author 2019 Christoph Wurst 9 | * 10 | * @license GNU AGPL version 3 or any later version 11 | * 12 | * This program is free software: you can redistribute it and/or modify 13 | * it under the terms of the GNU Affero General Public License as 14 | * published by the Free Software Foundation, either version 3 of the 15 | * License, or (at your option) any later version. 16 | * 17 | * This program is distributed in the hope that it will be useful, 18 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 19 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 20 | * GNU Affero General Public License for more details. 21 | * 22 | * You should have received a copy of the GNU Affero General Public License 23 | * along with this program. If not, see . 24 | */ 25 | 26 | namespace OCA\TwoFactorU2F\Provider; 27 | 28 | use OCA\TwoFactorU2F\AppInfo\Application; 29 | use OCP\Authentication\TwoFactorAuth\ILoginSetupProvider; 30 | use OCP\Template; 31 | 32 | class U2FLoginProvider implements ILoginSetupProvider { 33 | 34 | /** 35 | * @return Template 36 | */ 37 | public function getBody(): Template { 38 | return new Template(Application::APP_ID, 'loginsetup'); 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /lib/Listener/StateChangeActivity.php: -------------------------------------------------------------------------------- 1 | 12 | * @copyright Christoph Wurst 2018 13 | */ 14 | 15 | namespace OCA\TwoFactorU2F\Listener; 16 | 17 | use OCA\TwoFactorU2F\Event\DisabledByAdmin; 18 | use OCA\TwoFactorU2F\Event\StateChanged; 19 | use OCP\Activity\IManager; 20 | use OCP\EventDispatcher\Event; 21 | use OCP\EventDispatcher\IEventListener; 22 | 23 | class StateChangeActivity implements IEventListener { 24 | 25 | /** @var IManager */ 26 | private $activityManager; 27 | 28 | public function __construct(IManager $activityManager) { 29 | $this->activityManager = $activityManager; 30 | } 31 | 32 | public function handle(Event $event): void { 33 | if ($event instanceof StateChanged) { 34 | if ($event instanceof DisabledByAdmin) { 35 | $subject = 'u2f_disabled_by_admin'; 36 | } else { 37 | $subject = $event->isEnabled() ? 'u2f_device_added' : 'u2f_device_removed'; 38 | } 39 | 40 | $activity = $this->activityManager->generateEvent(); 41 | $activity->setApp('twofactor_u2f') 42 | ->setType('security') 43 | ->setAuthor($event->getUser()->getUID()) 44 | ->setAffectedUser($event->getUser()->getUID()) 45 | ->setSubject($subject); 46 | $this->activityManager->publish($activity); 47 | } 48 | } 49 | } 50 | -------------------------------------------------------------------------------- /src/main-challenge.js: -------------------------------------------------------------------------------- 1 | /* 2 | * @copyright 2018 Christoph Wurst 3 | * 4 | * @author 2018 Christoph Wurst 5 | * 6 | * @license GNU AGPL version 3 or any later version 7 | * 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU Affero General Public License as 10 | * published by the Free Software Foundation, either version 3 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU Affero General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU Affero General Public License 19 | * along with this program. If not, see . 20 | */ 21 | 22 | import Vue from 'vue' 23 | 24 | import Nextcloud from './mixins/Nextcloud' 25 | 26 | Vue.mixin(Nextcloud) 27 | 28 | const initialStateElement = document.getElementById('twofactor-u2f-req') 29 | const req = JSON.parse(initialStateElement.value) 30 | 31 | console.debug('Loaded initial state of the u2f challenge page', req) 32 | 33 | import Challenge from './components/Challenge' 34 | 35 | const View = Vue.extend(Challenge) 36 | new View({ 37 | propsData: { 38 | req, 39 | httpWarning: document.location.protocol !== 'https:', 40 | } 41 | }).$mount('#twofactor-u2f-challenge') 42 | -------------------------------------------------------------------------------- /src/tests/setup.js: -------------------------------------------------------------------------------- 1 | /* 2 | * @copyright 2018 Christoph Wurst 3 | * 4 | * @author 2018 Christoph Wurst 5 | * 6 | * @license GNU AGPL version 3 or any later version 7 | * 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU Affero General Public License as 10 | * published by the Free Software Foundation, either version 3 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU Affero General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU Affero General Public License 19 | * along with this program. If not, see . 20 | */ 21 | 22 | require('jsdom-global')() 23 | 24 | const t = (app, str) => str 25 | 26 | require('vue').mixin({ 27 | methods: { 28 | t 29 | } 30 | }) 31 | 32 | global.expect = require('chai').expect 33 | global.OC = { 34 | getCurrentUser: () => { 35 | return { uid: false } 36 | }, 37 | isUserAdmin() { 38 | return false 39 | }, 40 | getLanguage() { 41 | return 'en' 42 | } 43 | } 44 | global.t = t 45 | 46 | // https://github.com/vuejs/vue-test-utils/issues/936 47 | // better fix for "TypeError: Super expression must either be null or 48 | // a function" than pinning an old version of prettier. 49 | window.Date = Date 50 | -------------------------------------------------------------------------------- /lib/Db/Registration.php: -------------------------------------------------------------------------------- 1 | 12 | * @copyright Christoph Wurst 2018 13 | */ 14 | 15 | namespace OCA\TwoFactorU2F\Db; 16 | 17 | use JsonSerializable; 18 | use OCP\AppFramework\Db\Entity; 19 | 20 | /** 21 | * @method string getUserId() 22 | * @method void setUserId(string $userId) 23 | * @method string getKeyHandle() 24 | * @method void setKeyHandle(string $keyHandle) 25 | * @method string getPublicKey() 26 | * @method void setPublicKey(string $publicKey) 27 | * @method string getCertificate() 28 | * @method void setCertificate(string $Certificate) 29 | * @method int getCounter() 30 | * @method void setCounter(int $counter) 31 | * @method string getName() 32 | * @method void setName(string $name) 33 | */ 34 | class Registration extends Entity implements JsonSerializable { 35 | protected $userId; 36 | protected $keyHandle; 37 | protected $publicKey; 38 | protected $certificate; 39 | protected $counter; 40 | protected $name; 41 | 42 | public function jsonSerialize(): array { 43 | return [ 44 | 'id' => $this->getId(), 45 | 'userId' => $this->getUserId(), 46 | 'keyHandle' => $this->getKeyHandle(), 47 | 'publicKey' => $this->getPublicKey(), 48 | 'certificate' => $this->getCertificate(), 49 | 'counter' => $this->getCounter(), 50 | 'name' => $this->getName(), 51 | ]; 52 | } 53 | } 54 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/bug.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: 🐛 Bug 3 | about: Have you encountered a bug? 4 | version: 0.1 5 | --- 6 | 7 | ### Steps to reproduce 8 | 1. 9 | 2. 10 | 3. 11 | 12 | ### Expected behaviour 13 | Tell us what should happen 14 | 15 | 16 | ### Actual behaviour 17 | Tell us what happens instead 18 | 19 | 20 | ### Server configuration 21 | 22 | **Operating system**: 23 | 24 | **Web server:** 25 | 26 | **Database:** 27 | 28 | **PHP version:** 29 | 30 | **Version:** (see admin page) 31 | 32 | **Updated from an older version or fresh install:** 33 | 34 | **List of activated apps:** 35 | 36 | ``` 37 | If you have access to your command line run e.g.: 38 | sudo -u www-data php occ app:list 39 | from within your server installation folder 40 | ``` 41 | 42 | **The content of config/config.php:** 43 | ``` 44 | If you have access to your command line run e.g.: 45 | sudo -u www-data php occ config:list system 46 | from within your Nextcloud installation folder 47 | 48 | or 49 | 50 | Insert your config.php content here 51 | Make sure to remove all sensitive content such as passwords. (e.g. database password, passwordsalt, secret, smtp password, …) 52 | ``` 53 | 54 | #### Client configuration 55 | **Browser:** 56 | 57 | **Operating system:** 58 | 59 | #### Logs 60 | ##### Web server error log 61 | ``` 62 | Insert your webserver log here 63 | ``` 64 | 65 | ##### Server log (data/nextcloud.log) 66 | ``` 67 | Insert your server log here 68 | ``` 69 | 70 | ##### Browser log 71 | ``` 72 | Insert your browser log here, this could for example include: 73 | 74 | a) The javascript console log 75 | b) The network log 76 | ``` 77 | -------------------------------------------------------------------------------- /l10n/es_AR.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "Usted ha agregado una ficha U2F física", 3 | "You removed an U2F hardware token" : "Usted ha eliminado una ficha U2F física", 4 | "U2F device" : "dispositivo U2F", 5 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 6 | "Add U2F device" : "Agregar dispositivo U2F", 7 | "Please plug in your U2F device and press the device button to authorize." : "Favor de conectar su dispositivo U2F y presione el botón del dispositivo para autorizar. ", 8 | "Add" : "Añadir", 9 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 10 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 11 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 12 | "Retry" : "Reintentar", 13 | "An error occurred. Please try again." : "Se presentó un erorr. Favor de volver a intentar. ", 14 | "Unnamed device" : "Dispositivo sin nombre", 15 | "Remove" : "Eliminar", 16 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No se encuentra usando U2F como un segundo factor por el momento. ", 17 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 18 | },"pluralForm" :"nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;" 19 | } -------------------------------------------------------------------------------- /src/services/RegistrationService.js: -------------------------------------------------------------------------------- 1 | /* 2 | * @copyright 2018 Christoph Wurst 3 | * 4 | * @author 2018 Christoph Wurst 5 | * 6 | * @license GNU AGPL version 3 or any later version 7 | * 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU Affero General Public License as 10 | * published by the Free Software Foundation, either version 3 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU Affero General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU Affero General Public License 19 | * along with this program. If not, see . 20 | */ 21 | 22 | import Axios from '@nextcloud/axios' 23 | import {generateUrl} from '@nextcloud/router' 24 | 25 | export function startRegistration () { 26 | const url = generateUrl('/apps/twofactor_u2f/settings/startregister') 27 | 28 | return Axios.post(url) 29 | .then(resp => resp.data) 30 | } 31 | 32 | export function finishRegistration (data) { 33 | const url = generateUrl('/apps/twofactor_u2f/settings/finishregister') 34 | 35 | return Axios.post(url, data) 36 | .then(resp => resp.data) 37 | } 38 | 39 | export function removeRegistration (id) { 40 | const url = generateUrl('/apps/twofactor_u2f/settings/remove') 41 | const data = { 42 | id 43 | } 44 | 45 | return Axios.post(url, data) 46 | .then(resp => resp.data) 47 | } 48 | -------------------------------------------------------------------------------- /l10n/sq.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "Shtuat një shenjë hardware U2F", 3 | "You removed an U2F hardware token" : "Ju hoqët një U2F hardware token", 4 | "U2F device" : "Pajisje U2F", 5 | "Authenticate with an U2F device" : "Verifikoni me një pajisje U2F", 6 | "Add U2F device" : "Shto pajisjen U2F", 7 | "Please plug in your U2F device and press the device button to authorize." : "Ju lutemi futni pajisjen tuaj U2F dhe shtypni butonin e pajisjes për të autorizuar.", 8 | "Name your device" : "Emërtoni pajisjen tuaj", 9 | "Add" : "Shto", 10 | "Adding your device …" : "Shtoni pajisjen tuaj ...", 11 | "Server error while trying to add U2F device" : "Gabim serveri gjatë përpjekjes për të shtuar pajisjen U2F", 12 | "U2F device registration failed (error code {errorCode})" : "Regjistrimi i pajisjes U2F dështoi (gabim kodi {gabimKodi})", 13 | "Server error while trying to complete U2F device registration" : "Gabim serveri gjatë përpjekjes për të plotësuar regjistrimin e pajisjes U2F", 14 | "An error occurred: {msg}" : "Ndodhi një gabim: {msg}", 15 | "Retry" : "Riprovoni", 16 | "An error occurred. Please try again." : "Ndodhi një problem.Ju lutem provoni përsëri.", 17 | "Unnamed device" : "Paisje pa emër", 18 | "Remove" : "Hiq", 19 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "Asnjë pajisje U2F e konfiguruar. Ju nuk po përdorni U2F si faktor të dytë në këtë moment.", 20 | "The following devices are configured for U2F second-factor authentication:" : "Pajisjet në vijim janë konfiguruar për identifikimin me dy faktor U2F:" 21 | },"pluralForm" :"nplurals=2; plural=(n != 1);" 22 | } -------------------------------------------------------------------------------- /l10n/es_AR.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "Usted ha agregado una ficha U2F física", 5 | "You removed an U2F hardware token" : "Usted ha eliminado una ficha U2F física", 6 | "U2F device" : "dispositivo U2F", 7 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 8 | "Add U2F device" : "Agregar dispositivo U2F", 9 | "Please plug in your U2F device and press the device button to authorize." : "Favor de conectar su dispositivo U2F y presione el botón del dispositivo para autorizar. ", 10 | "Add" : "Añadir", 11 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 12 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 13 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 14 | "Retry" : "Reintentar", 15 | "An error occurred. Please try again." : "Se presentó un erorr. Favor de volver a intentar. ", 16 | "Unnamed device" : "Dispositivo sin nombre", 17 | "Remove" : "Eliminar", 18 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No se encuentra usando U2F como un segundo factor por el momento. ", 19 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 20 | }, 21 | "nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;"); 22 | -------------------------------------------------------------------------------- /l10n/sq.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "Shtuat një shenjë hardware U2F", 5 | "You removed an U2F hardware token" : "Ju hoqët një U2F hardware token", 6 | "U2F device" : "Pajisje U2F", 7 | "Authenticate with an U2F device" : "Verifikoni me një pajisje U2F", 8 | "Add U2F device" : "Shto pajisjen U2F", 9 | "Please plug in your U2F device and press the device button to authorize." : "Ju lutemi futni pajisjen tuaj U2F dhe shtypni butonin e pajisjes për të autorizuar.", 10 | "Name your device" : "Emërtoni pajisjen tuaj", 11 | "Add" : "Shto", 12 | "Adding your device …" : "Shtoni pajisjen tuaj ...", 13 | "Server error while trying to add U2F device" : "Gabim serveri gjatë përpjekjes për të shtuar pajisjen U2F", 14 | "U2F device registration failed (error code {errorCode})" : "Regjistrimi i pajisjes U2F dështoi (gabim kodi {gabimKodi})", 15 | "Server error while trying to complete U2F device registration" : "Gabim serveri gjatë përpjekjes për të plotësuar regjistrimin e pajisjes U2F", 16 | "An error occurred: {msg}" : "Ndodhi një gabim: {msg}", 17 | "Retry" : "Riprovoni", 18 | "An error occurred. Please try again." : "Ndodhi një problem.Ju lutem provoni përsëri.", 19 | "Unnamed device" : "Paisje pa emër", 20 | "Remove" : "Hiq", 21 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "Asnjë pajisje U2F e konfiguruar. Ju nuk po përdorni U2F si faktor të dytë në këtë moment.", 22 | "The following devices are configured for U2F second-factor authentication:" : "Pajisjet në vijim janë konfiguruar për identifikimin me dy faktor U2F:" 23 | }, 24 | "nplurals=2; plural=(n != 1);"); 25 | -------------------------------------------------------------------------------- /src/main-settings.js: -------------------------------------------------------------------------------- 1 | /* 2 | * @copyright 2018 Christoph Wurst 3 | * 4 | * @author 2018 Christoph Wurst 5 | * 6 | * @license GNU AGPL version 3 or any later version 7 | * 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU Affero General Public License as 10 | * published by the Free Software Foundation, either version 3 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU Affero General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU Affero General Public License 19 | * along with this program. If not, see . 20 | */ 21 | 22 | import store from './store' 23 | import Vue from 'vue' 24 | 25 | import Nextcloud from './mixins/Nextcloud' 26 | import { loadState } from '@nextcloud/initial-state' 27 | 28 | Vue.mixin(Nextcloud) 29 | 30 | const devices = loadState('twofactor_u2f', 'devices'); 31 | devices.sort((d1, d2) => { 32 | if (!d1.name) { 33 | return 1 34 | } else if (!d2.name) { 35 | return -1 36 | } else { 37 | return d1.name.localeCompare(d2.name) 38 | } 39 | }) 40 | store.replaceState({ 41 | devices 42 | }) 43 | 44 | import PersonalSettings from './components/PersonalSettings' 45 | 46 | const View = Vue.extend(PersonalSettings) 47 | new View({ 48 | propsData: { 49 | httpWarning: document.location.protocol !== 'https:', 50 | }, 51 | store, 52 | }).$mount('#twofactor-u2f-settings') 53 | -------------------------------------------------------------------------------- /lib/Db/RegistrationMapper.php: -------------------------------------------------------------------------------- 1 | 12 | * @copyright Christoph Wurst 2018 13 | */ 14 | 15 | namespace OCA\TwoFactorU2F\Db; 16 | 17 | use OCP\AppFramework\Db\QBMapper; 18 | use OCP\DB\QueryBuilder\IQueryBuilder; 19 | use OCP\IDBConnection; 20 | use OCP\IUser; 21 | 22 | class RegistrationMapper extends QBMapper { 23 | public function __construct(IDBConnection $db) { 24 | parent::__construct($db, 'twofactor_u2f_registrations'); 25 | } 26 | 27 | /** 28 | * @param IUser $user 29 | * @param int $id 30 | */ 31 | public function findRegistration(IUser $user, $id): Registration { 32 | /* @var $qb IQueryBuilder */ 33 | $qb = $this->db->getQueryBuilder(); 34 | 35 | $qb->select('id', 'user_id', 'key_handle', 'public_key', 'certificate', 'counter', 'name') 36 | ->from('twofactor_u2f_registrations') 37 | ->where($qb->expr()->eq('user_id', $qb->createNamedParameter($user->getUID()))) 38 | ->andWhere($qb->expr()->eq('id', $qb->createNamedParameter($id))); 39 | return $this->findEntity($qb); 40 | } 41 | 42 | /** 43 | * @param IUser $user 44 | * @return Registration[] 45 | */ 46 | public function findRegistrations(IUser $user): array { 47 | /* @var $qb IQueryBuilder */ 48 | $qb = $this->db->getQueryBuilder(); 49 | 50 | $qb->select('id', 'user_id', 'key_handle', 'public_key', 'certificate', 'counter', 'name') 51 | ->from('twofactor_u2f_registrations') 52 | ->where($qb->expr()->eq('user_id', $qb->createNamedParameter($user->getUID()))); 53 | return $this->findEntities($qb); 54 | } 55 | } 56 | -------------------------------------------------------------------------------- /appinfo/info.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | twofactor_u2f 4 | ⚠️ Deprecated ⚠️ Two-Factor U2F 5 | U2F two-factor provider (deprecated) 6 | Deprecated two-factor provider for U2F devices. The Two-Factor WebAuthn provider replaces this app. 7 | 6.4.0-alpha.1 8 | agpl 9 | Christoph Wurst 10 | TwoFactorU2F 11 | security 12 | 13 | https://github.com/nextcloud/twofactor_u2f#readme 14 | https://github.com/nextcloud/twofactor_u2f/issues 15 | https://github.com/nextcloud/twofactor_u2f.git 16 | https://raw.githubusercontent.com/nextcloud/twofactor_u2f/4e0542d888236b7f212bed0b536244d08803466f/screenshots/challenge.png 17 | https://raw.githubusercontent.com/nextcloud/twofactor_u2f/4e0542d888236b7f212bed0b536244d08803466f/screenshots/settings.png 18 | 19 | 20 | 21 | sqlite 22 | mysql 23 | pgsql 24 | 25 | 26 | 27 | 28 | OCA\TwoFactorU2F\Provider\U2FProvider 29 | 30 | 31 | 32 | 33 | OCA\TwoFactorU2F\Activity\Setting 34 | 35 | 36 | OCA\TwoFactorU2F\Activity\Provider 37 | 38 | 39 | 40 | -------------------------------------------------------------------------------- /lib/Listener/StateChangeRegistryUpdater.php: -------------------------------------------------------------------------------- 1 | 12 | * @copyright Christoph Wurst 2018 13 | */ 14 | 15 | namespace OCA\TwoFactorU2F\Listener; 16 | 17 | use OCA\TwoFactorU2F\Event\StateChanged; 18 | use OCA\TwoFactorU2F\Provider\U2FProvider; 19 | use OCA\TwoFactorU2F\Service\U2FManager; 20 | use OCP\Authentication\TwoFactorAuth\IRegistry; 21 | use OCP\EventDispatcher\Event; 22 | use OCP\EventDispatcher\IEventListener; 23 | 24 | class StateChangeRegistryUpdater implements IEventListener { 25 | 26 | /** @var IRegistry */ 27 | private $providerRegistry; 28 | 29 | /** @var U2FManager */ 30 | private $manager; 31 | 32 | /** @var U2FProvider */ 33 | private $provider; 34 | 35 | public function __construct(IRegistry $providerRegistry, U2FManager $manager, U2FProvider $provider) { 36 | $this->providerRegistry = $providerRegistry; 37 | $this->provider = $provider; 38 | $this->manager = $manager; 39 | } 40 | 41 | public function handle(Event $event): void { 42 | if ($event instanceof StateChanged) { 43 | $devices = $this->manager->getDevices($event->getUser()); 44 | if ($event->isEnabled() && count($devices) === 1) { 45 | // The first device was enabled -> enable provider for this user 46 | $this->providerRegistry->enableProviderFor($this->provider, $event->getUser()); 47 | } elseif (!$event->isEnabled() && empty($devices)) { 48 | // The last device was removed -> disable provider for this user 49 | $this->providerRegistry->disableProviderFor($this->provider, $event->getUser()); 50 | } 51 | } 52 | } 53 | } 54 | -------------------------------------------------------------------------------- /src/tests/components/Device.spec.js: -------------------------------------------------------------------------------- 1 | /* 2 | * @copyright 2018 Christoph Wurst 3 | * 4 | * @author 2018 Christoph Wurst 5 | * 6 | * @license GNU AGPL version 3 or any later version 7 | * 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU Affero General Public License as 10 | * published by the Free Software Foundation, either version 3 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU Affero General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU Affero General Public License 19 | * along with this program. If not, see . 20 | */ 21 | 22 | import {shallowMount, createLocalVue} from '@vue/test-utils' 23 | import Vuex from 'vuex' 24 | 25 | import Nextcloud from '../../mixins/Nextcloud' 26 | 27 | const localVue = createLocalVue() 28 | 29 | localVue.use(Vuex) 30 | localVue.mixin(Nextcloud) 31 | 32 | import Device from '../../components/Device' 33 | 34 | describe('Device component', () => { 35 | var actions 36 | var store 37 | 38 | beforeEach(() => { 39 | actions = {} 40 | store = new Vuex.Store({ 41 | state: { 42 | devices: [] 43 | }, 44 | actions 45 | }) 46 | }) 47 | 48 | it('renders devices without a name', () => { 49 | store.state.devices.push({ 50 | id: 1, 51 | name: undefined 52 | }) 53 | const device = shallowMount(Device, { 54 | store, 55 | localVue 56 | }) 57 | 58 | expect(device.text()).to.have.string('Unnamed device') 59 | }) 60 | }) 61 | -------------------------------------------------------------------------------- /l10n/zh_CN.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "添加了一个 U2F 硬件标识", 3 | "You removed an U2F hardware token" : "您已经移除了 U2F 硬件标识", 4 | "U2F disabled by an admin" : "“两步验证”被管理员禁用", 5 | "U2F device" : "U2F 设备", 6 | "Authenticate with an U2F device" : "U2F 设备认证", 7 | "Add U2F device" : "添加“两步验证”设备", 8 | "Please plug in your U2F device and press the device button to authorize." : "请插入您的 U2F 设备并按下设备按钮来授权。", 9 | "Name your device" : "为您的设备命名", 10 | "Add" : "添加", 11 | "Adding your device …" : "正在添加您的设备...", 12 | "Server error while trying to add U2F device" : "尝试添加 U2F 设备时服务器错误", 13 | "U2F device is already registered (error code {errorCode})" : "U2F 设备已注册(错误代码{errorCode})", 14 | "U2F device registration timeout reached (error code {errorCode})" : "U2F 设备注册超时(错误代码{errorCode})", 15 | "U2F device registration failed (error code {errorCode})" : "U2F 设备注册失败 (错误代码 {errorCode})", 16 | "Server error while trying to complete U2F device registration" : "在尝试完成 U2F 设备注册时服务器错误", 17 | "An error occurred: {msg}" : "发生了错误:{msg}", 18 | "Retry" : "重试", 19 | "Plug in your U2F device and press the device button to authorize." : "请插入您的 U2F 设备并按下设备按钮来授权。", 20 | "An error occurred. Please try again." : "发生错误。请重试。", 21 | "Your browser does not support U2F." : "您的浏览器不支持 U2F", 22 | "Please use an up-to-date browser that supports U2F devices, such as Chrome, Edge, Firefox, Opera or Safari." : "请使用支持 U2F 设备的最新浏览器,如Chrome、Edge、Firefox、Opera或Safari。", 23 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "您正在通过不安全的连接访问此网站。 浏览器可能因此拒绝 U2F 验证。", 24 | "Unnamed device" : "未命名的设备", 25 | "Remove" : "移除", 26 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "没有已设置的 U2F 设备。您现在没有使用 U2F 作为两步验证。", 27 | "The following devices are configured for U2F second-factor authentication:" : "下列设备设置了 U2F 两步验证:" 28 | },"pluralForm" :"nplurals=1; plural=0;" 29 | } -------------------------------------------------------------------------------- /tests/psalm-baseline.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | DisabledByAdmin 6 | StateChanged 7 | StateChanged 8 | 9 | 10 | 11 | 12 | StateChanged 13 | 14 | 15 | 16 | 17 | Event 18 | 19 | 20 | 21 | 22 | StateChanged 23 | 24 | 25 | 26 | 27 | StateChanged 28 | 29 | 30 | 31 | 32 | Template 33 | 34 | 35 | 36 | 37 | Template 38 | Template 39 | 40 | 41 | 42 | 43 | DisabledByAdmin 44 | DisabledByAdmin 45 | StateChanged 46 | StateChanged 47 | StateChanged 48 | StateChanged 49 | 50 | 51 | 52 | 53 | Template 54 | Template 55 | 56 | 57 | 58 | -------------------------------------------------------------------------------- /l10n/zh_CN.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "添加了一个 U2F 硬件标识", 5 | "You removed an U2F hardware token" : "您已经移除了 U2F 硬件标识", 6 | "U2F disabled by an admin" : "“两步验证”被管理员禁用", 7 | "U2F device" : "U2F 设备", 8 | "Authenticate with an U2F device" : "U2F 设备认证", 9 | "Add U2F device" : "添加“两步验证”设备", 10 | "Please plug in your U2F device and press the device button to authorize." : "请插入您的 U2F 设备并按下设备按钮来授权。", 11 | "Name your device" : "为您的设备命名", 12 | "Add" : "添加", 13 | "Adding your device …" : "正在添加您的设备...", 14 | "Server error while trying to add U2F device" : "尝试添加 U2F 设备时服务器错误", 15 | "U2F device is already registered (error code {errorCode})" : "U2F 设备已注册(错误代码{errorCode})", 16 | "U2F device registration timeout reached (error code {errorCode})" : "U2F 设备注册超时(错误代码{errorCode})", 17 | "U2F device registration failed (error code {errorCode})" : "U2F 设备注册失败 (错误代码 {errorCode})", 18 | "Server error while trying to complete U2F device registration" : "在尝试完成 U2F 设备注册时服务器错误", 19 | "An error occurred: {msg}" : "发生了错误:{msg}", 20 | "Retry" : "重试", 21 | "Plug in your U2F device and press the device button to authorize." : "请插入您的 U2F 设备并按下设备按钮来授权。", 22 | "An error occurred. Please try again." : "发生错误。请重试。", 23 | "Your browser does not support U2F." : "您的浏览器不支持 U2F", 24 | "Please use an up-to-date browser that supports U2F devices, such as Chrome, Edge, Firefox, Opera or Safari." : "请使用支持 U2F 设备的最新浏览器,如Chrome、Edge、Firefox、Opera或Safari。", 25 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "您正在通过不安全的连接访问此网站。 浏览器可能因此拒绝 U2F 验证。", 26 | "Unnamed device" : "未命名的设备", 27 | "Remove" : "移除", 28 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "没有已设置的 U2F 设备。您现在没有使用 U2F 作为两步验证。", 29 | "The following devices are configured for U2F second-factor authentication:" : "下列设备设置了 U2F 两步验证:" 30 | }, 31 | "nplurals=1; plural=0;"); 32 | -------------------------------------------------------------------------------- /tests/Unit/Activity/SettingTest.php: -------------------------------------------------------------------------------- 1 | 5 | * @copyright Copyright (c) 2016 Christoph Wurst 6 | * 7 | * Two-factor U2F 8 | * 9 | * This code is free software: you can redistribute it and/or modify 10 | * it under the terms of the GNU Affero General Public License, version 3, 11 | * as published by the Free Software Foundation. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU Affero General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU Affero General Public License, version 3, 19 | * along with this program. If not, see 20 | * 21 | */ 22 | 23 | namespace OCA\TwoFactorU2F\Tests\Unit\Activity; 24 | 25 | use OCA\TwoFactorU2F\Activity\Setting; 26 | use OCP\IL10N; 27 | use PHPUnit\Framework\TestCase; 28 | 29 | class SettingTest extends TestCase { 30 | private $l10n; 31 | 32 | /** @var Setting */ 33 | private $setting; 34 | 35 | protected function setUp(): void { 36 | parent::setUp(); 37 | 38 | $this->l10n = $this->createMock(IL10N::class); 39 | 40 | $this->setting = new Setting($this->l10n); 41 | } 42 | 43 | public function testAll() { 44 | $this->assertEquals(false, $this->setting->canChangeMail()); 45 | $this->assertEquals(false, $this->setting->canChangeStream()); 46 | $this->assertEquals('twofactor_u2f', $this->setting->getIdentifier()); 47 | $this->l10n->expects($this->once()) 48 | ->method('t') 49 | ->with('U2F device') 50 | ->willReturn('U2F Gerät'); 51 | $this->assertEquals('U2F Gerät', $this->setting->getName()); 52 | $this->assertEquals(30, $this->setting->getPriority()); 53 | $this->assertEquals(true, $this->setting->isDefaultEnabledMail()); 54 | $this->assertEquals(true, $this->setting->isDefaultEnabledStream()); 55 | } 56 | } 57 | -------------------------------------------------------------------------------- /l10n/ka_GE.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "თქვენ დაამატეთ U2F მოწყობილობის ტოკენი", 3 | "You removed an U2F hardware token" : "თქვენ გააუქმეთ U2F მოწყობილობის ტოკენი", 4 | "U2F device" : "U2F მოწყობილობა", 5 | "Authenticate with an U2F device" : "აუტენტიფიკაცია U2F მოწყობილობით", 6 | "Add U2F device" : "U2F მოწყობილობის დამატება", 7 | "Please plug in your U2F device and press the device button to authorize." : "გთხოვთ მიაერთოთ U2F მოწყობილობა და დააწვეთ მოწყობილობის ღილაკს ავტორიზაციისთვის.", 8 | "Add" : "დამატება", 9 | "Server error while trying to add U2F device" : "U2F მოწყობილობის დამატებისას სერვერთან წარმოიშვა შეცდომა", 10 | "U2F device is already registered (error code {errorCode})" : "U2F მოწყობილობა უკვე რეგისტრირებულია (შეცდომის კოდი {errorCode})", 11 | "U2F device registration timeout reached (error code {errorCode})" : "U2F მოწყობილობის რეგისტრაციის დრო ამოიწურა (შეცდომის კოდი {errorCode})", 12 | "U2F device registration failed (error code {errorCode})" : "U2F მოწყობილობის რეგისტრაცია ვერ მოხერხდა (შეცდომის კოდი {errorCode})", 13 | "Server error while trying to complete U2F device registration" : "U2F მოწყობილობის რეგისტრაციისას სერვერთან წარმოიშვა შეცდომა", 14 | "Retry" : "ვცადოთ ახლიდან", 15 | "An error occurred. Please try again." : "გამოჩნდა შეცდომა. გთხოვთ სცადოთ ახლიდან.", 16 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "ამ საიტს უკავშირდებით დაუცველი კავშირით. ბრაუზერებმა შეიძლება უარყონ U2F აუტენტიფიკაცია.", 17 | "Unnamed device" : "უსახელო მოწყობილობა", 18 | "Remove" : "გაუქმება", 19 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "U2F მოწყობილობები კონფიგურირებული არაა. ამ მომენტისთვის თქვენ მეორე ფაქტორად U2F-ს არ იყენებთ.", 20 | "The following devices are configured for U2F second-factor authentication:" : "U2F-s მეორე-ფაქტორის აუტენტიფიკაციისთვის გამოიყენება შემდეგი მოწყობილობები:" 21 | },"pluralForm" :"nplurals=2; plural=(n!=1);" 22 | } -------------------------------------------------------------------------------- /l10n/ka_GE.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "თქვენ დაამატეთ U2F მოწყობილობის ტოკენი", 5 | "You removed an U2F hardware token" : "თქვენ გააუქმეთ U2F მოწყობილობის ტოკენი", 6 | "U2F device" : "U2F მოწყობილობა", 7 | "Authenticate with an U2F device" : "აუტენტიფიკაცია U2F მოწყობილობით", 8 | "Add U2F device" : "U2F მოწყობილობის დამატება", 9 | "Please plug in your U2F device and press the device button to authorize." : "გთხოვთ მიაერთოთ U2F მოწყობილობა და დააწვეთ მოწყობილობის ღილაკს ავტორიზაციისთვის.", 10 | "Add" : "დამატება", 11 | "Server error while trying to add U2F device" : "U2F მოწყობილობის დამატებისას სერვერთან წარმოიშვა შეცდომა", 12 | "U2F device is already registered (error code {errorCode})" : "U2F მოწყობილობა უკვე რეგისტრირებულია (შეცდომის კოდი {errorCode})", 13 | "U2F device registration timeout reached (error code {errorCode})" : "U2F მოწყობილობის რეგისტრაციის დრო ამოიწურა (შეცდომის კოდი {errorCode})", 14 | "U2F device registration failed (error code {errorCode})" : "U2F მოწყობილობის რეგისტრაცია ვერ მოხერხდა (შეცდომის კოდი {errorCode})", 15 | "Server error while trying to complete U2F device registration" : "U2F მოწყობილობის რეგისტრაციისას სერვერთან წარმოიშვა შეცდომა", 16 | "Retry" : "ვცადოთ ახლიდან", 17 | "An error occurred. Please try again." : "გამოჩნდა შეცდომა. გთხოვთ სცადოთ ახლიდან.", 18 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "ამ საიტს უკავშირდებით დაუცველი კავშირით. ბრაუზერებმა შეიძლება უარყონ U2F აუტენტიფიკაცია.", 19 | "Unnamed device" : "უსახელო მოწყობილობა", 20 | "Remove" : "გაუქმება", 21 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "U2F მოწყობილობები კონფიგურირებული არაა. ამ მომენტისთვის თქვენ მეორე ფაქტორად U2F-ს არ იყენებთ.", 22 | "The following devices are configured for U2F second-factor authentication:" : "U2F-s მეორე-ფაქტორის აუტენტიფიკაციისთვის გამოიყენება შემდეგი მოწყობილობები:" 23 | }, 24 | "nplurals=2; plural=(n!=1);"); 25 | -------------------------------------------------------------------------------- /l10n/da.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "Du har tilføjet en U2F hardware nøgle", 3 | "You removed an U2F hardware token" : "Du har fjernet en U2F hardware nøgle", 4 | "U2F device" : "U2F enhed", 5 | "Authenticate with an U2F device" : "Godkend med en U2F enhed", 6 | "Add U2F device" : "Tilføj U2F enhed", 7 | "Please plug in your U2F device and press the device button to authorize." : "Sæt venligst din U2F enhed i og tryk på enhedsknappen for at godkende.", 8 | "Name your device" : "Navngiv din enhed", 9 | "Add" : "Tilføj", 10 | "Adding your device …" : "Tilføjer din enhed...", 11 | "Server error while trying to add U2F device" : "Serverfejl ved tilføjelse af U2F enhed", 12 | "U2F device is already registered (error code {errorCode})" : "U2F enhed er allerede registreret (fejlkode {errorCode})", 13 | "U2F device registration timeout reached (error code {errorCode})" : "U2F enhed registrering fik timeout (fejlkode {errorCode})", 14 | "U2F device registration failed (error code {errorCode})" : "Registrering af U2F enhed fejlede (fejlkode {errorCode})", 15 | "Server error while trying to complete U2F device registration" : "Serverfejl ved U2F enhed registrering", 16 | "An error occurred: {msg}" : "Der skete en fejl: {msg}", 17 | "Retry" : "Prøv igen", 18 | "An error occurred. Please try again." : "En fejl opstod. Prøv venligst igen.", 19 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Du tilgår denne side via en usikker forbindelse. Browseren vil derfor måske nægte dig at bruge U2F godkendelse.", 20 | "Unnamed device" : "Unavngiven enhed", 21 | "Remove" : "Fjern", 22 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "Ingen U2F enheder konfigureret. Du benytter ikke U2F som anden faktor i øjeblikket.", 23 | "The following devices are configured for U2F second-factor authentication:" : "De følgende enheder er konfigureret for U2F anden faktor login." 24 | },"pluralForm" :"nplurals=2; plural=(n != 1);" 25 | } -------------------------------------------------------------------------------- /lib/Activity/Setting.php: -------------------------------------------------------------------------------- 1 | 7 | * @copyright Copyright (c) 2018 Christoph Wurst 8 | * 9 | * Two-factor U2F 10 | * 11 | * This code is free software: you can redistribute it and/or modify 12 | * it under the terms of the GNU Affero General Public License, version 3, 13 | * as published by the Free Software Foundation. 14 | * 15 | * This program is distributed in the hope that it will be useful, 16 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 17 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18 | * GNU Affero General Public License for more details. 19 | * 20 | * You should have received a copy of the GNU Affero General Public License, version 3, 21 | * along with this program. If not, see 22 | * 23 | */ 24 | 25 | namespace OCA\TwoFactorU2F\Activity; 26 | 27 | use OCP\Activity\ISetting; 28 | use OCP\IL10N; 29 | 30 | class Setting implements ISetting { 31 | 32 | /** @var IL10N */ 33 | private $l10n; 34 | 35 | /** 36 | * @param IL10N $l10n 37 | */ 38 | public function __construct(IL10N $l10n) { 39 | $this->l10n = $l10n; 40 | } 41 | 42 | /** 43 | * @return boolean 44 | */ 45 | public function canChangeMail() { 46 | return false; 47 | } 48 | 49 | /** 50 | * @return boolean 51 | */ 52 | public function canChangeStream() { 53 | return false; 54 | } 55 | 56 | /** 57 | * @return string 58 | */ 59 | public function getIdentifier() { 60 | return 'twofactor_u2f'; 61 | } 62 | 63 | /** 64 | * @return string 65 | */ 66 | public function getName() { 67 | return $this->l10n->t('U2F device'); 68 | } 69 | 70 | /** 71 | * @return int 72 | */ 73 | public function getPriority() { 74 | return 30; 75 | } 76 | 77 | /** 78 | * @return boolean 79 | */ 80 | public function isDefaultEnabledMail() { 81 | return true; 82 | } 83 | 84 | /** 85 | * @return boolean 86 | */ 87 | public function isDefaultEnabledStream() { 88 | return true; 89 | } 90 | } 91 | -------------------------------------------------------------------------------- /l10n/da.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "Du har tilføjet en U2F hardware nøgle", 5 | "You removed an U2F hardware token" : "Du har fjernet en U2F hardware nøgle", 6 | "U2F device" : "U2F enhed", 7 | "Authenticate with an U2F device" : "Godkend med en U2F enhed", 8 | "Add U2F device" : "Tilføj U2F enhed", 9 | "Please plug in your U2F device and press the device button to authorize." : "Sæt venligst din U2F enhed i og tryk på enhedsknappen for at godkende.", 10 | "Name your device" : "Navngiv din enhed", 11 | "Add" : "Tilføj", 12 | "Adding your device …" : "Tilføjer din enhed...", 13 | "Server error while trying to add U2F device" : "Serverfejl ved tilføjelse af U2F enhed", 14 | "U2F device is already registered (error code {errorCode})" : "U2F enhed er allerede registreret (fejlkode {errorCode})", 15 | "U2F device registration timeout reached (error code {errorCode})" : "U2F enhed registrering fik timeout (fejlkode {errorCode})", 16 | "U2F device registration failed (error code {errorCode})" : "Registrering af U2F enhed fejlede (fejlkode {errorCode})", 17 | "Server error while trying to complete U2F device registration" : "Serverfejl ved U2F enhed registrering", 18 | "An error occurred: {msg}" : "Der skete en fejl: {msg}", 19 | "Retry" : "Prøv igen", 20 | "An error occurred. Please try again." : "En fejl opstod. Prøv venligst igen.", 21 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Du tilgår denne side via en usikker forbindelse. Browseren vil derfor måske nægte dig at bruge U2F godkendelse.", 22 | "Unnamed device" : "Unavngiven enhed", 23 | "Remove" : "Fjern", 24 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "Ingen U2F enheder konfigureret. Du benytter ikke U2F som anden faktor i øjeblikket.", 25 | "The following devices are configured for U2F second-factor authentication:" : "De følgende enheder er konfigureret for U2F anden faktor login." 26 | }, 27 | "nplurals=2; plural=(n != 1);"); 28 | -------------------------------------------------------------------------------- /l10n/ko.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "U2F 하드웨어 토큰을 추가함", 3 | "You removed an U2F hardware token" : "U2F 하드웨어 토큰을 삭제함", 4 | "U2F disabled by an admin" : "관리자가 U2F를 비활성화함", 5 | "U2F device" : "U2F 장치", 6 | "Authenticate with an U2F device" : "U2F 장치로 인증", 7 | "Add U2F device" : "U2F 장치 추가", 8 | "Please plug in your U2F device and press the device button to authorize." : "U2F 장치를 연결하고 장치의 단추를 눌러서 인증하십시오.", 9 | "Name your device" : "장치 이름 설정", 10 | "Add" : "추가", 11 | "Adding your device …" : "장치 추가 중 …", 12 | "Server error while trying to add U2F device" : "U2F 장치를 추가하는 중 서버 오류 발생", 13 | "U2F device is already registered (error code {errorCode})" : "U2F 장치가 이미 등록됨(오류 코드 {errorCode})", 14 | "U2F device registration timeout reached (error code {errorCode})" : "U2F 장치 등록 시간이 초과됨(오류 코드 {errorCode})", 15 | "U2F device registration failed (error code {errorCode})" : "U2F 장치 등록이 실패함(오류 코드 {errorCode})", 16 | "Server error while trying to complete U2F device registration" : "U2F 장치 등록을 마치는 중 서버 오류 발생", 17 | "An error occurred: {msg}" : "오류 발생: {msg}", 18 | "Retry" : "다시 시도", 19 | "Plug in your U2F device and press the device button to authorize." : "U2F 장치를 연결하고 장치의 단추를 눌러서 인증하십시오.", 20 | "An error occurred. Please try again." : "오류가 발생했습니다. 다시 시도하십시오.", 21 | "Your browser does not support U2F." : "브라우저에서 U2F를 지원하지 않습니다.", 22 | "Please use an up-to-date browser that supports U2F devices, such as Chrome, Edge, Firefox, Opera or Safari." : "U2F 기기를 지원하는 Chrome, Edge, Firefox, Opera, Safari 등 최신 브라우저를 사용하십시오", 23 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "이 사이트를 안전하지 않은 연결로 접근하고 있습니다. 브라우저에서 U2F 인증을 거부할 수도 있습니다.", 24 | "Unnamed device" : "이름 없는 장치", 25 | "Remove" : "삭제", 26 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "U2F 장치를 설정하지 않았습니다. U2F 2단계 인증을 사용하고 있지 않습니다.", 27 | "The following devices are configured for U2F second-factor authentication:" : "U2F 2단계 인증에 다음 장치를 사용하도록 설정되었습니다:" 28 | },"pluralForm" :"nplurals=1; plural=0;" 29 | } -------------------------------------------------------------------------------- /l10n/ko.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "U2F 하드웨어 토큰을 추가함", 5 | "You removed an U2F hardware token" : "U2F 하드웨어 토큰을 삭제함", 6 | "U2F disabled by an admin" : "관리자가 U2F를 비활성화함", 7 | "U2F device" : "U2F 장치", 8 | "Authenticate with an U2F device" : "U2F 장치로 인증", 9 | "Add U2F device" : "U2F 장치 추가", 10 | "Please plug in your U2F device and press the device button to authorize." : "U2F 장치를 연결하고 장치의 단추를 눌러서 인증하십시오.", 11 | "Name your device" : "장치 이름 설정", 12 | "Add" : "추가", 13 | "Adding your device …" : "장치 추가 중 …", 14 | "Server error while trying to add U2F device" : "U2F 장치를 추가하는 중 서버 오류 발생", 15 | "U2F device is already registered (error code {errorCode})" : "U2F 장치가 이미 등록됨(오류 코드 {errorCode})", 16 | "U2F device registration timeout reached (error code {errorCode})" : "U2F 장치 등록 시간이 초과됨(오류 코드 {errorCode})", 17 | "U2F device registration failed (error code {errorCode})" : "U2F 장치 등록이 실패함(오류 코드 {errorCode})", 18 | "Server error while trying to complete U2F device registration" : "U2F 장치 등록을 마치는 중 서버 오류 발생", 19 | "An error occurred: {msg}" : "오류 발생: {msg}", 20 | "Retry" : "다시 시도", 21 | "Plug in your U2F device and press the device button to authorize." : "U2F 장치를 연결하고 장치의 단추를 눌러서 인증하십시오.", 22 | "An error occurred. Please try again." : "오류가 발생했습니다. 다시 시도하십시오.", 23 | "Your browser does not support U2F." : "브라우저에서 U2F를 지원하지 않습니다.", 24 | "Please use an up-to-date browser that supports U2F devices, such as Chrome, Edge, Firefox, Opera or Safari." : "U2F 기기를 지원하는 Chrome, Edge, Firefox, Opera, Safari 등 최신 브라우저를 사용하십시오", 25 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "이 사이트를 안전하지 않은 연결로 접근하고 있습니다. 브라우저에서 U2F 인증을 거부할 수도 있습니다.", 26 | "Unnamed device" : "이름 없는 장치", 27 | "Remove" : "삭제", 28 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "U2F 장치를 설정하지 않았습니다. U2F 2단계 인증을 사용하고 있지 않습니다.", 29 | "The following devices are configured for U2F second-factor authentication:" : "U2F 2단계 인증에 다음 장치를 사용하도록 설정되었습니다:" 30 | }, 31 | "nplurals=1; plural=0;"); 32 | -------------------------------------------------------------------------------- /l10n/es_419.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 3 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 4 | "U2F device" : "dispositivo U2F", 5 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 6 | "Add U2F device" : "Agregar dispositivo U2F", 7 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 8 | "Add" : "Agregar", 9 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 10 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 11 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 12 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 13 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 14 | "Retry" : "Reintentar", 15 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 16 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 17 | "Unnamed device" : "Dispositivo sin nombre", 18 | "Remove" : "Eliminar", 19 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 20 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 21 | },"pluralForm" :"nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;" 22 | } -------------------------------------------------------------------------------- /l10n/es_CL.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 3 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 4 | "U2F device" : "dispositivo U2F", 5 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 6 | "Add U2F device" : "Agregar dispositivo U2F", 7 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 8 | "Add" : "Agregar", 9 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 10 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 11 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 12 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 13 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 14 | "Retry" : "Reintentar", 15 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 16 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 17 | "Unnamed device" : "Dispositivo sin nombre", 18 | "Remove" : "Eliminar", 19 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 20 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 21 | },"pluralForm" :"nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;" 22 | } -------------------------------------------------------------------------------- /l10n/es_CO.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 3 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 4 | "U2F device" : "dispositivo U2F", 5 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 6 | "Add U2F device" : "Agregar dispositivo U2F", 7 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 8 | "Add" : "Agregar", 9 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 10 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 11 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 12 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 13 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 14 | "Retry" : "Reintentar", 15 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 16 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 17 | "Unnamed device" : "Dispositivo sin nombre", 18 | "Remove" : "Eliminar", 19 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 20 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 21 | },"pluralForm" :"nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;" 22 | } -------------------------------------------------------------------------------- /l10n/es_CR.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 3 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 4 | "U2F device" : "dispositivo U2F", 5 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 6 | "Add U2F device" : "Agregar dispositivo U2F", 7 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 8 | "Add" : "Agregar", 9 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 10 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 11 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 12 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 13 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 14 | "Retry" : "Reintentar", 15 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 16 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 17 | "Unnamed device" : "Dispositivo sin nombre", 18 | "Remove" : "Eliminar", 19 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 20 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 21 | },"pluralForm" :"nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;" 22 | } -------------------------------------------------------------------------------- /l10n/es_DO.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 3 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 4 | "U2F device" : "dispositivo U2F", 5 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 6 | "Add U2F device" : "Agregar dispositivo U2F", 7 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 8 | "Add" : "Agregar", 9 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 10 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 11 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 12 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 13 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 14 | "Retry" : "Reintentar", 15 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 16 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 17 | "Unnamed device" : "Dispositivo sin nombre", 18 | "Remove" : "Eliminar", 19 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 20 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 21 | },"pluralForm" :"nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;" 22 | } -------------------------------------------------------------------------------- /l10n/es_EC.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 3 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 4 | "U2F device" : "dispositivo U2F", 5 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 6 | "Add U2F device" : "Agregar dispositivo U2F", 7 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 8 | "Add" : "Agregar", 9 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 10 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 11 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 12 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 13 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 14 | "Retry" : "Reintentar", 15 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 16 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 17 | "Unnamed device" : "Dispositivo sin nombre", 18 | "Remove" : "Eliminar", 19 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 20 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 21 | },"pluralForm" :"nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;" 22 | } -------------------------------------------------------------------------------- /l10n/es_GT.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 3 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 4 | "U2F device" : "dispositivo U2F", 5 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 6 | "Add U2F device" : "Agregar dispositivo U2F", 7 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 8 | "Add" : "Agregar", 9 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 10 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 11 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 12 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 13 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 14 | "Retry" : "Reintentar", 15 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 16 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 17 | "Unnamed device" : "Dispositivo sin nombre", 18 | "Remove" : "Eliminar", 19 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 20 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 21 | },"pluralForm" :"nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;" 22 | } -------------------------------------------------------------------------------- /l10n/es_HN.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 3 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 4 | "U2F device" : "dispositivo U2F", 5 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 6 | "Add U2F device" : "Agregar dispositivo U2F", 7 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 8 | "Add" : "Agregar", 9 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 10 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 11 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 12 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 13 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 14 | "Retry" : "Reintentar", 15 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 16 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 17 | "Unnamed device" : "Dispositivo sin nombre", 18 | "Remove" : "Eliminar", 19 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 20 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 21 | },"pluralForm" :"nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;" 22 | } -------------------------------------------------------------------------------- /l10n/es_MX.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 3 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 4 | "U2F device" : "dispositivo U2F", 5 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 6 | "Add U2F device" : "Agregar dispositivo U2F", 7 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 8 | "Add" : "Agregar", 9 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 10 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 11 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 12 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 13 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 14 | "Retry" : "Reintentar", 15 | "An error occurred. Please try again." : "Se presentó un error. Por favor vuelve a intentarlo.", 16 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 17 | "Unnamed device" : "Dispositivo sin nombre", 18 | "Remove" : "Eliminar", 19 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 20 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 21 | },"pluralForm" :"nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;" 22 | } -------------------------------------------------------------------------------- /l10n/es_NI.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 3 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 4 | "U2F device" : "dispositivo U2F", 5 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 6 | "Add U2F device" : "Agregar dispositivo U2F", 7 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 8 | "Add" : "Agregar", 9 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 10 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 11 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 12 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 13 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 14 | "Retry" : "Reintentar", 15 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 16 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 17 | "Unnamed device" : "Dispositivo sin nombre", 18 | "Remove" : "Eliminar", 19 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 20 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 21 | },"pluralForm" :"nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;" 22 | } -------------------------------------------------------------------------------- /l10n/es_PA.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 3 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 4 | "U2F device" : "dispositivo U2F", 5 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 6 | "Add U2F device" : "Agregar dispositivo U2F", 7 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 8 | "Add" : "Agregar", 9 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 10 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 11 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 12 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 13 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 14 | "Retry" : "Reintentar", 15 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 16 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 17 | "Unnamed device" : "Dispositivo sin nombre", 18 | "Remove" : "Eliminar", 19 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 20 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 21 | },"pluralForm" :"nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;" 22 | } -------------------------------------------------------------------------------- /l10n/es_PE.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 3 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 4 | "U2F device" : "dispositivo U2F", 5 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 6 | "Add U2F device" : "Agregar dispositivo U2F", 7 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 8 | "Add" : "Agregar", 9 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 10 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 11 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 12 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 13 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 14 | "Retry" : "Reintentar", 15 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 16 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 17 | "Unnamed device" : "Dispositivo sin nombre", 18 | "Remove" : "Eliminar", 19 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 20 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 21 | },"pluralForm" :"nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;" 22 | } -------------------------------------------------------------------------------- /l10n/es_PR.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 3 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 4 | "U2F device" : "dispositivo U2F", 5 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 6 | "Add U2F device" : "Agregar dispositivo U2F", 7 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 8 | "Add" : "Agregar", 9 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 10 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 11 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 12 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 13 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 14 | "Retry" : "Reintentar", 15 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 16 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 17 | "Unnamed device" : "Dispositivo sin nombre", 18 | "Remove" : "Eliminar", 19 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 20 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 21 | },"pluralForm" :"nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;" 22 | } -------------------------------------------------------------------------------- /l10n/es_PY.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 3 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 4 | "U2F device" : "dispositivo U2F", 5 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 6 | "Add U2F device" : "Agregar dispositivo U2F", 7 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 8 | "Add" : "Agregar", 9 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 10 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 11 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 12 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 13 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 14 | "Retry" : "Reintentar", 15 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 16 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 17 | "Unnamed device" : "Dispositivo sin nombre", 18 | "Remove" : "Eliminar", 19 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 20 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 21 | },"pluralForm" :"nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;" 22 | } -------------------------------------------------------------------------------- /l10n/es_SV.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 3 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 4 | "U2F device" : "dispositivo U2F", 5 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 6 | "Add U2F device" : "Agregar dispositivo U2F", 7 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 8 | "Add" : "Agregar", 9 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 10 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 11 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 12 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 13 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 14 | "Retry" : "Reintentar", 15 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 16 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 17 | "Unnamed device" : "Dispositivo sin nombre", 18 | "Remove" : "Eliminar", 19 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 20 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 21 | },"pluralForm" :"nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;" 22 | } -------------------------------------------------------------------------------- /l10n/es_UY.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 3 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 4 | "U2F device" : "dispositivo U2F", 5 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 6 | "Add U2F device" : "Agregar dispositivo U2F", 7 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 8 | "Add" : "Agregar", 9 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 10 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 11 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 12 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 13 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 14 | "Retry" : "Reintentar", 15 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 16 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 17 | "Unnamed device" : "Dispositivo sin nombre", 18 | "Remove" : "Eliminar", 19 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 20 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 21 | },"pluralForm" :"nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;" 22 | } -------------------------------------------------------------------------------- /l10n/es_419.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 5 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 6 | "U2F device" : "dispositivo U2F", 7 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 8 | "Add U2F device" : "Agregar dispositivo U2F", 9 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 10 | "Add" : "Agregar", 11 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 12 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 13 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 14 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 15 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 16 | "Retry" : "Reintentar", 17 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 18 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 19 | "Unnamed device" : "Dispositivo sin nombre", 20 | "Remove" : "Eliminar", 21 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 22 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 23 | }, 24 | "nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;"); 25 | -------------------------------------------------------------------------------- /l10n/es_CL.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 5 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 6 | "U2F device" : "dispositivo U2F", 7 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 8 | "Add U2F device" : "Agregar dispositivo U2F", 9 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 10 | "Add" : "Agregar", 11 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 12 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 13 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 14 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 15 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 16 | "Retry" : "Reintentar", 17 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 18 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 19 | "Unnamed device" : "Dispositivo sin nombre", 20 | "Remove" : "Eliminar", 21 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 22 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 23 | }, 24 | "nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;"); 25 | -------------------------------------------------------------------------------- /l10n/es_CO.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 5 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 6 | "U2F device" : "dispositivo U2F", 7 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 8 | "Add U2F device" : "Agregar dispositivo U2F", 9 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 10 | "Add" : "Agregar", 11 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 12 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 13 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 14 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 15 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 16 | "Retry" : "Reintentar", 17 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 18 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 19 | "Unnamed device" : "Dispositivo sin nombre", 20 | "Remove" : "Eliminar", 21 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 22 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 23 | }, 24 | "nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;"); 25 | -------------------------------------------------------------------------------- /l10n/es_CR.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 5 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 6 | "U2F device" : "dispositivo U2F", 7 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 8 | "Add U2F device" : "Agregar dispositivo U2F", 9 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 10 | "Add" : "Agregar", 11 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 12 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 13 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 14 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 15 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 16 | "Retry" : "Reintentar", 17 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 18 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 19 | "Unnamed device" : "Dispositivo sin nombre", 20 | "Remove" : "Eliminar", 21 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 22 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 23 | }, 24 | "nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;"); 25 | -------------------------------------------------------------------------------- /l10n/es_DO.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 5 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 6 | "U2F device" : "dispositivo U2F", 7 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 8 | "Add U2F device" : "Agregar dispositivo U2F", 9 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 10 | "Add" : "Agregar", 11 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 12 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 13 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 14 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 15 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 16 | "Retry" : "Reintentar", 17 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 18 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 19 | "Unnamed device" : "Dispositivo sin nombre", 20 | "Remove" : "Eliminar", 21 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 22 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 23 | }, 24 | "nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;"); 25 | -------------------------------------------------------------------------------- /l10n/es_EC.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 5 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 6 | "U2F device" : "dispositivo U2F", 7 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 8 | "Add U2F device" : "Agregar dispositivo U2F", 9 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 10 | "Add" : "Agregar", 11 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 12 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 13 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 14 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 15 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 16 | "Retry" : "Reintentar", 17 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 18 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 19 | "Unnamed device" : "Dispositivo sin nombre", 20 | "Remove" : "Eliminar", 21 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 22 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 23 | }, 24 | "nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;"); 25 | -------------------------------------------------------------------------------- /l10n/es_GT.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 5 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 6 | "U2F device" : "dispositivo U2F", 7 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 8 | "Add U2F device" : "Agregar dispositivo U2F", 9 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 10 | "Add" : "Agregar", 11 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 12 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 13 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 14 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 15 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 16 | "Retry" : "Reintentar", 17 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 18 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 19 | "Unnamed device" : "Dispositivo sin nombre", 20 | "Remove" : "Eliminar", 21 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 22 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 23 | }, 24 | "nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;"); 25 | -------------------------------------------------------------------------------- /l10n/es_HN.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 5 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 6 | "U2F device" : "dispositivo U2F", 7 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 8 | "Add U2F device" : "Agregar dispositivo U2F", 9 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 10 | "Add" : "Agregar", 11 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 12 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 13 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 14 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 15 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 16 | "Retry" : "Reintentar", 17 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 18 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 19 | "Unnamed device" : "Dispositivo sin nombre", 20 | "Remove" : "Eliminar", 21 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 22 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 23 | }, 24 | "nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;"); 25 | -------------------------------------------------------------------------------- /l10n/es_MX.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 5 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 6 | "U2F device" : "dispositivo U2F", 7 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 8 | "Add U2F device" : "Agregar dispositivo U2F", 9 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 10 | "Add" : "Agregar", 11 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 12 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 13 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 14 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 15 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 16 | "Retry" : "Reintentar", 17 | "An error occurred. Please try again." : "Se presentó un error. Por favor vuelve a intentarlo.", 18 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 19 | "Unnamed device" : "Dispositivo sin nombre", 20 | "Remove" : "Eliminar", 21 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 22 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 23 | }, 24 | "nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;"); 25 | -------------------------------------------------------------------------------- /l10n/es_NI.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 5 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 6 | "U2F device" : "dispositivo U2F", 7 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 8 | "Add U2F device" : "Agregar dispositivo U2F", 9 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 10 | "Add" : "Agregar", 11 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 12 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 13 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 14 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 15 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 16 | "Retry" : "Reintentar", 17 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 18 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 19 | "Unnamed device" : "Dispositivo sin nombre", 20 | "Remove" : "Eliminar", 21 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 22 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 23 | }, 24 | "nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;"); 25 | -------------------------------------------------------------------------------- /l10n/es_PA.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 5 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 6 | "U2F device" : "dispositivo U2F", 7 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 8 | "Add U2F device" : "Agregar dispositivo U2F", 9 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 10 | "Add" : "Agregar", 11 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 12 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 13 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 14 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 15 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 16 | "Retry" : "Reintentar", 17 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 18 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 19 | "Unnamed device" : "Dispositivo sin nombre", 20 | "Remove" : "Eliminar", 21 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 22 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 23 | }, 24 | "nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;"); 25 | -------------------------------------------------------------------------------- /l10n/es_PE.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 5 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 6 | "U2F device" : "dispositivo U2F", 7 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 8 | "Add U2F device" : "Agregar dispositivo U2F", 9 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 10 | "Add" : "Agregar", 11 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 12 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 13 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 14 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 15 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 16 | "Retry" : "Reintentar", 17 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 18 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 19 | "Unnamed device" : "Dispositivo sin nombre", 20 | "Remove" : "Eliminar", 21 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 22 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 23 | }, 24 | "nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;"); 25 | -------------------------------------------------------------------------------- /l10n/es_PR.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 5 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 6 | "U2F device" : "dispositivo U2F", 7 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 8 | "Add U2F device" : "Agregar dispositivo U2F", 9 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 10 | "Add" : "Agregar", 11 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 12 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 13 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 14 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 15 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 16 | "Retry" : "Reintentar", 17 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 18 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 19 | "Unnamed device" : "Dispositivo sin nombre", 20 | "Remove" : "Eliminar", 21 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 22 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 23 | }, 24 | "nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;"); 25 | -------------------------------------------------------------------------------- /l10n/es_PY.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 5 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 6 | "U2F device" : "dispositivo U2F", 7 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 8 | "Add U2F device" : "Agregar dispositivo U2F", 9 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 10 | "Add" : "Agregar", 11 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 12 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 13 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 14 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 15 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 16 | "Retry" : "Reintentar", 17 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 18 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 19 | "Unnamed device" : "Dispositivo sin nombre", 20 | "Remove" : "Eliminar", 21 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 22 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 23 | }, 24 | "nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;"); 25 | -------------------------------------------------------------------------------- /l10n/es_SV.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 5 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 6 | "U2F device" : "dispositivo U2F", 7 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 8 | "Add U2F device" : "Agregar dispositivo U2F", 9 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 10 | "Add" : "Agregar", 11 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 12 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 13 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 14 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 15 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 16 | "Retry" : "Reintentar", 17 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 18 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 19 | "Unnamed device" : "Dispositivo sin nombre", 20 | "Remove" : "Eliminar", 21 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 22 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 23 | }, 24 | "nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;"); 25 | -------------------------------------------------------------------------------- /l10n/es_UY.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "Agregaste una ficha U2F física", 5 | "You removed an U2F hardware token" : "Eliminaste una ficha U2F física", 6 | "U2F device" : "dispositivo U2F", 7 | "Authenticate with an U2F device" : "Autenticar con un dispositivo U2F", 8 | "Add U2F device" : "Agregar dispositivo U2F", 9 | "Please plug in your U2F device and press the device button to authorize." : "Por favor conecta tu dispositivo U2F y presiona el botón del dispositivo para autorizar. ", 10 | "Add" : "Agregar", 11 | "Server error while trying to add U2F device" : "Se presentó un error al intentar agregar un dispositivo U2F", 12 | "U2F device is already registered (error code {errorCode})" : "El dispositivo U2F ya está registrado (código de error {errorCode})", 13 | "U2F device registration timeout reached (error code {errorCode})" : "Se alcanzó el tiempo de expiración del registro del dispositivo U2F (código de error {errorCode})", 14 | "U2F device registration failed (error code {errorCode})" : "Se presentó una falla en el registro del dispositivo U2F (código de error {errorCode})", 15 | "Server error while trying to complete U2F device registration" : "Se presentó un error del servidor al tratar de completar el registro del dispositivo U2F", 16 | "Retry" : "Reintentar", 17 | "An error occurred. Please try again." : "Se presentó un erorr. Por favor vuelve a intentarlo.", 18 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Estás accediendo a este sitio vía una conexión insegura. Los navegadores pueden llegar a reusar la autenticación U2F.", 19 | "Unnamed device" : "Dispositivo sin nombre", 20 | "Remove" : "Eliminar", 21 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "No se han configurado dispositivos U2F. No estás usando U2F como un segundo factor ahora. ", 22 | "The following devices are configured for U2F second-factor authentication:" : "Los siguientes dispositivos están configurados para autenticación de dos-factores U2F:" 23 | }, 24 | "nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;"); 25 | -------------------------------------------------------------------------------- /l10n/zh_HK.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "你已新增一個U2F硬體檢驗代碼。", 3 | "You removed an U2F hardware token" : "你已移除一個U2F硬體檢驗代碼。", 4 | "U2F disabled by an admin" : "被系統管理員停用U2F功能", 5 | "U2F device" : "U2F裝置", 6 | "Authenticate with an U2F device" : "使用U2F裝置進行驗證", 7 | "⚠️ Deprecated ⚠️ Two-Factor U2F" : "⚠️ 已棄用 ⚠️ 雙因子 U2F", 8 | "U2F two-factor provider (deprecated)" : "U2F 雙重認證供應商 (已棄用)", 9 | "Deprecated two-factor provider for U2F devices. The Two-Factor WebAuthn provider replaces this app." : "已棄用 U2F 設備的雙因素提供程序。兩因素 WebAuthn 提供程序取代了此應用程式。", 10 | "Add U2F device" : "新增U2F裝置", 11 | "Please plug in your U2F device and press the device button to authorize." : "請接入您的U2F裝置並按下裝置上按鍵進行驗證", 12 | "Name your device" : "請命名您的裝置以利辨識", 13 | "Add" : "新增", 14 | "Adding your device …" : "正在新增你的裝置…", 15 | "Server error while trying to add U2F device" : "在新增U2F裝置時伺服器發生錯誤", 16 | "U2F device is already registered (error code {errorCode})" : "U2F裝置已經註冊(錯誤代碼 {errorCode})", 17 | "U2F device registration timeout reached (error code {errorCode})" : "U2F裝置註冊已逾時(錯誤代碼 {errorCode})", 18 | "U2F device registration failed (error code {errorCode})" : "U2F裝置註冊失敗(錯誤代碼 {errorCode})", 19 | "Server error while trying to complete U2F device registration" : "嘗試完成U2F裝置註冊時發生伺服器錯誤。", 20 | "An error occurred: {msg}" : "發生錯誤:{msg}", 21 | "Retry" : "重試", 22 | "Plug in your U2F device and press the device button to authorize." : "接入您的U2F裝置並按下裝置上按鍵進行驗證", 23 | "An error occurred. Please try again." : "發生錯誤,請再試一次。", 24 | "Your browser does not support U2F." : "您的瀏覽器不支援U2F協定", 25 | "Please use an up-to-date browser that supports U2F devices, such as Chrome, Edge, Firefox, Opera or Safari." : "請使用支持U2F設備的最新瀏覽器,例如Chrome,Edge,Firefox,Opera或Safari。", 26 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "您正使用不安全的連線。瀏覽器可能會因此拒絕U2F驗證", 27 | "Unnamed device" : "未命名的裝置", 28 | "Remove" : "移除", 29 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "尚未設定U2F裝置,您現階段無法使用U2F進行雙重認證。", 30 | "The following devices are configured for U2F second-factor authentication:" : "下列裝置已被設定為U2F雙重認證使用。" 31 | },"pluralForm" :"nplurals=1; plural=0;" 32 | } -------------------------------------------------------------------------------- /l10n/zh_HK.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "你已新增一個U2F硬體檢驗代碼。", 5 | "You removed an U2F hardware token" : "你已移除一個U2F硬體檢驗代碼。", 6 | "U2F disabled by an admin" : "被系統管理員停用U2F功能", 7 | "U2F device" : "U2F裝置", 8 | "Authenticate with an U2F device" : "使用U2F裝置進行驗證", 9 | "⚠️ Deprecated ⚠️ Two-Factor U2F" : "⚠️ 已棄用 ⚠️ 雙因子 U2F", 10 | "U2F two-factor provider (deprecated)" : "U2F 雙重認證供應商 (已棄用)", 11 | "Deprecated two-factor provider for U2F devices. The Two-Factor WebAuthn provider replaces this app." : "已棄用 U2F 設備的雙因素提供程序。兩因素 WebAuthn 提供程序取代了此應用程式。", 12 | "Add U2F device" : "新增U2F裝置", 13 | "Please plug in your U2F device and press the device button to authorize." : "請接入您的U2F裝置並按下裝置上按鍵進行驗證", 14 | "Name your device" : "請命名您的裝置以利辨識", 15 | "Add" : "新增", 16 | "Adding your device …" : "正在新增你的裝置…", 17 | "Server error while trying to add U2F device" : "在新增U2F裝置時伺服器發生錯誤", 18 | "U2F device is already registered (error code {errorCode})" : "U2F裝置已經註冊(錯誤代碼 {errorCode})", 19 | "U2F device registration timeout reached (error code {errorCode})" : "U2F裝置註冊已逾時(錯誤代碼 {errorCode})", 20 | "U2F device registration failed (error code {errorCode})" : "U2F裝置註冊失敗(錯誤代碼 {errorCode})", 21 | "Server error while trying to complete U2F device registration" : "嘗試完成U2F裝置註冊時發生伺服器錯誤。", 22 | "An error occurred: {msg}" : "發生錯誤:{msg}", 23 | "Retry" : "重試", 24 | "Plug in your U2F device and press the device button to authorize." : "接入您的U2F裝置並按下裝置上按鍵進行驗證", 25 | "An error occurred. Please try again." : "發生錯誤,請再試一次。", 26 | "Your browser does not support U2F." : "您的瀏覽器不支援U2F協定", 27 | "Please use an up-to-date browser that supports U2F devices, such as Chrome, Edge, Firefox, Opera or Safari." : "請使用支持U2F設備的最新瀏覽器,例如Chrome,Edge,Firefox,Opera或Safari。", 28 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "您正使用不安全的連線。瀏覽器可能會因此拒絕U2F驗證", 29 | "Unnamed device" : "未命名的裝置", 30 | "Remove" : "移除", 31 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "尚未設定U2F裝置,您現階段無法使用U2F進行雙重認證。", 32 | "The following devices are configured for U2F second-factor authentication:" : "下列裝置已被設定為U2F雙重認證使用。" 33 | }, 34 | "nplurals=1; plural=0;"); 35 | -------------------------------------------------------------------------------- /l10n/zh_TW.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "您新增了一個 U2F 硬體權杖", 3 | "You removed an U2F hardware token" : "您移除了一個 U2F 硬體權杖", 4 | "U2F disabled by an admin" : "系統管理員停用了 U2F 功能", 5 | "U2F device" : "U2F 裝置", 6 | "Authenticate with an U2F device" : "使用 U2F 裝置進行驗證", 7 | "⚠️ Deprecated ⚠️ Two-Factor U2F" : "⚠️ 已棄用 ⚠️ 兩步驟 U2F", 8 | "U2F two-factor provider (deprecated)" : "U2F 兩步驟提供者(已棄用)", 9 | "Deprecated two-factor provider for U2F devices. The Two-Factor WebAuthn provider replaces this app." : "已棄用 U2F 裝置的兩步驟提供者。兩步驟 WebAuthn 提供者取代了此應用程式。", 10 | "Add U2F device" : "新增 U2F 裝置", 11 | "Please plug in your U2F device and press the device button to authorize." : "請插入您的 U2F 裝置並按下裝置上的按鈕以進行驗證。", 12 | "Name your device" : "請為您的裝置命名", 13 | "Add" : "新增", 14 | "Adding your device …" : "正在新增您的裝置……", 15 | "Server error while trying to add U2F device" : "嘗試新增 U2F 裝置時發生伺服器錯誤", 16 | "U2F device is already registered (error code {errorCode})" : "U2F 裝置已被註冊(錯誤代碼 {errorCode})", 17 | "U2F device registration timeout reached (error code {errorCode})" : "U2F 裝置註冊逾時(錯誤代碼 {errorCode})", 18 | "U2F device registration failed (error code {errorCode})" : "U2F 裝置註冊失敗(錯誤代碼 {errorCode})", 19 | "Server error while trying to complete U2F device registration" : "嘗試完成 U2F 裝置註冊時發生伺服器錯誤。", 20 | "An error occurred: {msg}" : "發生錯誤:{msg}", 21 | "Retry" : "重試", 22 | "Plug in your U2F device and press the device button to authorize." : "插入您的 U2F 裝置並按下裝置上的按鈕以進行驗證。", 23 | "An error occurred. Please try again." : "發生錯誤。請再試一次。", 24 | "Your browser does not support U2F." : "您的瀏覽器不支援 U2F。", 25 | "Please use an up-to-date browser that supports U2F devices, such as Chrome, Edge, Firefox, Opera or Safari." : "請使用支援 U2F 裝置的最新瀏覽器,例如 Chrome、Edge、Firefox、Opera 或是 Safari。", 26 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "您正透過不安全的連線造訪此網站。瀏覽器可能會因此拒絕 U2F 驗證。", 27 | "Unnamed device" : "未命名的裝置", 28 | "Remove" : "移除", 29 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "尚未設定 U2F 裝置。您現階段無法使用 U2F 進行兩階段驗證。", 30 | "The following devices are configured for U2F second-factor authentication:" : "下列裝置已被設定為 U2F 兩步驟驗證使用。" 31 | },"pluralForm" :"nplurals=1; plural=0;" 32 | } -------------------------------------------------------------------------------- /src/components/LoginSetup.vue: -------------------------------------------------------------------------------- 1 | 21 | 22 | 39 | 40 | 70 | -------------------------------------------------------------------------------- /l10n/he.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "הוספת אסימון חומרה U2F", 3 | "You removed an U2F hardware token" : "הסרת אסימון חומרה U2F", 4 | "U2F disabled by an admin" : "U2F הושבת על ידי ההנהלה", 5 | "U2F device" : "התקן U2F", 6 | "Authenticate with an U2F device" : "אימות עם התקן U2F", 7 | "Add U2F device" : "הוספת התקן U2F", 8 | "Please plug in your U2F device and press the device button to authorize." : "נא לחבר את התקן ה־U2F שלך וללחוץ על כפתור ההתקן כדי לבצע אימות.", 9 | "Name your device" : "מתן שם להתקן שלך", 10 | "Add" : "הוספה", 11 | "Adding your device …" : "הוספת ההתקן שלך…", 12 | "Server error while trying to add U2F device" : "אירעה שגיאת שרת בעת הניסיון להוספת התקן U2F", 13 | "U2F device is already registered (error code {errorCode})" : "התקן ה־U2F כבר רשום (קוד שגיאה {errorCode})", 14 | "U2F device registration timeout reached (error code {errorCode})" : "הזמן שהוקצב לרישום התקן ה־U2F תם (קוד שגיאה {errorCode})", 15 | "U2F device registration failed (error code {errorCode})" : "רישום התקן ה־U2F נכשל (קוד שגיאה {errorCode})", 16 | "Server error while trying to complete U2F device registration" : "התקבלה שגיאת שרת בעת הניסיון להשלים את הרשמת התקן ה־U2F", 17 | "An error occurred: {msg}" : "אירעה שגיאה: {msg}", 18 | "Retry" : "ניסיון חוזר", 19 | "Plug in your U2F device and press the device button to authorize." : "נא לחבר את התקן ה־U2F שלך וללחוץ על כפתור ההתקן כדי לבצע אימות.", 20 | "An error occurred. Please try again." : "אירעה שגיאה. נא לנסות שוב.", 21 | "Your browser does not support U2F." : "הדפדפן שלך אינו תומך ב־U2F.", 22 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "בחרת לגשת לאתר דרך חיבור בלתי מאובטח. דפדפנים עשויים לסרב לאימות U2F.", 23 | "Unnamed device" : "התקן ללא שם", 24 | "Remove" : "הסרה", 25 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "לא מוגדרים התקני U2F. נכון לעכשיו אינך עושה שימוש ב־U2F לאימות דו־שלבי נכון לעכשיו.", 26 | "The following devices are configured for U2F second-factor authentication:" : "ההתקנים הבאים מוגדרים לטובת אימות דו־שלבי עם U2F:" 27 | },"pluralForm" :"nplurals=4; plural=(n == 1 && n % 1 == 0) ? 0 : (n == 2 && n % 1 == 0) ? 1: (n % 10 == 0 && n % 1 == 0 && n > 10) ? 2 : 3;" 28 | } -------------------------------------------------------------------------------- /l10n/zh_TW.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "您新增了一個 U2F 硬體權杖", 5 | "You removed an U2F hardware token" : "您移除了一個 U2F 硬體權杖", 6 | "U2F disabled by an admin" : "系統管理員停用了 U2F 功能", 7 | "U2F device" : "U2F 裝置", 8 | "Authenticate with an U2F device" : "使用 U2F 裝置進行驗證", 9 | "⚠️ Deprecated ⚠️ Two-Factor U2F" : "⚠️ 已棄用 ⚠️ 兩步驟 U2F", 10 | "U2F two-factor provider (deprecated)" : "U2F 兩步驟提供者(已棄用)", 11 | "Deprecated two-factor provider for U2F devices. The Two-Factor WebAuthn provider replaces this app." : "已棄用 U2F 裝置的兩步驟提供者。兩步驟 WebAuthn 提供者取代了此應用程式。", 12 | "Add U2F device" : "新增 U2F 裝置", 13 | "Please plug in your U2F device and press the device button to authorize." : "請插入您的 U2F 裝置並按下裝置上的按鈕以進行驗證。", 14 | "Name your device" : "請為您的裝置命名", 15 | "Add" : "新增", 16 | "Adding your device …" : "正在新增您的裝置……", 17 | "Server error while trying to add U2F device" : "嘗試新增 U2F 裝置時發生伺服器錯誤", 18 | "U2F device is already registered (error code {errorCode})" : "U2F 裝置已被註冊(錯誤代碼 {errorCode})", 19 | "U2F device registration timeout reached (error code {errorCode})" : "U2F 裝置註冊逾時(錯誤代碼 {errorCode})", 20 | "U2F device registration failed (error code {errorCode})" : "U2F 裝置註冊失敗(錯誤代碼 {errorCode})", 21 | "Server error while trying to complete U2F device registration" : "嘗試完成 U2F 裝置註冊時發生伺服器錯誤。", 22 | "An error occurred: {msg}" : "發生錯誤:{msg}", 23 | "Retry" : "重試", 24 | "Plug in your U2F device and press the device button to authorize." : "插入您的 U2F 裝置並按下裝置上的按鈕以進行驗證。", 25 | "An error occurred. Please try again." : "發生錯誤。請再試一次。", 26 | "Your browser does not support U2F." : "您的瀏覽器不支援 U2F。", 27 | "Please use an up-to-date browser that supports U2F devices, such as Chrome, Edge, Firefox, Opera or Safari." : "請使用支援 U2F 裝置的最新瀏覽器,例如 Chrome、Edge、Firefox、Opera 或是 Safari。", 28 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "您正透過不安全的連線造訪此網站。瀏覽器可能會因此拒絕 U2F 驗證。", 29 | "Unnamed device" : "未命名的裝置", 30 | "Remove" : "移除", 31 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "尚未設定 U2F 裝置。您現階段無法使用 U2F 進行兩階段驗證。", 32 | "The following devices are configured for U2F second-factor authentication:" : "下列裝置已被設定為 U2F 兩步驟驗證使用。" 33 | }, 34 | "nplurals=1; plural=0;"); 35 | -------------------------------------------------------------------------------- /l10n/he.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "הוספת אסימון חומרה U2F", 5 | "You removed an U2F hardware token" : "הסרת אסימון חומרה U2F", 6 | "U2F disabled by an admin" : "U2F הושבת על ידי ההנהלה", 7 | "U2F device" : "התקן U2F", 8 | "Authenticate with an U2F device" : "אימות עם התקן U2F", 9 | "Add U2F device" : "הוספת התקן U2F", 10 | "Please plug in your U2F device and press the device button to authorize." : "נא לחבר את התקן ה־U2F שלך וללחוץ על כפתור ההתקן כדי לבצע אימות.", 11 | "Name your device" : "מתן שם להתקן שלך", 12 | "Add" : "הוספה", 13 | "Adding your device …" : "הוספת ההתקן שלך…", 14 | "Server error while trying to add U2F device" : "אירעה שגיאת שרת בעת הניסיון להוספת התקן U2F", 15 | "U2F device is already registered (error code {errorCode})" : "התקן ה־U2F כבר רשום (קוד שגיאה {errorCode})", 16 | "U2F device registration timeout reached (error code {errorCode})" : "הזמן שהוקצב לרישום התקן ה־U2F תם (קוד שגיאה {errorCode})", 17 | "U2F device registration failed (error code {errorCode})" : "רישום התקן ה־U2F נכשל (קוד שגיאה {errorCode})", 18 | "Server error while trying to complete U2F device registration" : "התקבלה שגיאת שרת בעת הניסיון להשלים את הרשמת התקן ה־U2F", 19 | "An error occurred: {msg}" : "אירעה שגיאה: {msg}", 20 | "Retry" : "ניסיון חוזר", 21 | "Plug in your U2F device and press the device button to authorize." : "נא לחבר את התקן ה־U2F שלך וללחוץ על כפתור ההתקן כדי לבצע אימות.", 22 | "An error occurred. Please try again." : "אירעה שגיאה. נא לנסות שוב.", 23 | "Your browser does not support U2F." : "הדפדפן שלך אינו תומך ב־U2F.", 24 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "בחרת לגשת לאתר דרך חיבור בלתי מאובטח. דפדפנים עשויים לסרב לאימות U2F.", 25 | "Unnamed device" : "התקן ללא שם", 26 | "Remove" : "הסרה", 27 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "לא מוגדרים התקני U2F. נכון לעכשיו אינך עושה שימוש ב־U2F לאימות דו־שלבי נכון לעכשיו.", 28 | "The following devices are configured for U2F second-factor authentication:" : "ההתקנים הבאים מוגדרים לטובת אימות דו־שלבי עם U2F:" 29 | }, 30 | "nplurals=4; plural=(n == 1 && n % 1 == 0) ? 0 : (n == 2 && n % 1 == 0) ? 1: (n % 10 == 0 && n % 1 == 0 && n > 10) ? 2 : 3;"); 31 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # ⚠️ Deprecated ⚠️ U2F second factor provider for Nextcloud 2 | 3 | ⚠️ The U2F standard has been deprecated and therefore this app will be discontinued. The [Two-Factor WebAuthn](https://apps.nextcloud.com/apps/twofactor_webauthn) app can be used as a replacement. [Here](https://github.com/nextcloud/twofactor_webauthn#migration-from-two-factor-u2f) you can find migration instructions. 4 | 5 | ![Downloads](https://img.shields.io/github/downloads/nextcloud/twofactor_u2f/total.svg) 6 | ![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/nextcloud/twofactor_u2f/badges/quality-score.png?b=master) 7 | ![JavaScript Coverage Status](https://coveralls.io/repos/github/nextcloud/twofactor_u2f/badge.svg?branch=master) 8 | 9 | ![](screenshots/challenge.png) 10 | 11 | # Requirements 12 | In order to use this app for authentication, you have to use a browser that supports the U2F standard: 13 | 14 | * Brave Browser 15 | * Chromium 16 | * Google Chrome 17 | * Microsoft Edge 18 | * Mozilla Firefox 19 | * Opera 20 | 21 | ## Login with external apps 22 | Once you enable U2F with Two Factor U2F, your applications (for example your GNOME app) will need to login using device passwords. Which can be managed in your security settings. 23 | 24 | Official aplications such as the Android or IOS clients and desktop clients can use much safer tokens to login. Apps will automatically redirect you to a browser window to login as usual. 25 | 26 | ## Development Setup 27 | 28 | This app uses [composer](https://getcomposer.org/) and [npm](https://www.npmjs.com/) to manage dependencies. Use 29 | 30 | ```bash 31 | composer install 32 | npm install 33 | npm run build 34 | ``` 35 | 36 | or if you're using [Krankerl](https://github.com/ChristophWurst/krankerl) 37 | 38 | ```bash 39 | krankerl up 40 | ``` 41 | 42 | to set up a development version of this app. 43 | 44 | ## Supported devices 45 | 46 | As this App implements the U2F standard, 47 | Every device supporting U2F should work fine. The following devices are known to work: 48 | 49 | * [Google Titan Security Key](https://support.google.com/titansecuritykey/answer/9115487?hl=en) 50 | * [GoTrust IdenKey](https://www.gotrustid.com/idem-key) 51 | * [Nitrokey FIDO U2F](https://shop.nitrokey.com/shop/product/nitrokey-fido-u2f-20) 52 | * [SoloKey](https://github.com/solokeys/solo) 53 | * HW version 2.1V 54 | * [Yubikey 4 & 5 Series](https://www.yubico.com/products/yubikey-5-overview/) 55 | -------------------------------------------------------------------------------- /lib/Controller/SettingsController.php: -------------------------------------------------------------------------------- 1 | 12 | * @copyright Christoph Wurst 2018 13 | */ 14 | 15 | namespace OCA\TwoFactorU2F\Controller; 16 | 17 | require_once(__DIR__ . '/../../vendor/yubico/u2flib-server/src/u2flib_server/U2F.php'); 18 | 19 | use OCA\TwoFactorU2F\Service\U2FManager; 20 | use OCP\AppFramework\Http\JSONResponse; 21 | use OCP\Authentication\TwoFactorAuth\ALoginSetupController; 22 | use OCP\IRequest; 23 | use OCP\IUserSession; 24 | 25 | class SettingsController extends ALoginSetupController { 26 | 27 | /** @var U2FManager */ 28 | private $manager; 29 | 30 | /** @var IUserSession */ 31 | private $userSession; 32 | 33 | public function __construct(string $appName, IRequest $request, U2FManager $manager, IUserSession $userSession) { 34 | parent::__construct($appName, $request); 35 | $this->manager = $manager; 36 | $this->userSession = $userSession; 37 | } 38 | 39 | /** 40 | * @NoAdminRequired 41 | */ 42 | public function state(): JSONResponse { 43 | return new JSONResponse([ 44 | 'devices' => $this->manager->getDevices($this->userSession->getUser()) 45 | ]); 46 | } 47 | 48 | /** 49 | * @NoAdminRequired 50 | * @PasswordConfirmationRequired 51 | * @UseSession 52 | */ 53 | public function startRegister(): JSONResponse { 54 | return new JSONResponse($this->manager->startRegistration($this->userSession->getUser())); 55 | } 56 | 57 | /** 58 | * @NoAdminRequired 59 | * @PasswordConfirmationRequired 60 | * 61 | * @param string $registrationData 62 | * @param string $clientData 63 | * @param string|null $name device name, given by user 64 | */ 65 | public function finishRegister(string $registrationData, string $clientData, string $name = null): JSONResponse { 66 | return new JSONResponse($this->manager->finishRegistration($this->userSession->getUser(), $registrationData, $clientData, $name)); 67 | } 68 | 69 | /** 70 | * @NoAdminRequired 71 | * @PasswordConfirmationRequired 72 | * 73 | * @param int $id 74 | */ 75 | public function remove(int $id): JSONResponse { 76 | return new JSONResponse($this->manager->removeDevice($this->userSession->getUser(), $id)); 77 | } 78 | } 79 | -------------------------------------------------------------------------------- /src/tests/components/PersonalSettings.spec.js: -------------------------------------------------------------------------------- 1 | /* 2 | * @copyright 2018 Christoph Wurst 3 | * 4 | * @author 2018 Christoph Wurst 5 | * 6 | * @license GNU AGPL version 3 or any later version 7 | * 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU Affero General Public License as 10 | * published by the Free Software Foundation, either version 3 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU Affero General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU Affero General Public License 19 | * along with this program. If not, see . 20 | */ 21 | 22 | import {shallowMount, createLocalVue} from '@vue/test-utils' 23 | import Vuex from 'vuex' 24 | 25 | import Nextcloud from '../../mixins/Nextcloud' 26 | 27 | const localVue = createLocalVue() 28 | 29 | localVue.use(Vuex) 30 | localVue.mixin(Nextcloud) 31 | 32 | import PersonalSettings from '../../components/PersonalSettings' 33 | 34 | describe('Device component', () => { 35 | var actions 36 | var store 37 | 38 | beforeEach(() => { 39 | actions = {} 40 | store = new Vuex.Store({ 41 | state: { 42 | devices: [] 43 | }, 44 | actions 45 | }) 46 | }) 47 | 48 | it('shows text if no devices are configured', () => { 49 | const settings = shallowMount(PersonalSettings, { 50 | store, 51 | localVue 52 | }) 53 | 54 | expect(settings.text()).to.contain('No U2F devices configured') 55 | }) 56 | 57 | it('shows no info text if devices are configured', () => { 58 | store.state.devices.push({ 59 | id: 1, 60 | name: 'a' 61 | }) 62 | const settings = shallowMount(PersonalSettings, { 63 | store, 64 | localVue 65 | }) 66 | 67 | expect(settings.text()).to.not.contain('No U2F devices configured') 68 | }) 69 | 70 | it('shows a HTTP warning', () => { 71 | const settings = shallowMount(PersonalSettings, { 72 | store, 73 | localVue, 74 | propsData: { 75 | httpWarning: true 76 | } 77 | }) 78 | 79 | expect(settings.text()).to.contain('You are accessing this site via an') 80 | }) 81 | }) 82 | -------------------------------------------------------------------------------- /l10n/ja.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "U2F ハードウェアトークンを追加しました", 3 | "You removed an U2F hardware token" : "U2F ハードウェアトークンを削除しました", 4 | "U2F disabled by an admin" : "U2Fは管理者によって無効にされています", 5 | "U2F device" : "U2Fデバイス", 6 | "Authenticate with an U2F device" : "U2Fデバイスで認証する", 7 | "⚠️ Deprecated ⚠️ Two-Factor U2F" : "⚠️ 廃止 ⚠️ Two-Factor U2F", 8 | "U2F two-factor provider (deprecated)" : "U2F 二要素プロバイダー (廃止)", 9 | "Deprecated two-factor provider for U2F devices. The Two-Factor WebAuthn provider replaces this app." : "U2Fデバイスのための2要素プロバイダーは廃止されました。このアプリは、二要素WebAuthnプロバイダーに置き換わっています。", 10 | "Add U2F device" : "U2Fデバイスを追加", 11 | "Please plug in your U2F device and press the device button to authorize." : "U2Fデバイスを接続し、デバイスボタンを押して承認してください。", 12 | "Name your device" : "デバイスに名前をつける", 13 | "Add" : "追加", 14 | "Adding your device …" : "あなたのデバイスを追加しています…", 15 | "Server error while trying to add U2F device" : "U2Fデバイスの追加中にサーバーエラーが発生しました", 16 | "U2F device is already registered (error code {errorCode})" : "U2Fデバイスはすでに登録されています (エラーコード {errorCode})", 17 | "U2F device registration timeout reached (error code {errorCode})" : "U2Fデバイスの登録がタイムアウトしました (エラーコード {errorCode})", 18 | "U2F device registration failed (error code {errorCode})" : "U2Fデバイスの登録に失敗しました (エラーコード {errorCode})", 19 | "Server error while trying to complete U2F device registration" : "U2Fデバイスの登録を完了中にサーバーエラーが発生しました", 20 | "An error occurred: {msg}" : "エラーが発生しました: {msg}", 21 | "Retry" : "再試行", 22 | "Plug in your U2F device and press the device button to authorize." : "U2Fデバイスを接続し、デバイスボタンを押して認証します。", 23 | "An error occurred. Please try again." : "エラーが発生しました。もう一度実行してください。", 24 | "Your browser does not support U2F." : "お使いのブラウザーはU2Fに対応していません。", 25 | "Please use an up-to-date browser that supports U2F devices, such as Chrome, Edge, Firefox, Opera or Safari." : "Chrome、Edge、Firefox、OperaまたはSafariなどのU2Fデバイスをサポートした最新のブラウザーをご利用ください。", 26 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "あなたは安全ではない接続を経由してアクセスしています。ブラウザーはU2F認証を拒否する可能性があります。", 27 | "Unnamed device" : "名称設定されていないデバイス", 28 | "Remove" : "削除", 29 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "U2Fデバイスが設定されていません。二段階認証としてU2Fが使われていません。", 30 | "The following devices are configured for U2F second-factor authentication:" : "次のデバイスはU2F 二段階認証設定されています。" 31 | },"pluralForm" :"nplurals=1; plural=0;" 32 | } -------------------------------------------------------------------------------- /l10n/sr.json: -------------------------------------------------------------------------------- 1 | { "translations": { 2 | "You added an U2F hardware token" : "Додали сте U2F хардверски токен", 3 | "You removed an U2F hardware token" : "Уклонили сте U2F хардверски токен", 4 | "U2F disabled by an admin" : "Администратор искључио U2F", 5 | "U2F device" : "U2F уређај", 6 | "Authenticate with an U2F device" : "Пријави се са U2F уређајем", 7 | "Add U2F device" : "Додај U2F уређај", 8 | "Please plug in your U2F device and press the device button to authorize." : "Молимо утакните Ваш U2F уређај и притисните дугме на уређају да се пријавите.", 9 | "Name your device" : "Име Вашег уређаја", 10 | "Add" : "Додај", 11 | "Adding your device …" : "Додајем Ваш уређај…", 12 | "Server error while trying to add U2F device" : "Серверска грешка приликом додавања U2F уређаја", 13 | "U2F device is already registered (error code {errorCode})" : "U2F уређај је већ регистрован (код грешке {errorCode})", 14 | "U2F device registration timeout reached (error code {errorCode})" : "Рок за регистрацију У2Ф уређаја је истекао (код грешке {errorCode})", 15 | "U2F device registration failed (error code {errorCode})" : "РегистрацијаU2F уређаја није успела (код грешке {errorCode})", 16 | "Server error while trying to complete U2F device registration" : "Серверска грешка приликом довршавања регистрације U2F уређаја", 17 | "An error occurred: {msg}" : "Догодила се грешка: {msg}", 18 | "Retry" : "Покушај поново", 19 | "Plug in your U2F device and press the device button to authorize." : "Утакните Ваш U2F уређај и притисните дугме на уређају да се пријавите.", 20 | "An error occurred. Please try again." : "Десила се грешка. Покушајте поново.", 21 | "Your browser does not support U2F." : "Ваш веб читач не подржава U2F.", 22 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Приступате овом сајту преко небезбедне конекције. Веб читач може због тога да одбије U2F пријављивање.", 23 | "Unnamed device" : "Неименовани уређај", 24 | "Remove" : "Уклони", 25 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "Нема конфигурисаних U2F уређаја. Тренутно не користите универзални други фактор.", 26 | "The following devices are configured for U2F second-factor authentication:" : "Следећи уређају су конфигурисани за пријављивање са универзалним 2. фактором:" 27 | },"pluralForm" :"nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);" 28 | } -------------------------------------------------------------------------------- /l10n/ja.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "U2F ハードウェアトークンを追加しました", 5 | "You removed an U2F hardware token" : "U2F ハードウェアトークンを削除しました", 6 | "U2F disabled by an admin" : "U2Fは管理者によって無効にされています", 7 | "U2F device" : "U2Fデバイス", 8 | "Authenticate with an U2F device" : "U2Fデバイスで認証する", 9 | "⚠️ Deprecated ⚠️ Two-Factor U2F" : "⚠️ 廃止 ⚠️ Two-Factor U2F", 10 | "U2F two-factor provider (deprecated)" : "U2F 二要素プロバイダー (廃止)", 11 | "Deprecated two-factor provider for U2F devices. The Two-Factor WebAuthn provider replaces this app." : "U2Fデバイスのための2要素プロバイダーは廃止されました。このアプリは、二要素WebAuthnプロバイダーに置き換わっています。", 12 | "Add U2F device" : "U2Fデバイスを追加", 13 | "Please plug in your U2F device and press the device button to authorize." : "U2Fデバイスを接続し、デバイスボタンを押して承認してください。", 14 | "Name your device" : "デバイスに名前をつける", 15 | "Add" : "追加", 16 | "Adding your device …" : "あなたのデバイスを追加しています…", 17 | "Server error while trying to add U2F device" : "U2Fデバイスの追加中にサーバーエラーが発生しました", 18 | "U2F device is already registered (error code {errorCode})" : "U2Fデバイスはすでに登録されています (エラーコード {errorCode})", 19 | "U2F device registration timeout reached (error code {errorCode})" : "U2Fデバイスの登録がタイムアウトしました (エラーコード {errorCode})", 20 | "U2F device registration failed (error code {errorCode})" : "U2Fデバイスの登録に失敗しました (エラーコード {errorCode})", 21 | "Server error while trying to complete U2F device registration" : "U2Fデバイスの登録を完了中にサーバーエラーが発生しました", 22 | "An error occurred: {msg}" : "エラーが発生しました: {msg}", 23 | "Retry" : "再試行", 24 | "Plug in your U2F device and press the device button to authorize." : "U2Fデバイスを接続し、デバイスボタンを押して認証します。", 25 | "An error occurred. Please try again." : "エラーが発生しました。もう一度実行してください。", 26 | "Your browser does not support U2F." : "お使いのブラウザーはU2Fに対応していません。", 27 | "Please use an up-to-date browser that supports U2F devices, such as Chrome, Edge, Firefox, Opera or Safari." : "Chrome、Edge、Firefox、OperaまたはSafariなどのU2Fデバイスをサポートした最新のブラウザーをご利用ください。", 28 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "あなたは安全ではない接続を経由してアクセスしています。ブラウザーはU2F認証を拒否する可能性があります。", 29 | "Unnamed device" : "名称設定されていないデバイス", 30 | "Remove" : "削除", 31 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "U2Fデバイスが設定されていません。二段階認証としてU2Fが使われていません。", 32 | "The following devices are configured for U2F second-factor authentication:" : "次のデバイスはU2F 二段階認証設定されています。" 33 | }, 34 | "nplurals=1; plural=0;"); 35 | -------------------------------------------------------------------------------- /l10n/sr.js: -------------------------------------------------------------------------------- 1 | OC.L10N.register( 2 | "twofactor_u2f", 3 | { 4 | "You added an U2F hardware token" : "Додали сте U2F хардверски токен", 5 | "You removed an U2F hardware token" : "Уклонили сте U2F хардверски токен", 6 | "U2F disabled by an admin" : "Администратор искључио U2F", 7 | "U2F device" : "U2F уређај", 8 | "Authenticate with an U2F device" : "Пријави се са U2F уређајем", 9 | "Add U2F device" : "Додај U2F уређај", 10 | "Please plug in your U2F device and press the device button to authorize." : "Молимо утакните Ваш U2F уређај и притисните дугме на уређају да се пријавите.", 11 | "Name your device" : "Име Вашег уређаја", 12 | "Add" : "Додај", 13 | "Adding your device …" : "Додајем Ваш уређај…", 14 | "Server error while trying to add U2F device" : "Серверска грешка приликом додавања U2F уређаја", 15 | "U2F device is already registered (error code {errorCode})" : "U2F уређај је већ регистрован (код грешке {errorCode})", 16 | "U2F device registration timeout reached (error code {errorCode})" : "Рок за регистрацију У2Ф уређаја је истекао (код грешке {errorCode})", 17 | "U2F device registration failed (error code {errorCode})" : "РегистрацијаU2F уређаја није успела (код грешке {errorCode})", 18 | "Server error while trying to complete U2F device registration" : "Серверска грешка приликом довршавања регистрације U2F уређаја", 19 | "An error occurred: {msg}" : "Догодила се грешка: {msg}", 20 | "Retry" : "Покушај поново", 21 | "Plug in your U2F device and press the device button to authorize." : "Утакните Ваш U2F уређај и притисните дугме на уређају да се пријавите.", 22 | "An error occurred. Please try again." : "Десила се грешка. Покушајте поново.", 23 | "Your browser does not support U2F." : "Ваш веб читач не подржава U2F.", 24 | "You are accessing this site via an insecure connection. Browsers might therefore refuse the U2F authentication." : "Приступате овом сајту преко небезбедне конекције. Веб читач може због тога да одбије U2F пријављивање.", 25 | "Unnamed device" : "Неименовани уређај", 26 | "Remove" : "Уклони", 27 | "No U2F devices configured. You are not using U2F as second factor at the moment." : "Нема конфигурисаних U2F уређаја. Тренутно не користите универзални други фактор.", 28 | "The following devices are configured for U2F second-factor authentication:" : "Следећи уређају су конфигурисани за пријављивање са универзалним 2. фактором:" 29 | }, 30 | "nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);"); 31 | --------------------------------------------------------------------------------