tech5usa / TLSential

A server for providing short-lived TLS certificates to all services within a firewall restricted network.
GNU General Public License v3.0
15 stars 2 forks source link

Refactor certificate and user GET/DELETE methods. Add DELETE api/certifacte routes #41

Closed debus closed 4 years ago

debus commented 4 years ago

Relies on https://github.com/ImageWare/TLSential/pull/40 due to changes in api/api.go Addresses https://github.com/ImageWare/TLSential/issues/38

This PR addresses the following issues:

adding DELETE /api/certificate and DELETE /api/certificate/{id} routes Splitting up certificate.Delete into Delete and DeleteAll Same for user.Delete and user.Get

Testing

Hit the URLs and made sure the responses were sane. DELETE /api/certificate => No Content DELETE /api/certificate/someid => 404 GET /api/user => [{my_user}] GET /api/user/my_user => {my_user} GET /api/user/my_user_but_not => 404 DELETE /api/user/my_user_but_not => 404 DELETE /api/user => No Content

d1str0 commented 4 years ago

Lgtm