quiche: add EnvoyQuicPacketWriter with sendmsg to set source address#7416
quiche: add EnvoyQuicPacketWriter with sendmsg to set source address#7416mattklein123 merged 54 commits intoenvoyproxy:masterfrom
Conversation
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
Signed-off-by: Dan Zhang <danzh@google.com>
|
/retest |
|
🔨 rebuilding |
| Buffer::InstancePtr result_buffer(new Buffer::OwnedImpl()); | ||
| const uint64_t bytes_to_read = 11; | ||
| const uint64_t bytes_to_read = payload.length(); | ||
| // Make receive buffer 1 byte larger for trailling '\0'. |
There was a problem hiding this comment.
typo "trailling" (feel free to fix in your next PR)
|
@danzh1989 I suspect the coverage error is a legit timing error. It looks like something might be hanging on one of the UDP tests. /wait |
Signed-off-by: Dan Zhang <danzh@google.com>
|
@danzh2010 sorry this is going to need a master merge due to #7457 /wait |
|
/retest |
|
🤷♀️ nothing to rebuild. |
|
/retest |
|
🤷♀️ nothing to rebuild. |
|
/retest |
|
🤷♀️ nothing to rebuild. |
|
/acp rerun |
|
/azp rerun |
|
Command 'rerun' is not supported by Azure Pipelines. Supported commands
See additional documentation. |
|
/azp run envoy-macos |
|
Azure Pipelines successfully started running 1 pipeline(s). |
mattklein123
left a comment
There was a problem hiding this comment.
Thanks, will merge once 1.11 is cut.
| // if it's not specified in cmsghdr. | ||
| send_from_addr.reset(new Address::Ipv6Instance( | ||
| #ifdef IP_FREEBIND | ||
| "::9", |
There was a problem hiding this comment.
@danzh2010 this one cause problems during Google Envoy import. It seems we don't support the ability to bind to ::9 like this on our internal test farm. One of the issues that seems to exist here is that we assume that a compile time support for IP_FREEBIND translates to runtime ability. Do you think you could express this differently? CC @dnoe @yanavlasov
There was a problem hiding this comment.
@danzh2010 this one cause problems during Google Envoy import. It seems we don't support the ability > to bind to ::9 like this on our internal test farm. One of the issues that seems to exist here is that we
assume that a compile time support for IP_FREEBIND translates to runtime ability.
This might has walk-around, I'll check our test infrastructure about it.
Do you think you could express this differently? CC @dnoe @yanavlasov
It's hard to test it in a different way as we need an v6 address that we can use to send which is different from what kernel would have picked for us. An compromise is we always use ::1 for v6, but this will leave v6 behavior untested.
EnvoyQuicPacketWriter calls UdpListener::send() to write packet.
Modify IoSocketHandleImpl::sendmsg() to take source ip address and used it in ancillary data.
Risk Level: low, udp listener is not in use.
Testing: Added unit tests for EnvoyQuicPacketWriter and integration test for UdpListener to send self address.
Part of #2557