You can reset the code to one you know but it need the keyfob to be working first. I'll leave the info here on the chance you will need it
Provided that you can disarm the system with a working Radio Key or the current PIN, then you can program new Radio Keys into the alarm system yourself, using the keypad, at any time.If you do not have the current PIN, then option A is your best solution. However if you do not have a working Radio Key, then you will have to use option B and obtain the systems PIN code from Subaru (UK). Your dealer can obtain this for you if you can provide proof of ownership and the alarm systems 16-digit serial number.A. Using a working Radio Key:- Arm and then Disarm the system using a working Radio Key.- Within 30 seconds of disarming, type into the keypad- *17856*91*n# (where n is the total number of keys required to work the system)- Press each Radio Key briefly in turn (the dash board LED will flash and the siren beep each time)- Once the nth Radio Key has been programmed, you should be able to arm/disarm the system using any of the Radio Keys programmed.It is essential that all Radio Keys required to operate the system are programmed together. Any keys not present during the programming sequence above will no longer operate the system.B. Using the current PIN Code (if a working Radio Key is not available): - Arm and then Disarm the system using the current PIN- Within 30 seconds of disarming, type into the keypad- **abcd*91*n# (where abcd is the system’s PIN code and n is the total number of keys required to work the system)- Press each Radio Key briefly in turn (the dash board LED will flash and the siren beep each time)- Once the nth Radio Key has been programmed, you should be able to arm/disarm the system using any of the Radio Keys programmed.It is essential that all Radio Keys required to operate the system are programmed together. Any keys not present during the programming sequence above will no longer operate the system.When using the keypad always observe the following points:- The PIN number should not be entered too quickly or too slowly - when a digit has been pressed the small LED built into the keypad will illuminate briefly as confirmation and only then should the next digit be entered. - If an incorrect digit is pressed or the delay between entering digits exceeds10 seconds, then the LED above the keypad will flash rapidly and the PIN attempt should be abborted and started again after 30 seconds.- Due to the small size of the keypad some users may find a rubber tipped pencil easier to use. DO NOT use the sharp tip of a ball point pen etc, or press excessively hard on the keypad as this will only damage the membrane and cause a digit to remain pressed, causing a continual incorrect PIN.- The keypad allows only THREE PIN attempts and then will "Lock Up" if an incorrect number is entered a third time. This is a security feature to prevent random PIN attempts disarming the system.