https://steamcommunity.com/app/17300/discussions/0/613938693182120942/
Solution copied from steam link above:
Alright so since this is one of the first results on google, i figured i'd make a quick guide explaining the info above which does in fact allow you to use toggle aim down sight, no need for autohotkey or anything else.
Basically what you need to do is edit an XML file and create a CFG, this isn't too hard even if you don't know what you're doing:
1.) Go into your Crysis save game folder, normally found in C:\Users\[user]\Documents\My Games\Crysis, then go into the 'Profiles' and 'default' folders. In there you should see 3 files, actionmaps, attributes and profile (all .xml)
2.) Open 'actionmaps.xml' in notepad, to this right click on it and select 'open with' or open notepad through the start menu and drag and drop the file onto it
3.) We now need to find 2 lines, to do this in notepad ctrl+f and type 'zoom'. This should take you to the line '<action name="zoom" onPress="1" onRelease="1">'. Underneath this is a line called 'key name' and by default it should be 'mouse2', we need to change this to another key that isn't bound to anything, so i changed mine to 'k', making mine look like this '<key name="k"/>'
4.) Now we need to change the other line, 'xi_zoom'. It should be only a couple lines down from 'zoom', use ctrl+f again if you need to. This line is '<action name="xi_zoom" onPress="1" onRelease="1">' and we need to change this key name to 'mouse2' in the same method used above, so you should end up with '<key name="mouse2"/>' now under the xi_zoom line instead of the normal zoom.
5.) Double check everything, and save the file (File -> Save).
6.) Now we need to make the game realize these changes, and the method to use rather than manually typing thing every time you launch the game is to create a new file. To do this, we now need to find your crysis game install folder. In steam, this will usually be 'C:\Program Files (x86)\Steam\steamapps\common\Crysis', if you've changed the install location you know how to find this anyway.
7.) Now that we're in the crysis game folder, go into 'Game' then 'Config', you should end up at 'steamapps\common\Crysis\Game\Config'. This is where we need to place the new file we're going to create.
8.) Open notepad again, and paste these 2 lines into a new blank note 'con_restricted=0' and 'hud_ctrlzoommode=1'. Don't include the ' and make sure they're on 2 different lines. We now need to save this as a config file, to do this go 'File -> Save As' and as the name put 'autoexec.cfg' and change the file type from '.txt' to 'all files'. Save it on the desktop to make life easy.
9.) Now we copy and paste 'autoexec.cfg' into the 'Crysis\Game\Config' folder, which should end up with autoexec at the top of a bunch of other .cfg files.
10.) We should be done now, load up crysis and press the tilde key '~' (above tab, next to 1). If you've done it correctly, it should have both of the 'con_restricted=0' and 'hud_ctrlzoommode=1' lines in green. Now just load up a save and you should have aim down sights as a toggle on your right mouse button.