A while ago techb wrote a simple script to disable his keyboard. The problem tho is that his won't work for laptops, as you have to plug the keyboard out and in again. That's why I decided to write my own little bash script...
First run "xinput --list" to find the ID of the device you want to disable.
Afterwards use "xbindkeys -k" to find a key combo of "Fn + Key" with the name XF86Launch1 (or 2,3,4,...). Often there are different kinds of symbols on the bottom left of the key on the keyboard wich indicate a special key combo with the Fn key.
These key combinations will also work when the keyboard is disabled.
Finally, save the following script somewhere on your computer, replace the ID in the script (12) with the ID of the device you want to disable, and assign the upper key combo to this script.
#!/bin/bash
STATE=`xinput --list-props 12 | grep "Device Enabled" | awk '{print $4}'`
if [ $STATE -eq 0 ]
then
xinput set-int-prop 12 "Device Enabled" 8 1
else
xinput set-int-prop 12 "Device Enabled" 8 0
fi