feature: Hot security tips (#11810)

* 🔧 Add security issue detection (and logs)

* 🔧 Check for it on load

* 👷 Add some tests

* 👷 Make the linter happy

* 🔧 Allow them to be enabled by force

* 📝 Make message slightly prettier

* 🔧 Fix a typo in the code comment

* 🔧 Classic mistake

* 🚀 Optimize things a bit more

* 👷 Add tests, fix tests

* 📝 Document things

* 🔧 Make linter happy

* 🔧 One more piece of cleanup
This commit is contained in:
Felix Rieseberg 2018-02-03 06:50:12 -08:00 committed by Charles Kerr
parent 62d2a3472f
commit d586ef2f39
10 changed files with 541 additions and 14 deletions

View file

@ -15,7 +15,7 @@ if sys.platform == 'linux2':
# powerMonitor interaction with org.freedesktop.login1 service. The
# dbus_mock module takes care of setting up the fake server with mock,
# while also setting DBUS_SYSTEM_BUS_ADDRESS environment variable, which
# will be picked up by electron.
# will be picked up by electron.
try:
import lib.dbus_mock
except ImportError:
@ -62,6 +62,7 @@ def main():
try:
if args.use_instrumented_asar:
install_instrumented_asar_file(resources_path)
os.environ["ELECTRON_DISABLE_SECURITY_WARNINGS"] = "1"
subprocess.check_call([electron, 'spec'] + sys.argv[1:])
except subprocess.CalledProcessError as e:
returncode = e.returncode