在写自动化测试脚本时,如果想给firefox导入certificate,可以使用certutil工具。具体介绍可以看https://developer.mozilla.org/en-US/docs/Mozilla/Projects/NSS/Tools/certutil
certutil -A -n \"CN=SonicWALL Firewall DPI-SSL\" -t \"TCu,Cu,Tu\\" -d dbm:/root/.mozilla/firefox/ad128rgd.default -i $cer_opts{'outfile'}
certutil -A -n \"CN=SonicWALL Firewall DPI-SSL\" -t \"TCu,Cu,Tu\\" -d sql:/root/.mozilla/firefox/ad128rgd.default -i $cer_opts{'outfile'}
certutil支持两种类型的数据库: the legacy security databases (cert8.db, key3.db, and secmod.db) and new SQLite databases (cert9.db, key4.db, and pkcs11.txt). If the prefix sql:
is not used, then the tool assumes that the given databases are in the old format.