One way of doing it shortly is using cmdlet from exchange shell:
Add-IPBlockListEntry –IPAddress 10.10.1.123 or use -IPRange 10.10.1.0/16

Other way of doing it is using the Exchange Manager:

1. Select Hub Transport On exchange 2007 Server manager under Configuration node.
2. Mark the Hub Transport server on the details pane.
3. Click the Anti-spam tab.
4. Click IP block List.
5. In the right Actions pane, select the Properties link.
6. Click add to select the blocked IP Addresses.
7. Choose the "Never let this address expire" option if positive that this address will be never allowed.
8. Choose the "Block until date and time" option to limit the time this address will be blocked.
9. Click OK for all windows.