Is it possible to recalculate the system configuration checksum on a Cisco RV180W

0

My Cisco RV180W has a corrupt configuration which is breaking the user interface in a few places. After a factory reset, it's fine - but if I restore my previous configuration it breaks again.

The backed-up configuration (.cfg) files are text files, and ideally I would like to restore parts of my old configuration (e.g. firewall rules, VPN users) by editing my 'clean' configuration file. However, the files contain a checksum line in the format:

systemConfig[1]["checksum"]="f0761710438b1ef29d811c76bd4c0f06"

... and if this checksum doesn't match the file contents, the router refuses to restore the file.

Does anyone know how I can recalculate this checksum after making manual changes to the configuration file?

David Miller

Posted 2013-09-02T09:35:12.550

Reputation: 334

How embarrassing - I found my own answer with Google at https://supportforums.cisco.com/thread/2187263. (I really did search before posting here!)

The answer is to replace the checksum line with: systemConfig[1]["checksum"]="0"

– David Miller – 2013-09-02T11:23:44.390

You can certainly post a self-answer to your question. It's better than doing it in a comment. – a CVn – 2013-09-02T11:30:47.003

Thanks. I will do in 5 hours - I don't have the reputation to do so immediately. :-) – David Miller – 2013-09-02T13:16:56.190

Answers

1

As suggested, I'm reposting the answer that I found at https://supportforums.cisco.com/thread/2187263 as an answer now that I can...

The Cisco RV180W will accept a zero checksum in its configuration files. The checksum (specified at around line 13 of the .cfg file) is set to zero like this:

systemConfig[1]["checksum"]="0"

This works around the 'Failed to update configuration as the file may have been invalid / corrupted' error that the router gives if an attempt is made to restore the configuration from a manually edited file specifying a non-zero (and incorrect) checksum.

I have successfully used this technique to restore firewall rules and VPN users from an older configuration file. However, I would recommend extreme care in editing these configuration files manually. Don't use this technique to load a configuration file that really is invalid/corrupted.

David Miller

Posted 2013-09-02T09:35:12.550

Reputation: 334

0

You can also Remove the Existing checksum line and then calculate a new Checksum and then add it back.

So Remove following line form the Config (your Checksum will be Different) and save the file:

systemConfig[1]["checksum"] = "95aa284477b339a42ca65f51af0087b1"

Then Calculate a new MD5 Checksum you can use this site: http://onlinemd5.com/ or on OS X Or Linux, you can use the Command:

md5 <filename>

looks like this:

ScottsMac$ md5 charlie-gateway.hbg-2014.0911.01.cfg 
MD5 (charlie-gateway.hbg-2014.0911.01.cfg) = c16d28f5ece01d7561790377fb18d0cd

Add the Checksum line back into the file with the new Checksum

systemConfig[1]["checksum"] = "c16d28f5ece01d7561790377fb18d0cd"

Save and reload, it.

scooter133

Posted 2013-09-02T09:35:12.550

Reputation: 111