Hack Forums
[Ubuntu] how to secure LAMP? - Printable Version

+- Hack Forums (https://hackforums.net)
+-- Forum: Tech (https://hackforums.net/forumdisplay.php?fid=444)
+--- Forum: Computing (https://hackforums.net/forumdisplay.php?fid=88)
+---- Forum: Linux (https://hackforums.net/forumdisplay.php?fid=85)
+---- Thread: [Ubuntu] how to secure LAMP? (/showthread.php?tid=5964280)



how to secure LAMP? - raggaescience - Apr 26, 2019

So I am following a guide from Ubuntu documentation:

https://help.ubuntu.com/community/ApacheMySQLPHP

When I do the following, I still can't edit the file on Ubuntu:

Code
sanders@sanders-VirtualBox:~$ gksudo "gedit /etc/apache2/ports.conf"
bash: gksudo: command not found
sanders@sanders-VirtualBox:~$ sudo "gedit /etc/apache2/ports.conf"
sudo: gedit /etc/apache2/ports.conf: command not found

What do I do about this? I'm trying to secure LAMP on my Ubuntu VM.


RE: how to secure LAMP? - VoIPv2 - Apr 26, 2019

(Apr 26, 2019 02:31 PM)raggaescience Wrote:  So I am following a guide from Ubuntu documentation:

https://help.ubuntu.com/community/ApacheMySQLPHP

When I do the following, I still can't edit the file on Ubuntu:

Code
sanders@sanders-VirtualBox:~$ gksudo "gedit /etc/apache2/ports.conf"
bash: gksudo: command not found
sanders@sanders-VirtualBox:~$ sudo "gedit /etc/apache2/ports.conf"
sudo: gedit /etc/apache2/ports.conf: command not found

What do I do about this? I'm trying to secure LAMP on my Ubuntu VM.

Look at your errors better.

The code should read:
Code
sanders@sanders-VirtualBox:~$ sudo gedit "/etc/apache2/ports.conf"



RE: how to secure LAMP? - raggaescience - Apr 26, 2019

(Apr 26, 2019 04:09 PM)VoIPv2 Wrote:  Look at your errors better.

The code should read:
Code
sanders@sanders-VirtualBox:~$ sudo gedit "/etc/apache2/ports.conf"

But in the documentation it says gksudo and when I did it your way it won’t let me insert letters into the document and opens in nano instead of geddit.


RE: how to secure LAMP? - VoIPv2 - Apr 26, 2019

(Apr 26, 2019 04:11 PM)raggaescience Wrote:  But in the documentation it says gksudo and when I did it your way it won’t let me insert letters into the document and opens in nano instead of geddit.

It says either:

Code
sanders@sanders-VirtualBox:~$ sudo nano  "/etc/apache2/ports.conf"
or
Code
sanders@sanders-VirtualBox:~$ gksudo  "/etc/apache2/ports.conf"

You run the option you prefer. GKSUDO is just an elevated graphical prompt. Similar to Windows "Run as Administrator"