Skip to content
Snippets Groups Projects
Select Git revision
1 result Searching

endpoint.py

  • Moul's avatar
    11444356
    [fix] #170: endpoint: Fix ipv4/host attributes mix up · 11444356
    Moul authored
    In case only an IPv4 is present, the latter ends up in server/host attribute
    Since HOST_REGEX is using dots, the IPv4 is matched as a host
    
    Only happening to BMA(S) and GVA since the other endpoints' regex are
    using one among (host|ipv6|ipv4)
    
    Use ipaddress as a trick after regex matching to
    switch ipv4 and server/host attributes
    11444356
    History
    [fix] #170: endpoint: Fix ipv4/host attributes mix up
    Moul authored
    In case only an IPv4 is present, the latter ends up in server/host attribute
    Since HOST_REGEX is using dots, the IPv4 is matched as a host
    
    Only happening to BMA(S) and GVA since the other endpoints' regex are
    using one among (host|ipv6|ipv4)
    
    Use ipaddress as a trick after regex matching to
    switch ipv4 and server/host attributes