how to export cPHulk blacklist

kazar

Active Member
May 18, 2008
27
0
51
NYC/Earth
cPanel Access Level
Root Administrator
Before cPHulk moved from mysql to whatever it uses now to log blacklisted IPs, I was able to run mysql cphulkd -e "select IP from blacklist;" | egrep "[0-9]" to output a list of blacklisted IPs/ranges. I have built up my blacklist over a period of years at this point and would really like to be able to preserve it for possible reuse after a server rebuild or in another account.

Is there a new way to get the list out of WHM?

tia,

kazar
 

kazar

Active Member
May 18, 2008
27
0
51
NYC/Earth
cPanel Access Level
Root Administrator
update: I see now that cPHulk does still use mysql. The table is now called ip_lists with blacklisted addresses indicated by "2" in the "TYPE" column. There is no longer a column that stores a single value for IP range (such as 107.150.53.0/24) but instead there are STARTADDRESS and ENDADDRESS columns with the IP # in the format such as "00000000000000000000ffffd9aecaff"

I have no idea how to print this in the shell in the same human-readable IP address range format that I use to input blacklisted addresses. I have opened a support ticket and will post back here when I receive a response.
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,884
2,245
463

shoutandecho

Registered
Feb 16, 2015
4
0
1
cPanel Access Level
Root Administrator
Hi! Is there a way to view, manipulate, and export the cPHulk list without using the command line? In the old system, I could just grab the list, use a text editor to manipulate the list, and then paste it back in. Now there doesn't seem to be a way to even view the entire list within the WHM interface at all.

I did view the document Michael helpfully provided, but it doesn't seem to deal with manipulating or viewing the entire cPHulk blacklist. It looks like the web interface now only allows for entering and scrolling through a big list; you can't select all and export or select all and delete or search for a range, etc, and the command line can't do any sort of bulk editing either.

Anyway, i was wondering if anything has changed because the new interface has take an enormous step back in terms of blacklist management.
 
Last edited:

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,884
2,245
463
Hi! Is there a way to view, manipulate, and export the cPHulk list without using the command line? In the old system, I could just grab the list, use a text editor to manipulate the list, and then paste it back in. Now there doesn't seem to be a way to even view the entire list within the WHM interface at all.

I did view the document Michael helpfully provided, but it doesn't seem to deal with manipulating or viewing the entire cPHulk blacklist. It looks like the web interface now only allows for entering and scrolling through a big list; you can't select all and export or select all and delete or search for a range, etc, and the command line can't do any sort of bulk editing either.

Anyway, i was wondering if anything has changed because the new interface has take an enormous step back in terms of blacklist management.
Hello,

It's not possible to export or search the blacklist via WHM, but please continue to vote and add your feedback to the existing feature request located at:

Show all IP addresses listed in cphulk

Thank you.
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,884
2,245
463