Commit 50b069a1 authored by ale's avatar ale

Do not ignore DeviceInfo if 'id' is not set

Some services (e.g. smtp auth) don't provide us with a device ID.
Ignoring the rest of the information, such as the IP, prevents ratelimits
and blacklists from working.
parent ffc5d879
Pipeline #5557 passed with stages
in 1 minute and 34 seconds
......@@ -34,9 +34,6 @@ func (d *DeviceInfo) encodeToMap(m map[string]string, prefix string) {
func decodeDeviceInfoFromMap(m map[string]string, prefix string) *DeviceInfo {
if _, ok := m[prefix+"id"]; !ok {
return nil
return &DeviceInfo{
ID: m[prefix+"id"],
RemoteAddr: m[prefix+"remote_addr"],
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment