npub1n0k5...dwhk
npub1n0k5...dwhk
nostr:npub146y59dkatpwkx0ncs9u34vhmm60dedmdla0s8zy8yw22pqfj4huq36dp2y
bafybeihn4pt25sfnasjjxo2byvp74jik6s3edafd47qkgh3sjh2m2ndyx4.ipfs.cf-ipfs.com/#/note1zmefkecr6twksx27q4k77n6lqd4rqr8g7s7ew2vrfa0zmrl9vamq4urr9v
i wonder if we have any standard about what should be allowed in hashtags
iris renders
#iris-ipfs as hashtag, but primal shows #iris as hashtag and then -ipfs as text
maybe link like this:
hostr:a77ec9cc45b080cef42ffc2e2045e48dc97b2497aaf9a666b69782f8489f471b
so i intergrated hostr into #iris-ipfs
https://bafybeihypyqclc5spvhwazcm6vo542u3laprseoxiuvy36xthey5su2kny.ipfs.cf-ipfs.com/#/hostr/e0f64a05c89032aac28469e1656faf4425e1ca5faddade84237132e79072a18c
https://bafybeihypyqclc5spvhwazcm6vo542u3laprseoxiuvy36xthey5su2kny.ipfs.cf-ipfs.com
```js
function hostr_loader(){
let m = location.hash.match(/^#\/hostr\/(\S+)/)
if(m){
let id = m[1]
let s = new WebSocket("wss://relay.nostr.band")
s.onopen = () => {
s.send(JSON.stringify(["REQ","q",{"ids":[id]}]))
}
s.onmessage = e => {
s.close()
document.body.outerHTML = "<body><style>body {margin: 0;} iframe {width: 100%; height: 100%; border: none;}</style></body>"
let f = document.createElement("iframe")
console.log("data", JSON.parse(e.data)[2].content)
f.src = "data:text/html;base64," + btoa(JSON.parse(e.data)[2].content)
document.body.append(f)
}
}
}
hostr_loader()
```
we could use any nostr app as #hostr webhost https://iris.to/
just load content into iframe
it wont be able to access sensitive data like localStorage
url could be something like:
https://iris.to/hostrf2ca1bb6c7e907d06dafe4687e579fce76b37e4e93b7605022da52e6cc
which would execute code like following (where f.src would come from hostr note, we would convert hash "hostrf2ca1bb6c7e907d06dafe4687e579fce76b37e4e93b7605022da52e6cc" into hex and query from relay):
document.write("<html><head><style>body {margin: 0;} iframe {width: 100%; height: 100%; border: none;}</style></head><body></body></html>"); f = document.createElement("iframe"); f.src = 'data:text/html;,<script>document.write("hello from iframe"); console.log(localStorage);</script>'; document.body.append(f);
im not sure if its good idea to generate names client side
my client side generated name is Square Gibbon, but you cannot use search to find my user, because the name is client side generated
now you can, because i said that name in this note, so you can find this note
fixed direct linking by changing to hash router
#iris #ipfs
http://bafybeid6p3j3ps4igbahspqcpyweat7ipkiifprapark53ilvktcm7swu4.ipfs.localhost:8080/#/npub1n0k5tmnuxfq7aga6wjfp52uz93elz3r7t93rzss9myd83nyevghq67dwhk
this one works for viewing media

Magnet Player
A place for streaming torrents directly from your browser.
#seeding self created #torrent confirmed to work through #tor
sudo orjail firefox
#btorrent #webtorrent
View quoted note →
βTorrent: Browser WebTorrent Client
βTorrent is the first fully-featured Browser WebTorrent Client
creating gallery with preview
montage -mode concatenate -tile 5x $(find /path/to/images/ | sort | tail -n +2 | head -n 9) -resize 200x200 -quality 59 gallery.webp
cat gallery.webp | base64 -w 0 > gallery.webp.base64
<meta property="og:type" content="article" />
<meta property="og:title" content="00004-716949222.png" />
<meta property="og:site_name" content="hostr" />
<meta property="og:description" content="image description" />
<meta property="og:image" content="data:image/webp;base64,imagedata"/>
<meta property="og:image:width" content="665" />
<meta property="og:image:height" content="400" />
https://npub10yjtwupadl7hvgkun2xju8yp3dhgwy5cskw6wunhdduzwxhhklnq3g0zkr.hostr.cc/d/gallery.html?x
47,3 KiB html document with webp
https://npub1aevx3wwqgfvnhw8tw9mctfc0r7d7vtjd26c2rgu3m5un4q2x5jpqg75ja7.hostr.cc/d/meta-test-webp.html