2017 © Pedro Peláez
 

library twofactor-dir

The most powerful and the simplest library to add two factor authentication by google authenticator, in every directory that you want in just one step

image

thecsea/twofactor-dir

The most powerful and the simplest library to add two factor authentication by google authenticator, in every directory that you want in just one step

  • Sunday, September 27, 2015
  • by carduz
  • Repository
  • 2 Watchers
  • 3 Stars
  • 108 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 0 Forks
  • 2 Open issues
  • 15 Versions
  • 5 % Grown

The README.md

twofactor-dir

Build status: Build Status Scrutinizer Code Quality Code Coverage Build Status Latest Stable Version Total Downloads Latest Unstable Version License, (*1)

The most powerful and the simplest library to add two factor authentication by google authenticator, for every directory that you want in just one step, (*2)

  • Add two factor in different directory with different secret
  • Lock all pages and files until the correct code is inserted
  • Set automatically mod rewrite redirect to insert code page until the correct code is inserted
  • Update you htaccess automatically
  • Easily installation in each dir in just one step
  • Only one software installation location to allow you to manage it easily
  • You can always set up two factor in new directories without change other installations, keeping the same software installation location

Constraints

  • httacces and mod rewrite needed
  • php write permission
  • the date time on the server must be synchronized (only 1 minute of margin)

Download

Get/update composer

This library require composer (download composer here https://getcomposer.org/), (*3)

Update composer, (*4)

php composer.phar self-update, (*5)

Download

Download via composer require (we suggest to create a dedicated directory for this), (*6)

php composer.phar require thecsea/twofactor-dir, (*7)

or insert library as dependency in your composer project, (*8)

thecsea/twofactor-dir": "1.0.*, (*9)

in the last case you have to install or update you project, (*10)

php composer.phar install, (*11)

or, (*12)

php composer.phar update, (*13)

N.B. If you don't have access to server terminal you can perform installation on your pc and upload all via ftp, (*14)

Update twofactor-dir

You can update twofactor-dir (according to version limit set in composer.json), (*15)

php composer.phar update, (*16)

Use

Installation

You can set different different directory keeping only one software location, but you mustn't change it, (*17)

Set up twofactor-dir

  1. Give php write permissions to the directory where you want to set up twofactor-dir
  2. Enable htacces and mod rewrite
  3. open via a browser the following page and insert the directory position (preferably absolute link)

vendor/thecsea/twofactor-dir/files/install.php, (*18)

after this you will see new files and htaccess updated, (*19)

We suggest to hide via htaccess the twofactor-dir installation directory, (*20)

First Use

You can get secret or QR code on YOUR_DIR/get_qr.php. We suggest to use a https connection, (*21)

After linked a device we suggest to hide get_qr.php for not logged users in the following way:, (*22)

CAUTION Comment RewriteRule ^get_qr.php$ get_qr.php [L,QSA] on htaccess generated after get qr for the first time, so you are able to get qr (to add more devices) only after login, (*23)

Use

When you try to access to each page of the directory you will be redirected to insert code page, when you insert code you will be logged until the session is closed., (*24)

You can add new devices after login (insert code page) calling YOUR_DIR/get_qr.php, (*25)

Customize

Obviously you can customize interface modifying: * redirect.php * get_qr.php, (*26)

Disable

You can disable twofactor-dir temporarily commenting the redirect instructions on .htaccess, (*27)

Uninstall

To unistall twofactor-dir for a directory you have to remove the following files from your dir: * get_qr.php * redirect.php * secret.php, (*28)

and remove the twofactor-dir lines (marked) from .htacces, (*29)

CAUTION: You must keep the twofactor-dir installation (installation downloaded by composer) if you have set up it in other directories, (*30)

Credits

By thecsea.it

The Versions

27/09 2015

dev-master

9999999-dev http://www.thecsea.it/progetti/

The most powerful and the simplest library to add two factor authentication by google authenticator, in every directory that you want in just one step

  Sources   Download

GPL-2.0

The Requires

 

The Development Requires

authentication google directory two factor

27/09 2015

v1.0.14

1.0.14.0 http://www.thecsea.it/progetti/

The most powerful and the simplest library to add two factor authentication by google authenticator, in every directory that you want in just one step

  Sources   Download

GPL-2.0

The Requires

 

The Development Requires

authentication google directory two factor

24/09 2015

v1.0.13

1.0.13.0 http://www.thecsea.it/progetti/

The most powerful and the simplest library to add two factor authentication by google authenticator, in every directory that you want in just one step

  Sources   Download

GPL-2.0

The Requires

 

The Development Requires

authentication google directory two factor

30/07 2015

v1.0.12

1.0.12.0 http://www.thecsea.it/progetti/

The most powerful and the simplest library to add two factor authentication by google authenticator, in every directory that you want in just one step

  Sources   Download

GPL-2.0

The Requires

 

The Development Requires

authentication google directory two factor

29/07 2015

1.0.11

1.0.11.0 http://www.thecsea.it/progetti/

The most powerful and the simplest library to add two factor authentication by google authenticator, in every directory that you want in just one step

  Sources   Download

GPL-2.0

The Requires

 

The Development Requires

authentication google directory two factor

29/07 2015

1.0.10

1.0.10.0 http://www.thecsea.it/progetti/

The most powerful and the simplest library to add two factor authentication by google authenticator, in every directory that you want in just one step

  Sources   Download

GPL-2.0

The Requires

 

The Development Requires

authentication google directory two factor

29/07 2015

v1.0.9

1.0.9.0 http://www.thecsea.it/progetti/

The most powerful and the simplest library to add two factor authentication by google authenticator, in every directory that you want in just one step

  Sources   Download

GPL-2.0

The Requires

 

The Development Requires

authentication google directory two factor

29/07 2015

v1.0.8

1.0.8.0 http://www.thecsea.it/progetti/

The most powerful and the simplest library to add two factor authentication by google authenticator, in every directory that you want in just one step

  Sources   Download

GPL-2.0

The Requires

 

The Development Requires

authentication google directory two factor

29/07 2015

v1.0.7

1.0.7.0 http://www.thecsea.it/progetti/

The most powerful and the simplest library to add two factor authentication by google authenticator, in every directory that you want in just one step

  Sources   Download

GPL-2.0

The Requires

 

The Development Requires

authentication google directory two factor

28/07 2015

v1.0.6

1.0.6.0 http://www.thecsea.it/progetti/

The most powerful and the simplest library to add two factor authentication by google authenticator, in every directory that you want in just one step

  Sources   Download

GPL-2.0

The Requires

 

The Development Requires

authentication google directory two factor

28/07 2015

v1.0.5

1.0.5.0 http://www.thecsea.it/progetti/

The most powerful and the simplest library to add two factor authentication by google authenticator, in every directory that you want in just one step

  Sources   Download

GPL-2.0

The Requires

 

The Development Requires

authentication google directory two factor

28/07 2015

v1.0.4

1.0.4.0 http://www.thecsea.it/progetti/

The most powerful and the simplest library to add two factor authentication by google authenticator, in every directory that you want in just one step

  Sources   Download

GPL-2.0

The Requires

 

The Development Requires

authentication google directory two factor

28/07 2015

v1.0.2

1.0.2.0 http://www.thecsea.it/progetti/

The most powerful and the simplest library to add two factor authentication by google authenticator, in every directory that you want in just one step

  Sources   Download

GPL-2.0

The Requires

 

The Development Requires

authentication google directory two factor

28/07 2015

v1.0.1

1.0.1.0 http://www.thecsea.it/progetti/

The most powerful and the simplest library to add two factor authentication by google authenticator, in every directory that you want in just one step

  Sources   Download

GPL-2.0

The Requires

 

The Development Requires

authentication google directory two factor

28/07 2015

v1.0.0

1.0.0.0 http://www.thecsea.it/progetti/

The most powerful and the simplest library to add two factor authentication by google authenticator, in every directory that you want in just one step

  Sources   Download

GPL-2.0

The Requires

 

The Development Requires

authentication google dir two factor