Re: Preventing Denial of Service Attack In IPC Serialization
On Jul 9, 8:53 am, jlind...@hotmail.com wrote:
1) The flaw in B.Ser was pointed out by Sebastian Redl, not you.
2) The simple fix for it was also pointed out by Sebastian Redl.
3) That simple fix is valid, as long as one only passes in bounded
amounts of data to the deserialization framework.
Jeffs, and your, point was that *Boost.Asio* was using serialization
in the same flawed way you are. That was obviously untrue.
It is true. It is very apparent in the code.
And that doesn't affect the veracity of point (1), BTW.
2. The "simple fix" is not a fix, IMO.
Thats your own, wholly unsubstantiated, opinion. I, and others, have
given concrete arguments for why it is a valid fix (see point (3)).
3. It will be seen in the future, perhaps this thread, that the only
way to solve this problem, that the ideal way (so far), of solving
this problem, is to let the objects themselves participate in the
control of how much data is being received, _not_ pre-allocating any
buffers, nor doing any reallocation. I am willing to exercise as much
patience as necessary until everyone else sees this.
Are you speaking as a prophet or an engineer?
If you still think, as you did in your OP, that there is a general
problem with the use of C++ serialization frameworks in IPC
applications, then please specify exactly what that problem is.
Well, I have a solution to the problem that I illustrated in my OP. I
do not consider the "pre-allocate a 1MB buffer". My hands are tied
right now with administrative issues unrelated to engineering, but
someday soon I will normalize my solution and present it here, and it
will be seen that, aside from the arbitariness in specification of
limits on how much data can be received from a socket, the solution is
workable.
The question still stands: What exactly is the problem?
The problem is that the sender can induce DoS at the receiver. Your
"solution" is not a solution because it does not solve this problem.
Not even in a bad way, now that I think about it.
The allegations in your OP, concerning C++ serialization frameworks
and IPC applications, have been comprehensively refuted. Is there
another problem you are now considering?
You are talking in circles. The truth is, some hacker is going to
find some commercial naked implementation of Boost Serialization and
bring down the machine that is running it. And the code will have to
be fixed, but you will still be right.
-Le Chaud Lapin-
--
[ See http://www.gotw.ca/resources/clcm.htm for info about ]
[ comp.lang.c++.moderated. First time posters: Do this! ]