You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2019/11/21 10:26:25 UTC

[GitHub] [pulsar] fanyunbojerry opened a new pull request #5713: avoid unsafe split when validate hostname which might be ipv6 address

fanyunbojerry opened a new pull request #5713: avoid unsafe split when validate hostname which might be ipv6 address
URL: https://github.com/apache/pulsar/pull/5713
 
 
   <!--
   ### Contribution Checklist
     
     - Name the pull request in the form "[Issue XYZ][component] Title of the pull request", where *XYZ* should be replaced by the actual issue number.
       Skip *Issue XYZ* if there is no associated github issue for this pull request.
       Skip *component* if you are unsure about which is the best component. E.g. `[docs] Fix typo in produce method`.
   
     - Fill out the template below to describe the changes contributed by the pull request. That will give reviewers the context they need to do the review.
     
     - Each pull request should address only one issue, not mix up code from multiple issues.
     
     - Each commit in the pull request has a meaningful commit message
   
     - Once all items of the checklist are addressed, remove the above text and this checklist, leaving only the filled out template below.
   
   **(The sections below can be removed for hotfixes of typos)**
   -->
   
   ### Motivation
   Pulsar doesn't support deploy on IPv6 network environment.
   This PR just makes an effort to make it.
   The error happens if the client connect to brokers by IPv6 address, like fec0:0:0:ffff::1.
   - Wrong format: fec0:0:0:ffff::1:6650
   - Correct format: [fec0:0:0:ffff::1]:6650
   
   Cause the split regex is ':', brackets are needed and the ip:port can't split by ':' directly.
   
   ### Modifications
   
   validateHostName in ServiceURI
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services