Anybody written a JSON Parser?
Moderators: Susan Smith, admin, Gabriel
-
- Posts: 292
- Joined: Fri Jun 19, 2009 9:01 am
- Location: Lawrence, Kansas
- Contact:
Re: Anybody written a JSON Parser?
Any and all examples you have would be helpful! Especially POST operations of JSON data.
Steve Koger
Computer Specialist
SEKESC-MACS Division
Computer Specialist
SEKESC-MACS Division
-
- Posts: 292
- Joined: Fri Jun 19, 2009 9:01 am
- Location: Lawrence, Kansas
- Contact:
Re: Anybody written a JSON Parser?
Just checking if you had a chance to throw together some examples?
Steve Koger
Computer Specialist
SEKESC-MACS Division
Computer Specialist
SEKESC-MACS Division
Re: Anybody written a JSON Parser?
I haven't had any time, very busy week, but I finally dug up BR 4.2 release notes where some HTTP client documentation lives.
Coincidentally, I need to write a BR program that involves HTTP client using GET and POST to talk to a web server. So I will try to post an example asap.
Coincidentally, I need to write a BR program that involves HTTP client using GET and POST to talk to a web server. So I will try to post an example asap.
Re: Anybody written a JSON Parser?
I made an example of a BR http client sending a request to BR http server, which runs in another BR session. BR forum won't let me upload the ZIP file containing the example though. So I can upload it elsewhere or email it to those who need it
-
- Posts: 292
- Joined: Fri Jun 19, 2009 9:01 am
- Location: Lawrence, Kansas
- Contact:
Re: Anybody written a JSON Parser?
You can rename the file from a .zip extension to a .txt and then it will allow you to upload. Then anyone who downloads needs to rename the file back to a .zip extension.
Meanwhile you can send it to steve.koger@greenbush.org.
Meanwhile you can send it to steve.koger@greenbush.org.
Steve Koger
Computer Specialist
SEKESC-MACS Division
Computer Specialist
SEKESC-MACS Division
Re: Anybody written a JSON Parser?
The problem is that the file is too big.
Here is a link where you can download the example that works on BR 4.31hg:
https://drive.google.com/file/d/0BzAKV2 ... sp=sharing
Instructions:
1) unzip
2) copy your brserial.dat into httpclient folder
3) load BR.exe and run web_server.bro
Windows may ask you to allow BR through the firewall
4) load a second session of BR.exe and run httpclient.br
5) watch as data gets sent from httpclient to web_server, then processed and sent back to the client
Here is a link where you can download the example that works on BR 4.31hg:
https://drive.google.com/file/d/0BzAKV2 ... sp=sharing
Instructions:
1) unzip
2) copy your brserial.dat into httpclient folder
3) load BR.exe and run web_server.bro
Windows may ask you to allow BR through the firewall
4) load a second session of BR.exe and run httpclient.br
5) watch as data gets sent from httpclient to web_server, then processed and sent back to the client
-
- Posts: 292
- Joined: Fri Jun 19, 2009 9:01 am
- Location: Lawrence, Kansas
- Contact:
Re: Anybody written a JSON Parser?
Thanks! Just what I needed. Although I have it uploading JSON to non-BR http server.
Steve Koger
Computer Specialist
SEKESC-MACS Division
Computer Specialist
SEKESC-MACS Division