- 最新
- 投票最多
- 评论最多
I'm going to answer my own question. From the FAQ https://aws.amazon.com/lambda/faqs/ :
"Lambda attempts to impose as few restrictions as possible on normal language and operating system activities, but there are a few activities that are disabled: Inbound network connections are blocked by AWS Lambda, and for outbound connections only TCP/IP sockets are supported, and ptrace (debugging) system calls are blocked. TCP port 25 traffic is also blocked as an anti-spam measure."
Digging a little deeper from this blog and GitHub page https://www.jethrocarr.com/, the Lambda OS kernel lacks the CAP_NET_RAW kernel capability to manipulate raw sockets.
So, you can't do ICMP or UDP from a Lambda function.
AWS Lambda waived the restriction for UDP. The current FAQ documentation states:
Inbound network connections are blocked by AWS Lambda, and for outbound connections only TCP/IP and UDP/IP sockets are supported, and ptrace (debugging) system calls are blocked. TCP port 25 traffic is also blocked as an anti-spam measure.
相关内容
- AWS 官方已更新 1 年前
- AWS 官方已更新 1 年前