- Products
- Learn
- Local User Groups
- Partners
- More
AI Security Masters E7:
How CPR Broke ChatGPT's Isolation and What It Means for You
Blueprint Architecture for Securing
The AI Factory & AI Data Center
Call For Papers
Your Expertise. Our Stage
Good, Better, Best:
Prioritizing Defenses Against Credential Abuse
Ink Dragon: A Major Nation-State Campaign
Watch HereCheckMates Go:
CheckMates Fest
Hi,
FYI I've just raised an SR for the management API (R81.20 T65).
When using the above command, if you had previously included the value "urls-defined-as-regular-expression true" then the SET command will reset it to false, unless you include this argument again.
Thanks
Jamie
Can you send command you did? I can try it on my lab mgmt
Andy
Hi Andy,
Using the BASH script below to send the commands (argument 1 being a filename):
#!/bin/bash
#
session=`mgmt_cli -r true login --format json| jq -r '.sid'`
COUNT=0
FILE=`mktemp`
F=`mktemp`
grep ^[^#] <$1 >$F
while IFS= read -r line
do
echo "echo $line" >>$FILE
echo "usleep 100" >>$FILE
echo "mgmt_cli $line ignore-warnings true --ignore-errors true --session-id \"$session\" 2>&1" >>$FILE
COUNT=$((COUNT+1))
if [ `expr $COUNT \% 2000` = "0" ]; then
echo "mgmt_cli publish --session-id \"$session\" 2>&1" >>$FILE
fi
done <$F
source $FILE
mgmt_cli publish --session-id $session 2>&1
mgmt_cli logout --session-id $session 2>&1
rm $FILE $F
The command set in question:
set session description "Create Blacklist Object" new-name "APCL-API"
add application-site name "Sample-Blocklist" primary-category "High Risk" urls-defined-as-regular-expression true url-list.1 "dummy"
set application-site name "Sample-Blocklist" url-list.add "\\/site\\.com"
set application-site name "Sample-Blocklist" url-list.add "\\.site\\.com"
set application-site name "Sample-Blocklist" url-list.remove "dummy"
Thanks
Jamie
Just rebooting it, will try soon.
Andy
Just tried, yes, I see your point.
Some clarification: it seems to be only the REMOVE verb affecting it.
Thanks
Jamie
There are a few API calls like that (particularly with Gateway objects).
Please send me the SR in a PM.
Also tagging @Omer_Kleinstern
Interestingly, it wasn't the remove command alone that was resetting the flag, but only if the PREVIOUS command failed to explicitly specify the flag (the commands were not completely atomic). I've had a private hotfix built and tested successfully (for application-site only), so hopefully this will be rolled into a hotfix take soon.
Yes, that's the exact behavior I was talking about.
Have you considered Ansible by chance? Check Point has modules for the set/show/delete application-site APIs:
With this, you can specify that attribute as part of the request. Ansible will handle your login session and you get a consistent interface.
---
- name: Manage application sites
hosts: mgmt_server
connection: httpapi
gather_facts: false
become: false
vars:
ansible_api_key: MGMT_API_KEY
ansible_network_os: check_point.mgmt.checkpoint
block_list:
name: Sample_Blocklist
primary_category: High Risk
url_list:
add:
- '\/site.com'
- '\.site\.com'
remove:
- dummy
tasks:
- name: Get application site info
check_point.mgmt.cp_mgmt_application_site:
name: app_site_facts
- name: Update application sites
check_point.mgmt.cp_mgmt_application_site:
name: "{{ block_list.name }}"
primary_category: "{{ block_list.primary_category }}"
url_list: "{{ (app_site_facts['ansible_facts']['application_site']['url_list'] |list) + block_list.url_list.add | difference(block_list.url_list.remove) }}"
urls_defined_as_regular_expression: true
...
(Untested, but should be close)
The idea is to "model" the object you want then work with the model. It pays enormous dividends, tho.
Leaderboard
Epsum factorial non deposit quid pro quo hic escorol.
| User | Count |
|---|---|
| 66 | |
| 19 | |
| 13 | |
| 12 | |
| 11 | |
| 9 | |
| 9 | |
| 7 | |
| 7 | |
| 7 |
Tue 28 Apr 2026 @ 06:00 PM (IDT)
Under the Hood: Securing your GenAI-enabled Web Applications with Check Point WAFThu 30 Apr 2026 @ 03:00 PM (PDT)
Hillsboro, OR: Securing The AI Transformation and Exposure ManagementTue 28 Apr 2026 @ 06:00 PM (IDT)
Under the Hood: Securing your GenAI-enabled Web Applications with Check Point WAFTue 12 May 2026 @ 10:00 AM (CEST)
The Cloud Architects Series: Check Point Cloud Firewall delivered as a serviceThu 30 Apr 2026 @ 03:00 PM (PDT)
Hillsboro, OR: Securing The AI Transformation and Exposure ManagementAbout CheckMates
Learn Check Point
Advanced Learning
YOU DESERVE THE BEST SECURITY