Jump to content

Recommended Posts

Posted

I have just bought a very good hosting which I could access via ftp and ssh.

However, this is my first time experience, so I need some help.

 

 

1) when log in via ssh client program, I got this:

bash$

what does that mean?

 

2) how do I configure a .htaccess??

 

3) I have designed a little php file, but the bad thing is, I can actually see the content of it. eg, http://www.xxx.com/xxx.php. Why?

 

Beside, I feel sick using terminal instead of something easier like cpanel.

Does any one know a quick short guide to understand all this kinda stuff??

 

thanks

Posted

1) It means you are using the bash command shell.

 

2) Write one according to the standards for your webserver software (there are tutorials on doing this)

 

3) Is php installed on the server, is the webserver software configured correctly and set up to work with the dir in which the file is stored

 

My advice, learn to use the terminal, I am reluctant to allow people acces to things such as cpanel on my servers as they are a seriouse security risk :s

 

But there are several free ones out there such as webmin, but it's best to start it use it stop it, lock it to your ip and change the port it uses from

3) Is php installed on the server, is the webserver software configured correctly and set up to work with the dir in which the file is stored the default.

Posted

thaks Klaynos,

 

yes, the server supports pHp. The server is Apache.

 

However, I still have the same problem on another free webhosting supporting pHp.

Does the server check the content of the pHp rather than its file extension??

 

I just typed a few characters which are non-related to pHp, but in pHp document, and I can see the content via a browser after I uploaded it.

 

 

Secondly, why is cpanel a security risk??

 

Thirdly, my webhosting support SSL and SSH. How can they restrain hackers from obtaining data during transaction? saying the data is encrypted is too vague.

 

 

thanks alot

 

ps, xxx means something something something.

Posted

alright,

 

you have said it is a porn site, so I am not going to click it. :-D

 

Any way, it is coincidence that links to porn, but that does not matter as long as you dont click it. Does that make you very constrained from clicking it????

 

Just focus on my questions,please.

 

thank you.

Posted
thaks Klaynos' date='

 

yes, the server supports pHp. The server is Apache.

 

However, I still have the same problem on another free webhosting supporting pHp.

Does the server check the content of the pHp rather than its file extension??

 

I just typed a few characters which are non-related to pHp, but in pHp document, and I can see the content via a browser after I uploaded it.

 

 

Secondly, why is cpanel a security risk??

 

Thirdly, my webhosting support SSL and SSH. How can they restrain hackers from obtaining data during transaction? saying the data is encrypted is too vague.

 

 

thanks alot

 

ps, xxx means something something something.[/quote']

 

 

What is this "content"? Baring in mind, php uses tags (<?php ?> (for god sake don't use short tags)) to convey when executable code is being written. If these tags are not used the content is sent straight to the output buffer and therefore sent as the result page. This makes it easier to write webpages as you can write a page normally as you would with (X)HTML and then include snippets of php code to do certain tasks and get certain data elements from say a database.

 

The Server will check the extension against its list of extensions and uses and determine what to do with the file. As long as the server is setup properly to utilise the php interpreter (or a built in module in the case of mod_php) it will pass the script through to the module and then send the output as a response.

 

As far as the encryption methods SSH uses, check out this Wiki entry on the subject - Wiki. It explains what encryption techniques it uses (Public Key Encryption etc).

 

Lastly, it's not hard to use http://blah.com or even the actual web address to the script as you don't seem to have anything particularly vital in the php script atm. Using xxx does cause problems as some people do mistakenly click it. Luckily it leads to a "are you sure you wish to enter" page but there is simply no reason to use that link. Your reasoning for using it is understandable but you now know what it is and theres simply no reason not to use a different address. I personally don't care but others might find it offensive.

Posted

What Aet said, and cpanel is a problem because it has historically had security holes and gives other people a single nice attack point where they can hit your machine :(

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.