Subject: Callout Protocol Core - Kept parameter

From: Martin Thelian <[email-masked]>
Date: Mon, 17 Apr 2006 16:21:46 +0200

Hi,

I am confused about the definition of the Kept parameter of a DUM 
message. The parameter is defined in rfc4037 as follows
|>   DUM: extends message with {
|>           xid my-offset;
|>           [As-is: org-offset];
|>           [Kept: org-offset org-size ];
|>           [Modp: modp];
|>   } and payload;

And in rfc4236 the Kept parameter is e.g. used in the following example:
|>    P: DUM 88 65
|>       Kept: 65 64
|>       AM-Part: response-header
|>
|>       64:HTTP/1.1 200 OK
|>       Content-Type: text/html
|>       Content-Length: 95

I'm confused, because the value of the Kept parameter doesn't follow the 
rules for a valid message format (see: rfc 4037, 3.1). A value can be a 
struct, list or atom. The value shown in the example is not a struct or 
list, so it must be an atom value. But a atom value must not have 
spaces, or the value has to be quoted.

So, what's the correct representation of the Kept parameter value?

As list?
|> Kept: (65,64)

As structure?
|> Kept: {65 64}

Quoted?
|> Kept: "65 64"

Regards,
Martin Thelian

---

From: Martin Thelian <[email-masked]>
Date: Tue, 25 Apr 2006 18:32:38 +0200

Hi!

Thank you for your answer.

Martin Stecher schrieb:
> [..]
> I am confused too and wonder why I didn't see that before.
> Probably the idea was that the value of a named parameter can be a
> space separated list of values and therefore the CRLF separation of
> the named parameters has been introduced.
> That means:
>
>   named-value = name ":" SP value *(SP value)
>   
 From my point of view this would be the best solution to resolve this 
conflict.
The rule for named values could then be rewritten to:

named-value = name ":" SP anonym-parameters

> [...]
> Would work by syntax but I think the idea of a list is that the number
> of elements is not preset.
>   
I've used this example, because there is the following sentence in rfc4037:

|> For simplicity, preserved data is always a contiguous chunk of
|> original data, described by an (offset, size) pair using a "Kept"
|> parameter of a Data Use Mine (DUM) message.

In this sentence the Kept parameter parts where written as list. But 
maybe it's only a strange coincidence.
>> Quoted?
>> |> Kept: "65 64"
>>     
> No! Quoted syntax is size colon value and not appropriate here.
>   
Yes, you are right. The above example is syntactically invalid and 
should be written as "5:65 64". Anyway. It makes no sense to do this.

Regards,
Martin