Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/dalf/cryptcheck-backend


https://github.com/dalf/cryptcheck-backend

Last synced: 10 days ago
JSON representation

Awesome Lists containing this project

README

        

Web server to run [cryptcheck](https://github.com/aeris/cryptcheck), without scheduling, database, cache.

Provide one API similar to the one cryptcheck.fr:
* ```/https/.json```
* ```/https/:.json```

Result:
* If there is no error, a similar JSON structure is returned.
```json
{"service":"https",
"host":"",
"pending":false,
"result": ,
"created_at": "",
"updated_at": "",
"args": 443}
```
* If one argument is invalid, the HTTP status code is 400, a json
```json
{"status":400,"error":"Invalid port","error_message":" is not a number"}
```
* If cryptcheck triggers an exception, the HTTP status code is 503:
```json
{"status":503,"error":"Address not available","error_message":"Address not available - connect(2) for []:443"}
```
* If the host don't have an IPv6 connectivity:
```json
{"service":"https","host":"","pending":false,"result":[{"hostname":"","port":443,"error":"Network unreachable - connect(2) for []:443"}],"created_at":"","updated_at":"","args":443}
```

# Build docker image

```sh
make docker-build
```

# Run docker image

```sh
make docker-run
```

Or
```sh
docker run --rm -p 7000:7000 dalf/cryptcheck-backend:latest -o 0.0.0.0
```