[Information]/[Fortinet] Fortigate

[Fortinet] API 토큰을 통해 FortiGate 연동 (Connect FortiGate device via API Token)

starterr 2025. 6. 30. 14:37
반응형

API 토큰을 통해 FortiGate 장치 연결

 

FortiConverter는 REST-API를 통해 구성을 가져올 수 있습니다.

각 API 요청은 API 토큰을 사용하여 인증될 수 있습니다.


FortiGate GUI에서 새로운 REST API 관리자를 생성하면 API 토큰이 생성됩니다.

 

 

Step 1: Create an administrator profile

1) On the FortiGate GUI, select System > Admin Profiles > Create New.

 

2) Create a New Profile.

 

3) Enter a profile name and enable all the Read/Write permissions.

Please note the profile name, it will be used in Step 2.

 

Create an administrator profile
Create an administrator profile

 

4) Click OK.

 

 

 

Step 2: Set up the global scope in the admin profile:

If your device is in multiple VDOM mode, please set the scope of the admin profile into "global":

 

1) Open the CLI console.


2) Input the following commands:

config global
 config system accprofile
  edit <your admin profile>
   set scope global
  next
 end
end

 

 

Step 3: Create a REST API Admin:

1) On the FortiGate GUI, select System > Administrators > Create New > REST API Admin.

 

Create a REST API Admin
Create a REST API Admin

 

2) Enter the API-user's name and select the profile name you created from Step 1.

 

3) The trusted host must be specified to ensure that the machine of your FortiConverter installed can reach the Forti

 

Create a REST API Admin
Create a REST API Admin

 

 

4) Click OK and an API token will be generated.

 

Create a REST API Admin
Create a REST API Admin

 

5) Make a note of the API token as it’s only shown once and cannot be retrieved.

6) Click Close to complete creation of the REST API Admin.

 

 

Regenerate an API token for API-user:

In FortiGate GUI, go to System > Administrators.


1) Edit your REST API admin user


2) Click Regenerate.

 

In CLI console, use the CLI command below:

execute api-user generate-key [API user name]

 

	The steps above must be performed from the FortiGate GUI as an administrator with the super_admin profile.

 

 

https://docs.fortinet.com/document/forticonverter/7.2.1/online-help/866905/connect-fortigate-device-via-api-token

 

Connect FortiGate device via API Token | Online Help

 

docs.fortinet.com

 


 

[Fortinet] FortiGate HA failover Alert 설정 - SNMP OID값

 

[Fortinet] FortiGate HA failover Alert 설정 - SNMP OID값

FortiGate 방화벽 내 SNMP를 이용하여 모니터링 시스템을 통해 장비의 OID 값을 수집하면 OID 값에 따라 다양한 정보를 받아서 변경된 결과값에 알람을 설정할 수 있다. 해당 방식으로 많은 고객사에

infoofit.tistory.com

 

[Fortinet] Fortigate log filter 특정 로그 예외 처리하는 방법

 

[Fortinet] Fortigate log filter 특정 로그 예외 처리하는 방법

- Fortigate log filter 특정 로그 예외 처리하는 방법해당 명령어를 사용하여 특정 log만 syslog 서버 또는 fortianalyzer(Fortinet log 저장 장치)로 보내거나 특정 log를 저장하지 않게 설정이 가능 log filter 설

infoofit.tistory.com

 

반응형