/prog/ - Programming

[X]

Mark sensitive


File: dbc1e5cbb04c967776ce73318f(...).gif (118.30 KB)
Attempt at creating a FChannel local client Anonymous 07/28/21(Wed)04:30:40 No. fprog-DK37PT1F [Report]

I am done with FCHAM, so I have started a new project: a client for FChannel. My idea is to allow you to subscribe to instance's boards by specifying (in a configuration file maybe) which outboxes to download, after that the client will download the outboxes and build an HTML page of for you. My idea is that the HTML will be static, local, and without javascript. It may download attached files locally idk. I don't intend to let you post replies from the client (I don't even know how I would do that), but it can link to the post so you can reply from its instance. It doesn't seen too hard to build these pages, I think I will take a look at the server's repo and just translate code from it. You can check it out here http://git.p6nhckzlonbw72mhxqcyfa474ssavlnud6tvpmhjzf37r2zyz2ommtqd.onion/fchan-client/log.html, but to say it is currently barebones would be overestimating it. Anyway, I like to put puns on the names of my projects, but I am lacking inspiration for this one (fchan-client is too inane for my taste), any suggestions?

>>
Anonymous 07/28/21(Wed)04:33:01 No. fprog-16TF4WEP [Report]

>>fprog-DK37PT1F (OP) by the way the no-js thing is just because i don't know js very well to add it to the project, i don't think running js in a local page would be harmful

>>
Anonymous 07/28/21(Wed)05:29:42 No. fprog-ZTO5BD4K [Report]

>>fprog-DK37PT1F (OP) i am honestly surprised this is capable of parsing the entire outbox of fchan.xyz/b/ into a webpage almost instantly, firefox even hiccups when trying to load the output

>>
Anonymous 07/28/21(Wed)05:51:26 No. fprog-01G1NYT4 [Report] >>fprog-0C8DU5CF

>>fprog-DK37PT1F (OP) i thought of a better name for the project: FBI - Federation Box Importer here is the new url http://git.p6nhckzlonbw72mhxqcyfa474ssavlnud6tvpmhjzf37r2zyz2ommtqd.onion/fbi/log.html

>>
File f710331bfe772b79b632a943eb(...).png (305.03 KB)
Anonymous 07/28/21(Wed)06:00:23 No. fprog-LQ036RSO [Report]

>>cunny Make it in electron plz

>>
Anonymous 07/28/21(Wed)06:03:20 No. fprog-FEPHPO0O [Report]

>>fprog-DK37PT1F (OP)/ZTO5BD4K/01G1NYT4 dike post bussy

>>
Anonymous 07/28/21(Wed)15:20:07 No. fprog-YLX6EKJQ [Report] >>fprog-1YMKUI7H

>>fprog-DK37PT1F (OP) Onion site is down :( cannot download this, sounds pretty cool though

>>
Anonymous 07/28/21(Wed)15:54:24 No. fprog-1YMKUI7H [Report]

>>fprog-YLX6EKJQ i usually only keep the service up on weekend, but since i got ahead of myself and posted about my projects yesterday i guess i should keep it up for visitors it is up now

>>
Anonymous 07/28/21(Wed)23:16:20 No. fprog-0C8DU5CF [Report] >>fprog-5ET9CLBU

>>fprog-01G1NYT4 >>fprog-DK37PT1F (OP) based OP, although i think this would be cool to implement as an rss feed so you can pipe it into sfeed or something. it seems like the main use case would benefit from this

>>
Anonymous 07/29/21(Thu)01:15:45 No. fprog-5ET9CLBU [Report] >>fprog-MYDBF63T

>>fprog-0C8DU5CF idk anon, rss seems like a weird way to read threads from an image board

>>
Anonymous 07/29/21(Thu)10:23:51 No. fprog-OLMDY4BR [Report] >>fprog-G3YZ87H1

fbi is kinda usable right now. most of the core features are in, but still lacks some QoL to be easier to use. now instead of generating a single huge page with all thread and all replies, it breaks it into pages of 10 thread each (still shows all replies, i will give each thread its own page and only show the last few replies on the board's page). it can download attachments locally, but this is disable because it takes too long to download all (/b/ alone has over 200M of files), you can set the variable allow_dl_attach to true if you want to download it all anyway (so all images will show up nicely on the posts) you can try it by creating a 'files' directory and a file named 'subs' on it with one subscription per line (do not write the protocol or trailing slash, write 'fchan.xyz/prog' instead of 'https://fchan.xyz/prog/'). multiple board subscription (such as subbing to multiple /prog/s) is not yet supported, if it somehow works (haven't tested) it think the second board's newest post will only appear after the first's oldest. i will sort this out in the future. this wasn't so hard, but i am not sure how i will merge multiple boards' outboxes so their posts show up in the correct order. devchad, how you you do it?

>>
Anonymous 07/31/21(Sat)08:27:35 No. fprog-G3YZ87H1 [Report] >>fprog-SZZZO0S9

>>fprog-OLMDY4BR its has optargs now, you can pass -u to redownload the outboxes before rebuilding the pages, -f to set the subscriptions file (it looks for it at ~/.config/fbi/subscriptions by default, with ./subscriptions as a fallback (that is, in the current dir)) and -a to download attachments locally. regarding subscribing to multiple equally-named boards: NOW it will show the second board's newest post after the first's oldest (previously it was overwriting them), i looked around FChannel's code to look for how the posts are organized, but couldn't find it (i only kinda skimmed through the files though), but i think i have an idea on how to do it

>>
Anonymous 07/31/21(Sat)15:22:11 No. fprog-MYDBF63T [Report] >>fprog-SZZZO0S9

>>fprog-5ET9CLBU why? you're literally just fetching feeds with text. it makes sense to me

>>
Anonymous 08/01/21(Sun)04:09:15 No. fprog-SZZZO0S9 [Report] >>fprog-H2K0MNTD >>fprog-M57RXN8E

>>fprog-G3YZ87H1 i did it, now if you subscribe multiple instances on the same board their threads will be mixed and chronologically organized. the only thing left to make it a decent browser is to create an individual page for each thread show only its last few posts on the board's page after that will be aesthetic improvements, like the coveted alternative stylesheets (possibly with a picker), which i am still waiting for that op to deliver (inb4 he won't) >>fprog-MYDBF63T are there rss readers with image support? otherwise browsing imageboards without images would be weird

>>
Anonymous 08/01/21(Sun)09:02:54 No. fprog-H2K0MNTD [Report] >>fprog-RHNQX5UX >>fprog-PXVQOZ9L

>>fprog-SZZZO0S9 Atom supports limited HTML so image or other media embeds / linking is trivial. Look at multichan: each server, tag, and thread have their own atom feeds: http://0chan.vip/atom/

>>
Anonymous 08/01/21(Sun)10:50:04 No. fprog-RHNQX5UX [Report]

>>fprog-H2K0MNTD cool, i will first get fbi to present itself like a regular chan interface before looking into that you are welcome to fork and implement a feed, though. i will merge later

>>
Anonymous 08/01/21(Sun)20:22:01 No. fprog-PXVQOZ9L [Report] >>fprog-K03PNMCF

>>fprog-H2K0MNTD multichan is DOA. rss/atom feed for an imageboard is retarded.

>>
Anonymous 08/02/21(Mon)05:39:12 No. fprog-K03PNMCF [Report]

>>fprog-PXVQOZ9L > rss/atom feed for an imageboard is retarded Wrong

>>
Anonymous 08/02/21(Mon)17:10:03 No. fprog-OGBJ06YF [Report] >>fprog-A2CUR43J

>>fprog-DK37PT1F (OP) > My idea is to allow you to subscribe Lost my interest right there

>>
Anonymous 08/02/21(Mon)21:01:54 No. fprog-A2CUR43J [Report]

>>fprog-OGBJ06YF anon... that's how activitypub works

>>
Anonymous 08/03/21(Tue)01:44:47 No. fprog-M57RXN8E [Report] >>fprog-BGF9J6ZQ

>>fprog-SZZZO0S9 now threads have their own files, on the board file only their last 5 replies will be show (you can change this number) now to work on the aesthetic i think by this weekend fbi will be mostly, if not completely, finished

>>
Anonymous 08/05/21(Thu)08:20:07 No. fprog-BGF9J6ZQ [Report] >>fprog-RPG6GC7W >>fprog-YM5JLIUV

>>fprog-M57RXN8E i am done with the aesthetic changes, now fbi looks about the same as fchannel, here are the changes * references and quote are now stylized * references have title text * clicking a reference takes you to the referred post * handle subject, postername and tripcode * bolden current board (like page) * support for alternative stylesheets * removed stupid restrictions on url format, now you can copy and paste from the browser * option to update a single board for now only the red and blue stylesheets are available if anyone cares to make alternative styles to be used with fbi, it will also be compatible with fchannel

>>
Anonymous 08/05/21(Thu)14:21:44 No. fprog-RPG6GC7W [Report]

>>fprog-BGF9J6ZQ based fbichad lookin good

>>
Anonymous 08/05/21(Thu)16:24:13 No. fprog-YM5JLIUV [Report]

>>fprog-BGF9J6ZQ sounds awesome, i'll check it out on the weekend

>>
Anonymous 08/07/21(Sat)00:11:28 No. fprog-RO2OPAB6 [Report] >>fprog-KHPQKD94

it is live http://git.p6nhckzlonbw72mhxqcyfa474ssavlnud6tvpmhjzf37r2zyz2ommtqd.onion/fbi/file/README.html

>>
File 2021-08-06-202151_371x272_(...).png (16.14 KB)
Anonymous 08/07/21(Sat)00:22:26 No. fprog-KHPQKD94 [Report] >>fprog-6YOT70KH >>fprog-P8K726I4

>>fprog-RO2OPAB6 got it, have a weird issue. I have lua-cjson 5.3 but for some reason fbi only seems to look for 5.2 and won't run with 5.3

>>
Anonymous 08/07/21(Sat)00:44:37 No. fprog-6YOT70KH [Report]

>>fprog-KHPQKD94 i think the problem is that you are running it with lua 5.2 i use lua 5.4 and it looks for modules in similar paths, except it is /5.4/ instead of /5.2/

>>
Anonymous 08/07/21(Sat)01:08:20 No. fprog-P8K726I4 [Report]

>>fprog-KHPQKD94 >fbi:4:package.cpath = package.cpath..';.deps/?.so' if you can find where cjson.so is on your system, you can append it to this line similar to what i did. the '?' will substitute for the filename. or, you know, just use the lua-cjson version that comes with.

>>
File saitama_anonymous.png (457.72 KB)
Anonymous always deliveries 05/15/22(Sun)10:43:20 No. fprog-U579GTI5 [Report]

Following up on >>fprog-DK37PT1F FBI 2.0 is almost done. The only thing major left to do is figuring out how to post from it. My old computer where I used to run my onion service on has died for good this time, so I will spend the day figuring out QEMU to run it off a VM. Meanwhile, here is a list of features to look forward to: * configuration page: change a few client options on the frontend itself (but you really should use the config file since that won't save to disk) * catalog: scroll bar on posts to be able to read the entire post instead of just cutting off what doesn't fit in a box * overboard: put everything in a single place instead of hopping over 9000 different boards * two modes: inclusion and exclusion * in inclusion mode, only the boards on the overboard's list will be added to the overboard * in exclusion mode, all the boards are added to the overboard, except for the ones on the list * board merging: simulates things like /a/ pulling from /amh/, just a way to avoid redundant boards with different names across different instances * aesthetically consistent error pages: as opposed to gay text/plain responses * customizable CSS: basically everything has it own class instead of hardcoded styles, and you can pick which style sheet to use from the config page * RSS feeds: for a single thread or an entire board (including the overboard) * search page: search for posts based on content, subject, author, tripcode, attachment, date, reply count, and original instance * expand image on click (no js required!) * limit length of posts on index (you can configure how many lines are shown) * attempts to go to a reply's URL will be redirected to its parent thread (instead of treating the reply itself like a thread) * asyncronously download outboxes and attachments (you can configure the time interval) * generally superior HTML everywhere (in my humble opinion)

>>
File 1c35bee261d45030fad1ca7ea6(...).jpg (35.81 KB)
Anonymous 05/22/22(Sun)12:50:51 No. fprog-EQWUOAGM [Report] >>fprog-5NEXVVQW

Sorry for the late update, I spend the past week battling the masculine urge to exsanguinate myself, turns out I just needed to jack off to fix that. Anyway, I still tried to reinstall my old server elsewhere, but it dawned on me that it would be a pain in the ass, and onionshare has a shitton of dependencies that I don't wanna install just to serve a single one (1) file over tor, so I will instead serve the fbi2 archive using socat. Just open a connection on port 1 of xt2piyzy4iy3auwtrkp3n6vkohj2kmnn36ji65mck2blnj7wgph7y2id.onion and it will send you the file. What worked for me was >socat -u SOCKS4A:localhost:xt2piyzy4iy3auwtrkp3n6vkohj2kmnn36ji65mck2blnj7wgph7y2id.onion:1,socksport=9050 STDOUT > fbi2.pax.xz adjust socksport to what you use. As it is right now, you need to download the attachments for them to show, but I will now add an option to instead request them directly from the instance. Let me know if there is anything too hard to understand/use, UX isn't my expertise.

>>
Anonymous 05/22/22(Sun)13:36:32 No. fprog-5NEXVVQW [Report]

>>fprog-EQWUOAGM >I will now add an option to instead request them directly from the instance. Done and already updated the archive. The option is off by default, change it in the config file.

>>
Anonymous 05/23/22(Mon)23:38:32 No. fprog-583521FC [Report]

>>fprog-DK37PT1F there is no captcha endpoint in feditext and i'm also pretty sure fchannel doesn't have one either. i'll eventually get around to adding a captcha endpoint to feditext. there's a list of things i'd like to get done first, however you should implement this hack for now. nobody will be running fchannel's fiber branch in production for the next little while, and you can see if the response is from feditext by simply looking at the server response header. i've been busy with other things and haven't gotten around to working on feditext, nor fchannel's fiber branch, but i'm still around somewhat and plan to work on both of them when i have enough time.

>>
Posted from FBI2 Anonymous 05/25/22(Wed)00:20:48 No. fprog-3V8JQRWB [Report] >>fprog-GSXECQIN

It is done, I will now work on compatibility with feditext.

>>
Anonymous 05/29/22(Sun)22:04:14 No. fprog-GSXECQIN [Report]

>>fprog-3V8JQRWB BASED AS FUCK OP. thank you for your service o7, can't wait to try this

>>
Anonymous 06/01/22(Wed)00:06:55 No. fprog-5777D02F [Report]

>>fprog-3V8JQRWB Compatibility for the two is going to be clunky. FChannel's captcha is located at /public/${captchacode}.png while feditext's is located at /captcha/${captchacode}. This alone wouldn't be a problem, since FChannel's captcha code has only 8 characters while feditext's has 16, so I could just change where the img's src from based on that. The real problem is in the form. In FChannel, the captcha solution's name is "captcha" and the captcha code's is "captchaCode", meanwhile feditext's form calls the captcha solution "solution" and the code "captcha". So I will also have to make a different form depending on which instance is being posted to. Okay okay, this isn't gonna be that hard, I can just change the names depending on the length on the captcha code. But I would really appreciate if both server developers could agree on a single standard so client developers (me) don't have to account for every small difference in implementation. Or at least have somewhere I can easily look which software the server is running, to make it easier to tell different backends apart. Oh and don't even get me started on using a checkbox for sage instead of a options field, I hope it at least secretly accepts a field named "options".

>>
File 95496b59d9202364c2e4f9fd03(...).jpg (253.30 KB)
Anonymous 06/01/22(Wed)00:57:19 No. fprog-VB4B8B0T [Report]

Oh motherfucker. You know, I got my functions all dolled up to make it easier for me to write alternative captcha fetchers and forms and all that gay shit for future alternative backends, but between feditext's own autistic ID system, and it requiring the post ID to POST (to reply to this thread, for example, I would need to POST to /prog/435), AND it's outbox using an ID system similar to FChannel's, I literally have no fucking clue how I am supposed to get FBI2 to work with feditext, at least when it comes to creating posts there. I will leave things are they are for now, if the textdev can make it so that the post form can use hidden elements to tell where to send the post to, and have it use the "true" ID of a post (the random one, not the sequential) that would be fucking rad because it is the sole thing stopping me. You don't even need to overwrite your current functions, just make it so that sending a POST request to /post works exactly like in FChannel.

>>
Anonymous 06/01/22(Wed)01:35:13 No. fprog-7D34EB17 [Report]

>sage horribly broken in its current state so don't even bother options doesn't exist and sage barely exists, i'll probably rip it out and think about how it's done in fchan i need to do a couple things around the ui anyway because it sucks to scroll up and down to post, would like a post form similar to fchan's javascript one >id system ah, sorry that caused you this much pain. i'll checkout writing a /post endpoint soon(tm), along with a /captcha endpoint to make your life easier, or whatever you think is best. i'll rename form ids to those similarly found in fchan. i thought i had also made it redirect posts to the activitypub id but apparently i didn't. i'm interested in figuring out how to best standardize this between implementations without being too overtly complicated. activitypub has a client-to-server protocol, no? i remember reading that it's essentially unused, but it's there. just something for thought

>>
Anonymous 06/01/22(Wed)02:38:16 No. fprog-4DEF04F3 [Report]

>Or at least have somewhere I can easily look which software the server is running, to make it easier to tell different backends apart. feditext sends a server header in every response in the form of `feditext/git revision` haven't updated awoo yet but you should be able to post to the id similar to fchan's, it should just figure it out on its own. also renamed captcha ids to be like fchan's. i'll work on /post and /captcha in the coming days, there's other things i need to do in the meantime as for client to server, i've only read negative things about activitypub's c2s protocol, so maybe not that. devchad if you're here, fbichad, thoughts?

>>
Anonymous 06/01/22(Wed)03:04:00 No. fprog-71741F5D [Report]

>captcha fields names, sage checkbox, etc That was unnecessary, sorry. I just wrote a different form that is used when feditext is the instance being used. In principle I can do the same for any other backend, so there is no real need for everyone to use the same form. >i need to do a couple things around the ui anyway because it sucks to scroll up and down to post, would like a post form similar to fchan's javascript one You should see how I did the post form for FBI2. It stays at the bottom of the page when not selected, but when it is (using the CSS :target, so when the browser looks for #post-form) its position then becomes fixed, following you around, and there is a little [X] that sends it back to the bottom. I think it is pretty elegant for a non-js form. I will leave that socat hack up for a bit if you wanna download it, but I will be checking out soon. >you should be able to post to the id similar to fchan's I will test it later. >feditext sends a server header in every response in the form of `feditext/git revision` I am sure curl has a way to shove the headers into stdout along with the response, I will figure it out later. >activitypub's c2s protocol If the standard sucks ass, we can just make our own.

>>
Anonymous 06/01/22(Wed)03:38:53 No. fprog-O7TOIGT0 [Report]

>>fprog-4DEF04F3 >>fprog-71741F5D >c2s protocol, so maybe not that. devchad if you're here, fbichad, thoughts? >If the standard sucks ass, we can just make our own. since things are being reworked and different implementations created a discussion on what we want to work with for a 'standard' would be good. as we can see it can get messy quickly. sane defaults would be smart. >You should see how I did the post form for FBI2. this is interesting ill have to look at it and implement it for fchannel.

>>
Anonymous 06/01/22(Wed)04:00:45 No. fprog-3494131C [Report]

>Server header That already helps a lot, would be nice if FChannel sent one too, but since there are only 2 servers for now, it already works very well. And yes, using the standard ID doesn't work for posting yet, let me know when you update awoo. Other than that, getting a captcha is working fine. >standard About /post and post forms, while standardizing would be nice, I don't think it is strictly necessary. I can create alternative post forms for other backends fairly easily now, and as long as /post doesn't have quirky implementations like feditext, it should be fine too. But, of course, this is only if clients are being actively developed, so if a new backend is made with a different form and the clientdevs don't include it, then it wouldn't work. So I think that even if other servers use their own post forms and /post equivalents, they should still accept FChannel's OG /post format just to be safe, since it is highly probable all clients will support at least that. As for /captcha, simply returning a 'text/plain' response with a captcha code would be enough, but I prefer that it also returns the captcha image encoded in base64 to be readily added to an img tag, so the client doesn't have to make 2 requests. Since we already use JSON, it could return an object like that with, say, a field named 'code' and one name 'image'.

>>
Anonymous 06/02/22(Thu)22:19:11 No. fprog-1628AF2E [Report]

>css post form that's actually pretty cool. i'll look into implementing it the next time i have a chance. i grabbed a copy of fbi2 while the socat hack was up so i'll reference it. i'd like to have as much as the frontend free of javascript as possible, both because of my opinions and because i forgot everything i knew about it >c2s protocol well, now that i think about it, most of what i'd think the ideal protocol could be was already discussed. i implemented the /captcha endpoint and updated awoo, it's there if you want it along with posting to the activitypub ids. /captcha is just a simple code/image (base64) json response as requested. posting has /post (not implemented in feditext yet), you can get everything with the outbox or just individual threads by changing the Accept header to one of activitystreams i'll try to keep /post as similar to how fchan does it as possible when i do implement it. maybe also a "thin outbox" or something containing just thread OPs, whoever found the beautiful hack of /prog/0 inspired this

>>
Anonymous 06/03/22(Fri)22:25:20 No. fprog-7YYEU6JW [Report]

>>fprog-1628AF2E >i'd like to have as much as the frontend free of javascript as possible If you need inspiration, look at several other IBs and how they do their frontends, that's what I have been doing. Sometimes you find things you didn't know were possible, like CSS postform and expanding images with only CSS. There is actually a lot that can be done with CSS only. >i implemented the /captcha endpoint and updated awoo Looks great, I will make FBI2 use that later. >thin outbox That's something that I have been thinking about too. Like being able to request only the latest posts when updating the outboxes in FBI2, because redownloading the entire outbox is pointless. Doesn't HTTP have a Last-Modified header or something similar? I thought that when a client is being used to send a new post to the server, the reply should be either the AP object of the post (to be appended to the local outbox) or an error object explaining what went wrong (wrong captcha, post too long, no attachment, etc) so a proper error page can be generated.

>>
Anonymous 06/03/22(Fri)22:27:52 No. fprog-AM6GXJD4 [Report]

2 more suggestions: An endpoint to get the list of boards (aka actors) of the instance to make it easier to subscribe to all of them. Change the meaning of the 'replies' attribute of a post. You see, on a regular post (reply to a thread, non-OP), the 'replies' contains the list of posts that directly mention said post (using >>), but on a thread, the 'replies' contains the list of posting replying to that thread, regardless of whether they mention OP or not. You probably noticed that the backquotes on a OP (the little >>s linking to mentions) contain every single reply to that thread, meanwhile the backquotes of posts work as intended. I don't know which other AP attribute to use instead of 'replies', probably something along the lines of 'mentions'. This is a fairly minor bug, though, and fixing it would cause incompatibility with FChannel, so I'd wait until devchad is also onboard with this before working on it.

>>
Anonymous 06/04/22(Sat)17:53:40 No. fprog-3974DB95 [Report]

>Doesn't HTTP have a Last-Modified header or something similar? the client can use If-Modified-Since which'll just result in a 304 Not Modified if the server says it hasn't been modified, else it'll send the content. that would be something nice. i'll implement this soon(tm) for activitypub routes. backwards compatible too since if the server doesn't care it'll just return 200 and the content anyway >the reply to a client posting should be either the AP object of the post or an error can do, will implement when i get around to it. i already return {"error": ...} if an error occurs but i don't think i do anything if it was successful other than return a 200 >boards fchan has this already with /following. it has the "main" actor, dunno how it works underneath everything but it works like an actor and it follows boards that are on the instance. do i like it? not really, so i'll probably just use /following and ditch everything else while remaining (mostly) compatible >replies i think it's implemented correctly already but my knowledge of activitypub was mostly gained from skimming the spec and banging requests off of fchannel until it worked. replies is supposed to be just that; replies to this object.

>>
Anonymous 06/04/22(Sat)20:58:59 No. fprog-6GIVJOIO [Report]

>>fprog-3974DB95 >If-Modified-Since Nice, HTTP seems to have a header to just about anything. >returning error to client Could also use the Accept header here, if the client only accepts JSON, and not HTML, then the server replies with a JSON, either a custom error object or the AS of the new post, else it replies with the regular HTML page. >/following Exactly what I was looking for, thanks. >replies is supposed to be just that; replies to this object. Well, I still think that replies and mentions should be two separate concepts. Mentions being a subset of replies.

>>
From FBI2 to Awoo to FChan Anonymous 06/05/22(Sun)13:48:43 No. fprog-1D2D372C [Report]

Now requesting /captcha first before scraping it off the board page. I am also thinking about using a "home" instance. As it is right now, when FBI2 replies to a thread, it sends the POST to the instance where the thread was created, the home instance would then be used regardless of that. The problem is that not all instances have the same board, so I can't use awoo to post to fchan's /b/ (especially given how posting works in feditext, maybe in fchannel it is possible to post to /b/ from /prog/, even if it doesn't follow /b/, but I think it could be considered abusive use). Alternatively, I could set home instances on a board-by-board basis. I tried sending the POST request to http://awoobbsamzdzpji2etemlbj2xvugsljyqwfcltd2jiirbdjmicgxeiid.onion/prog/DK37PT1F, but it failed (Invalid post ID). Trying http://awoobbsamzdzpji2etemlbj2xvugsljyqwfcltd2jiirbdjmicgxeiid.onion/prog/435 now.

>>
From FBI2 to Awoo to FChan Anonymous 06/05/22(Sun)13:55:11 No. fprog-42594E51 [Report]

Now requesting /captcha first before scraping it off the board page. I am also thinking about using a "home" instance. As it is right now, when FBI2 replies to a thread, it sends the POST to the instance where the thread was created, the home instance would then be used regardless of that. The problem is that not all instances have the same board, so I can't use awoo to post to fchan's /b/ (especially given how posting works in feditext, maybe in fchannel it is possible to post to /b/ from /prog/, even if it doesn't follow /b/, but I think it could be considered abusive use). Alternatively, I could set home instances on a board-by-board basis. I tried sending the POST request to http://awoobbsamzdzpji2etemlbj2xvugsljyqwfcltd2jiirbdjmicgxeiid.onion/prog/DK37PT1F, but it failed (Invalid post ID). Trying http://awoobbsamzdzpji2etemlbj2xvugsljyqwfcltd2jiirbdjmicgxeiid.onion/prog/435 now.

>>
Anonymous 06/05/22(Sun)14:35:31 No. fprog-2FD7E80E [Report]

you found an edge case that i didn't anticipate! it doesn't resolve ids that aren't its own. this shouldn't be too hard to fix since fchannel does it, maybe i should make all of the post forms go to /post and use the same kind of form that fchannel does and rid myself of posting to /prog/ or /prog/435 because then i could use inReplyTo to figure out where its going and do something based on that i have some spare time later today, i'll fuck around with it then. >maybe in fchannel it is possible to post to /b/ from /prog/, even if it doesn't follow /b/ the first post i made with feditext to fchan could be considered abusive use then, because fchan wasn't following me. i just told feditext it was and to my surprise, the post was accepted (see >>fprog-DK37PT1F) now there's 4 instances following me so i need not worry about this but fchan will accept posts even though it doesn't know who you are, and i'm pretty sure this is how it's supposed to work.

>>
Anonymous 06/05/22(Sun)20:17:24 No. fprog-RHQ9EFP8 [Report]

>>fprog-2FD7E80E >i just told feditext it was and to my surprise, the post was accepted Wait, then it means that instances can have a dummy board /client/ to serve as the actor used by clients thus making that home instance problem moot since you can just post to anywhere from any instance. But yea, you will need to make /post work like FChannel's, I'm pretty sure inReplyTo and sendTo will be necessary. And this is all only for replies, to create a new thread you obviously would need a real board, but that's a different matter.

>>
Anonymous 06/05/22(Sun)20:24:51 No. fprog-2327G187 [Report]

To be more precise on what I mean: FChannel uses inReplyTo, sendTo and boardName, but you can probably get away with just 2 of those. inReplyTo tells which thread is being replied (in this case https://fchan.xyz/prog/DK37PT1F) and from there you can extract the board name without relying on sendTo, and boardName is actually the name of the actor being used (which would be 'client' for client requests).

>>
Anonymous 06/06/22(Mon)01:08:28 No. fprog-56ED81C7 [Report]

just implemented /post and switched everything off to that endpoint. posting to thread ids will no longer work, you'll have to update that but the advantage is that your fchannel form thing should just work. >sendTo didn't need it, in fact i think fchannel only has it because of how it's designed. does fbi use it for any reason? >/client/ that may suck to implement. just need to import the thread first, and then we can post because you're supposed to check if an object exists the client may be waiting over 60 seconds for their post to actually post i may think about this for some time, leave it open for discussion.

>>
Anonymous 06/06/22(Mon)16:08:11 No. fprog-7876C821 [Report]

>implemented /post Great, I should be able to post from FBI2 without any problems now. >fchannel form thing should just work I still prefer to keep separate forms, for future servers. Also, FChannel receives POST requests encoded as multipart/form-data, which is completely unnecessary for feditext since it doesn't take attachments, and showing a file input would be pointless as well.

>>
Anonymous 06/06/22(Mon)16:22:19 No. fprog-546CA1B6 [Report]

due to me being extremely retarded i accidentally deleted this thread on my instance before fbi anon's post propagated and then i managed to hit a bug i was hoping to avoid next thing i'm writing is a confirmation dialog for deleting original post follows: >implemented /post Great, I should be able to post from FBI2 without any problems now. >fchannel form thing should just work I still prefer to keep separate forms, for future servers. Also, FChannel receives POST requests encoded as multipart/form-data, which is completely unnecessary for feditext since it doesn't take attachments, and showing a file input would be pointless as well.

>>
Anonymous 06/10/22(Fri)16:39:08 No. fprog-E945398D [Report]

I saw commit 1795cfba5039afc165de5abaaf4052471c685a6f (fedi: respect If-Modified-Since) and just wanna be clear: does the outbox now work as all-or-nothing? I mean, either it sends 304 Not Modified or the entire outbox? If that's the case, then it will be easy to make FBI2 compatible with it: just don't overwrite the local copy with an empty response (which I should have done by now tbh), but ideally it would return only the threads that were modified since that date. That would be a bit harder for me since it would need FBI2 to save it's local outboxes to disk and overwrite entries as necessary. An even more extreme version of it would be sending only the new replies detached from the thread object, so that I'd need to append them to the correct thread based on the 'inReplyTo' attribute. By the way, is it just me or does feditext not send a 'updated' attribute with the thread? I need it to properly order the threads otherwise FBI2 falls back to using 'published' which means the thread is completely unbumped. Though I think it would be pretty easy to get it myself by using the time of the latest reply, but how do I know if a reply was saged?

>>
Anonymous 06/10/22(Fri)19:45:59 No. fprog-D4KYJGCL [Report]

the outbox works as all or nothing, if a post wasn't created since If-Modified-Since it sends a 304 and nothing else with it. however if something was done since that date, the full outbox is sent >ideally it would return only the threads that were modified since that date that is ideal but complicates things. i'm not sure how actual activitypub implementations do it; or if anything at all for that matter >sending only the new replies detached from the thread object that makes things simpler, hell i can even use existing functions for that but i don't know >updated i don't think it does, no, at least anymore maybe. it should be dropped for posts, but not threads. >how do I know if a reply was saged? i don't even think you can on normal fchan, but there's one way to find out, i'll test with this post which is a sage post

>>
Anonymous 06/10/22(Fri)19:50:12 No. fprog-D6AD04A1 [Report]

okay, you just don't. look at the updated attribute of the thread, that's all you have to work with

>>
Anonymous 06/11/22(Sat)14:14:46 No. fprog-IKU0HCXU [Report]

I say leave the outbox as it is, the backwards compatibility is nice. Besides, there is bigger fish to fry. >sage You know, back when I was working on the headless server, I'd just send the options in the outbox, so if a post had 'sage' among the options you could treat it accordingly. But I don't think the AP vocabulary had an appropriate attribute for that; we can just make our own tbh.

>>
File a2c9f135b65edaf67d89c8fde4(...).png (443.55 KB)
Anonymous 06/13/22(Mon)00:04:16 No. fprog-D8QK0JNN [Report] >>fprog-9E97HWUL

Just finished reorganizing how FBI2 handles missing attributes. Some default values here, a little metatable with __index there, and now it will be easier to account for quirky outbox implementations in the future without having to check if everything exists. Duck typing is pretty easy once you get the hang of it. The TODO list has mostly only boring entries now, so I may actually get to set up the old HTTP server again at some point while procrastinating.

>>
Anonymous 06/18/22(Sat)18:18:02 No. fprog-9E97HWUL [Report] >>fprog-CT1RFIUI

>>fprog-D8QK0JNN >I may actually get to set up the old HTTP server again at some point while procrastinating And here it is: http://xdni7g5asjyvbjqo4tp4qar5j7kcjjuifnrwbxxubb37bgrxdyicnzyd.onion/ I'm a bit too lazy to set up everything as it once was, so for now it will just be a directory listing. This is currently on a VM, I will set everything up properly once I have it running on a permanent place.

>>
federal postman !nJkWir8Qy/ 07/02/22(Sat)23:03:40 No. fprog-CT1RFIUI [Report] >>fprog-TDA6QGTW

>>>><<<<< I just overhauled the function that formats the content of a post into proper HTML and I need to see if it is working all fine. Don't mind me. >test >testing >there is a quirk in how lua makes substitutions >thats why im adding so many greentexts <i added pinktext too <it seems hip and cool among other imageboards <when did pinktext come to be btw? im a bit curious about its history <i think it should be called lilactext tbh, like how GreenText is a joke on > it should be joke on < too >any other nice color that starts with l? idk >aaaaa (((and this text too))) (((gotta see how (((well))) it copes))) also going to test (((tripcodes))) because i need to make sure the way i format it is correct whats the difference between regular and secure tripcode anyway? gotta test references too https://fchan.xyz/prog/DK37PT1F >>fprog-DK37PT1F (OP) https://fchan.xyz/prog/DK37PT1F >>fprog-9E97HWUL>>fprog-9E97HWUL>>fprog-9E97HWUL >>fprog-9E97HWUL >>fprog-9E97HWUL >>>fprog-9E97HWUL > >>fprog-9E97HWUL > sample text >>fprog-9E97HWUL <>>fprog-9E97HWUL < >>fprog-9E97HWUL < sample text >>fprog-9E97HWUL ok i think thats all

>>
Anonymous 07/02/22(Sat)23:06:13 No. fprog-ZMEVXWHS [Report]

if i write a literal &_gt_; the browser will replace it with a < need to account for that too

>>
Anonymous 07/02/22(Sat)23:19:22 No. fprog-C36FE617 [Report]

i think see the problem, fchannels seems to escape a < at the beginning of a line, and that messes up the rest of the format

>>
Anonymous 07/02/22(Sat)23:20:30 No. fprog-DB8C91BE [Report]

not only at the begining of the line, but anywhere? whatever, im just rambling at this point

>>
Anonymous 07/03/22(Sun)11:43:34 No. fprog-BGAVUK4W [Report] >>fprog-0EDN6CQS

fchannel's html escaping kinda sucks imo and one thing i was going to fix and then i lost interest and had other things come up. all it does is replace a < with & gt; there's a couple other problems which has spanned from this and also breaks the catalog maybe this has changed since then, i don't know. i just don't have the willpower to install postgres just yet to hack on fchannel (yet) feditext does it more properly(?) by escaping the html and matching upon the escaped html

>>
Anonymous 07/03/22(Sun)12:10:29 No. fprog-TDA6QGTW [Report] >>fprog-0EDN6CQS

>>fprog-CT1RFIUI >what's the difference between regular and secure tripcode anyway? regular tripcodes are tossed verbatim into a hash function. they are predictable, therefore not secure. they have ! as the prefix. secure tripcodes also use a hash function, but use a secret piece of data (randomly generated) that only the server knows. they have !! as the prefix. a regular tripcode gets the same results every time on servers using the same hash function, a secure tripcode does not

>>
Anonymous 07/03/22(Sun)14:24:35 No. fprog-0EDN6CQS [Report] >>fprog-3LRHFODW

>>fprog-BGAVUK4W The real problem here is not even HTML being escaped improperly, it is that is it escaped on the outbox, which IMO should contain the raw post content as it was sent and let clients escape it however they see fit. If you look at prog's outbox you will see that all literal < are replaced with & lt; there instead of remaining raw. >>fprog-TDA6QGTW So one is salted and works only on the server, the other is not and works everywhere, cool. Servers could share their salt with other trusted servers, or allow some sort of user registration by associating a tripcode with someone. Servers could allow users to bypass captchas based on tripcode.

>>
Anonymous 07/03/22(Sun)15:43:43 No. fprog-3LRHFODW [Report] >>fprog-X8EJ21BS

>>fprog-0EDN6CQS >The real problem here is not even HTML being escaped improperly, it is that is it escaped on the outbox, which IMO should contain the raw post content this. i am in the process of converting the activity structs to be compliant with plemroma and what they do is have a source filed which is the raw source of the content and the content field is the parsed html. ill change this when things get converted. for now things have to be escaped how they are because the parse functions render as template HTML and people can just script w.e they want which is not good

>>
File 68f4e1e907653616ca0ddbbb69(...).gif (944.77 KB)
Anonymous 07/03/22(Sun)18:34:40 No. fprog-ZO2J34WU [Report] >>fprog-FSAUDEL7

Can I ask you to also add compatibility with FBI2 like feditext has? I mean the captcha endpoint, send a Server header with the IB backend (not nginx), understand the If-Modified-Since header when the outbox is requested, and take into account the Accept header when a POST request is made. I don't know if you have been following this thread, so I can explain those features if you want me to.

>>
Anonymous 07/03/22(Sun)18:51:54 No. fprog-FSAUDEL7 [Report]

>>fprog-ZO2J34WU yeah ill work on adding those. ill probably add the captcha endpoint when i change the captcha because the current one is trivial to break if someone wanted so providing an endpoint that can easily be broken time and a time again wouldnt be good but the other stuff makes sense.

>>
Anonymous 07/03/22(Sun)21:24:50 No. fprog-X8EJ21BS [Report] >>fprog-14I2I7K5

>>fprog-3LRHFODW while on my travels to see if what i was thinking was true, i found another issue! i found a way to discover the mod key and have an (albeit invalid) session token generated where i am in control of the password the report to this post will contain the mod key for proof while i haven't vetted the source yet, i'm sure that this is largely a non-issue for anywhere that checks auth, hopefully everywhere but if the whole point was to keep the mod key private, the location of where the issue is went with it

>>
Anonymous 07/03/22(Sun)21:55:28 No. fprog-14I2I7K5 [Report]

>>fprog-X8EJ21BS thanks for reporting that should be fixed.

>>
File f156d65bda77c318129ed7f42e(...).jpg (385.31 KB)
Anonymous 07/11/22(Mon)01:01:22 No. fprog-A7KRE2L2 [Report]

some times it is very hard to keep it together while programming for example, take a look at https://poopchan.org/pen/following do you notice anything? look at fchan.xyz/pen's entry >"id": " https://fchan.xyz/pen", why? WHY IS THERE A FUCKING SPACE BEFORE THE FUCKING ID WHY WHY WHY WHY WHY WHY WHY WH YWH YWHW YWH YW HWY HWY HWY WHY WHWY HW YWH YWH WYW HWY HWY HWY HYWH WYH WYW HWY WH YWHW YW HWYHWYWHYWHWYHWYWHWYHWYWHYWHWYHWYWHYWHWYWHYWHWYHWYWHWYHWYHWYWHWYHWYWHYWHWYWH no prob i will just remove the ^ from my match string and it will work ...OR FUCKING WILL IT? https://fchan.xyz/b/following >"id": "https://penchan.xyz" WHY THE FUCK IS IT FOLLOWING PENCHAN ITSELF INSTEAD OF ITS /B/?????? WHY CANT DATA JUST BE CONSISTNET AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA ok ok i can just make it default to the instance's board in such cases ...but is that even how it works? when it says simply "https://penchan.xyz" does it mean the same board as the actor (in this case 'b') or the entirety of penchan?

>>
Anonymous 07/14/22(Thu)17:53:29 No. fprog-B0331F3D [Report]

Releasing FBI2, now it is called CIA. The server is up: http://git.p6nhckzlonbw72mhxqcyfa474ssavlnud6tvpmhjzf37r2zyz2ommtqd.onion/cia/file/README.html FChannel can't show my past post with the changelog (though you can read it on the textboard - thank you, based feditext), but basically now you can post from the client, hide posts, see a map of the federation, and there is a page showing statistics about instances, posts, boards, etc.


[Post a Reply] 73 / 8

[Home] [Rules] [FAQ]

All trademarks and copyrights on this page are owned by their respective parties.

v0.1.1

Theme: