tapLock

Seamless SSO for R applications

https://github.com/ixpantia/taplock

Science Score: 26.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
  • Academic publication links
  • Committers with academic emails
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (11.7%) to scientific vocabulary

Keywords

prodverse
Last synced: 10 months ago · JSON representation

Repository

Seamless SSO for R applications

Basic Info
Statistics
  • Stars: 37
  • Watchers: 3
  • Forks: 6
  • Open Issues: 4
  • Releases: 1
Topics
prodverse
Created over 2 years ago · Last pushed about 1 year ago
Metadata Files
Readme Changelog License

README.md

tapLock

R-CMD-check <!-- badges: end -->

The goal of tapLock is to secure your R applications with OpenID Connect and OAuth 2.0.

tapLock is an R library that provides a simple interface to integrate OpenID Connect / OAuth 2.0 authentication into you Shiny applications and Plumber APIs. tapLock uses a unique approach to effectively secure your applications without the need to write almost any code.

Installation

You can install tapLock from CRAN with:

r install.packages("tapLock")

You can install the development version of tapLock from GitHub with:

``` r

install.packages("pak")

pak::pak("ixpantia/tapLock") ```

Example

1. Create an authentication configuration

``` r library(taplock)

authconfig <- newopenidconfig( provider = "google", clientid = Sys.getenv("CLIENTID"), clientsecret = Sys.getenv("CLIENTSECRET"), appurl = Sys.getenv("APP_URL") ) ```

2. Secure your Shiny application

To secure your Shiny Application you will need to add the middleware layers using tower and configure the client credentials.

Here is an example of a Shiny application that uses tapLock to secure itself:

``` r library(shiny) library(tapLock)

authconfig <- newopenidconfig( provider = "google", clientid = Sys.getenv("CLIENTID"), clientsecret = Sys.getenv("CLIENTSECRET"), appurl = Sys.getenv("APP_URL") )

ui <- fluidPage( tags$h1("r.sso example"), uiOutput("profile"), textOutput("user") )

server <- function(input, output, session) {

output$profile <- renderUI({ tags$img(src = gettokenfield(token(), "picture")) })

output$user <- renderText({ givenname <- gettokenfield(token(), "givenname") familyname <- gettokenfield(token(), "familyname") expiresat <- expiresat(token()) glue::glue( "Hello {givenname} {familyname}!", "Your authenticated session will expire at {expires_at}.", .sep = " " ) }) |> bindEvent(TRUE)

} shinyApp(ui, server) |> tower::createtower() |> tapLock::addauthlayers(authconfig) |> tower::build_tower() ```

Authentication providers

tapLock supports the following authentication providers:

If you need support for other providers, please contact us at hola@ixpantia.com. Or, if you are a developer, you can contribute to the project by adding support for additional providers.

Security Model

tapLock is unique in its approach to securing Shiny applications. tapLock utilizes middlewares that intercept all incoming requests (both HTTP and WebSocket requests) and validates the authentication token. This approach allows tapLock to be lean and efficient since no expensive WebSocket connections are started until the user is authenticated. It also prevents sensitive data in the UI portion of the application from being exposed to unauthenticated users.

Auth Flow

Owner

  • Name: ixpantia
  • Login: ixpantia
  • Kind: organization
  • Location: Costa Rica

GitHub Events

Total
  • Create event: 2
  • Release event: 1
  • Issues event: 11
  • Watch event: 17
  • Issue comment event: 1
  • Push event: 21
  • Pull request event: 8
  • Fork event: 1
Last Year
  • Create event: 2
  • Release event: 1
  • Issues event: 11
  • Watch event: 17
  • Issue comment event: 1
  • Push event: 21
  • Pull request event: 8
  • Fork event: 1

Committers

Last synced: about 1 year ago

All Time
  • Total Commits: 56
  • Total Committers: 3
  • Avg Commits per committer: 18.667
  • Development Distribution Score (DDS): 0.036
Past Year
  • Commits: 33
  • Committers: 2
  • Avg Commits per committer: 16.5
  • Development Distribution Score (DDS): 0.03
Top Committers
Name Email Commits
andres a****o@g****m 54
andrea a****a@i****m 1
Mauro Lepore m****e@g****m 1
Committer Domains (Top 20 + Academic)

Issues and Pull Requests

Last synced: 11 months ago

All Time
  • Total issues: 16
  • Total pull requests: 17
  • Average time to close issues: about 2 months
  • Average time to close pull requests: 5 days
  • Total issue authors: 5
  • Total pull request authors: 3
  • Average comments per issue: 0.13
  • Average comments per pull request: 0.0
  • Merged pull requests: 15
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 6
  • Pull requests: 8
  • Average time to close issues: about 1 month
  • Average time to close pull requests: 13 days
  • Issue authors: 4
  • Pull request authors: 1
  • Average comments per issue: 0.0
  • Average comments per pull request: 0.0
  • Merged pull requests: 6
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
  • andyquinterom (10)
  • saudiwin (1)
  • jrosell (1)
  • timothyfraser (1)
  • andreavargasmon (1)
Pull Request Authors
  • andyquinterom (21)
  • maurolepore (2)
  • andreavargasmon (2)
Top Labels
Issue Labels
enhancement (1)
Pull Request Labels
enhancement (2)

Packages

  • Total packages: 1
  • Total downloads:
    • cran 490 last-month
  • Total dependent packages: 0
  • Total dependent repositories: 0
  • Total versions: 1
  • Total maintainers: 1
cran.r-project.org: tapLock

Seamless Single Sign-on for 'shiny'

  • Versions: 1
  • Dependent Packages: 0
  • Dependent Repositories: 0
  • Downloads: 490 Last month
Rankings
Dependent packages count: 27.9%
Dependent repos count: 34.4%
Average: 49.7%
Downloads: 86.9%
Maintainers (1)
Last synced: 12 months ago

Dependencies

.github/workflows/pkgdown.yaml actions
  • JamesIves/github-pages-deploy-action v4.4.1 composite
  • actions/checkout v3 composite
  • r-lib/actions/setup-pandoc v2 composite
  • r-lib/actions/setup-r v2 composite
  • r-lib/actions/setup-r-dependencies v2 composite
DESCRIPTION cran
  • curl * imports
  • future * imports
  • glue * imports
  • httr2 * imports
  • jose * imports
  • lubridate * imports
  • promises * imports
  • purrr * imports
  • stats * imports
  • stringr * imports
  • shiny * suggests