p0wny-shell icon indicating copy to clipboard operation
p0wny-shell copied to clipboard

Error while parsing response: SyntaxError: JSON.parse: unexpected end of data at line 1 column 1 of the JSON data

Open troidesss opened this issue 3 years ago • 4 comments

Hi, i have error what can be wrong?

troidesss avatar Oct 15 '20 20:10 troidesss

No idea what is going wrong, maybe PHP error are print in the middle of the JSON?

flozz avatar Feb 02 '21 12:02 flozz

You seem to have a problem in function makeRequest(url, params, callback).

This happens if you have a JSON.parse(xhr.responseText) where xhr.responseText is not Json but an HTML page, that gets returned. Of course, this can not be parsed then as Json...

I had this error, when trying to run the shell on an application that was hosted on Windows. You don't have things like /bin/bash there. It seems the script is only useful on Linux hosts.

void-m4110c avatar Aug 19 '21 11:08 void-m4110c

I know some people have it working with Windows but yes it is not the dev focus.

Also it is not normal you receive HTML content in response of the XHR.... Can you provide the content of the HTML page? is it a php error page?

flozz avatar Aug 19 '21 12:08 flozz

Hi, i have error what can be wrong?

it seems like, php is not installed on that target machine. if the machine is owned by you...try this

sudo apt install php libapache2-mod-php

i hope it should work now...

akr3ch avatar Feb 12 '22 07:02 akr3ch

@flozz What is the state of this issue, is this still open?

cli-ish avatar May 31 '23 18:05 cli-ish

I think we can close this issue :)

flozz avatar Jun 01 '23 11:06 flozz