Avatar
Oren ☂️
3316e2d88ff91e1089c75feedcd8baa2258b45455a3b156af617d7ec79b45fe5
Software Developleb https://github.com/oren-z0 CTO at RITREK.com Check out: https://niot.space https://ln2.email

nostr:note1uk728fkpgt8qqe2a9gylc9af5e4kjkyr05f3c04zpv8jgzwu9s6qpks74v

Replying to Avatar calle

Huge milestone: First demo of Nostr Web Services (NWS) bringing TCP to Nostr. With NWS, you can host any existing web application on Nostr without having to use DNS or even announce your public IP to the world, simply by sharing your service's npub (or nprofile).

Try it out the demo yourself. Here is a Cashu test mint running with NWS. Let's use curl to retrieve the mint's information. The request travels from your computer to the public NWS entry relay, then through nostr to the service's NWS exit relay. At the other end is a Cashu mint with HTTPS encryption.

```

curl -s -x socks5h://relay.8333.space:8882 https://nprofile1qqs8a8nk09fhrxylcd42haz8ev4cprhnk5egntvs0whafvaaxpk8plgpzemhxue69uhhyetvv9ujuwpnxvejuumsv93k2g6k9kr/v1/info --insecure | jq

```

I can't stress this enough: THE MINT RUNS BEHIND HTTPS!

The NWS entry relay can't read your traffic. It's encrypted. We can host public entry relays that can be used by anyone.

This means we can plug the entire internet to it 🌐.

Let's plug it into Cashu for now. Nutshell wallet supports socks5 proxies (that's how it uses Tor). By setting the public entry relay as the proxy, the wallet can now connect to a mint's npub/nprofile and communicate with it via NWS.

This is going to be so freaking cool. And it's going to be a lot more useful than just for Cashu. There are still bugs and issues that need to be ironed out but the code is coming out soon. Watch this space.

Is the communication wrapped as ephemeral nostr events or is it some other way?

A reminder to all the #Trump simps…

#meme #memestr

😂 Actually you don’t need websockets over nostr because with http-over-nostr the client side can behave as a server and wait for requests initiated by others.

When you think about it, WebSockets themselves are kind of a hack. In the old days every computer had a public IP address and could open a port to wait for information from others. Today most computers are behind NAT and firewalls so to wait for information from some server you need to actively initiate a communication channel and keep it alive.

Using VPN doesn’t mean you have a static public IP address. It doesn’t mean you can easily configure your computer to become a server in a way that allows others to initiate a connection with it.

I think Tor can give you an onion address, based on your public-key, so it remains yours even if the network changes.

Can you install a Holesail server on Arduino or ESP32?

Nostr is not P2P so technically the relays could track the amount of traffic, and if they collect the ip-addresses I guess they could track who is communicating with who.

From what I understand Holesail needs the servers/relays only in the initial setup of the communication channel. That’s kind of overhead if all you want to do is one or two http api calls and disconnect (like when you pay a static lnurlp).

nostr:npub1h5t3asu90f2x48rxtcqkjvwhza7m6kngs7vjyanx8xqyswc6es2s4645z5 Do I understand correctly?

Interesting. What does the hash represent? How does it bypass the home NAT?

I also think https://holesail.io/ is an interesting project for large traffic.

But for #IoT devices, http-over-nostr would be the best. All kind of Arduino/ESP32 projects can easily connect to websockets, so they could serve simple “websites” for configuration and operation.

Replying to Avatar Oren ☂️

Here is another demo of my NIP implementation.

Now using ephemeral events, NIP-44 encryption and NIP-59 gift wraps:

https://github.com/nostr-protocol/nips/pull/1276

I suggest we’ll call it NIP-80 after the default http port.

Imagine future browsers ( #browstr ) allowing you to enter http://.nostr/… and it would simply send the http request and receive the response via nostr events! Just like .onion sites but without the slowness of TOR.

It can also be useful for #iot devices that can serve a simple configuration-website and allow “browsing” them from anywhere in the world. I think TOR is too complicated to run on such devices.

nostr:npub1gcxzte5zlkncx26j68ez60fzkvtkm9e0vrwdcvsjakxf9mu9qewqlfnj5z WDYT? https://v.nostr.build/VAREX7f6XB8sTPQr.mp4

nostr:npub1h5t3asu90f2x48rxtcqkjvwhza7m6kngs7vjyanx8xqyswc6es2s4645z5 How would you compare this to #holesail ? I think the solutions can complete each other - a simple website access could be done via ephemeral nostr events, but heavier communication (i.e. video) should be done over Holesail.

Here is another demo of my NIP implementation.

Now using ephemeral events, NIP-44 encryption and NIP-59 gift wraps:

https://github.com/nostr-protocol/nips/pull/1276

I suggest we’ll call it NIP-80 after the default http port.

Imagine future browsers ( #browstr ) allowing you to enter http://.nostr/… and it would simply send the http request and receive the response via nostr events! Just like .onion sites but without the slowness of TOR.

It can also be useful for #iot devices that can serve a simple configuration-website and allow “browsing” them from anywhere in the world. I think TOR is too complicated to run on such devices.

nostr:npub1gcxzte5zlkncx26j68ez60fzkvtkm9e0vrwdcvsjakxf9mu9qewqlfnj5z WDYT? https://v.nostr.build/VAREX7f6XB8sTPQr.mp4

For example Iran and Qatar have an incentive that Israel will go to a war with Lebanon - to increase the oil consumption.

Or if Yemen shoots on ships in the Red Sea, they now have to take the long route around Africa.

The USD being the world’s reserve currency for oil trade makes the USA a middleman and they get a cut of the profits, but the main beneficiaries from increased oil consumption are the oil producers.

But Iran, Qatar, Saudi Arabia & Russia will still have an incentive to create wars.