SlideShare ist ein Scribd-Unternehmen logo
1 von 16
Downloaden Sie, um offline zu lesen
Motivation                           Introducing Remorseful              Summary
...                                   .
..                                    ......




                             Design of Remorseful
             A Distributed User Management and Authentication Solution


                                       Weisi Dai
                                      (09055029)

                       Department of Computer Science and Technology
                                 Xi’an Jiaotong University


                                     Mar 14, 2012
Motivation                     Introducing Remorseful   Summary
...                             .
..                              ......


                                 Outline



      Motivation
        The Basic Problem That I Studied
        Previous Work


      Introducing Remorseful
          Technical Details
          Object Models
Motivation                        Introducing Remorseful    Summary
...                                .
..                                 ......


                 Distributed User Authentication Solution


             • mongoDB
             • HTML5
             • Javascript
             • Application

      Roles
             • Users
             • Administrator(s)
Motivation                          Introducing Remorseful   Summary
...                                  .
..                                   ......


                                        Roles

      Users
             • Register
             • Pay
             • Choose Plan
             • Log in via clients


      Administrator(s)
             • Add and ban users
             • Add and edit plans
             • Add and modify peer servers info
Motivation                           Introducing Remorseful              Summary
...                                   .
..                                    ......


                          We need a(n)                        solution




             • Simple
             • Effective
             • No Single-point Failure!
Motivation                             Introducing Remorseful                  Summary
...                                     .
..                                      ......


                                        RADIUS
                 abbr for Remote Authentication Dial In User System, RFC2865




             • Complete Solution, both Commercial and Free
                 • Our NIC uses that!
             • Designed for Accounting in Telecommunication Industry
                 • Very very heavily used!

             • Complicated
Motivation                             Introducing Remorseful   Summary
...                                     .
..                                      ......


                       MagiAdmin and OVpnUsrMng

      MagiAdmin, by Aveline Swan
             • PHP-based
             • Not Scalable
             • Not So Fault-Tolerant
             • Not Open-Source


      OVpnUsrMng
             • Python And Django based
             • SQLite as Database
             • Not So Scalable
Motivation                           Introducing Remorseful   Summary
...                                   .
..                                    ......


                 Perfect Combination, Simple and Scalable



      Database: mongoDB
             K-V Store, NOSQL

      Web: Node.js
             Javascript on the Server Side

      OS: Unix like
Motivation                 Introducing Remorseful           Summary
...                         .
..                          ......


                                User
      CREATE TABLE IF NOT EXISTS ‘Remorseful‘.‘User‘ (
        ‘idUser‘ INT NOT NULL ,
        ‘UserName‘ TINYTEXT NOT NULL ,
        ‘Password‘ TINYTEXT NOT NULL ,
        ‘Email‘ TINYTEXT NOT NULL ,
        ‘Contact‘ TINYTEXT NULL ,
        ‘Credit‘ INT(11) NOT NULL ,
        ‘Banned‘ TINYINT(1) NOT NULL ,
        ‘Plan‘ INT NULL ,
        PRIMARY KEY (‘idUser‘, ‘UserName‘) ,
        UNIQUE INDEX ‘UserName_UNIQUE‘ (‘UserName‘ ASC) ,
        INDEX ‘Plan‘ (‘Plan‘ ASC) ,
        CONSTRAINT ‘Plan‘
          FOREIGN KEY (‘Plan‘ )
          REFERENCES ‘Remorseful‘.‘Plan‘ (‘idPlan‘ )
          ON DELETE NO ACTION
Motivation                 Introducing Remorseful        Summary
...                         .
..                          ......


                                Plan



      CREATE TABLE IF NOT EXISTS ‘Remorseful‘.‘Plan‘ (
        ‘idPlan‘ INT NOT NULL ,
        ‘PlanTitle‘ TINYTEXT NOT NULL ,
        ‘Bandwidth‘ INT NOT NULL ,
        ‘Connection‘ INT NOT NULL ,
        ‘MonthlyFee‘ INT NOT NULL ,
        ‘Hidden‘ TINYINT(1) NOT NULL ,
        PRIMARY KEY (‘idPlan‘, ‘PlanTitle‘) )
Motivation                 Introducing Remorseful          Summary
...                         .
..                          ......


                              Record
      CREATE TABLE IF NOT EXISTS ‘Remorseful‘.‘Record‘ (
        ‘idRecord‘ INT NOT NULL ,
        ‘Service‘ TINYTEXT NOT NULL ,
        ‘ConnTime‘ DATETIME NOT NULL ,
        ‘DisconnTime‘ DATETIME NULL ,
        ‘IP‘ TINYTEXT NOT NULL ,
        ‘BandwidthUp‘ MEDIUMTEXT NULL ,
        ‘BandwidthDown‘ MEDIUMTEXT NULL ,
        ‘User‘ INT NOT NULL ,
        PRIMARY KEY (‘idRecord‘) ,
        INDEX ‘User‘ (‘User‘ ASC) ,
        CONSTRAINT ‘User‘
          FOREIGN KEY (‘User‘ )
          REFERENCES ‘Remorseful‘.‘User‘ (‘idUser‘ )
          ON DELETE NO ACTION
          ON UPDATE NO ACTION)
Motivation                 Introducing Remorseful           Summary
...                         .
..                          ......


                            Payment

      CREATE TABLE IF NOT EXISTS ‘Remorseful‘.‘Payment‘ (
        ‘idPayment‘ INT NOT NULL ,
        ‘User‘ INT NOT NULL ,
        ‘Via‘ TINYTEXT NOT NULL ,
        ‘Amount‘ INT NOT NULL ,
        ‘TIME‘ DATETIME NOT NULL DEFAULT now() ,
        PRIMARY KEY (‘idPayment‘) ,
        INDEX ‘User‘ (‘User‘ ASC) ,
        CONSTRAINT ‘User‘
          FOREIGN KEY (‘User‘ )
          REFERENCES ‘Remorseful‘.‘User‘ (‘idUser‘ )
          ON DELETE NO ACTION
          ON UPDATE NO ACTION)
Motivation                 Introducing Remorseful        Summary
...                         .
..                          ......


                                Peer




      CREATE TABLE IF NOT EXISTS ‘Remorseful‘.‘Peer‘ (
        ‘idPeer‘ INT NOT NULL ,
        ‘IP‘ VARCHAR(45) NOT NULL ,
        ‘PORT‘ INT NOT NULL ,
        PRIMARY KEY (‘idPeer‘) )
Motivation                           Introducing Remorseful                         Summary
...                                   .
..                                    ......


                                    EER Diagram
              Record
                                                                Plan
             idRecord INT
                                                               idPlan INT
             Service TINYTEXT
                                         User                  PlanTitle TINYTEXT
             ConnTime DATETIME
                                       idUser INT              Bandwidth LONG
             DisconnTime DATETIME
                                       UserName TINYTEXT       Connection INT
             IP TINYTEXT
                                       Password TINYTEXT       Hidden BOOL
             BandwidthUp LONG
                                       Email TINYTEXT          MonthlyFee INT
             BandwidthDown LONG
                                       Contact TINYTEXT       Indexes
             User INT
                                       Credit INTEGER         PRIMARY
        Indexes
                                       Banned BOOL
        PRIMARY
                                       Plan INT                  Payment
        User
                                      Indexes                   idPayment INT
                                      PRIMARY                   User INT
              Peer                    UserName_UNIQUE
                                                                Via TINYTEXT
         idPeer INT                   Plan
                                                                Amount INT
         IP VARCHAR(45)
                                                                TIME DATETIME
         PORT INT
                                                              Indexes
        Indexes
                                                              PRIMARY
        PRIMARY
                                                              User



      Created with MySQL Workbench 5.2.34
Motivation                             Introducing Remorseful   Summary
...                                     .
..                                      ......


                             Summary: Remorseful




             • Consistent Front-End and Back-End
             • mongoDB for K-V Store, Distributed
             • 5 Tables, or 5 Models

      Any Questions?
Appendix
.



                       Remorseful online




      Released under GPL v3, and online at
      http://github.com/multiple1902/remorseful

Weitere ähnliche Inhalte

Ähnlich wie Design of Remorseful

Python business intelligence (PyData 2012 talk)
Python business intelligence (PyData 2012 talk)Python business intelligence (PyData 2012 talk)
Python business intelligence (PyData 2012 talk)Stefan Urbanek
 
Apache Pinot Meetup Sept02, 2020
Apache Pinot Meetup Sept02, 2020Apache Pinot Meetup Sept02, 2020
Apache Pinot Meetup Sept02, 2020Mayank Shrivastava
 
CouchApps: Requiem for Accidental Complexity
CouchApps: Requiem for Accidental ComplexityCouchApps: Requiem for Accidental Complexity
CouchApps: Requiem for Accidental ComplexityFederico Galassi
 
Data Democratization at Nubank
 Data Democratization at Nubank Data Democratization at Nubank
Data Democratization at NubankDatabricks
 
Resdk java custo_webi_dg
Resdk java custo_webi_dgResdk java custo_webi_dg
Resdk java custo_webi_dgkilbull
 
Debugging a .NET program after crash (Post-mortem debugging)
Debugging a .NET program after crash (Post-mortem debugging)Debugging a .NET program after crash (Post-mortem debugging)
Debugging a .NET program after crash (Post-mortem debugging)Mirco Vanini
 
Pspice userguide ingles
Pspice userguide inglesPspice userguide ingles
Pspice userguide inglesunoenero
 
Microservices designing deploying
Microservices designing deployingMicroservices designing deploying
Microservices designing deployingSuresh Kumar
 
Microservices designing deploying
Microservices designing deployingMicroservices designing deploying
Microservices designing deployingtranhieu5959
 
Microservices_Designing_Deploying.pdf
Microservices_Designing_Deploying.pdfMicroservices_Designing_Deploying.pdf
Microservices_Designing_Deploying.pdfBinh Ng
 
Microservices designing deploying
Microservices designing deployingMicroservices designing deploying
Microservices designing deployinggaurav shukla
 
BDD - Buzzword Driven Development - Build the next cool app for fun and for.....
BDD - Buzzword Driven Development - Build the next cool app for fun and for.....BDD - Buzzword Driven Development - Build the next cool app for fun and for.....
BDD - Buzzword Driven Development - Build the next cool app for fun and for.....Michele Orselli
 
BDD - Buzzword Driven Development - Build the next cool app for fun and for.....
BDD - Buzzword Driven Development - Build the next cool app for fun and for.....BDD - Buzzword Driven Development - Build the next cool app for fun and for.....
BDD - Buzzword Driven Development - Build the next cool app for fun and for.....Alessandro Cinelli (cirpo)
 
KVSの性能、RDBMSのインデックス、更にMapReduceを併せ持つAll-in-One NoSQL: MongoDB
KVSの性能、RDBMSのインデックス、更にMapReduceを併せ持つAll-in-One NoSQL: MongoDB KVSの性能、RDBMSのインデックス、更にMapReduceを併せ持つAll-in-One NoSQL: MongoDB
KVSの性能、RDBMSのインデックス、更にMapReduceを併せ持つAll-in-One NoSQL: MongoDB Rakuten Group, Inc.
 

Ähnlich wie Design of Remorseful (20)

CDI and Weld
CDI and WeldCDI and Weld
CDI and Weld
 
Python business intelligence (PyData 2012 talk)
Python business intelligence (PyData 2012 talk)Python business intelligence (PyData 2012 talk)
Python business intelligence (PyData 2012 talk)
 
Ds8800 plan guide
Ds8800 plan guideDs8800 plan guide
Ds8800 plan guide
 
Apache Pinot Meetup Sept02, 2020
Apache Pinot Meetup Sept02, 2020Apache Pinot Meetup Sept02, 2020
Apache Pinot Meetup Sept02, 2020
 
CouchApps: Requiem for Accidental Complexity
CouchApps: Requiem for Accidental ComplexityCouchApps: Requiem for Accidental Complexity
CouchApps: Requiem for Accidental Complexity
 
Data Democratization at Nubank
 Data Democratization at Nubank Data Democratization at Nubank
Data Democratization at Nubank
 
Book Getting Started Src
Book Getting Started SrcBook Getting Started Src
Book Getting Started Src
 
Db2
Db2Db2
Db2
 
Resdk java custo_webi_dg
Resdk java custo_webi_dgResdk java custo_webi_dg
Resdk java custo_webi_dg
 
Debugging a .NET program after crash (Post-mortem debugging)
Debugging a .NET program after crash (Post-mortem debugging)Debugging a .NET program after crash (Post-mortem debugging)
Debugging a .NET program after crash (Post-mortem debugging)
 
Pspice userguide ingles
Pspice userguide inglesPspice userguide ingles
Pspice userguide ingles
 
Openobject bi
Openobject biOpenobject bi
Openobject bi
 
Nu229 a00mr
Nu229 a00mrNu229 a00mr
Nu229 a00mr
 
Microservices designing deploying
Microservices designing deployingMicroservices designing deploying
Microservices designing deploying
 
Microservices designing deploying
Microservices designing deployingMicroservices designing deploying
Microservices designing deploying
 
Microservices_Designing_Deploying.pdf
Microservices_Designing_Deploying.pdfMicroservices_Designing_Deploying.pdf
Microservices_Designing_Deploying.pdf
 
Microservices designing deploying
Microservices designing deployingMicroservices designing deploying
Microservices designing deploying
 
BDD - Buzzword Driven Development - Build the next cool app for fun and for.....
BDD - Buzzword Driven Development - Build the next cool app for fun and for.....BDD - Buzzword Driven Development - Build the next cool app for fun and for.....
BDD - Buzzword Driven Development - Build the next cool app for fun and for.....
 
BDD - Buzzword Driven Development - Build the next cool app for fun and for.....
BDD - Buzzword Driven Development - Build the next cool app for fun and for.....BDD - Buzzword Driven Development - Build the next cool app for fun and for.....
BDD - Buzzword Driven Development - Build the next cool app for fun and for.....
 
KVSの性能、RDBMSのインデックス、更にMapReduceを併せ持つAll-in-One NoSQL: MongoDB
KVSの性能、RDBMSのインデックス、更にMapReduceを併せ持つAll-in-One NoSQL: MongoDB KVSの性能、RDBMSのインデックス、更にMapReduceを併せ持つAll-in-One NoSQL: MongoDB
KVSの性能、RDBMSのインデックス、更にMapReduceを併せ持つAll-in-One NoSQL: MongoDB
 

Kürzlich hochgeladen

Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUK Journal
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slidevu2urc
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Servicegiselly40
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxKatpro Technologies
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Igalia
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024Results
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Scriptwesley chun
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?Antenna Manufacturer Coco
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Enterprise Knowledge
 

Kürzlich hochgeladen (20)

Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 

Design of Remorseful

  • 1. Motivation Introducing Remorseful Summary ... . .. ...... Design of Remorseful A Distributed User Management and Authentication Solution Weisi Dai (09055029) Department of Computer Science and Technology Xi’an Jiaotong University Mar 14, 2012
  • 2. Motivation Introducing Remorseful Summary ... . .. ...... Outline Motivation The Basic Problem That I Studied Previous Work Introducing Remorseful Technical Details Object Models
  • 3. Motivation Introducing Remorseful Summary ... . .. ...... Distributed User Authentication Solution • mongoDB • HTML5 • Javascript • Application Roles • Users • Administrator(s)
  • 4. Motivation Introducing Remorseful Summary ... . .. ...... Roles Users • Register • Pay • Choose Plan • Log in via clients Administrator(s) • Add and ban users • Add and edit plans • Add and modify peer servers info
  • 5. Motivation Introducing Remorseful Summary ... . .. ...... We need a(n) solution • Simple • Effective • No Single-point Failure!
  • 6. Motivation Introducing Remorseful Summary ... . .. ...... RADIUS abbr for Remote Authentication Dial In User System, RFC2865 • Complete Solution, both Commercial and Free • Our NIC uses that! • Designed for Accounting in Telecommunication Industry • Very very heavily used! • Complicated
  • 7. Motivation Introducing Remorseful Summary ... . .. ...... MagiAdmin and OVpnUsrMng MagiAdmin, by Aveline Swan • PHP-based • Not Scalable • Not So Fault-Tolerant • Not Open-Source OVpnUsrMng • Python And Django based • SQLite as Database • Not So Scalable
  • 8. Motivation Introducing Remorseful Summary ... . .. ...... Perfect Combination, Simple and Scalable Database: mongoDB K-V Store, NOSQL Web: Node.js Javascript on the Server Side OS: Unix like
  • 9. Motivation Introducing Remorseful Summary ... . .. ...... User CREATE TABLE IF NOT EXISTS ‘Remorseful‘.‘User‘ ( ‘idUser‘ INT NOT NULL , ‘UserName‘ TINYTEXT NOT NULL , ‘Password‘ TINYTEXT NOT NULL , ‘Email‘ TINYTEXT NOT NULL , ‘Contact‘ TINYTEXT NULL , ‘Credit‘ INT(11) NOT NULL , ‘Banned‘ TINYINT(1) NOT NULL , ‘Plan‘ INT NULL , PRIMARY KEY (‘idUser‘, ‘UserName‘) , UNIQUE INDEX ‘UserName_UNIQUE‘ (‘UserName‘ ASC) , INDEX ‘Plan‘ (‘Plan‘ ASC) , CONSTRAINT ‘Plan‘ FOREIGN KEY (‘Plan‘ ) REFERENCES ‘Remorseful‘.‘Plan‘ (‘idPlan‘ ) ON DELETE NO ACTION
  • 10. Motivation Introducing Remorseful Summary ... . .. ...... Plan CREATE TABLE IF NOT EXISTS ‘Remorseful‘.‘Plan‘ ( ‘idPlan‘ INT NOT NULL , ‘PlanTitle‘ TINYTEXT NOT NULL , ‘Bandwidth‘ INT NOT NULL , ‘Connection‘ INT NOT NULL , ‘MonthlyFee‘ INT NOT NULL , ‘Hidden‘ TINYINT(1) NOT NULL , PRIMARY KEY (‘idPlan‘, ‘PlanTitle‘) )
  • 11. Motivation Introducing Remorseful Summary ... . .. ...... Record CREATE TABLE IF NOT EXISTS ‘Remorseful‘.‘Record‘ ( ‘idRecord‘ INT NOT NULL , ‘Service‘ TINYTEXT NOT NULL , ‘ConnTime‘ DATETIME NOT NULL , ‘DisconnTime‘ DATETIME NULL , ‘IP‘ TINYTEXT NOT NULL , ‘BandwidthUp‘ MEDIUMTEXT NULL , ‘BandwidthDown‘ MEDIUMTEXT NULL , ‘User‘ INT NOT NULL , PRIMARY KEY (‘idRecord‘) , INDEX ‘User‘ (‘User‘ ASC) , CONSTRAINT ‘User‘ FOREIGN KEY (‘User‘ ) REFERENCES ‘Remorseful‘.‘User‘ (‘idUser‘ ) ON DELETE NO ACTION ON UPDATE NO ACTION)
  • 12. Motivation Introducing Remorseful Summary ... . .. ...... Payment CREATE TABLE IF NOT EXISTS ‘Remorseful‘.‘Payment‘ ( ‘idPayment‘ INT NOT NULL , ‘User‘ INT NOT NULL , ‘Via‘ TINYTEXT NOT NULL , ‘Amount‘ INT NOT NULL , ‘TIME‘ DATETIME NOT NULL DEFAULT now() , PRIMARY KEY (‘idPayment‘) , INDEX ‘User‘ (‘User‘ ASC) , CONSTRAINT ‘User‘ FOREIGN KEY (‘User‘ ) REFERENCES ‘Remorseful‘.‘User‘ (‘idUser‘ ) ON DELETE NO ACTION ON UPDATE NO ACTION)
  • 13. Motivation Introducing Remorseful Summary ... . .. ...... Peer CREATE TABLE IF NOT EXISTS ‘Remorseful‘.‘Peer‘ ( ‘idPeer‘ INT NOT NULL , ‘IP‘ VARCHAR(45) NOT NULL , ‘PORT‘ INT NOT NULL , PRIMARY KEY (‘idPeer‘) )
  • 14. Motivation Introducing Remorseful Summary ... . .. ...... EER Diagram Record Plan idRecord INT idPlan INT Service TINYTEXT User PlanTitle TINYTEXT ConnTime DATETIME idUser INT Bandwidth LONG DisconnTime DATETIME UserName TINYTEXT Connection INT IP TINYTEXT Password TINYTEXT Hidden BOOL BandwidthUp LONG Email TINYTEXT MonthlyFee INT BandwidthDown LONG Contact TINYTEXT Indexes User INT Credit INTEGER PRIMARY Indexes Banned BOOL PRIMARY Plan INT Payment User Indexes idPayment INT PRIMARY User INT Peer UserName_UNIQUE Via TINYTEXT idPeer INT Plan Amount INT IP VARCHAR(45) TIME DATETIME PORT INT Indexes Indexes PRIMARY PRIMARY User Created with MySQL Workbench 5.2.34
  • 15. Motivation Introducing Remorseful Summary ... . .. ...... Summary: Remorseful • Consistent Front-End and Back-End • mongoDB for K-V Store, Distributed • 5 Tables, or 5 Models Any Questions?
  • 16. Appendix . Remorseful online Released under GPL v3, and online at http://github.com/multiple1902/remorseful