CS5331 Submission#20
Open
luyangkenneth wants to merge 60 commits into
Open
Conversation
…oint * Added backend Sqlite3 database. The database file will be located at `/src/service/database.db` when docker initializes the application. * Added schema declaration for `users` table. * Added database initialization, setup and teardown. * Added implementation for `/users/register` API endpoint. * Changed `/src/service/team_members.txt`. * Changed `/README.md` filling up some parts.
…ries. Also added relevant CSS and JS files.
* Added some debug print statements * Fixed user created to return 201 Created
* Added implementation for `/users/authenticate` endpoint * Added `tokens` table into database schema * Added Postman collection at `/src/service/postman_collection.json` to test API according to specification * Changed provided `make_json_response()` helper function into more general form
* Updated Postman colleciton so that testing is more seamless
* Added Postman test cases for newly implemented endpoint * Changed schema for `tokens` table to reference `users` table
…ded logout functionality. Added authenticated user menu
…ded logout functionality. Added authenticated user menu
* Request to `/users/expire` with an expired token now returns false status * Updated Postman collection with expired token test cases
* sqlite3 BOOLEAN type is equivalent to INTEGER where 0 is false and 1 is true
… / user authentication functions * Added implementation of `/diary/create` endpoint * Added common token validation function * Added `diary_entries` schema. Note that `text` is a reserved keyword, must be double quoted
* Changed `diary_entries` schema to include username. Doh! * Changed `validate_token` helper function to return username as well
* `publish_date` is stored as a string in ISO8601 format with microseconds truncated
…ted users * Added custom sqlite3 adapters to convert bool (python) to BOOLEAN (sqlite3) and back * Added Postman test cases for newly implemented endpoints
* Changed `diary/create` endpoint to return new diary entry id as `result` attribute as per specifications * Added respective Postman test cases
…on validations * Added validation helper functions for diary entry id and public value * Added response helper functions for validation failure of id and public values * Added Postman test cases for implemented endpoint
* Added installation of python2 bcrypt module to Dockerfile * Changed `users` table password attribute to reflect as hashed_password * Implemented bcrypt hashed password and comparison with default rounds=12
* Answered couple of README questions
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
ad14e1017873fe5c989eab1572079977e561683fa1fe4fbd6dc32d7ba9d9a023