Jeg synes at de er mærkeligt at de beskriver Linux Mint som en usikker distro. Der var rigtignok et problem med at deres side var blevet hacket og en modificeret version af distroen lagt op, men det var jo et engangstilfælde og et forlængst overstået kapitel.
#1: Jeg synes at de er mærkeligt at de beskriver Linux Mint som en usikker distro.
Det er jo også kun mandens påstand, men der er ting i Mint der sikkerhedsmæssigt kunne strammes op. Det er bare ikke særligt relevant.
Hvis man ønsker info fra anden side, så kan man installere Lynis. Den analysere installationen fremfor at udtale sig kategorisk:
#!/bin/bash
echo
echo -e "\033[1;33mInstall Lynis Security adviser if it aren't and run the program\033[0m"
sudo apt-get install lynis
sudo lynis update info
echo -e "If Lynis aren't \033[1;32mUp-to-date\033[0m, please run the OS Update Manager."
echo
echo -e "If Lynis weren't updated using Update Manager, You may wish to visit Lynis website to manually download and install Lynis:
\033[1;4;31mhttps://packages.cisofy.com/#package\033[0m
Alternatively, add the PPA to automaticly handle Lynis (recommended):
\033[1;4;31mhttps://packages.cisofy.com/community\033[0m"
echo
tput setaf 3
tput bold
read -n1 -r -p "Press any key to start scanning..." key
sudo touch /etc/lynis/custom.prf
tput sgr0
# show log
read -n1 -r -p "Press any key to read the log..." key
RUN_TEXTEDITOR=""
if command -v xed 2> /dev/null; then
RUN_TEXTEDITOR= xed /tmp/lynis.log
elif command -v gedit 2> /dev/null; then
RUN_TEXTEDITOR= gedit /tmp/lynis.log
else
printf "'xed' and 'gedit' aren't installed. You need to open lynis log file manually by typing 'nano /tmp/lynis.log' or by another text editior if you want to read the log"
fi
# We're gonna exit the terminal
echo
tput setaf 3
tput bold
read -n1 -r -p "Press any key to exit..." key
tput sgr0
exit
$SHELL
Noget lidt andet, så kan man downloade nogle batch jeg selv bruger til opsætte Ubuntu 14, 16 og Mint 17 og 18. Den indeholder også det ovenstående batch og en hel del mere, men de er udelukkende lavet for min egen skyld og ikke ment til udgivelse.
Marlar. Der er også et script til at placere vinduer på skrivebordet, men det er ikke out of box. Jeg husker du snakkede lidt om det. Koden er her:
#!/usr/bin/env python3
import subprocess
import time
import sys
app = sys.argv[1]
get = lambda x: subprocess.check_output(["/bin/bash", "-c", x]).decode("utf-8")
ws1 = get("wmctrl -lp"); t = 0
subprocess.Popen(["/bin/bash", "-c", app])
while t < 30:
ws2 = [w.split()[0:3] for w in get("wmctrl -lp").splitlines() if not w in ws1]
procs = [[(p, w[0]) for p in get("ps -e ww").splitlines() \
if app in p and w[2] in p] for w in ws2]
if len(procs) > 0:
w_id = procs[0][0][1]
cmd1 = "wmctrl -ir "+w_id+" -b remove,maximized_horz"
cmd2 = "wmctrl -ir "+w_id+" -b remove,maximized_vert"
cmd3 = "xdotool windowsize --sync "+procs[0][0][1]+" "+sys.argv[4]+"% "+sys.argv[5]+"%"
cmd4 = "xdotool windowmove "+procs[0][0][1]+" "+sys.argv[2]+" "+sys.argv[3]
for cmd in [cmd1, cmd2, cmd3, cmd4]:
subprocess.call(["/bin/bash", "-c", cmd])
break
time.sleep(0.5)
t = t+1
Kommentarer3
Jeg synes at de er
Jeg synes at de er
Det er jo også kun mandens påstand, men der er ting i Mint der sikkerhedsmæssigt kunne strammes op. Det er bare ikke særligt relevant.
Hvis man ønsker info fra anden side, så kan man installere Lynis. Den analysere installationen fremfor at udtale sig kategorisk:
#!/bin/bash
echo
echo -e "\033[1;33mInstall Lynis Security adviser if it aren't and run the program\033[0m"
sudo apt-get install lynis
sudo lynis update info
echo -e "If Lynis aren't \033[1;32mUp-to-date\033[0m, please run the OS Update Manager."
echo
echo -e "If Lynis weren't updated using Update Manager, You may wish to visit Lynis website to manually download and install Lynis:
\033[1;4;31mhttps://packages.cisofy.com/#package\033[0m
Alternatively, add the PPA to automaticly handle Lynis (recommended):
\033[1;4;31mhttps://packages.cisofy.com/community\033[0m"
echo
tput setaf 3
tput bold
read -n1 -r -p "Press any key to start scanning..." key
sudo touch /etc/lynis/custom.prf
tput sgr0
# enable /etc/lynis/custom.prf
/usr/sbin/lynis configure settings quick
# start scan
sudo lynis audit system
# show log
read -n1 -r -p "Press any key to read the log..." key
RUN_TEXTEDITOR=""
if command -v xed 2> /dev/null; then
RUN_TEXTEDITOR= xed /tmp/lynis.log
elif command -v gedit 2> /dev/null; then
RUN_TEXTEDITOR= gedit /tmp/lynis.log
else
printf "'xed' and 'gedit' aren't installed. You need to open lynis log file manually by typing 'nano /tmp/lynis.log' or by another text editior if you want to read the log"
fi
# We're gonna exit the terminal
echo
tput setaf 3
tput bold
read -n1 -r -p "Press any key to exit..." key
tput sgr0
exit
$SHELL
Noget lidt andet, så kan
Marlar. Der er også et script til at placere vinduer på skrivebordet, men det er ikke out of box. Jeg husker du snakkede lidt om det. Koden er her:
#!/usr/bin/env python3
import subprocess
import time
import sys
app = sys.argv[1]
get = lambda x: subprocess.check_output(["/bin/bash", "-c", x]).decode("utf-8")
ws1 = get("wmctrl -lp"); t = 0
subprocess.Popen(["/bin/bash", "-c", app])
while t < 30:
ws2 = [w.split()[0:3] for w in get("wmctrl -lp").splitlines() if not w in ws1]
procs = [[(p, w[0]) for p in get("ps -e ww").splitlines() \
if app in p and w[2] in p] for w in ws2]
if len(procs) > 0:
w_id = procs[0][0][1]
cmd1 = "wmctrl -ir "+w_id+" -b remove,maximized_horz"
cmd2 = "wmctrl -ir "+w_id+" -b remove,maximized_vert"
cmd3 = "xdotool windowsize --sync "+procs[0][0][1]+" "+sys.argv[4]+"% "+sys.argv[5]+"%"
cmd4 = "xdotool windowmove "+procs[0][0][1]+" "+sys.argv[2]+" "+sys.argv[3]
for cmd in [cmd1, cmd2, cmd3, cmd4]:
subprocess.call(["/bin/bash", "-c", cmd])
break
time.sleep(0.5)
t = t+1
https://www.dropbox.com/s/6rq2jiauhr1gjqd/run-menu.zip?dl=1
Ændring i Composer installationen:
Composer
Php-composer-semver
Php-composer-spdx-licenses
Mere failsafe post install
Tilføjet PPA til Atom Text Editor