Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IP Sorting range issues #99

Closed
barryboom opened this issue Nov 7, 2021 · 2 comments
Closed

IP Sorting range issues #99

barryboom opened this issue Nov 7, 2021 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@barryboom
Copy link

Describe The Problem
When using the sort peers by Allowed IP it seems to fail to recognise early / single digit IPs as attached

instead of going 10.1.1.1 , 10.1.1.2 it seems to start at 10.1.1.10 then place 10.1.1.2 and the start of the .20 ranges

screenshots attached

To Reproduce
server with maybe 20+ like mine i have over 50 Peers, change to sort peers by Allowed IPs then review sequeance

OS Information:

  • OS: [e.g. Ubuntu 20.04.3]
  • Python Version: [e.g v3.7]

Sample of your .conf file

Please provide a sample of your configuration file that you are having problem with. You can replace your public key and private key to ABCD...

[Interface]
PrivateKey = ABCDEFGHIJKLMNOP=
Address = 10.9.0.6/24
DNS = 8.8.8.8,8.8.4.4
[Peer]
PublicKey = ABCDEFGHIJKLMNOP=
AllowedIPs = 0.0.0.0/0, ::/0
Endpoint = MYSERVERIP:52080
PersistentKeepalive = 25
AlllowedIP
AllowedIPsorting

@barryboom barryboom added the bug Something isn't working label Nov 7, 2021
@donaldzou
Copy link
Owner

Hi, sorry for the super late reply. I used the sort function in Python and I believe it will sort it in lexicographic order. I will fix this in the next major release.

@donaldzou donaldzou self-assigned this Nov 19, 2021
@donaldzou donaldzou reopened this Dec 22, 2021
@donaldzou
Copy link
Owner

This issue has been solved in the next release ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants