From 128549f10beb406333fa23c1693750c06ff7bc4a Mon Sep 17 00:00:00 2001 From: Timothy Andrew Date: Mon, 6 Jun 2016 10:14:51 +0530 Subject: Implement U2F registration. - Move the `TwoFactorAuthsController`'s `new` action to `show`, since the page is not used to create a single "two factor auth" anymore. We can have a single 2FA authenticator app, along with any number of U2F devices, in any combination, so the page will be accessed after the first "two factor auth" is created. - Add the `u2f` javascript library, which provides an API to the browser's U2F implementation. - Add tests for the JS components --- spec/javascripts/fixtures/u2f/register.html.haml | 1 + 1 file changed, 1 insertion(+) create mode 100644 spec/javascripts/fixtures/u2f/register.html.haml (limited to 'spec/javascripts/fixtures') diff --git a/spec/javascripts/fixtures/u2f/register.html.haml b/spec/javascripts/fixtures/u2f/register.html.haml new file mode 100644 index 00000000000..393c0613fd3 --- /dev/null +++ b/spec/javascripts/fixtures/u2f/register.html.haml @@ -0,0 +1 @@ += render partial: "u2f/register", locals: { create_u2f_profile_two_factor_auth_path: '/profile/two_factor_auth/create_u2f' } -- cgit v1.2.1 From 86b07caa599a7f064e9077770b1a87c670d7607c Mon Sep 17 00:00:00 2001 From: Timothy Andrew Date: Mon, 6 Jun 2016 10:20:39 +0530 Subject: Implement authentication (login) using a U2F device. - Move the `authenticate_with_two_factor` method from `ApplicationController` to the `AuthenticatesWithTwoFactor` module, where it should be. --- spec/javascripts/fixtures/u2f/authenticate.html.haml | 1 + 1 file changed, 1 insertion(+) create mode 100644 spec/javascripts/fixtures/u2f/authenticate.html.haml (limited to 'spec/javascripts/fixtures') diff --git a/spec/javascripts/fixtures/u2f/authenticate.html.haml b/spec/javascripts/fixtures/u2f/authenticate.html.haml new file mode 100644 index 00000000000..859e79a6c9e --- /dev/null +++ b/spec/javascripts/fixtures/u2f/authenticate.html.haml @@ -0,0 +1 @@ += render partial: "u2f/authenticate", locals: { new_user_session_path: "/users/sign_in" } -- cgit v1.2.1