Re: [PATCH XENSTORE v1 06/10] xenstored: handle port reads correctly

2021-03-02 Thread Jürgen Groß
On 02.03.21 08:48, Norbert Manthey wrote: On 3/2/21 6:15 AM, Jürgen Groß wrote: On 26.02.21 16:36, Andrew Cooper wrote: On 26/02/2021 14:41, Norbert Manthey wrote: The read value could be larger than a signed 32bit integer. As -1 is used as error value, we should not rely on using the full 32

Re: [PATCH XENSTORE v1 06/10] xenstored: handle port reads correctly

2021-03-01 Thread Norbert Manthey
On 3/2/21 6:15 AM, Jürgen Groß wrote: > On 26.02.21 16:36, Andrew Cooper wrote: >> On 26/02/2021 14:41, Norbert Manthey wrote: >>> The read value could be larger than a signed 32bit integer. As -1 is >>> used as error value, we should not rely on using the full 32 bits. >>> Hence, when reading the

Re: [PATCH XENSTORE v1 06/10] xenstored: handle port reads correctly

2021-03-01 Thread Jürgen Groß
On 26.02.21 16:36, Andrew Cooper wrote: On 26/02/2021 14:41, Norbert Manthey wrote: The read value could be larger than a signed 32bit integer. As -1 is used as error value, we should not rely on using the full 32 bits. Hence, when reading the port number, we should make sure we only return vali

Re: [PATCH XENSTORE v1 06/10] xenstored: handle port reads correctly

2021-02-26 Thread Andrew Cooper
On 26/02/2021 14:41, Norbert Manthey wrote: > The read value could be larger than a signed 32bit integer. As -1 is > used as error value, we should not rely on using the full 32 bits. > Hence, when reading the port number, we should make sure we only return > valid values. > > This change sanity ch

[PATCH XENSTORE v1 06/10] xenstored: handle port reads correctly

2021-02-26 Thread Norbert Manthey
The read value could be larger than a signed 32bit integer. As -1 is used as error value, we should not rely on using the full 32 bits. Hence, when reading the port number, we should make sure we only return valid values. This change sanity checks the input. The issue is that the value for the por