History log of /haiku/src/kits/network/libnetapi/NetworkRequest.cpp
Revision Date Author Comments
# f40841ac 28-Jul-2017 Adrien Destugues <pulkomandy@pulkomandy.tk>

BNetworkRequest: fix _GetLine on empty lines.

On an empty line terminated by \n, we would access the temporary buffer
(stack allocated) with an index of (uint32)-1. On 32bit machine this
would just read the byte before the array on the stack, but on 64bit it
would crash.

Check that the length is at least 1 before trying to access a character
in the array.

Fixes #13625.

Thanks to accessays for proofreading the code:


# 755f6d2f 14-Jun-2015 Adrien Destugues <pulkomandy@gmail.com>

BNetworkRequest: Remove workaround that is not needed anymore

Now that netresolv handles DNS resolution properly, there is no need to
force IPv4 here.


# be37c44a 26-Sep-2014 Adrien Destugues <pulkomandy@gmail.com>

style fix.


# 2f368731 26-Sep-2014 Adrien Destugues <pulkomandy@gmail.com>

UrlRequest: add empty SetTimeout for ease of use.

* Requests that support this can implement it, NetworkRequest does
* Build fix: no need to return status_t.


# 654ae69a 24-Sep-2014 Adrien Destugues <pulkomandy@gmail.com>

NetworkRequest: add a SetTimeout method.


# c98378e5 15-Sep-2014 Adrien Destugues <pulkomandy@gmail.com>

Add HTTP proxy support.

* Move default context management to BUrlRequest since some code
(including the testsuite) bypass the BUrlProtocolRoster.
* Introduce proxy host and port in BUrlContext
* Have BHttpRequest use the proxy when making requests


# 89b4e98a 04-Aug-2014 Adrien Destugues <pulkomandy@pulkomandy.tk>

Move signal hack to BNetworkRequest

* This is used to unlock sockets when a read is pending after a close
* It is not needed on requests that don't use a socket.


# 2f9b1874 04-Aug-2014 Adrien Destugues <pulkomandy@pulkomandy.tk>

Factor out a BNetworkRequest

* Shares common behavior between the Gopher and HTTP request handlers.
* Most of this can be used when implemeting other protocols.


# 755f6d2f8343c912febc4861b9f675ce8f4ecb13 14-Jun-2015 Adrien Destugues <pulkomandy@gmail.com>

BNetworkRequest: Remove workaround that is not needed anymore

Now that netresolv handles DNS resolution properly, there is no need to
force IPv4 here.


# be37c44a19207fb96be88d335a2e6f57722fca46 26-Sep-2014 Adrien Destugues <pulkomandy@gmail.com>

style fix.


# 2f368731056f04ae32733515a1f6d909de9e79d6 26-Sep-2014 Adrien Destugues <pulkomandy@gmail.com>

UrlRequest: add empty SetTimeout for ease of use.

* Requests that support this can implement it, NetworkRequest does
* Build fix: no need to return status_t.


# 654ae69aa615200d378cb3dac74dd6ad85b62b93 24-Sep-2014 Adrien Destugues <pulkomandy@gmail.com>

NetworkRequest: add a SetTimeout method.


# c98378e51ae02d8ad6e833c7eb8223a10cbd46f5 15-Sep-2014 Adrien Destugues <pulkomandy@gmail.com>

Add HTTP proxy support.

* Move default context management to BUrlRequest since some code
(including the testsuite) bypass the BUrlProtocolRoster.
* Introduce proxy host and port in BUrlContext
* Have BHttpRequest use the proxy when making requests


# 89b4e98a8fbef003d06732181a384bda84c969c8 04-Aug-2014 Adrien Destugues <pulkomandy@pulkomandy.tk>

Move signal hack to BNetworkRequest

* This is used to unlock sockets when a read is pending after a close
* It is not needed on requests that don't use a socket.


# 2f9b1874977669807fe200c7d3595d86a1984454 04-Aug-2014 Adrien Destugues <pulkomandy@pulkomandy.tk>

Factor out a BNetworkRequest

* Shares common behavior between the Gopher and HTTP request handlers.
* Most of this can be used when implemeting other protocols.