eigenkarmanetwork / EKN

EigenKarma Network API
MIT License
6 stars 1 forks source link

Implement approval log #4

Open tayler6000 opened 2 years ago

tayler6000 commented 2 years ago

To help mitigate issues of misbehaving services/connections with #3, a separate SQLite database will be created that will store a permanent log of every action performed by an account, and an approval log.

The approval log will show every event performed by a user and will give them a chance to approve it if the action was legitimate, or reverse and flag it if it was fraudulent. After an event is approved or flagged it is removed from the approval log, and the approval or flagging is added to the permanent log. Flagging will be raised to an administrator's attention automatically through some means.

plexish commented 2 years ago

Will the votes be counted by default until approved?

tayler6000 commented 2 years ago

Will the votes be counted by default until approved?

Votes will be effective immediately but can be reversed if flagged in the approval log. If they're approved, nothing will happen except taking it out of the approval log and adding it to the total log.

mruwnik commented 1 year ago

why a separate SQLite database, rather than an additional table?

tayler6000 commented 1 year ago

I think it was my initial instinct to make it a separate database altogether to make sure that it wasn't susceptible to any SQL injection, and could be a true permanent record only capable of additional rows. Currently, I see no reason why it needs to be its own db and not just a separate table. @plexish do you remember if I/we had a specific reasoning for it being a separate db?

plexish commented 1 year ago

No relevant memories found.