Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 13 May 2014 10:00:01 GMT
From:      Dennis Yusupoff <dyr@smartspb.net>
To:        freebsd-bugs@FreeBSD.org
Subject:   Re: bin/189471: ipfw table regression
Message-ID:  <201405131000.s4DA01ts033021@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help
The following reply was made to PR bin/189471; it has been noted by GNATS.

From: Dennis Yusupoff <dyr@smartspb.net>
To: bycn82 <bycn82@gmail.com>, bug-followup@FreeBSD.org
Cc:  
Subject: Re: bin/189471: ipfw table regression
Date: Tue, 13 May 2014 13:58:11 +0400

 This is a multi-part message in MIME format.
 --------------060309080704020200020902
 Content-Type: text/plain; charset=ISO-8859-1
 Content-Transfer-Encoding: 7bit
 
 OK, I will try.
 
 I think it's a time to add "helper" argument to *ipfw table add* command
 so that you could set data type explicity, is it IPv6 or IPv4. Something
 like that:
 
 ipfw table XX add beef.de ipv6
 ipfw table XX add beef.de ipv4
 
 AFAIK, it greatly reduce complexity of programming attempt to guess what
 kind of input data user meant.
 
 13.05.2014 10:45, bycn82 ?????:
 > developers are still working on it, so
 >
 > 1.    you can get the latest source which already fixed this issue.
 >
 > 2.    or just comment out the whole else trunk as below
 >         } else {
 >             /* Port or any other key */
 >             key = strtol(arg, &p, 10);
 >             /* Skip non-base 10 entries like 'fa1' */
 >             if (p != arg) {
 >                 pkey = (uint32_t *)paddr;
 >                 *pkey = htonl(key);
 >                 type = IPFW_TABLE_CIDR;
 >                 addrlen = sizeof(uint32_t);
 >             }
 >         }
 >
 > 3.    or only comment out this  line in the else trunk
 >     type = IPFW_TABLE_CIDR;
 >
 >
 > Can the developer help to explain what kind of data you want to
 > support in the table?
 
 -- 
 Best regards,
 Dennis Yusupoff,
 network engineer of
 Smart-Telecom ISP
 Russia, Saint-Petersburg 
 
 
 --------------060309080704020200020902
 Content-Type: text/html; charset=ISO-8859-1
 Content-Transfer-Encoding: 7bit
 
 <html>
   <head>
     <meta content="text/html; charset=ISO-8859-1"
       http-equiv="Content-Type">
   </head>
   <body text="#000000" bgcolor="#FFFFFF">
     OK, I will try.<br>
     <br>
     I think it's a time to add "helper" argument to *ipfw table add*
     command so that you could set data type explicity, is it IPv6 or
     IPv4. Something like that:<br>
     <br>
     ipfw table XX add beef.de ipv6<br>
     ipfw table XX add beef.de ipv4<br>
     <br>
     AFAIK, it greatly reduce complexity of programming attempt to guess
     what kind of input data user meant.<br>
     <br>
     <div class="moz-cite-prefix">13.05.2014 10:45, bycn82 &#1087;&#1080;&#1096;&#1077;&#1090;:<br>
     </div>
     <blockquote cite="mid:5371BF77.5060400@gmail.com" type="cite">
       <meta http-equiv="content-type" content="text/html;
         charset=ISO-8859-1">
       <font face="Calibri">developers are still working on it, so <br>
         <br>
         1.&nbsp;&nbsp;&nbsp; you can get the latest source which already fixed this
         issue.<br>
         <br>
         2.&nbsp;&nbsp;&nbsp; or just comment out the whole else trunk as below<br>
         &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; } else {<br>
         &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; /* Port or any other key */<br>
         &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; key = strtol(arg, &amp;p, 10);<br>
         &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; /* Skip non-base 10 entries like 'fa1' */<br>
         &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; if (p != arg) {<br>
         &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; pkey = (uint32_t *)paddr;<br>
         &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; *pkey = htonl(key);<br>
         &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; type = IPFW_TABLE_CIDR;<br>
         &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; addrlen = sizeof(uint32_t);<br>
         &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; }<br>
         &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; }<br>
         <br>
         3.&nbsp;&nbsp;&nbsp; or only comment out this&nbsp; line in the else trunk <br>
       </font><font face="Calibri"> &nbsp;&nbsp;&nbsp; type = IPFW_TABLE_CIDR;</font><br>
       <br>
       <br>
       <font face="Calibri">Can the developer help to explain what kind
         of data you want to support in the table?<br>
       </font> </blockquote>
     <br>
     <pre class="moz-signature" cols="72">-- 
 Best regards,
 Dennis Yusupoff,
 network engineer of
 Smart-Telecom ISP
 Russia, Saint-Petersburg </pre>
   </body>
 </html>
 
 --------------060309080704020200020902--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201405131000.s4DA01ts033021>