1
0
mirror of https://github.com/labstack/echo.git synced 2024-11-24 08:22:21 +02:00
Commit Graph

20 Commits

Author SHA1 Message Date
toimtoimtoim
626f13e338 CSRF/RequestID mw: switch math/random usage to crypto/random 2023-07-21 13:10:56 +03:00
Mojtaba Arezoumand
d77e8c09b2
Added ErrorHandler and ErrorHandlerWithContext in CSRF middleware (#2257)
* feat: add error handler to csrf middleware

Co-authored-by: Mojtaba Arezoomand <mojtaba.arezoomand@snapp.cab>
2022-09-01 10:51:55 +03:00
Martti T
4a1ccdfdc5
JWT, KeyAuth, CSRF multivalue extractors (#2060)
* CSRF, JWT, KeyAuth middleware support for multivalue value extractors
* Add flag to JWT and KeyAuth middleware to allow continuing execution `next(c)` when error handler decides to swallow the error (returns nil).
2022-01-24 22:03:45 +02:00
Martti T
a4ab482b60
Add Go 1.16 to CI and drop 1.12 specific code (#1850)
* Correct incorrect years in CHANGELOG.md
* CI tests with last 4 versions. Remove 1.12 and below specific code
* Rename proxy test
2021-04-16 11:38:12 +02:00
Roland Lammel
c7c792d3bd Fix CSRF tests for Go 1.12 2021-01-03 01:45:58 +01:00
Roland Lammel
4310e90d58 Support Go 1.12 for http.SameSiteNoneMode 2021-01-03 01:09:18 +01:00
Vadim Sabirov
dc147d9b97 Fix #1523 by adding secure cookie if SameSite mode is None 2020-12-03 10:21:31 +03:00
Vadim Sabirov
8b2c77b107 Fix #1523 by adding SameSite mode for CSRF settings 2020-03-04 18:14:23 +03:00
Alex Ungur
6d9e043284 Introduced Go module support as v4, removed obsolete CloseNotifier() mechanism
This reintroduces support for Go modules, as v4.

CloseNotifier() is removed as it has been obsoleted, see https://golang.org/doc/go1.11#net/http

It was already NOT working (not sending signals) as of 1.11 the functionality was gone, we merely
deleted the functions that exposed it. If anyone still relies on it they should migrate to using
`c.Request().Context().Done()` instead.

Closes #1268, #1255
2019-01-30 16:11:42 +02:00
Emir Ribić
c8fd197fa8 Replace http constants with stdlib ones, i.e.: http.MethodGet instead of echo.GET (#1205) 2018-10-14 20:46:58 +05:30
Vishal Rana
434f4d1ae8 Fixed #990
Signed-off-by: Vishal Rana <vr@labstack.com>
2017-12-28 10:41:13 -08:00
Vishal Rana
cb9255e775 Using httptest
Signed-off-by: Vishal Rana <vr@labstack.com>
2017-05-13 15:44:27 -07:00
Diego Siqueira
d67c6f029c Underscoring unnecessary variables on CSRF test (#836) 2017-04-01 09:29:12 -07:00
Vishal Rana
29fd5831ff Fixed test
Signed-off-by: Vishal Rana <vr@labstack.com>
2017-02-22 15:57:12 -08:00
Vishal Rana
2aec0353f5 First commit to v3, #665
Signed-off-by: Vishal Rana <vr@labstack.com>
2016-09-22 22:56:00 -07:00
Vishal Rana
579cb79a41 Using random string from gommon
Signed-off-by: Vishal Rana <vr@labstack.com>
2016-07-18 23:24:50 -07:00
Vishal Rana
0dab439ea4 Fixed #600
Signed-off-by: Vishal Rana <vr@labstack.com>
2016-07-16 20:13:27 -07:00
Vishal Rana
98d744b8fb Fixed #597 (#598)
Signed-off-by: Vishal Rana <vr@labstack.com>
2016-07-13 16:55:46 -07:00
Vishal Rana
c654c422c4 More coverage and better response adapter for standard/response
Signed-off-by: Vishal Rana <vr@labstack.com>
2016-06-06 22:27:36 -07:00
Vishal Rana
98dd8bf9e9 Added CSRF middleware, #341.
Signed-off-by: Vishal Rana <vr@labstack.com>
2016-05-12 17:45:00 -07:00