Commit Graph

9 Commits

Author SHA1 Message Date
taciomcosta
10ff4eecef
Backend: fix IPv6 address parsing erroneous (#28585)
* Backend: Fix parsing of client IP address

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

Co-authored-by: Arve Knudsen <arve.knudsen@gmail.com>
2020-11-25 07:55:22 +01:00
Arve Knudsen
574553ec7b
Chore: Fix issues found by staticcheck (#28802)
* Fix linting issues

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>
2020-11-05 11:29:39 +01:00
Emil Tullstedt
d664853179
Tests: Change util GoConvey tests to use testify (#26724) 2020-08-13 11:10:48 +02:00
Arve Knudsen
16c185c3b9
Chore: Drop xerrors dependency (#26718)
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>
2020-07-31 09:45:20 +02:00
Sofia Papagiannaki
886bad2fd5
Util: Modify SplitHostPortDefault not to return an error for empty input (#20351)
* Util: Optionally allow empty input in SplitHostPortDefault

Due to a recent change the SQL Server tests failed because passing an
empty datasource url in `util.SplitHostPortDefault` was no more allowed.
This fix contains the following modifications:
- Modifies the util.SplitHostPortDefault not to return an error for empty input.
- Modifies the util.SplitHostPort to return an error for empty input.
- Introduces an additional test for empty input.
2019-11-18 10:42:51 +02:00
Arve Knudsen
b858a5f496
Don't truncate IPv6 addresses (#19573)
* Bugfix: Fix parsing of IPv6 addresses

Make sure that IPv6 addresses aren't truncated when parsing. Fixes #18924
* util: Change network address parsing funcs to return error
* pkg/api: Return NetworkAddress instead of host/port
2019-10-09 08:58:45 +02:00
Marcus Efraimsson
d433ca7d40
fix util for splitting host and port
Now you can provide both a default host and a default port
2019-02-04 13:10:32 +01:00
Marcus Efraimsson
0495499b4f
fix ip address parsing of loopback address 2019-01-21 10:20:23 +01:00
Marcus Efraimsson
e08f61059b
utils 2019-01-15 15:16:20 +01:00