)]}'
{
  "commit": "ccd62005490de907105c92444631a5914500cb32",
  "tree": "5e17cf4f181598bfddb70f17b6ae2f3a7de315c2",
  "parents": [
    "b35300fc67cc050ce3f709a88a4437153d85e0ee"
  ],
  "author": {
    "name": "Michael Brown",
    "email": "mcb30@ipxe.org",
    "time": "Tue Feb 18 15:28:55 2025 +0000"
  },
  "committer": {
    "name": "Michael Brown",
    "email": "mcb30@ipxe.org",
    "time": "Tue Feb 18 15:38:54 2025 +0000"
  },
  "message": "[crypto] Start up RBG on demand if needed\n\nThe ANS X9.82 specification implicitly assumes that the RBG_Startup\nfunction will be called before it is needed, and includes checks to\nmake sure that Generate_function fails if this has not happened.\nHowever, there is no well-defined point at which the RBG_Startup\nfunction is to be called: it\u0027s just assumed that this happens as part\nof system startup.\n\nWe currently call RBG_Startup to instantiate the DRBG as an iPXE\nstartup function, with the corresponding shutdown function\nuninstantiating the DRBG.  This works for most use cases, and avoids\nan otherwise unexpected user-visible delay when a caller first\nattempts to use the DRBG (e.g. by attempting an HTTPS download).\n\nThe download of autoexec.ipxe for UEFI is triggered by the EFI root\nbus probe in efi_probe().  Both the root bus probe and the RBG startup\nfunction run at STARTUP_NORMAL, so there is no defined ordering\nbetween them.  If the base URI for autoexec.ipxe uses HTTPS, then this\nmay cause random bits to be requested before the RBG has been started.\n\nExtend the logic in rbg_generate() to automatically start up the RBG\nif startup has not already been attempted.  If startup fails\n(e.g. because the entropy source is broken), then do not automatically\nretry since this could result in extremely long delays waiting for\nentropy that will never arrive.\n\nReported-by: Michael Niehaus \u003cniehaus@live.com\u003e\nSigned-off-by: Michael Brown \u003cmcb30@ipxe.org\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "4b45b34745933155f2b9e4469f7a6ca795060951",
      "old_mode": 33188,
      "old_path": "src/crypto/rbg.c",
      "new_id": "5e1c25f530e34650229847dd7e1ab070cf7678ca",
      "new_mode": 33188,
      "new_path": "src/crypto/rbg.c"
    },
    {
      "type": "modify",
      "old_id": "758238a656882f906d96f5026f3a1a60d8e88eb1",
      "old_mode": 33188,
      "old_path": "src/include/ipxe/rbg.h",
      "new_id": "4bf3055d100f87356467f68ad8912585cc860fa6",
      "new_mode": 33188,
      "new_path": "src/include/ipxe/rbg.h"
    }
  ]
}
