Created on
08-09-2024
06:31 AM
Edited on
04-07-2025
10:45 AM
By
wmichael
Description | This article describes how to recover an IPsec pre-shared key in plain text format using the FortiGate API. |
Scope | FortiGate. |
Solution |
Note: This article assumes that the admin has an IPsec tunnel set up with a pre-shared key defined, but has forgotten the actual plain text of that key. For demonstration purposes, this article will use a VPN tunnel with a pre-shared key of 'My_PSK'. Although the pre-shared key 'My_PSK' is known for this example, the focus is to help the admin recover the pre-shared key in plain text format.
Log in into the FortiGate GUI using the super_admin profile:
Open a new tab in the browser (such as Firefox or Google Chrome) and use the following path to obtain the PSK in plain text:
https://FortiGate_IP/api/v2/cmdb/vpn.ipsec/phase1-interface?plain-text-password=1
|