петък, октомври 10, 2025

Retrieving passwords from Fortigate

 https://community.fortinet.com/t5/FortiGate/Technical-Tip-How-to-Recover-BGP-Password/ta-p/414414

 1. Copy ENC password from CLI

sh vpn ipsec phase1-interface test-vpn-tunnel
config vpn ipsec phase1-interface
    edit "test-vpn-tunnel"
        .....
        set psksecret ENC tP2sK9fIsnZfffZg9cG6u5hkyC/MUVXBsIcaOTJlH2cV4K89XjE86c98KyolJrmiWJsQqT12rK82a1o2EiUZFWrTxik8JQegsPVbIZvq2qIPfcNCifgQAco/NjuQ4f5PyIipJzS5tyWMbysWYsP4GTNlQ==
    next
end

 2. Create an SSID in Fortigate (enable WiFi Controller under System -> Feature Visibility) 

    2.1. Set Pre-shared Key -> Passprase

    2.2 Edit in CLI & change the passphrase of the SSID to the BGP password copied from Step 1

config wireless-controller vap
    edit "TEST"
        set passphrase ENC <----- Encrypted BGP Password copied from Step 1.
    next
end

3. From FortiGate GUI, go to WiFi Controller -> SSID -> Edit SSID. On the 'Passphrase' parameter, select the 'eye' icon to reveal the password.

 That method is tested and confirmed working on Fortigate 7.0 for local users, radius secret, IPSec PSK

 

Another way of retrieving IPSec PSK password:  

Retrieving IPsec VPN PSK key from Fortigate 


 

 

 

сряда, октомври 08, 2025

iRedMail greylisting

 Disable greylisting for sender IP:
python3 greylisting_admin.py --disable --from '45.56.127.226'

To whitelist IP addresses/networks of some mail domain, for example, outlook.com, microsoft.com, please run command like below:
cd /opt/iredapd/tools/
python3 spf_to_greylist_whitelists.py outlook.com microsoft.com



Show and add server-wide whitelists or blacklists:

python3 wblist_admin.py --list --whitelist
python3 wblist_admin.py --list --blacklist

# Whitelist IP address, email address, entire domain, subdomain (including main domain)
python3 wblist_admin.py --add --whitelist 192.168.1.10 user@domain.com @iredmail.org @.example.com

# Blacklist IP address, email address, entire domain, subdomain (including main domain)
python3 wblist_admin.py --add --blacklist 202.96.134.133 bad-user@domain.com @bad-domain.com @.sub-domain.com

For per-user or per-domain whitelists and blacklists, please use option --account. for example:

python3 wblist_admin.py --account @mydomain.com --add --whitelist 192.168.1.10 user@example.com
python3 wblist_admin.py --account user@mydomain.com --add --blacklist 172.16.1.10 baduser@example.com

python3 wblist_admin.py --account @mydomain.com --list --whitelist
python3 wblist_admin.py --account user@mydomain.com --list --blacklist

четвъртък, април 03, 2025

Lost in translation (Български поговорки)

 

Don't call "bear" not to come.    Не викай "мецо" да не дойде.
From the drunk even the madman runs away.    От пияния и лудият бяга.
Finished her like the dog in the field.    Свърши я като кучето на нивата.
The vineyard does not want a prayer, wants a mattock.    Лозето не иска молитва, а мотика.
The dogs bark to themselves, the caravan is walking.    Кучетата си лаят, керванът си върви.
Noone is bigger than the bread.    Никой не е по-голям от хляба.
Neither fish nor cancer (crab, lobster).    Ни риба, ни рак.
Quiet waters are the deepest.    Тихите води са най-дълбоки.
On bare ass (belly) a pair of pistols.    На гол гъз (тумбак) чифте пищови.
For the wolf we're talking and he is in the pen.    За вълка говорим, а той е в кошарата.
The wolf is stuffed and the lamb in its entirety.    И вълкът - сит, и агнето - цяло.
Meal wrestling makes.    'Ранътъ пра'и борбътъ.
Eagle, crab and pike.    Орел, рак и щука.
For him who blows.    За тоя, дето духа.
For him who swings the fores.    За тоя, дето клати гората.
On every hair times 108.    На всеки косъм по сто и осем.
Line an ass on the bridge.    Като магаре на мост.
Like an elephant in a glassware shop.    Като слон в стъкларски магазин.
Like a calf in a train.    Като теле в железница. 
On the ant a road costs.    На мравката път стува.
Bent sits, staithgt reasons.    Криво седи, право съди.
With a cloak in the summer, with a purse in the winter.    Лете със абичка, зиме със торбичка.
Strike the seddle the donkey to conceive.    Бий самара да се сеща магарето.
Many grannies, feeble child.    Много баби - хилаво дете.
Which watch?    Колко е часът?
Help yourself God to help you too.    Помогни си сам, за да ти помогне и Господ.
These are flowers, there will be fruit too.    (Russian proverb) Это цветочки, а еще и ягодки будут.
Under the road and over the road.    Под път и над път.
Ears don't stand higher than the eyes.    Ушите не стоят по-горе от очите.
For green spawn (cavier).    За зелен хайвер.
To see where the crabs hybernate.    Да види къде зимуват раците.
House on fire to burn the rats.    Запали къщата да изгори мишките.
Patient, horse, for green grass.    Трай, коньо, за зелена трева.
Two water-mellons under the armpit.    Две дини под една мишница.
Sick healthy brings.    Болен здрав носи.
To plant him on duck's eggs.    Да го насадиш на пачи яйца.
Water stamps - thirsty walks.    Вода гази - жаден ходи.
White coins for black days.    Бели пари за черни дни.
He who studies will succeed.    Който учи ще сполучи.
Piper house does not feed.    Свирач къща не храни.