Stream: wasi

Topic: wasi-sockets DNS


view this post on Zulip Alex Crichton (Sep 28 2023 at 22:58):

For those interested I've posted an initial implementation of the ip-name-lookup interface to https://github.com/bytecodealliance/wasmtime/issues/7070. The implementation and tests are pretty bare bones for now as I mostly wanted to set up the plumbing of types and bindgen and all that.

@Badeend (sorry for the ping both on github and here) I suspect you have an implementation already in mind and/or a test suite already in mind, and I'd be happy to switch implementations and/or fill out tests as well, so was wondering if you do indeed already have these things in mind to share here. If not, no worries!

A fast and secure runtime for WebAssembly. Contribute to bytecodealliance/wasmtime development by creating an account on GitHub.

view this post on Zulip kellytk (Oct 11 2023 at 03:15):

I'm developing a tool which will perform DNS lookups. I could write it directly in Rust, however I'd like to target a wasm+wasi environment if possible. I require two features: 1. To resolve name => [ipv4|6] address(es), 2. To obtain the associated TTL for the record. Will both be offered by Preview 2?

view this post on Zulip Alex Crichton (Oct 11 2023 at 05:05):

Currently wasi:sockets/ip-name-lookup can perform translation to ip addresses, but I don't believe it currently has information about TTL. If you're interested in that I think it'd be good to open an issue on the wasi-sockets repository

WASI API proposal for managing sockets. Contribute to WebAssembly/wasi-sockets development by creating an account on GitHub.

view this post on Zulip kellytk (Oct 11 2023 at 17:49):

https://github.com/WebAssembly/wasi-sockets/issues/65#issuecomment-1757809815 provided an update and answer to my feature request. ""TTL" is a concept specific to DNS and ip-name-lookup is not a DNS API."... "If you need access to the TTL value, the only option available in WASI right now is to perform the UDP communication yourself."

I'm developing a tool which will perform DNS lookups, cache results, and refresh the cache. I could write it directly in Rust, however I'd like to target a wasm+wasi environment if possible. I requ...

Last updated: Oct 23 2024 at 20:03 UTC