B3AR Posted February 24, 2021 Share Posted February 24, 2021 So I am new to this and I am trying to setup a c2 remote server I am following along this video https://www.youtube.com/watch?v=TIpx_ENurLY but when I try to install c2 it shoots out this error <see below>. Any idea on what I am doing wrong. [c2.zip] End-of-central-directory signature not found. Either this file is not a zipfile, or it constitutes one disk of a multi-part archive. In the latter case the central directory and zipfile comment will be found on the last disk(s) of this archive. unzip: cannot find zipfile directory in one of c2.zip or c2.zip.zip, and cannot find c2.zip.ZIP, period. Quote Link to comment Share on other sites More sharing options...
chrizree Posted February 24, 2021 Share Posted February 24, 2021 For some reason wget https://c2.hak5.org/dl -O c2.zip doesn't seem to work anymore. If you cat the downloaded file it will most likely be a html file, hence unzip complaining about the fact that it is not recognized as a zip file. Try wget https://c2.hak5.org/download/community -O c2.zip instead. The file should be about 47.5 MB when downloaded. 1 Quote Link to comment Share on other sites More sharing options...
B3AR Posted February 24, 2021 Author Share Posted February 24, 2021 Thanks, it fixed the download issue but It did not give me a c2 token and when I try to use browser to reach server it cannot be reached. heres the working download code for those who are having issues wget https://c2.hak5.org/download/community -O c2.zip && unzip -qq && \ IP=$(curl -s https://checkip.amazonaws.com) && \ echo "Copy the below setup token to browser http://$IP:8080" &&\ ./c2_community-linux-64 -hostname $IP-listenip $IP Quote Link to comment Share on other sites More sharing options...
chrizree Posted February 24, 2021 Share Posted February 24, 2021 The zip file is missing in that string when issuing the unzip command Quote Link to comment Share on other sites More sharing options...
chrizree Posted February 24, 2021 Share Posted February 24, 2021 You are probably also using the wrong name for the binary Quote Link to comment Share on other sites More sharing options...
B3AR Posted February 24, 2021 Author Share Posted February 24, 2021 I was able to unzip it but all it says is inflating: c2-3.1.1_amd64_linux inflating: c2-3.1.1_amd64_windows.exe inflating: c2-3.1.1_armv5_linux inflating: c2-3.1.1_armv6_linux inflating: c2-3.1.1_armv7_linux inflating: c2-3.1.1_armv8_linux inflating: c2-3.1.1_i386_linux inflating: c2-3.1.1_i386_windows.exe Im not sure where I would find the c2 token Quote Link to comment Share on other sites More sharing options...
chrizree Posted February 24, 2021 Share Posted February 24, 2021 You will get it when you successfully run the binary Not ./c2_community-linux-64 but ./c2-*_amd64_linux (or to be more specific c2-3.1.1_amd64_linux but using the asterisk variant makes it more "transparent" to new releases) Quote Link to comment Share on other sites More sharing options...
B3AR Posted February 24, 2021 Author Share Posted February 24, 2021 So I changed the code replaced all files but still no token wget https://c2.hak5.org/download/community -O c2.zip && unzip c2.zip && \ IP=$(curl -s https://checkip.amazonaws.com) && \ echo "Copy the below setup token to browser http://$IP:8080" &&\ ./c2-*_amd64_linux -hostname $IP-listenip $IP Quote Link to comment Share on other sites More sharing options...
chrizree Posted February 24, 2021 Share Posted February 24, 2021 Don't you get the bash error when running that string? It should be pretty obvious. The command line is not correct, get rid of all the backslashes, they are not needed when running it as a single line wget https://c2.hak5.org/download/community -O c2.zip && unzip c2.zip && IP=$(curl -s https://checkip.amazonaws.com) && echo "Copy the below setup token to browser http://$IP:8080" && ./c2-*_amd64_linux -hostname $IP-listenip $IP 1 Quote Link to comment Share on other sites More sharing options...
chrizree Posted February 24, 2021 Share Posted February 24, 2021 And I'm not that sure the hostname will work out that very well as it's specified above, listenip shouldn't really be needed in a "standard" setup, now it just makes a mess of the actual hostname as it is in the string above as the actual parameter will be a part of the hostname/IP Quote Link to comment Share on other sites More sharing options...
5yNt4X Posted March 2, 2021 Share Posted March 2, 2021 @chrizree You are a legend - syntax syntax syntax. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.