MyNixOS website logo
Description

Simple Authentification for 'shiny' Applications.

Provides a simple authentification mechanism for single 'shiny' applications. Authentification and password change functionality are performed calling user provided functions that typically access some database backend. Source code of main applications is protected until authentication is successful.

version cranlogs

Simple authentification mechanism for single 'shiny' applications.

Provides a simple authentification and password change functionality are performed calling user provided functions that typically access some database backend.
Source code of main applications is protected until authentication is successful.

ATENTION: This project uses borrowed and modified (stripped and incomplete) code from ShinyManager which provides a more secure, extended, generic and completed authentication solution, please use it instead for stable applications.

Installation

Install from CRAN with :

install.packages("shinydbauth")

Or install development version from GitHub :

remotes::install_github("diegoefe/shinydbauth")

Usage

To run the sample application:

  1. Open a terminal (bash) and cd into demo.
  2. Choose database backend to use:
    1. For SQLite:
      1. cd to "db" and run mk_db.sh and go back:
        $ cd db
        $ ./mk_db.sh
        $ cd ..
        
      2. look for users and passwords in sqlite.sql
    2. For PostgreSQL:
      1. Create a database and two functions:
        • fetch_user()
        • update_user() Use the signatures for db_pg.R's queries
      2. Copy sample-auth.R to auth.R and set it up with correct values:
        $ cp sample-auth.R auth.R
        $ vim auth.R
        
  3. Open app.R and follow SETUP instructions
  4. Run the demo:
    ./launch_in_browser.sh
    

Available languages

  • English
  • Español

Password validity period

Using options("shinydbauth.pwd_validity"), you can set password validity period. It defaults to Inf. You can specify for example options("shinydbauth.pwd_validity" = 90) if you want to force user changing password each 90 days.

Failure limit

Using options("shinydbauth.pwd_failure_limit"), you can set password failure limit. It defaults to Inf. You can specify for example options("shinydbauth.pwd_failure_limit" = 5) if you want to lock user account after 5 wrong password.

Relevant R documentation

require(shinydbauth)

# shiny integration
?secure_app
?create_server
?auth_ui # ui definition


# change labels / language
 ?set_labels

Customization

You can customize the module (css, image, language, ...).

?secure_app
?auth_ui
?set_labels
Metadata

Version

1.0.0.1

License

Unknown

Platforms (75)

    Darwin
    FreeBSD
    Genode
    GHCJS
    Linux
    MMIXware
    NetBSD
    none
    OpenBSD
    Redox
    Solaris
    WASI
    Windows
Show all
  • aarch64-darwin
  • aarch64-genode
  • aarch64-linux
  • aarch64-netbsd
  • aarch64-none
  • aarch64_be-none
  • arm-none
  • armv5tel-linux
  • armv6l-linux
  • armv6l-netbsd
  • armv6l-none
  • armv7a-darwin
  • armv7a-linux
  • armv7a-netbsd
  • armv7l-linux
  • armv7l-netbsd
  • avr-none
  • i686-cygwin
  • i686-darwin
  • i686-freebsd
  • i686-genode
  • i686-linux
  • i686-netbsd
  • i686-none
  • i686-openbsd
  • i686-windows
  • javascript-ghcjs
  • loongarch64-linux
  • m68k-linux
  • m68k-netbsd
  • m68k-none
  • microblaze-linux
  • microblaze-none
  • microblazeel-linux
  • microblazeel-none
  • mips-linux
  • mips-none
  • mips64-linux
  • mips64-none
  • mips64el-linux
  • mipsel-linux
  • mipsel-netbsd
  • mmix-mmixware
  • msp430-none
  • or1k-none
  • powerpc-netbsd
  • powerpc-none
  • powerpc64-linux
  • powerpc64le-linux
  • powerpcle-none
  • riscv32-linux
  • riscv32-netbsd
  • riscv32-none
  • riscv64-linux
  • riscv64-netbsd
  • riscv64-none
  • rx-none
  • s390-linux
  • s390-none
  • s390x-linux
  • s390x-none
  • vc4-none
  • wasm32-wasi
  • wasm64-wasi
  • x86_64-cygwin
  • x86_64-darwin
  • x86_64-freebsd
  • x86_64-genode
  • x86_64-linux
  • x86_64-netbsd
  • x86_64-none
  • x86_64-openbsd
  • x86_64-redox
  • x86_64-solaris
  • x86_64-windows