I also have the same problem with my Razer Deathadder. Buttons 4 and 5 are not even detected in Call of Duty 4 modern warfare. That clearly rules out even attempting to bind them to anything useful like grenade or special grenade.
In other applications like web browsers etc. buttons 4 and 5 work just fine.
Mouse: Razer DeathAdder
OS: Vista 32 home premium
MB: Gigabyte X38-DQ6
Mouse driver: HID-compatible ??!? (found in the device manager)
Razer Driver version 1.08 /Firmware version 1.27
Could there be two drivers for the mouse? One of them being the windows standard drivers and the other Raizers drivers. Could it be possible that call of duty (and other games) go looking for the drivers in the wrong place and find the standard windows mouse drivers? I only see the HID-compatible mentioned in the device manager.