gtsocial-umbx

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README | LICENSE

commit 7e6350b44807d55e678e7e88b74cff258ef98425
parent ffc55e9b15461c47f0fc38bb53495026bace10e8
Author: tobi <31960611+tsmethurst@users.noreply.github.com>
Date:   Tue, 21 Sep 2021 11:40:16 +0200

remove hardcoded friendica user agent block (#239)


Diffstat:
Minternal/api/security/useragentblock.go | 7-------
1 file changed, 0 insertions(+), 7 deletions(-)

diff --git a/internal/api/security/useragentblock.go b/internal/api/security/useragentblock.go @@ -20,7 +20,6 @@ package security import ( "net/http" - "strings" "github.com/gin-gonic/gin" "github.com/sirupsen/logrus" @@ -38,10 +37,4 @@ func (m *Module) UserAgentBlock(c *gin.Context) { c.AbortWithStatus(http.StatusTeapot) return } - - if strings.Contains(strings.ToLower(ua), strings.ToLower("friendica")) { - l.Debugf("aborting request with user-agent %s because it contains 'friendica'", ua) - c.AbortWithStatus(http.StatusTeapot) - return - } }