Follow linter advices

Signed-off-by: Knut Ahlers <knut@ahlers.me>
This commit is contained in:
Knut Ahlers 2017-08-03 20:12:15 +02:00
parent 0e64f3950f
commit 2ace4a3f7b
Signed by: luzifer
GPG key ID: DC2729FDD34BE99E
2 changed files with 6 additions and 1 deletions

View file

@ -1,3 +1,8 @@
![](https://badges.fyi/github/license/Luzifer/ots)
![](https://badges.fyi/github/latest-release/Luzifer/ots)
![](https://badges.fyi/github/downloads/Luzifer/ots)
[![Go Report Card](https://goreportcard.com/badge/github.com/Luzifer/ots)](https://goreportcard.com/report/github.com/Luzifer/ots)
# Luzifer / OTS # Luzifer / OTS
`ots` is a one-time-secret sharing platform. The secret is encrypted with a symmetric 256bit AES encryption in the browser before being sent to the server. Afterwards an URL containing the ID of the secret and the password is generated. The password is never sent to the server so the server will never be able to decrypt the secrets it delivers with a reasonable effort. Also the secret is immediately deleted on the first read. `ots` is a one-time-secret sharing platform. The secret is encrypted with a symmetric 256bit AES encryption in the browser before being sent to the server. Afterwards an URL containing the ID of the secret and the password is generated. The password is never sent to the server so the server will never be able to decrypt the secrets it delivers with a reasonable effort. Also the secret is immediately deleted on the first read.

View file

@ -65,7 +65,7 @@ func assetDelivery(res http.ResponseWriter, r *http.Request) {
assetName = "/index.html" assetName = "/index.html"
} }
ext := assetName[strings.LastIndex(assetName, "."):len(assetName)] ext := assetName[strings.LastIndex(assetName, "."):]
assetData, err := Asset(path.Join("frontend", assetName)) assetData, err := Asset(path.Join("frontend", assetName))
if err != nil { if err != nil {
http.Error(res, "404 not found", http.StatusNotFound) http.Error(res, "404 not found", http.StatusNotFound)