SlideShare a Scribd company logo
Tapir User Manager

Paul Houle, Library Systems, CU Library
http://www.honeylocust.com/x/products/tum/
Ph18@cornell.edu
TUM Features
• Cookie-based authentication
• Optional self-registration
• w/ e-mail address verification
• Automatic password resets
• Simple to integrate into existing applications
• Supports PHP and Perl applications
• Advanced Administrative Interface
• Add or Update User Records
• Real-time graphing
• E-mail sending to users
Why not Apache auth?
Apache’s authentication is integrated with the
web server, BUT:
•Users can’t log out
• No support for permanent login
• No automatic password reset
• Password file must be edited by hand
Web Portals
A web portal is a collection of web applications
that share:
• Common visual appearance
• A single user database
User management is necessary for administrative
screens, community, e-commerce, content
management, etc.
The web software crisis
Two kinds of open-source and commercial web
software:
• Frameworks
• Provide user management, templating, and
other services, BUT
• Have a high-learning curve and almost
always do something seriously wrong.
• Applications
• Many excellent apps exist, but since there’s
no standard, they don’t share a user database.
So we re-invent the wheel for every site…
Performance Goals
Appropriate for small to large sites:
• PHP/MySQL combination is easy to install and
maintain
• Supports > 1 M hits/day
• Doesn’t need to hit database to authenticate
• Supports > 1 M users
• Supports horizontal scaling
Experience: TUM exceeds above goals.
What it doesn’t do
It’s important to guarantee performance and
reliability, so:
• We don’t support other databases
• We don’t support other user database backends, i.e.
• LDAP
• Web services
Integration with outside services, for better or
worse, is by copying information.
• No (intrinsic) defense against packet sniffing.
Toolset
Based on market-leading tools for top
performance, reliability and maintainability:
•Apache 2 web server
• PHP 4 (transitioning to 5)
• MySQL 4.0 (transitioning to 4.1)
Secondary tools:
• Smarty templating system
• jpGraph (real-time graphing)
Programmers Eye View
require_once “tapir_auth.php”;
$auth=new Tapir_Auth();
// For personalization…
$auth->optional();

// To control access..
$auth->required();

$email=$auth->get_email();
$first_name=$auth->get_first_name();
Authentication Object
$auth->required() and related functions are about
200 lines of code in most languages.
By implementing the ‘Tapir_Auth’ object in a
language (say Java, TCL), applications written in
that language can use TUM authentication and
benefit from the TUM UI written in PHP.
Applications have the full power of SQL to access
the user db.
TUM is based on open standards (cookies, SQL)
and avoids roach motels (session-variable facilities
and proprietary object databases.)
Database access
Supports a single database connection per script,
lazy connection creation, interoperation with
other MySQL APIs, robust error handling and
convenience:

$count=
$auth->conn->select_scalar(
“SELECT COUNT(*) FROM tapir_users”)
Session Cookies
Based on “Do’s and Don’ts of Client Authentication on the Web”
http://cookies.lcs.mit.edu/pubs/webauth:tr.pdf
398927:1:132.236.212.35:1097859122:15:oQjG5oe2T6uMmlvHyS7CnBte/d4

Session Id

Ip address

Capabilities
Timestamp

User Id

Cryptographic Hash

Cookies are reissued when timestamp is > 10 m
old. SHA1 hash with secret protects cookie from
forgery or alteration.
Other Cookies
tapir_permanent:
Secret token for permanent login like
Amazon, Yahoo.

tapir_browser:
Standard cookie issued by Apache’s
mod_usertrack to track browsers
If we add SSL support, we’ll also add a
tapir_secure cookie that only travels over SSL.
Customization
• A site can provide templates (plain PHP or
smarty) for both the user and admin pages
• Namespace conventions allow sites to add own
tables and columns to tapir_ tables
• Numerous hooks provided to allow modification
of login and registration behavior (can replace
forms, talk to external systems, etc.)
• Much of the admin UI is table-driven, much
customization is almost trivial.
• Configuration management system lets local sites
replace files, and configure PHP, Perl and Apache
configuration files with M4 macros
External User Interface
UI: Devil in the Details
• Jacob Nielsen:
• Authentication is a major barrier to usability
• Many processes on commercial web sites have
<50% success rate
•With Tivejo, we increased the registration success
rate from 60% to 85%, arXiv attains nearly 95%
•Base 32t coding for (e-mail verification, password
reset, and other) tokens: 60-bit security in 12 easyto-type characters, insensitive to case and common
errors such as 0/O and 1/L confusion
K8TLTI-78FKTR
Administrative Interface
•Benefits from development for multiple projects
•Tour: (arXiv.org)
• Main screen
• Advanced Search
• User detail screen
• Real-time graphing
UI Toolkit
• Purposely set out NOT to develop a universal
framework, BUT
• developing a sophisticated UI that’s consistent
and maintainable has required us to develop a
framework
• the “update protocol”
• template system
• the “screen” concept
• query builder
• real-time graphing
Case Study: Tivejo
• For a while, Brazil’s #1 voice chat service;
250,000+ users and 300,000 hits per day
• Web site controlled access to a Windows
application, interacted with Paltalk.com via a
‘REST’ web service
UDP, peer-to-peer, “VoIP”
browser

registers

chat client

authentication, call setup

downloads

Tivejo www

other user

web service
Paltalk.com

Tivejo mail

Tivejo db
Case Study: LS Wikis
Wanted a wiki for both public and private
documentation – existing wiki software didn’t
support authentication.
• Ported TUM to Solaris (install scripts)
• Two wikis:
•funkenstein: open registration
•docs-production: closed registration
• Chose PHP Wiki: Wiki Tiki Tavi
• About an hour to get authentication minimally
working.
• Another two days to get everything right
Case Study: arXiv.org
World’s largest physics publisher: (also math, cs…)
•293,000+ papers (nearly 200 submissions/day)
•60,000+ registered users
Legacy System:
Perl CGI scripts, using filesystem for paper
storage and Berkeley DB for user database. Very
messy data, some users aren’t even registered, not
possible to determine submitter of all papers
Requirement:
Flexible user database so we can implement
“endorsements” to control problem submissions.
Case Study: arXiv.org II
Challenges:
• Implement Perl Auth object for legacy scripts
• Clean up user database as best possible
• Making a complex user interface for
endorsement simple for users
• Making it easy for administrators to do routine
and not-so-routine jobs
Still to do:
• Move all admin functions to web
• Move e-mail subscriptions to web
• Require Password option, hide .PHP urls, etc.
Conclusion
TUM: Best-of-breed user management system, works with
(not against) existing applications and mainstream programming methods; incorporates lessons learned from a number of
projects; provides the interface that users expect from major
commercial sites; convenient to install and administer.

http://www.honeylocust.com/x/products/tum/

More Related Content

PDF
CNIT 129S - Ch 3: Web Application Technologies
PDF
CNIT 129S: Ch 5: Bypassing Client-Side Controls
PDF
Ch 3: Web Application Technologies
PDF
CNIT 129S: Ch 3: Web Application Technologies
PDF
CNIT 129S: Securing Web Applications Ch 1-2
PDF
CNIT 129S: 12: Attacking Users: Cross-Site Scripting (Part 1 of 2)
PPT
gofortution
PDF
CNIT 129S: Ch 7: Attacking Session Management
CNIT 129S - Ch 3: Web Application Technologies
CNIT 129S: Ch 5: Bypassing Client-Side Controls
Ch 3: Web Application Technologies
CNIT 129S: Ch 3: Web Application Technologies
CNIT 129S: Securing Web Applications Ch 1-2
CNIT 129S: 12: Attacking Users: Cross-Site Scripting (Part 1 of 2)
gofortution
CNIT 129S: Ch 7: Attacking Session Management

What's hot (20)

PDF
CNIT 129S: 13: Attacking Users: Other Techniques (Part 1 of 2)
PDF
CNIT 129S: Ch 6: Attacking Authentication
PDF
CNIT 129S: Ch 4: Mapping the Application
PDF
CNIT 129S: 8: Attacking Access Controls
PDF
CNIT 129: 6. Attacking Authentication
PDF
CNIT 129S: 11: Attacking Application Logic
PDF
CNIT 129S - Ch 6a: Attacking Authentication
PDF
CNIT 129S: 10: Attacking Back-End Components
PDF
CNIT 129S: 13: Attacking Users: Other Techniques (Part 2 of 2)
PDF
Mobile security chess board - attacks & defense
PPT
Web Server Technologies II: Web Applications & Server Maintenance
PPT
iOS Application Security Testing
PPTX
Extending drupal authentication
ODP
Web Server-Side Programming Techniques
PPT
HTML5 hacking
PPT
Web Services Hacking and Security
PPT
Introduction to the Web API
PDF
Best Practice in Web Service Design
PDF
Ch 5: Bypassing Client-Side Controls
PPT
Application fuzzing
CNIT 129S: 13: Attacking Users: Other Techniques (Part 1 of 2)
CNIT 129S: Ch 6: Attacking Authentication
CNIT 129S: Ch 4: Mapping the Application
CNIT 129S: 8: Attacking Access Controls
CNIT 129: 6. Attacking Authentication
CNIT 129S: 11: Attacking Application Logic
CNIT 129S - Ch 6a: Attacking Authentication
CNIT 129S: 10: Attacking Back-End Components
CNIT 129S: 13: Attacking Users: Other Techniques (Part 2 of 2)
Mobile security chess board - attacks & defense
Web Server Technologies II: Web Applications & Server Maintenance
iOS Application Security Testing
Extending drupal authentication
Web Server-Side Programming Techniques
HTML5 hacking
Web Services Hacking and Security
Introduction to the Web API
Best Practice in Web Service Design
Ch 5: Bypassing Client-Side Controls
Application fuzzing
Ad

Viewers also liked (6)

PDF
Classical Mechanics of a Three Spin Cluster
ODP
Future Proof
PPT
The Global Performing Arts Database
PDF
Semiclassical mechanics of a non-integrable spin cluster
ODP
Journalism and the Semantic Web
PPT
Arxiv.org: Research And Development Directions
Classical Mechanics of a Three Spin Cluster
Future Proof
The Global Performing Arts Database
Semiclassical mechanics of a non-integrable spin cluster
Journalism and the Semantic Web
Arxiv.org: Research And Development Directions
Ad

Similar to Tapir user manager (20)

PPT
PPT
FOSSwire3 + OpenID
DOCX
ISOL536Security Architecture and DesignWeek 6Web Threa.docx
PDF
Fixing Twitter Improving The Performance And Scalability Of The Worlds Most ...
PDF
Fixing twitter
PDF
Fixing_Twitter
PDF
Fixing Twitter Improving The Performance And Scalability Of The Worlds Most ...
PPT
Security and information assurance
PPT
GTU MCA PHP Interview Questions And Answers for freshers
KEY
Fixing Twitter Velocity2009
PPT
Open Source & Identity Management
ZIP
The Power of Open Data
PDF
Securing web applications
PPTX
Lecture 20101124
PDF
FOSDEM 2009 Thunderbird 3 talk
PPT
Database layer in php
PPT
Open Id, O Auth And Webservices
PDF
dist-access. access control in distributed systemspdf
PDF
Hacking For Innovation
PPTX
Collaboration Portal for Researchers
FOSSwire3 + OpenID
ISOL536Security Architecture and DesignWeek 6Web Threa.docx
Fixing Twitter Improving The Performance And Scalability Of The Worlds Most ...
Fixing twitter
Fixing_Twitter
Fixing Twitter Improving The Performance And Scalability Of The Worlds Most ...
Security and information assurance
GTU MCA PHP Interview Questions And Answers for freshers
Fixing Twitter Velocity2009
Open Source & Identity Management
The Power of Open Data
Securing web applications
Lecture 20101124
FOSDEM 2009 Thunderbird 3 talk
Database layer in php
Open Id, O Auth And Webservices
dist-access. access control in distributed systemspdf
Hacking For Innovation
Collaboration Portal for Researchers

More from Paul Houle (20)

PDF
Chatbots in 2017 -- Ithaca Talk Dec 6
PDF
Estimating the Software Product Value during the Development Process
PPTX
Universal Standards for LEI and other Corporate Reference Data: Enabling risk...
PPTX
Fixing a leaky bucket; Observations on the Global LEI System
PDF
Cisco Fog Strategy For Big and Smart Data
PPTX
Making the semantic web work
PPTX
Ontology2 platform
PPTX
Ontology2 Platform Evolution
PDF
Paul houle the supermen
PDF
Paul houle what ails enterprise search
PDF
Subjective Importance Smackdown
PDF
Extension methods, nulls, namespaces and precedence in c#
PDF
Dropping unique constraints in sql server
PDF
Prefix casting versus as-casting in c#
PDF
Paul houle resume
PDF
Keeping track of state in asynchronous callbacks
PDF
Embrace dynamic PHP
PDF
Once asynchronous, always asynchronous
PDF
What do you do when you’ve caught an exception?
PDF
Extension methods, nulls, namespaces and precedence in c#
Chatbots in 2017 -- Ithaca Talk Dec 6
Estimating the Software Product Value during the Development Process
Universal Standards for LEI and other Corporate Reference Data: Enabling risk...
Fixing a leaky bucket; Observations on the Global LEI System
Cisco Fog Strategy For Big and Smart Data
Making the semantic web work
Ontology2 platform
Ontology2 Platform Evolution
Paul houle the supermen
Paul houle what ails enterprise search
Subjective Importance Smackdown
Extension methods, nulls, namespaces and precedence in c#
Dropping unique constraints in sql server
Prefix casting versus as-casting in c#
Paul houle resume
Keeping track of state in asynchronous callbacks
Embrace dynamic PHP
Once asynchronous, always asynchronous
What do you do when you’ve caught an exception?
Extension methods, nulls, namespaces and precedence in c#

Recently uploaded (20)

PPTX
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
PPTX
Digital-Transformation-Roadmap-for-Companies.pptx
PPTX
Understanding_Digital_Forensics_Presentation.pptx
PDF
Diabetes mellitus diagnosis method based random forest with bat algorithm
PPTX
Programs and apps: productivity, graphics, security and other tools
PDF
Encapsulation theory and applications.pdf
PPTX
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
PDF
The Rise and Fall of 3GPP – Time for a Sabbatical?
PDF
Per capita expenditure prediction using model stacking based on satellite ima...
PDF
Encapsulation_ Review paper, used for researhc scholars
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
PDF
MIND Revenue Release Quarter 2 2025 Press Release
PDF
Dropbox Q2 2025 Financial Results & Investor Presentation
PDF
Machine learning based COVID-19 study performance prediction
PDF
Approach and Philosophy of On baking technology
PDF
Spectral efficient network and resource selection model in 5G networks
PDF
cuic standard and advanced reporting.pdf
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PPT
Teaching material agriculture food technology
PDF
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
Digital-Transformation-Roadmap-for-Companies.pptx
Understanding_Digital_Forensics_Presentation.pptx
Diabetes mellitus diagnosis method based random forest with bat algorithm
Programs and apps: productivity, graphics, security and other tools
Encapsulation theory and applications.pdf
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
The Rise and Fall of 3GPP – Time for a Sabbatical?
Per capita expenditure prediction using model stacking based on satellite ima...
Encapsulation_ Review paper, used for researhc scholars
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
MIND Revenue Release Quarter 2 2025 Press Release
Dropbox Q2 2025 Financial Results & Investor Presentation
Machine learning based COVID-19 study performance prediction
Approach and Philosophy of On baking technology
Spectral efficient network and resource selection model in 5G networks
cuic standard and advanced reporting.pdf
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
Teaching material agriculture food technology
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf

Tapir user manager

  • 1. Tapir User Manager Paul Houle, Library Systems, CU Library http://www.honeylocust.com/x/products/tum/ Ph18@cornell.edu
  • 2. TUM Features • Cookie-based authentication • Optional self-registration • w/ e-mail address verification • Automatic password resets • Simple to integrate into existing applications • Supports PHP and Perl applications • Advanced Administrative Interface • Add or Update User Records • Real-time graphing • E-mail sending to users
  • 3. Why not Apache auth? Apache’s authentication is integrated with the web server, BUT: •Users can’t log out • No support for permanent login • No automatic password reset • Password file must be edited by hand
  • 4. Web Portals A web portal is a collection of web applications that share: • Common visual appearance • A single user database User management is necessary for administrative screens, community, e-commerce, content management, etc.
  • 5. The web software crisis Two kinds of open-source and commercial web software: • Frameworks • Provide user management, templating, and other services, BUT • Have a high-learning curve and almost always do something seriously wrong. • Applications • Many excellent apps exist, but since there’s no standard, they don’t share a user database. So we re-invent the wheel for every site…
  • 6. Performance Goals Appropriate for small to large sites: • PHP/MySQL combination is easy to install and maintain • Supports > 1 M hits/day • Doesn’t need to hit database to authenticate • Supports > 1 M users • Supports horizontal scaling Experience: TUM exceeds above goals.
  • 7. What it doesn’t do It’s important to guarantee performance and reliability, so: • We don’t support other databases • We don’t support other user database backends, i.e. • LDAP • Web services Integration with outside services, for better or worse, is by copying information. • No (intrinsic) defense against packet sniffing.
  • 8. Toolset Based on market-leading tools for top performance, reliability and maintainability: •Apache 2 web server • PHP 4 (transitioning to 5) • MySQL 4.0 (transitioning to 4.1) Secondary tools: • Smarty templating system • jpGraph (real-time graphing)
  • 9. Programmers Eye View require_once “tapir_auth.php”; $auth=new Tapir_Auth(); // For personalization… $auth->optional(); // To control access.. $auth->required(); $email=$auth->get_email(); $first_name=$auth->get_first_name();
  • 10. Authentication Object $auth->required() and related functions are about 200 lines of code in most languages. By implementing the ‘Tapir_Auth’ object in a language (say Java, TCL), applications written in that language can use TUM authentication and benefit from the TUM UI written in PHP. Applications have the full power of SQL to access the user db. TUM is based on open standards (cookies, SQL) and avoids roach motels (session-variable facilities and proprietary object databases.)
  • 11. Database access Supports a single database connection per script, lazy connection creation, interoperation with other MySQL APIs, robust error handling and convenience: $count= $auth->conn->select_scalar( “SELECT COUNT(*) FROM tapir_users”)
  • 12. Session Cookies Based on “Do’s and Don’ts of Client Authentication on the Web” http://cookies.lcs.mit.edu/pubs/webauth:tr.pdf 398927:1:132.236.212.35:1097859122:15:oQjG5oe2T6uMmlvHyS7CnBte/d4 Session Id Ip address Capabilities Timestamp User Id Cryptographic Hash Cookies are reissued when timestamp is > 10 m old. SHA1 hash with secret protects cookie from forgery or alteration.
  • 13. Other Cookies tapir_permanent: Secret token for permanent login like Amazon, Yahoo. tapir_browser: Standard cookie issued by Apache’s mod_usertrack to track browsers If we add SSL support, we’ll also add a tapir_secure cookie that only travels over SSL.
  • 14. Customization • A site can provide templates (plain PHP or smarty) for both the user and admin pages • Namespace conventions allow sites to add own tables and columns to tapir_ tables • Numerous hooks provided to allow modification of login and registration behavior (can replace forms, talk to external systems, etc.) • Much of the admin UI is table-driven, much customization is almost trivial. • Configuration management system lets local sites replace files, and configure PHP, Perl and Apache configuration files with M4 macros
  • 16. UI: Devil in the Details • Jacob Nielsen: • Authentication is a major barrier to usability • Many processes on commercial web sites have <50% success rate •With Tivejo, we increased the registration success rate from 60% to 85%, arXiv attains nearly 95% •Base 32t coding for (e-mail verification, password reset, and other) tokens: 60-bit security in 12 easyto-type characters, insensitive to case and common errors such as 0/O and 1/L confusion K8TLTI-78FKTR
  • 17. Administrative Interface •Benefits from development for multiple projects •Tour: (arXiv.org) • Main screen • Advanced Search • User detail screen • Real-time graphing
  • 18. UI Toolkit • Purposely set out NOT to develop a universal framework, BUT • developing a sophisticated UI that’s consistent and maintainable has required us to develop a framework • the “update protocol” • template system • the “screen” concept • query builder • real-time graphing
  • 19. Case Study: Tivejo • For a while, Brazil’s #1 voice chat service; 250,000+ users and 300,000 hits per day • Web site controlled access to a Windows application, interacted with Paltalk.com via a ‘REST’ web service UDP, peer-to-peer, “VoIP” browser registers chat client authentication, call setup downloads Tivejo www other user web service Paltalk.com Tivejo mail Tivejo db
  • 20. Case Study: LS Wikis Wanted a wiki for both public and private documentation – existing wiki software didn’t support authentication. • Ported TUM to Solaris (install scripts) • Two wikis: •funkenstein: open registration •docs-production: closed registration • Chose PHP Wiki: Wiki Tiki Tavi • About an hour to get authentication minimally working. • Another two days to get everything right
  • 21. Case Study: arXiv.org World’s largest physics publisher: (also math, cs…) •293,000+ papers (nearly 200 submissions/day) •60,000+ registered users Legacy System: Perl CGI scripts, using filesystem for paper storage and Berkeley DB for user database. Very messy data, some users aren’t even registered, not possible to determine submitter of all papers Requirement: Flexible user database so we can implement “endorsements” to control problem submissions.
  • 22. Case Study: arXiv.org II Challenges: • Implement Perl Auth object for legacy scripts • Clean up user database as best possible • Making a complex user interface for endorsement simple for users • Making it easy for administrators to do routine and not-so-routine jobs Still to do: • Move all admin functions to web • Move e-mail subscriptions to web • Require Password option, hide .PHP urls, etc.
  • 23. Conclusion TUM: Best-of-breed user management system, works with (not against) existing applications and mainstream programming methods; incorporates lessons learned from a number of projects; provides the interface that users expect from major commercial sites; convenient to install and administer. http://www.honeylocust.com/x/products/tum/