[Bro-Dev] new IPv6 code
Robin Sommer
robin at icir.org
Wed Feb 15 13:09:15 PST 2012
I'm going through the v6-addr branch. Good job with that!
A few questions:
- in BroValUnion, 'addr_val' is of type pointer type IPAddr*. I
suppose that's to keep the union size as small as possible, which
makes sense. I'd still be curious though how allocating the
addresses dynamically compares against storing the instance directly
inside the union. Have you tried that? I realize it's not an easy
change to do that, so fine if not.
- The DNS binpac analyzer generates both dns_a6_reply and
dns_aaaa_reply, but the standard analyzer only the latter (for both
resource record types). What is correct?
- In the RPC code, there's this:
is_mapped_dce_rpc_endpoint(const ConnID* id, TransportProto proto)
········{
········if ( id->dst_addr.family() == IPAddr::IPv6 )
················return false;
...
}
Does the protocol not support IPv6 at all or is that a "todo"?
- in DPM.cc, the ExpectedConn class: should it now store IPAddr
instead of uint32[4] for orig and resp?
- Expr.cc, BinaryExpr::AddrFold: why still the uint32[4] here? If it's
just to make the macro work, I'd just remove that and use
comparision operators instead.
- IP.h, IP_Hdr: Do we need the new src_addr/dst_addr attributes? Why
not construct on the fly out of ip4/ip6?
- PktSrc.cc:
- protocol = (data[3] << 24) + (data[2] << 16) + (data[1] << 8) + data[0];
+ protocol = (data[0] << 24) + (data[1] << 16) + (data[2] << 8) + data[3];
Does that mean this was buggy before?
Robin
--
Robin Sommer * Phone +1 (510) 722-6541 * robin at icir.org
ICSI/LBNL * Fax +1 (510) 666-2956 * www.icir.org
More information about the bro-dev
mailing list