about summary refs log tree commit diff stats
path: root/src/loader/cgi.nim
Commit message (Collapse)AuthorAgeFilesLines
* Add urlenc, urldec; fix a URL encoding bug; improve trans.cgibptato2024-01-081-0/+2
| | | | | | | | | | * Fix incorrect internal definition of the fragment percent-encode set * urlenc, urldec: these are simple utility programs mainly for use with shell local CGI scripts. (Sadly the printf + xargs solution is not portable.) * Pass libexec directory as an env var to local CGI scripts * Update trans.cgi to use urldec and add an example for combining it with selections
* Use std/* imports everywherebptato2024-01-071-5/+5
|
* Compile with styleCheck:usagesbptato2023-12-281-2/+2
| | | | much better
* cgi: return ConnectionError when script is not executablebptato2023-12-211-1/+2
|
* Implement local CGI error message handlingbptato2023-12-151-1/+7
| | | | | | This was documented, but not implemented until now. Also, improve the loader module's protocol documentation.
* Move http out of main binarybptato2023-12-131-17/+15
| | | | | | | | | | | | Now it is (technically) no longer mandatory to link to libcurl. Also, Chawan is at last completely protocol and network backend agnostic :) * Implement multipart requests in local CGI * Implement simultaneous download of CGI data * Add REQUEST_HEADERS env var with all headers * cssparser: add a missing check in consumeEscape
* Move out ftp: protocol; fix some local CGI bugsbptato2023-12-121-8/+15
|
* Move out file: protocol handling to adapter/bptato2023-12-121-1/+0
|
* local CGI improvements, move data: to cgi-binbptato2023-12-121-14/+82
| | | | error codes are WIP, not final yet...
* local CGI: add mapped URI env vars; move about: to adaptersbptato2023-12-121-3/+16
| | | | | | | | | | | | | | | * Add MAPPED_URI_* as environment variables when a request is coming from urimethodmap It costs us compatibility with w3m, but it seems to be a massive improvement over smuggling in the URL as a query string and then writing an ad-hoc parser for every single urimethodmap script. The variables are set for every urimethodmap request, to avoid accidental leaking of global environment variables. * Move about: to adapters (an obvious improvement over the previous solution)
* Add w3m-cgi-compat optionbptato2023-10-011-1/+5
|
* loader: add local-cgibptato2023-09-301-0/+165
Add w3m-style local CGI support. It is not quite as powerful as w3m's local CGI, because it lacks an equivalent to W3m-control. Not sure if it's worth adding; we certainly shouldn't allow passing JS in headers, but a custom language for headers does not sound like a great idea either... eh, idk. also, TODO add multipart