{"action":"created","issue":{"url":"https://api.github.com/repos/letsencrypt/boulder/issues/851","labels_url":"https://api.github.com/repos/letsencrypt/boulder/issues/851/labels{/name}","comments_url":"https://api.github.com/repos/letsencrypt/boulder/issues/851/comments","events_url":"https://api.github.com/repos/letsencrypt/boulder/issues/851/events","html_url":"https://github.com/letsencrypt/boulder/issues/851","id":108227533,"number":851,"title":"Audit Log the version number, and preferably before we crash","user":{"login":"jcjones","id":518542,"avatar_url":"https://avatars.githubusercontent.com/u/518542?v=3","gravatar_id":"","url":"https://api.github.com/users/jcjones","html_url":"https://github.com/jcjones","followers_url":"https://api.github.com/users/jcjones/followers","following_url":"https://api.github.com/users/jcjones/following{/other_user}","gists_url":"https://api.github.com/users/jcjones/gists{/gist_id}","starred_url":"https://api.github.com/users/jcjones/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jcjones/subscriptions","organizations_url":"https://api.github.com/users/jcjones/orgs","repos_url":"https://api.github.com/users/jcjones/repos","events_url":"https://api.github.com/users/jcjones/events{/privacy}","received_events_url":"https://api.github.com/users/jcjones/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":12,"created_at":"2015-09-24T22:40:54Z","updated_at":"2015-09-24T23:42:53Z","closed_at":null,"body":"The version number of Boulder that we're running should be logged at AUDIT. It would also be preferable that the log printout happen before we crash due to PKCS11 errors, database connection issues, or the like, to help diagnose issues.\r\n\r\nAs an example, running Boulder such that it can't read its config gives no indication as to the version in use (though you can get it with `--help`):\r\n\r\n```bash\r\n$ /opt/boulder/bin/boulder-ca --config /etc/boulder/config.json\r\n2015/09/24 22:31:12 Using default logging configuration.\r\n2015/09/24 22:31:12 [AUDIT] Unable to read config file: open /etc/boulder/config.json: permission denied\r\nUnable to read config file: open /etc/boulder/config.json: permission denied\r\n```\r\n\r\nSimilarly, as an example, Boulder doesn't print the version until it's fully online, and does not log it at AUDIT:\r\n\r\n```bash\r\n$ sudo /opt/boulder/bin/boulder-ca --config /etc/boulder/config.json\r\n2015/09/24 22:31:16 [DEBUG] Parsed OID [2 23 140 1 2 1]\r\n2015/09/24 22:31:16 [DEBUG] Parsed OID [1 3 6 1 4 1 44947 1 1 1]\r\n2015/09/24 22:31:16 Connecting to database\r\n2015/09/24 22:31:16 booting debug server at \"0.0.0.0:8000\"\r\n2015/09/24 22:31:16 Connected to database\r\n2015/09/24 22:31:16 Connecting to database\r\n2015/09/24 22:31:16 Connected to database\r\n2015/09/24 22:31:16 Policy Authority Starting\r\n2015/09/24 22:31:16 Certificate Authority Starting\r\n2015/09/24 22:31:16 [DEBUG] Parsed OID [2 23 140 1 2 1]\r\n2015/09/24 22:31:16 [DEBUG] Parsed OID [1 3 6 1 4 1 44947 1 1 1]\r\n2015/09/24 22:31:16 [DEBUG] parse expiry in profile\r\n2015/09/24 22:31:16 [DEBUG] expiry is valid\r\n2015/09/24 22:31:16 [DEBUG] parse expiry in profile\r\n2015/09/24 22:31:16 [DEBUG] expiry is valid\r\n2015/09/24 22:31:16 [DEBUG] validating configuration\r\n2015/09/24 22:31:16 [DEBUG] validate local profile\r\n2015/09/24 22:31:16 [DEBUG] profile is valid\r\n2015/09/24 22:31:16 [DEBUG] validate local profile\r\n2015/09/24 22:31:16 [DEBUG] profile is valid\r\n2015/09/24 22:31:16 [DEBUG] configuration ok\r\n2015/09/24 22:31:16 [DEBUG] validating configuration\r\n2015/09/24 22:31:16 [DEBUG] validate local profile\r\n2015/09/24 22:31:16 [DEBUG] profile is valid\r\n2015/09/24 22:31:16 [DEBUG] validate local profile\r\n2015/09/24 22:31:16 [DEBUG] profile is valid\r\n2015/09/24 22:31:16 Versions: boulder-ca=( +520c5c3 Thu Sep 24 22:04:15 UTC 2015) Golang=(go1.5) BuildHost=(...)\r\n```"},"comment":{"url":"https://api.github.com/repos/letsencrypt/boulder/issues/comments/143081015","html_url":"https://github.com/letsencrypt/boulder/issues/851#issuecomment-143081015","issue_url":"https://api.github.com/repos/letsencrypt/boulder/issues/851","id":143081015,"user":{"login":"jsha","id":220205,"avatar_url":"https://avatars.githubusercontent.com/u/220205?v=3","gravatar_id":"","url":"https://api.github.com/users/jsha","html_url":"https://github.com/jsha","followers_url":"https://api.github.com/users/jsha/followers","following_url":"https://api.github.com/users/jsha/following{/other_user}","gists_url":"https://api.github.com/users/jsha/gists{/gist_id}","starred_url":"https://api.github.com/users/jsha/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jsha/subscriptions","organizations_url":"https://api.github.com/users/jsha/orgs","repos_url":"https://api.github.com/users/jsha/repos","events_url":"https://api.github.com/users/jsha/events{/privacy}","received_events_url":"https://api.github.com/users/jsha/received_events","type":"User","site_admin":false},"created_at":"2015-09-24T23:42:53Z","updated_at":"2015-09-24T23:42:53Z","body":"Also, filed https://github.com/letsencrypt/boulder/issues/852 to talk more about the long-term thing."}}