Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
Wingy
30 days ago
|
parent
|
context
|
favorite
| on:
Show HN: Docker-phobia: Analyze Docker image size ...
curl should probably scream when it detects piping unencrypted wan (not local ips) connections to shell, sort of like what openssh does when a host’s fingerprint changes
mr_mitm
30 days ago
|
next
[–]
How could curl detect where it's piped to?
take-five
30 days ago
|
parent
|
next
[–]
Something like (in Python)
os.isatty(sys.stdout.fileno())
Zambyte
30 days ago
|
root
|
parent
|
next
[–]
That doesn't say where it's piped though. It could be redirected to a file, or piped to something harmless like jq.
timando
30 days ago
|
parent
|
prev
|
next
[–]
Iterate through /proc/<pid>/fd and check for the pipe id in the symlink target.
adamomada
30 days ago
|
prev
[–]
The shell would have to give the warning
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search: