Categories
Cryptocurrency Development Ethereum

EIP-712 typed signature for arrays

I’m trying to generate a typed signature for an array in JavaScript based on EIP-712 and using eth-sig-util. My problem is that I need to sign an array. It says in the specification to use Type[] or Type[n] for arrays. Definition: The reference types are arrays and structs. Arrays are either fixed size or dynamic […]

Categories
Development JSON

how to parse nested json in scala

Goal: I am trying to parse the following HAR format to a postman_collection json, and persist the result into json in disk. I need to do the same from postman_collection to HAR format, but lets start with the HAR first. example HAR format used to import data and describe HTTP calls from: https://github.com/Kong/httpsnippet { “queryString”: […]

Categories
Development JSON

how to parse nested json in scala

Goal: I am trying to parse the following HAR format to a postman_collection json. example HAR format used to import data and describe HTTP calls from: https://github.com/Kong/httpsnippet { “queryString”: [ { “name”: “foo”, “value”: “baz” }, { “name”: “baz”, “value”: “abc” } ], “method”: “POST”, “url”: “http://mockbin.com/har?key=value”, “httpVersion”: “HTTP/1.1”, “queryString”: [ { “name”: “foo”, “value”: […]

Categories
Development JSON

how to parse nested json in scala

I am trying to implement a parser between a postman collection json and the HAR json as in the following example json. It should work in both directions, e.g. from postman collection to HAR and HAR to postman collection. example HAR format used to import data and describe HTTP calls from: https://github.com/Kong/httpsnippet { “queryString”: [ […]

Categories
Development JSON

how to parse nested json in scala

{ “queryString”: [ { “name”: “foo”, “value”: “baz” }, { “name”: “baz”, “value”: “abc” } ], “method”: “POST”, “url”: “http://mockbin.com/har?key=value”, “httpVersion”: “HTTP/1.1”, “queryString”: [ { “name”: “foo”, “value”: “bar” }, { “name”: “foo”, “value”: “baz” }, { “name”: “baz”, “value”: “abc” } ], “headers”: [ { “name”: “accept”, “value”: “application/json” }, { “name”: “content-type”, “value”: […]

Categories
Development JSON

how to parse nested json in scala

{ “queryString”: [ { “name”: “foo”, “value”: “baz” }, { “name”: “baz”, “value”: “abc” } ], “method”: “POST”, “url”: “http://mockbin.com/har?key=value”, “httpVersion”: “HTTP/1.1”, “queryString”: [ { “name”: “foo”, “value”: “bar” }, { “name”: “foo”, “value”: “baz” }, { “name”: “baz”, “value”: “abc” } ], “headers”: [ { “name”: “accept”, “value”: “application/json” }, { “name”: “content-type”, “value”: […]

Categories
Development JSON

how to parse nested json in scala

{ “queryString”: [ { “name”: “foo”, “value”: “baz” }, { “name”: “baz”, “value”: “abc” } ], “method”: “POST”, “url”: “http://mockbin.com/har?key=value”, “httpVersion”: “HTTP/1.1”, “queryString”: [ { “name”: “foo”, “value”: “bar” }, { “name”: “foo”, “value”: “baz” }, { “name”: “baz”, “value”: “abc” } ], “headers”: [ { “name”: “accept”, “value”: “application/json” }, { “name”: “content-type”, “value”: […]

Categories
Development

How to return JSON “true” in Python

I have a simple python code that returns a JSON object with one boolean fields and two others. The goal is to get the following response { “prop”: “foo”, “name”: “bar”, “isSomething”: true } I need a valid JSON true, but the python response gives me a JSON string “true”. { “prop”: “foo”, “name”: “bar”, […]

Categories
Development

Spring Boot with Spring Security returns 404 on valid login

When I activate Spring Security trough custom bean @PreAuthorize(“@mySecurity.check(#car)”) valid requests (check returns true) will end up in 404, and invalid requests will end up in 200. Without the PreAuthorize all works fine. The authorisation is done via JWT, and the granted authorities are set correctly. When I step through the debugger, the PreAuthorize check […]