- CheckMates
- :
- Products
- :
- Quantum
- :
- Management
- :
- Re: Json Network Feed
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
Are you a member of CheckMates?
×- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Json Network Feed
Hi
Try to create a Network Feed parsing a JSON. Unfortunately Test Feed in SmartConsole always exit with error message:
"Object name contains special characters or whitespaces. Invalid character: 'space'"
Feed URL: https://www.gstatic.com/ipranges/goog.json
JSON Query: jq -r '.prefixes[].ipv4Prefix'
also tried with JSON Query: jq -r '.prefixes[] | select(.ipv4Prefix) | .ipv4Prefix'
Using the JQ Playground jq playground both of my queries work.
What's wrong with my input in JSON Query field?
Thx for support
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The JSON Query does not include jq -r, only the expression.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The JSON Query does not include jq -r, only the expression.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Phoneboy is right, I tested in the lab and it worked how he described it.
Andy
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks for your answers - I also tried without the "jq" command but get same error message.
Can you post a screenshot of the "New Network Feed" window?
I assume I struggle with the quotation marks. I tried several ways but without success!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hey @AndreasSalv
Please give me some time and I will test. I cant recall how I did it the other day, but will figure it out.
Andy
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Below is 100% right, but now says no data found, so must be something wrong with the feed itself.
Andy
".prefixes[] | select(.ipv4Prefix) | .ipv4Prefix"
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Sorry fo the delay .... tested directly on cli and there I get data:
[Expert@nfw110:1]# curl_cli -k https://www.gstatic.com/ipranges/goog.json | jq -r ".prefixes[] | select(.ipv4Prefix) | .ipv4Prefix"
Tested on SmartConsole again:
Result:
and tested this way:
and got:
so difference is used fw appliance:
curl_cli uses vs1 on nfw110 (this is also the finally used one), SmartConsole uses nfw500 which is not the one I really want but I can't choose a VSX based fw...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Did you do it like I tried?
".prefixes[] | select(.ipv4Prefix) | .ipv4Prefix"
Andy
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes also tried without the -r Option of JQ
