From: "Michael Köppl" <m.koeppl@proxmox.com>
To: "Michael Köppl" <m.koeppl@proxmox.com>, pve-devel@lists.proxmox.com
Subject: Re: [PATCH http-server 1/1] apiserver: send TLS close notify at the end of streamed responses
Date: Tue, 03 Nov 2026 17:19:22 +0100 [thread overview]
Message-ID: <DMLPNHFQNE3G.1ET0IJ7H3LQIY@proxmox.com> (raw)
In-Reply-To: <20261103155223.1960754-1-m.koeppl@proxmox.com>
I was made aware and simply forgot that I should probably give an
example how to reproduce this.
1. Create a container
2. Back it up to PBS
3. The script below covers a simplified form of what the E2E test does.
Running it as root on a test node, pointing it at the container
backup like `repro.sh pbs:backup/ct/100/2026-11-03T12:00:00Z` will
return the data (the container's hostname) successfully downloaded,
but curl will show error 56.
```
#!/bin/bash
# e.g. repro.sh pbs:backup/ct/100/2026-11-03T12:00:00Z
volid=$1
storage=${volid%%:*}
ticket=$(perl -MPVE::AccessControl -e 'print PVE::AccessControl::assemble_ticket("root\@pam")')
filepath=$(printf '/root.pxar.didx/etc/hostname' | base64 -w0)
curl -sSk -G -H "Cookie: PVEAuthCookie=$ticket" \
--data-urlencode "volume=$volid" --data-urlencode "filepath=$filepath" \
"https://localhost:8006/api2/json/nodes/$(hostname)/storage/$storage/file-restore/download"
echo "exit code: $?"
```
Thanks, @Maximiliano for pointing this out.
On Tue Nov 3, 2026 at 4:52 PM CET, Michael Köppl wrote:
> A streamed response (e.g. for the single file restore download), has no
> Content-Length nor chunked encoding, so the client can only tell where
> the body ends by the connection being closed. The response accounced
> 'Connection: Keep-Alive' and, at the end of the stream, push_shutdown()
> shut down the socket directly, bypassing the TLS layer. The client then
[snip]
next prev parent reply other threads:[~2026-11-03 16:19 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-03 15:52 [PATCH http-server 1/1] apiserver: send TLS close notify at the end of streamed responses Michael Köppl
2026-11-03 16:19 ` Michael Köppl [this message]
2026-11-05 17:50 ` applied: " Thomas Lamprecht
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=DMLPNHFQNE3G.1ET0IJ7H3LQIY@proxmox.com \
--to=m.koeppl@proxmox.com \
--cc=pve-devel@lists.proxmox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox