<feed xmlns='http://www.w3.org/2005/Atom'>
<title>xavi/libweb/include/slweb, branch master</title>
<subtitle>Small and lightweight web framework written in C99 and POSIX.1-2008.
</subtitle>
<id>https://gitea.privatedns.org/xavi/libweb/atom?h=master</id>
<link rel='self' href='https://gitea.privatedns.org/xavi/libweb/atom?h=master'/>
<link rel='alternate' type='text/html' href='https://gitea.privatedns.org/xavi/libweb/'/>
<updated>2023-10-10T22:07:13+00:00</updated>
<entry>
<title>Rename project from slweb to libweb</title>
<updated>2023-10-10T22:07:13+00:00</updated>
<author>
<name>Xavier Del Campo Romero</name>
<email>xavi.dcr@tutanota.com</email>
</author>
<published>2023-10-10T21:21:35+00:00</published>
<link rel='alternate' type='text/html' href='https://gitea.privatedns.org/xavi/libweb/commit/?id=0222b75e8554796548e079aa3393c512ae30ac24'/>
<id>urn:sha1:0222b75e8554796548e079aa3393c512ae30ac24</id>
<content type='text'>
It was found out there was another project of the same name around
(https://git.sr.ht/~strahinja/slweb/), also related to website
generation.

In order to avoid confusion, a new name has been chosen for this
project. Surprisingly, libweb was not in use by any distributions
(according to https://repology.org and AUR index), and it should
reflect well the intention behind this project i.e., being a library
to build web-related stuff.
</content>
</entry>
<entry>
<title>http: Support HEAD</title>
<updated>2023-10-10T21:15:26+00:00</updated>
<author>
<name>Xavier Del Campo Romero</name>
<email>xavi.dcr@tutanota.com</email>
</author>
<published>2023-10-02T21:37:44+00:00</published>
<link rel='alternate' type='text/html' href='https://gitea.privatedns.org/xavi/libweb/commit/?id=07e0063870725506447a0ad29a6b92bb8c8c4e0b'/>
<id>urn:sha1:07e0063870725506447a0ad29a6b92bb8c8c4e0b</id>
<content type='text'>
</content>
</entry>
<entry>
<title>http.h: Remove stale comment</title>
<updated>2023-09-27T19:55:58+00:00</updated>
<author>
<name>Xavier Del Campo Romero</name>
<email>xavi.dcr@tutanota.com</email>
</author>
<published>2023-09-26T23:07:54+00:00</published>
<link rel='alternate' type='text/html' href='https://gitea.privatedns.org/xavi/libweb/commit/?id=0d54bbf08674174c1e7b91ce39984c29b78cf0ba'/>
<id>urn:sha1:0d54bbf08674174c1e7b91ce39984c29b78cf0ba</id>
<content type='text'>
This shall be replaced with more meaningful man pages for all functions
in slweb.
</content>
</entry>
<entry>
<title>http: Use null-terminated string for POST data</title>
<updated>2023-09-09T00:32:34+00:00</updated>
<author>
<name>Xavier Del Campo Romero</name>
<email>xavi.dcr@tutanota.com</email>
</author>
<published>2023-09-09T00:22:00+00:00</published>
<link rel='alternate' type='text/html' href='https://gitea.privatedns.org/xavi/libweb/commit/?id=5be3ffdd3bfd96b314509f6f03e211e309d0fef3'/>
<id>urn:sha1:5be3ffdd3bfd96b314509f6f03e211e309d0fef3</id>
<content type='text'>
application/x-www-form-urlencoded-data is (or should be) always text, so
it is preferrable to define struct http_post member "data" as a null-
terminated string.

For applications already making this assumption, this change should now
remove the need for string duplication.
</content>
</entry>
<entry>
<title>http: Insert name into http_post_file</title>
<updated>2023-09-08T22:39:43+00:00</updated>
<author>
<name>Xavier Del Campo Romero</name>
<email>xavi.dcr@tutanota.com</email>
</author>
<published>2023-09-08T22:36:26+00:00</published>
<link rel='alternate' type='text/html' href='https://gitea.privatedns.org/xavi/libweb/commit/?id=34d716082a0136056373f3d0c6ed7abce45484b3'/>
<id>urn:sha1:34d716082a0136056373f3d0c6ed7abce45484b3</id>
<content type='text'>
Whereas slcl, the project where slweb started, ignored this field, some
applications might require it.
</content>
</entry>
<entry>
<title>http: Allow multiple non-file Content-Disposition</title>
<updated>2023-09-08T22:21:42+00:00</updated>
<author>
<name>Xavier Del Campo Romero</name>
<email>xavi.dcr@tutanota.com</email>
</author>
<published>2023-09-08T22:19:39+00:00</published>
<link rel='alternate' type='text/html' href='https://gitea.privatedns.org/xavi/libweb/commit/?id=09909c0a3b326efd6a2b87df95d0e73c1e394c29'/>
<id>urn:sha1:09909c0a3b326efd6a2b87df95d0e73c1e394c29</id>
<content type='text'>
Now, slweb accepts requests such as:

--boundary
Content-Disposition: form-data; name="field1"

value1
--boundary
Content-Disposition: form-data; name="field2"

value2
--boundary
Content-Disposition: form-data; name="field3"; filename="example.txt"

The following breaking changes have been introduced:

Member "dir" from struct http_post was a leftover from the days where
slcl and slweb were one project. It did not make sense for slweb, since
it should not decide which Content-Disposition names are allowed. In
other words, "dir" was only relevant in the scope of slcl.

Member "n" from struct http_post used to have two meanings:

- The length of a URL-encoded request.
- The number of files on a multipart/form-data request.

Since "npairs" had to be introduced to struct http_post, it did not make
sense to keep this dual meaning any more. Therefore, "n" has been
restricted to the former, whereas a new member, called "nfiles", has
been introduced for the latter.
</content>
</entry>
<entry>
<title>handler: Define port as unsigned short</title>
<updated>2023-09-07T13:41:46+00:00</updated>
<author>
<name>Xavier Del Campo Romero</name>
<email>xavi.dcr@tutanota.com</email>
</author>
<published>2023-09-07T13:41:46+00:00</published>
<link rel='alternate' type='text/html' href='https://gitea.privatedns.org/xavi/libweb/commit/?id=f9e3516f5026babdea65e4cb6bb3756f0f8dd25a'/>
<id>urn:sha1:f9e3516f5026babdea65e4cb6bb3756f0f8dd25a</id>
<content type='text'>
Port numbers are unsigned by definition. Fortunately, this was a minor
issues since server_init was doing an implicit cast to unsigned short.
</content>
</entry>
<entry>
<title>Move header files to subdirectory</title>
<updated>2023-07-20T23:28:38+00:00</updated>
<author>
<name>Xavier Del Campo Romero</name>
<email>xavi.dcr@tutanota.com</email>
</author>
<published>2023-07-20T21:47:33+00:00</published>
<link rel='alternate' type='text/html' href='https://gitea.privatedns.org/xavi/libweb/commit/?id=8c3ba33ced08b211db0cd5f81675bdf62f55acc7'/>
<id>urn:sha1:8c3ba33ced08b211db0cd5f81675bdf62f55acc7</id>
<content type='text'>
Since slweb is meant as a library, it is advisable to keep public header
files under their own directory in order to avoid name clashing i.e.,

 #include "something.h"

Now becomes:

 #include "slweb/something.h"
</content>
</entry>
</feed>
