JSON format to use for rlm_rest
Hi Guys I am struggling to find the right format to respond with to the rlm_rest module in JSON format. I'm responding with : { "ClearText-Password": "12345", "Reply-Message": "pass" } I'm responding with the correct Content-Type of "application/json" I'm getting to following error: (10) rest : Processing body (10) rest : Decoding attribute "ClearText-Password" (10) WARNING: rest : Attribute name refers to outer request but not in a tunnel, skipping (10) rest : Decoding attribute "Reply-Message" (10) WARNING: rest : Attribute name refers to outer request but not in a tunnel, skipping Could someone please point me in the right direction. I've tried many different ways of formating the JSON. Thank you
On 16 Mar 2014, at 13:59, Werner Stucky <wernerml@stucky-solutions.net> wrote:
Hi Guys
I am struggling to find the right format to respond with to the rlm_rest module in JSON format.
I'm responding with :
{ "ClearText-Password": "12345", "Reply-Message": "pass" }
I'm responding with the correct Content-Type of "application/json"
I'm getting to following error:
(10) rest : Processing body (10) rest : Decoding attribute "ClearText-Password" (10) WARNING: rest : Attribute name refers to outer request but not in a tunnel, skipping (10) rest : Decoding attribute "Reply-Message" (10) WARNING: rest : Attribute name refers to outer request but not in a tunnel, skipping
Could someone please point me in the right direction. I've tried many different ways of formating the JSON.
Hm, probably API change during pre-releases, it did work two years ago when I wrote the code. I'll check it now and commit a fix. Your JSON text looks correct. Arran Cudbard-Bell <a.cudbardb@freeradius.org> FreeRADIUS Development Team FD31 3077 42EC 7FCD 32FE 5EE2 56CF 27F9 30A8 CAA2
On 16 Mar 2014, at 16:07, Arran Cudbard-Bell <a.cudbardb@freeradius.org> wrote:
On 16 Mar 2014, at 13:59, Werner Stucky <wernerml@stucky-solutions.net> wrote:
Hi Guys
I am struggling to find the right format to respond with to the rlm_rest module in JSON format.
I'm responding with :
{ "ClearText-Password": "12345", "Reply-Message": "pass" }
I'm responding with the correct Content-Type of "application/json"
I'm getting to following error:
(10) rest : Processing body (10) rest : Decoding attribute "ClearText-Password" (10) WARNING: rest : Attribute name refers to outer request but not in a tunnel, skipping (10) rest : Decoding attribute "Reply-Message" (10) WARNING: rest : Attribute name refers to outer request but not in a tunnel, skipping
Could someone please point me in the right direction. I've tried many different ways of formating the JSON.
Hm, probably API change during pre-releases, it did work two years ago when I wrote the code.
I'll check it now and commit a fix. Your JSON text looks correct.
Ok, could you try v3.0.x HEAD. Arran Cudbard-Bell <a.cudbardb@freeradius.org> FreeRADIUS Development Team FD31 3077 42EC 7FCD 32FE 5EE2 56CF 27F9 30A8 CAA2
participants (2)
-
Arran Cudbard-Bell -
Werner Stucky