Re: JWT decoder

2021-08-11 Thread Daniel Verite
Masih Tavassoli wrote: > But there doesn't seem to be a way doing it in postgres. > Has anyone got any suggesions? RFC 7519 says: A JWT is represented as a sequence of URL-safe parts separated by period ('.') characters. Each part contains a base64url-encoded value. The number

Re: JWT decoder

2021-08-09 Thread Mladen Gogala
Hmmm, Pl/Python and Pl/Perl are languages usable from within Postgres. You can write Python functions in Postgres. I apologize for not making that clear. On 8/9/21 1:15 AM, Masih Tavassoli wrote: There are lots of decoders but I need to do it within postgresql. On Monday, August 9, 2021, 01:2

Re: JWT decoder

2021-08-08 Thread Masih Tavassoli
That was not the question, the question is how do you decode base64url (not base64) in postgres sql? On Monday, August 9, 2021, 02:08:44 PM GMT+10, rob stone wrote: Hello, On Mon, 2021-08-09 at 02:16 +, Masih Tavassoli wrote: > Hi experts, > > I am trying to find a way to decode

Re: JWT decoder

2021-08-08 Thread Masih Tavassoli
There are lots of decoders but I need to do it within postgresql. On Monday, August 9, 2021, 01:24:33 PM GMT+10, Mladen Gogala wrote: You could probably use Pl/Python. Python has base64 module and urllib module which can deal with all URL strings I am aware of.  Pl/Perl would probabl

Re: JWT decoder

2021-08-08 Thread rob stone
Hello, On Mon, 2021-08-09 at 02:16 +, Masih Tavassoli wrote: > Hi experts, > > I am trying to find a way to decode a URL request header and extract > its JSON fields in postgreql . > > I can do this in Oracle sql using  > > select    (utl_raw.cast_to_varchar2 (utl_encode.base64_decode( > ut

Re: JWT decoder

2021-08-08 Thread Mladen Gogala
You could probably use Pl/Python. Python has base64 module and urllib module which can deal with all URL strings I am aware of. Pl/Perl would probably do as well. On 8/8/21 10:16 PM, Masih Tavassoli wrote: Hi experts, I am trying to find a way to decode a URL request header and extract its J