You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@guacamole.apache.org by Steven Pollock <ja...@gmail.com> on 2017/10/26 00:58:20 UTC

base64 encoded url

Running into a snag with this, could use some help.

http://11.26.56.131:8080/guacamole/#/client/MwBjAG15c3Fs/?username=secretuser&password=secretpassword

--this works in the URL
echo 'MwBjAG15c3Fs' | base64 -d

*3cmysql*

However, reversing, that is trying to create the base64 encoding does not.

echo '3cmysql' | base64

*M2NteXNxbAo=*

Anyone know how to properly encode?
Thanks!

-Steve

(415) 320-1102 <https://www.google.com/voice/#phones>

Re: base64 encoded url

Posted by Steven Pollock <ja...@gmail.com>.
Many thanks, this is a great help.

for completeness:

*printf '4\0c\0mysql' | base64 *

*NABjAG15c3Fs*

*is the correct answer.*

Regards,

-Steve

(415) 320-1102 <https://www.google.com/voice/#phones>


On Wed, Oct 25, 2017 at 7:37 PM, Nick Couchman <ni...@gmail.com>
wrote:

> On Wed, Oct 25, 2017 at 20:59 Steven Pollock <ja...@gmail.com>
> wrote:
>
>> Running into a snag with this, could use some help.
>>
>> http://11.26.56.131:8080/guacamole/#/client/MwBjAG15c3Fs/?
>> username=secretuser&password=secretpassword
>>
>> --this works in the URL
>> echo 'MwBjAG15c3Fs' | base64 -d
>>
>> *3cmysql*
>>
>> However, reversing, that is trying to create the base64 encoding does not.
>>
>> echo '3cmysql' | base64
>>
>> *M2NteXNxbAo=*
>>
>> Anyone know how to properly encode?
>>
>
> The encoding is a combination of three things:
> - ConnectIon ID (3)
> - Type (c)
> - Datasource name (MySQL)
>
> They are separated by a null terminator (\0), which is what you're missing
> when you try the echo command above.
>
> -Nick
>

Re: base64 encoded url

Posted by Nick Couchman <ni...@gmail.com>.
On Wed, Oct 25, 2017 at 20:59 Steven Pollock <ja...@gmail.com> wrote:

> Running into a snag with this, could use some help.
>
> http://11.26.56.131:8080/guacamole/#/client/MwBjAG15c3Fs/?username=
> secretuser&password=secretpassword
>
> --this works in the URL
> echo 'MwBjAG15c3Fs' | base64 -d
>
> *3cmysql*
>
> However, reversing, that is trying to create the base64 encoding does not.
>
> echo '3cmysql' | base64
>
> *M2NteXNxbAo=*
>
> Anyone know how to properly encode?
>

The encoding is a combination of three things:
- ConnectIon ID (3)
- Type (c)
- Datasource name (MySQL)

They are separated by a null terminator (\0), which is what you're missing
when you try the echo command above.

-Nick