class: middle, center ## auth0 package ## .gray[secure*] .deep-orange[authentication in shiny apps] <a href='https://curso-r.github.com/auth0', target="_blank"> <img src="img/logo.png" width="320" style="display: block; margin: auto;" /> </a> ## .blue[satRday] ### Insper .red[(] São Paulo, 2019 --- class: shuriken-100 .blade1.bg-cyan[ # What? ] .hole.center[ # now you can do this! <br/> <br/> <img src="img/hello.png" width="100%" style="display: block; margin: auto;" /> ] .blade3.bg-light-blue.yellow.center[ ## https: //github.com/curso-r/auth0 ] --- class: split-three, center .row.left[ # Why? .center[ ## Connect using MANY providers ] .pull-left[ <img src="img/social.png" width="80%" style="display: block; margin: auto;" /> ] .pull-right[ <img src="img/enterprise.png" width="70%" style="display: block; margin: auto;" /> ] ] .row.middle[ ## ] .row[ ## ] --- class: split-three, center .row.left[ # Why? .center[ ## Connect using MANY providers ] .pull-left[ <img src="img/social.png" width="80%" style="display: block; margin: auto;" /> ] .pull-right[ <img src="img/enterprise.png" width="70%" style="display: block; margin: auto;" /> ] ] .row.middle[ ## ] .row.bg-lime.black[ <br/> <br/> ## FREE (mium) ] --- class: split-one .left[ # How? ] ## Use `app.R` ```r library(shiny) library(auth0) ui <- fluidPage( h1("Olar"), logoutButton("tchau") ) server <- function(input, output, session) { } *shinyAppAuth0(ui, server) ## only difference ``` --- class: split-one .left[ # How? ] ## Use `app.R` ```r library(shiny) library(auth0) ui <- fluidPage( h1("Olar"), logoutButton("tchau") ) server <- function(input, output, session) { } *shinyAppAuth0(ui, server) ## only difference ``` <img src="img/notbad.jpg" width="30%" style="display: block; margin: auto;" /> --- # Really, just that? .right-column[ No :/ ### Create Auth0 account ### Create new Auth0 Application ### Fill connection info in `_auth0.yml` file .left[ ```r name: myApp shiny_config: local_url: http://localhost:8100 remote_url: https://johndoe.shinyapps.io/myapp auth0_config: api_url: https://<USERNAME>.auth0.com credentials: key: <CLIENT ID> secret: <CLIENT SECRET> ``` ] ] .left-column[ ] --- # Really, just that? .right-column[ No :/ ### Create Auth0 account ### Create new Auth0 Application ### Fill connection info in `_auth0.yml` file .left[ ```r name: myApp shiny_config: local_url: http://localhost:8100 remote_url: https://johndoe.shinyapps.io/myapp auth0_config: api_url: https://<USERNAME>.auth0.com credentials: key: <CLIENT ID> secret: <CLIENT SECRET> ``` ] ] .left-column[ <img src="img/okay.png" width="100%" style="display: block; margin: auto;" /> ] --- class: split-four .row.bg-cyan.middle.left[ # .white[More?] .center[ ## `logoutButton()` #### log out button ] ] .row.bg-light-blue.center[ <br/> ## `session$userData$auth0_info` #### Capture user info ] .row.bg-cyan.center[ <br/> ## `use_auth0()` #### Create `_auth0.yml` file ] .row.bg-light-blue.center[ <br/> ## `auth0_ui()` and `auth0_server()` #### to use with `ui.R` and `server.R` framework ] --- # Examples <img src="img/example2.png" width="1179" style="display: block; margin: auto;" /> --- # Examples <img src="img/example.png" width="1188" style="display: block; margin: auto;" /> --- class: center split-three .row.bg-white.left[ # Do you need help? <img src="img/yes.gif" width="25%" height="10%" style="display: block; margin: auto;" /> ] .row.bg-lime[ <br/> <br/> # Make **bookmarking** work well <img src="img/bookmark.png" width="785" style="display: block; margin: auto;" /> ] .row.bg-green[ <br/> <br/> # Implement Auth0's user .yellow[**API**] ] --- class: center split-four .row.bg-pink.left[ # .yellow[Where?] .center[ ### .white[**CRAN**] ```r install.packages("auth0") ``` ] ] .row.bg-purple[ <br/> ### .white[**GitHub**] ```r remotes::install_github("curso-r/auth0") ``` ] .row.bg-pink[ <br/> ### .white[**Issues**] ```r https://github.com/curso-r/auth0/issues ``` ] .row.bg-purple[ <br/> ### .white[**Site**] ```r https://curso-r.github.io/auth0 ``` ] --- # Security ## I'm not a security expert! <img src="img/bob1.png" width="788" style="display: block; margin: auto;" /> --- # Security ## I'm not a security expert! <img src="img/bob2.png" width="801" style="display: block; margin: auto;" /> --- # Security ## I'm not a security expert! <img src="img/bob3.png" width="787" style="display: block; margin: auto;" /> <img src="img/love.gif" width="30%" style="display: block; margin: auto;" /> --- class: center middle # Stalk us <br/> <br/> .pull-left[ ### .red[Julio Trecenti] ([@jtrecenti](https://github.com/jtrecenti), cre) <img src="img/jubs.jpeg" width="40%" style="display: block; margin: auto;" /> ### Curso-R team ([@curso-r](https://github.com/curso-r), aut) <img src="img/cursor.png" width="80%" style="display: block; margin: auto;" /> ] .pull-right[ ### Dean Attali ([@daattali](https://github.com/daattali), ctb) <img src="img/dean.jpeg" width="40%" style="display: block; margin: auto;" /> ### José Jesus ([@jjesusfilho](https://github.com/jjesusfilho), ctb) <img src="img/jose.png" width="40%" style="display: block; margin: auto;" /> ]