pondělí 13. března 2023

OpenVAS / GVM trouble with initial scan

 I installed GVM to Kali and tried to create a new config. I failed with strange error that config is not found.

After some investigation I've realized that I have to run gvm-feed-update and check if it succeeded.

Then go to https://127.0.0.1:9392/feedstatus and check the status. When everything is ready you can start using GVM.

úterý 17. ledna 2023

Docker to podman - trouble with container names

As you know, in Rocky linux there is no docker, but aliased podman. This brings some complications and I'd like to describe here one that was very painful.
Firs of all - there is no docker compose up alias, you have to install podman-componse.
How to do it?

    pip3 install podman-compose

Then podman-compose ( https://github.com/containers/podman-compose ) will be located in /usr/local/bin/ directory.
The next step is to run it, but it was not able to communicate to each other. Why?
You have to install podman-plugins.

    sudo dnf install podman-plugins

Then you are almost there, but it is necessary to remove the network and let it create again.

pátek 21. října 2022

How to run X11 applications from WSL2

 Install Xming X server.

Open WSL and set up the DISPLAY variable:

export DISPLAY="`sed -n 's/nameserver //p' /etc/resolv.conf`:0"

try to run some X application, for example xclock

If an error will be shown, check the Xming log

You will find there:

client 4 rejected from IP XXX.XXX.XXX.XXX

Go to c:\Program Files (x86)\Xming\

Edit X0.hosts and add IP address from the error log above

Restart Xming

pátek 12. srpna 2022

How to reset your SonarQube admin password in H2

What you should do when you have Sonar in docker and you can't remember, which password you have for your admin user? If you use internal H2 database it is not so easy...

First of all connect to your docker container:

docker exec -it container_id /bin/bash


Then run following commands to connect to H2 database:

cd /opt/sonarqube/lib/jdbc/h2

java -cp h2-1.4.199.jar org.h2.tools.Shell


You will be asked to fill following values:

URL jdbc:h2:tcp://localhost:9092/sonar

Driver org.h2.Driver

User [none]

Password [none]


Then just change your admin password:

UPDATE users SET crypted_password = '$2a$12$uCkkXmhW5ThVK8mpBvnXOOJRLd64LJeHTeCkSuB3lfaR2N0AYBaSi', salt=null, hash_method='BCRYPT' WHERE login = 'admin'


pondělí 20. června 2022

How to mount EFS to EC2 instance on AWS

Command is simple and you can find it in GUI - click on attach:

mount -t efs -o tls fs-some_id_of_efs:/ efs

Of course you have to create efs directory first - typically in /mnt/ directory.

It is quite simple, use Amazon linux image and install:

sudo yum install amazon-efs-utils nfs-utils


And thats all...