Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Devise @ Rails Summit 2009
Search
Carlos Antonio
October 13, 2009
Programming
1
78
Devise @ Rails Summit 2009
Lightning Talk releasing Devise.
Carlos Antonio
October 13, 2009
Tweet
Share
More Decks by Carlos Antonio
See All by Carlos Antonio
Contribuindo para Open Source @ 1º Tech Day GURU- PR
carlosantoniodasilva
2
220
Contributing to Open Source: from beginning to lessons learned @ Tropical Ruby 2015
carlosantoniodasilva
5
410
Os truques que o Rails não te contou @ RubyConf Brasil 2014
carlosantoniodasilva
20
820
Os truques que o Rails não te contou @ TDC Floripa 2014
carlosantoniodasilva
18
930
Tricks that Rails didn't tell you about @ RailsConf 2014
carlosantoniodasilva
76
11k
Integração de gems com o Rails @ RS on Rails
carlosantoniodasilva
2
140
Escrevendo Aplicações Melhores @ RubyConf Brasil
carlosantoniodasilva
3
140
Railties @ WyeWorks
carlosantoniodasilva
1
91
Plataformatec's Hacking Evenings @ RubyConf Uruguay
carlosantoniodasilva
1
79
Other Decks in Programming
See All in Programming
Snowflakeで眠ったデータを起こそう!
estie
0
150
DMMプラットフォームがTiDB Cloudを採用した背景
pospome
9
4.3k
Ruby Function Composition
bkuhlmann
1
340
Scalable Customer Journey Orchestration (CJO)
lewuathe
0
440
WebGLで始める コンピュータグラフィックス入門
heller77
0
330
Try creating your own orderedmap
kazamori
1
250
新宿ダンジョンを可視化してみた
satoshi7190
3
400
敵対的ポイフル
futabato
0
140
Deep Dive into React Stream/Serialize
mugi_uno
3
720
Ruby GitHub Packages
bkuhlmann
0
650
Milestoner
bkuhlmann
1
420
StoreKit2によるiOSのアプリ内課金のリニューアル
kangnux
0
130
Featured
See All Featured
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
352
28k
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
221
21k
Put a Button on it: Removing Barriers to Going Fast.
kastner
58
3.1k
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
501
140k
Designing for Performance
lara
601
67k
Build your cross-platform service in a week with App Engine
jlugia
226
17k
Visualization
eitanlees
137
14k
Automating Front-end Workflow
addyosmani
1357
200k
For a Future-Friendly Web
brad_frost
172
9k
Gamification - CAS2011
davidbonilla
77
4.6k
The Mythical Team-Month
searls
217
42k
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
188
16k
Transcript
Plataforma 2009 Autenticação flexível com Devise http://github.com/plataformatec/devise
None
Plataforma 2009 Soluções Existentes
Plataforma 2009 Clearance • Pontos positivos – Estrutura completa, como
engine (MVC) – Confirmação de conta – Recuperação de senha • Pontos negativos – Pouco flexível (apenas model User) – Não modularizado
Plataforma 2009 Authlogic • Pontos positivos – Modelo bem flexível
– Criptografia – Magic columns • Pontos negativos – Não é solução completa (MVC) como o Clearance – Trata a sessão como modelo
Plataforma 2009 Nossa proposta
Plataforma 2009 Devise • Pontos positivos – Rack based (via
Warden): Rails, Metal, Sinatra – Solução completa (MVC), como engine – Múltiplos roles (logar como admin, user, ...) – Modular e flexível • Pontos negativos – Pouca base instalada – Menos de 10 watchers no github
Plataforma 2009 class User < ActiveRecord::Base devise :authenticable end
Plataforma 2009 class User < ActiveRecord::Base devise :confirmable end
Plataforma 2009 class User < ActiveRecord::Base devise :recoverable end
Plataforma 2009 class User < ActiveRecord::Base devise :validatable end
Plataforma 2009 class User < ActiveRecord::Base devise :all end
Plataforma 2009 ActionController::Routing::Routes.draw do |map| map.devise_for :users end
Plataforma 2009 ...tem mais coisa vindo
Plataforma 2009 Proteção contra Brute Force self.attempts_count = 10 self.attempts_timeframe
= 2.hours
Plataforma 2009 Remember me self.remember_me = 2.weeks
Plataforma 2009 Migratable create_table :users do |t| t.authenticable t.confirmable end
Plataforma 2009 Magic colums self.login_count self.last_request_at self.last_login_ip
Plataforma 2009 github.com/plataformatec/devise blog.plataformatec.com.br