Patching because I have other things to do but basically this diff at line 20 shows that even though self.secret was assigned toa string value, it was still being given the type of tuple with the first/only item being the string value
I have no idea how this was happeneing but its fixed as of now
* also im ignoring the cargo_bin flag in the environment for now as its just causing issues while debugging
+ Turning _make_requests into a lower level driver which now creates Response types with its own self.url now
+ Request.make is now smarter and uses its own state to dispatch the proper request
Emits a respective Response object as well
start_time >= end_time
Which means we won't get weird requests from clients anymore(hopefully)
* Route handler for /message/time_range now handles db::Response::RestrictedInput
Responds with a simple 400 and nothing else
Should make it more dsecriptive with really weird input and prevent even more confusing 500 responses to the client
+ db-lib::Channels::add now also potentially returns this new RestrictedInput variant
* Refactored serde facing puller functions to be more clear
- Removing incorrect commentary
* Changed login handler to start using mysql based api
! Further refactoring in the previous to be more readable
This is only initialized once and is read only after the fact so it should be fine
2. Adding a Claim struct that all JWT's will use for their structure. A helpful .new() function is provided
3. AuthReason::ServerIssue(String) is a now a thing
Should help the auth module be more clear in what's going on
4. fn get_jwt_json -> renamed from get_jwt to indicate we're getting something from json payload. Nothing more
5. async fn valid_jwt: Attempts to decode the given token, if successful it then looks if that user has given us an active jwt budget-session-key if (returns boolean)
6. wall_entry now returns an AuthReason without the sql wrapping, since thats db-lib's problem anyway
Also we're collecting all data upfront then verifying it as we go.
7. async fn login_get_jwt::ROUTE
On login_auth here we simply create a JWT for the user, store it in cache, then give it back to the user to use.
Tokens take a week to expire
8. Removed busted tests that weren't doing anything useful for the time being