Closed cremesk closed 2 years ago
Hey @cremesk
Sorry, I have been slacking on my projects so I didn't see this. Right now, you could use leveldb-cli or similar to remove them, however, that might be tedious because there will be a lot of records to remove. I plan to remove leveldb support and fix up sqlite support (sqlite is broken right now), and I'll add in an endpoint to delete a user. I should probably also add in an endpoint to accept an existing user list to make it easy to migrate... preserving add date etc.
I could probably hack something in sooner to delete a user.
@cremesk I'm starting on this now. I'll add an endpoint for an administrator to use to delete a user. It'll be hacky, but I need to overhaul a good bit of this so I don't mind doing a hacky patch for this to get it working.
hi @gbmor , thanks for your effort and also sorry for my late reply. I tried to use leveldb-cli but that seems kind of broken and is not executable.
@cremesk OK, it's merged in.
There's a new config file field AdminPassword
(just below DatabasePath
in the provided default config), be sure to change it or getwtxt won't start.
Then:
$ curl -X DELETE -H 'X-Auth: mypassword' 'https://twtxt.envs.net/api/admin/users?url=http://example.com/twtxt.txt'
200 OK
Also the makefile should chmod 600
your existing config file but double check it after just to make sure everyone can't see the admin password
Lemme know when you have it set up and I'll close this.
wow thank you ben! It works quite excellently here on my site!
also the update ran without problems ;)
hi,
how can i delete a user entry?
i use leveldb.