summaryrefslogtreecommitdiffstats
path: root/src/include
Commit message (Collapse)AuthorAgeFilesLines
...
| * [cmdline] Add "--timeout" parameter to "ifconf" commandJoe Groocock2020-07-221-1/+2
| | | | | | | | | | Modified-by: Michael Brown <mcb30@ipxe.org> Signed-off-by: Michael Brown <mcb30@ipxe.org>
| * [xfer] Remove address family from definition of a socket openerMichael Brown2020-07-151-2/+0Star
| | | | | | | | | | | | | | | | All implemented socket openers provide definitions for both IPv4 and IPv6 using exactly the same opener method. Simplify the logic by omitting the address family from the definition. Signed-off-by: Michael Brown <mcb30@ipxe.org>
| * [libc] Add bit-rotation functions for unsigned long valuesMichael Brown2020-07-091-8/+26
| | | | | | | | | | | | | | | | | | Generalise the bit rotation implementations to use a common macro, and add roll() and rorl() to handle unsigned long values. Each function will still compile down to a single instruction. Signed-off-by: Michael Brown <mcb30@ipxe.org>
| * [libc] Provide an unoptimised generic_memcpy_reverse()Michael Brown2020-07-071-0/+2
| | | | | | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
| * [efi] Enable stack protection where possibleMichael Brown2020-06-241-0/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Enable -fstack-protector for EFI builds, where binary size is less critical than for BIOS builds. The stack cookie must be constructed immediately on entry, which prohibits the use of any viable entropy source. Construct a cookie by XORing together various mildly random quantities to produce a value that will at least not be identical on each run. On detecting a stack corruption, attempt to call Exit() with an appropriate error. If that fails, then lock up the machine since there is no other safe action that can be taken. The old conditional check for support of -fno-stack-protector is omitted since this flag dates back to GCC 4.1. Signed-off-by: Michael Brown <mcb30@ipxe.org>
| * [crypto] Ensure that test code drags in required ASN.1 object identifiersMichael Brown2020-06-171-0/+18
| | | | | | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* | Merge branch 'master' into openslxSimon Rettberg2019-12-032-5/+37
|\|
| * [peerdist] Limit number of concurrent raw block downloadsMichael Brown2019-08-161-0/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Raw block downloads are expensive if the origin server uses HTTPS, since each concurrent download will require local TLS resources (including potentially large received encrypted data buffers). Raw block downloads may also be prohibitively slow to initiate when the origin server is using HTTPS and client certificates. Origin servers for PeerDist downloads are likely to be running IIS, which has a bug that breaks session resumption and requires each connection to go through the full client certificate verification. Limit the total number of concurrent raw block downloads to ameliorate these problems. Signed-off-by: Michael Brown <mcb30@ipxe.org>
| * [process] Add PROC_INIT() for initialising static processesMichael Brown2019-08-161-5/+13
| | | | | | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* | Merge branch 'openslx' of git.openslx.org:openslx-ng/ipxe into openslxSimon Rettberg2019-08-021-1/+1
|\ \
| * | [login] Add "--nouser" option to just ask for passwordSimon Rettberg2019-04-011-1/+1
| | |
| * | Merge branch 'master' into openslxSimon Rettberg2019-03-284-4/+59
| |\ \
* | \ \ Merge branch 'master' into openslxSimon Rettberg2019-08-029-8/+260
|\ \ \ \ | |/ / / |/| | / | | |/ | |/|
| * | [fdt] Add ability to parse a MAC address from a flattened device treeMichael Brown2019-07-192-0/+103
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The Raspberry Pi NIC has no EEPROM to hold the MAC address. The platform firmware (e.g. UEFI or U-Boot) will typically obtain the MAC address from the VideoCore firmware and add it to the device tree, which is then made available to subsequent programs such as iPXE or the Linux kernel. Add the ability to parse a flattened device tree and to extract the MAC address. Signed-off-by: Michael Brown <mcb30@ipxe.org>
| * | [build] Fix use of inline assembly on GCC 8 ARM64 buildsMichael Brown2019-07-141-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit 1a7746603 ("[build] Fix use of inline assembly on GCC 4.8 ARM64 builds") switched from using "%c0" to "%a0" in order to avoid an "invalid operand prefix" error on the ARM64 version of GCC 4.8. It appears that the ARM64 version of GCC 8 now produces an "invalid address mode" error for the "%a0" form, but is happy with the original "%c0" form. Switch back to using the "%c0" form, on the assumption that the requirement for "%a0" was a temporary aberration. Originally-fixed-by: John L. Jolly <jjolly@suse.com> Signed-off-by: Michael Brown <mcb30@ipxe.org>
| * | [intelxl] Add driver for Intel 40 Gigabit Ethernet NIC virtual functionsMichael Brown2019-04-271-0/+1
| | | | | | | | | | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
| * | [vlan] Provide vlan_netdev_rx() and vlan_netdev_rx_err()Michael Brown2019-04-271-2/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | The Hermon driver uses vlan_find() to identify the appropriate VLAN device for packets that are received with the VLAN tag already stripped out by the hardware. Generalise this capability and expose it for use by other network card drivers. Signed-off-by: Michael Brown <mcb30@ipxe.org>
| * | [pci] Add support for PCI MSI-X interruptsMichael Brown2019-04-243-0/+89
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The Intel 40 Gigabit Ethernet virtual functions support only MSI-X interrupts, and will write back completed interrupt descriptors only when the device attempts to raise an interrupt (or when a complete cacheline of receive descriptors has been completed). We cannot actually use MSI-X interrupts within iPXE, since we never have ownership of the APIC. However, an MSI-X interrupt is fundamentally just a DMA write of a single dword to an arbitrary address. We can therefore configure the device to "raise" an interrupt by writing a meaningless value to an otherwise unused memory location: this is sufficient to trigger the receive descriptor writeback logic. Signed-off-by: Michael Brown <mcb30@ipxe.org>
| * [ocsp] Accept response certID with missing hashAlgorithm parametersMichael Brown2019-03-101-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | One of the design goals of ASN.1 DER is to provide a canonical serialization of a data structure, thereby allowing for equality of values to be tested by simply comparing the serialized bytes. Some OCSP servers will modify the request certID to omit the optional (and null) "parameters" portion of the hashAlgorithm. This is arguably legal but breaks the ability to perform a straightforward bitwise comparison on the entire certID field between request and response. Fix by comparing the OID-identified hashAlgorithm separately from the remaining certID fields. Originally-fixed-by: Thilo Fromm <Thilo@kinvolk.io> Signed-off-by: Michael Brown <mcb30@ipxe.org>
| * [tls] Display validator messages only while validation is in progressMichael Brown2019-03-101-0/+2
| | | | | | | | | | | | | | Allow the cipherstream to report progress status messages during connection establishment. Signed-off-by: Michael Brown <mcb30@ipxe.org>
| * [tls] Support stateless session resumptionMichael Brown2019-03-061-0/+12
| | | | | | | | | | | | | | Add support for RFC5077 session ticket extensions to allow for stateless TLS session resumption. Signed-off-by: Michael Brown <mcb30@ipxe.org>
| * [tls] Support stateful session resumptionMichael Brown2019-02-211-2/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | Record the session ID (if any) provided by the server and attempt to reuse it for any concurrent connections to the same server. If multiple connections are initiated concurrently (e.g. when using PeerDist) then defer sending the ClientHello for all but the first connection, to allow time for the first connection to potentially obtain a session ID (and thereby speed up the negotiation for all remaining connections). Signed-off-by: Michael Brown <mcb30@ipxe.org>
| * [efi] Blacklist the Dell Ip4ConfigDxe driverMichael Brown2019-02-192-0/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On a Dell OptiPlex 7010, calling DisconnectController() on the LOM device handle will lock up the system. Debugging shows that execution is trapped in an infinite loop that is somehow trying to reconnect drivers (without going via ConnectController()). The problem can be reproduced in the UEFI shell with no iPXE code present, by using the "disconnect" command. Experimentation shows that the only fix is to unload (rather than just disconnect) the "Ip4ConfigDxe" driver. Add the concept of a blacklist of UEFI drivers that will be automatically unloaded when iPXE runs as an application, and add the Dell Ip4ConfigDxe driver to this blacklist. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* | Merge branch 'master' into openslxSimon Rettberg2019-02-151-0/+1
|\|
| * [init] Show startup and shutdown function names in debug messagesMichael Brown2019-01-251-0/+1
| | | | | | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* | Merge branch 'master' into openslxSimon Rettberg2018-09-131-0/+1
|\|
| * [intelxl] Add driver for Intel 40 Gigabit Ethernet NICsMichael Brown2018-07-171-0/+1
| | | | | | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* | [settings] Add md5 encoding type for doing ${foo:md5}Simon Rettberg2018-05-291-0/+1
| | | | | | | | | | | | | | This obviously only works for formatting, not parsing. This makes it possible to implement client side password checks without giving the password away too easily. Not super secure as it's md5, but enough for basic protection.
* | [menu] Add --hidden option to create hotkey-only entriesSimon Rettberg2018-05-281-1/+3
| |
* | [console] Add option to update margins and bg-image of vesa mode consoleSimon Rettberg2018-05-281-0/+2
|/ | | | | | | Adding --update to the console call will prevent the vesa mode from being initialized again. The existing mode will be reused. This makes it possible to quickly update the background image or console margins without ugly flickering.
* [icplus] Add driver for IC+ network cardSylvie Barlow2018-04-201-0/+1
| | | | | Signed-off-by: Sylvie Barlow <sylvie.c.barlow@gmail.com> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [mii] Add bit-bashing interfaceSylvie Barlow2018-04-201-0/+55
| | | | | | Signed-off-by: Sylvie Barlow <sylvie.c.barlow@gmail.com> Modified-by: Michael Brown <mcb30@ipxe.org> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [mii] Add mii_find()Sylvie Barlow2018-04-201-0/+4
| | | | | | | Add the function mii_find() in order to locate the PHY address. Signed-off-by: Sylvie Barlow <sylvie.c.barlow@gmail.com> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [mii] Fix typo in parameter nameMichael Brown2018-04-201-1/+1
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [tcp] Add missing packed attribute on struct tcp_headerMichael Brown2018-04-191-1/+1
| | | | | | Debugged-by: Mark Rutland <mark.rutland@arm.com> Debugged-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [mii] Separate concepts of MII interface and MII deviceMichael Brown2018-04-191-19/+48
| | | | | | | | | | | | | We currently have no generic concept of a PHY address, since all existing implementations simply hardcode the PHY address within the MII access methods. A bit-bashing MII interface will need to be provided with an explicit PHY address in order to generate the correct waveform. Allow for this by separating out the concept of a MII device (i.e. a specific PHY address attached to a particular MII interface). Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [tls] Rename tls_session to tls_connectionMichael Brown2018-03-241-2/+2
| | | | | | | | | | | | In TLS terminology a session conceptually spans multiple individual connections, and essentially represents the stored cryptographic state (master secret and cipher suite) required to establish communication without going through the certificate and key exchange handshakes. Rename tls_session to tls_connection in order to make the name tls_session available to represent the session state. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [list] Add list_is_first_entry() and list_is_last_entry()Michael Brown2018-03-241-0/+22
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [rng] Use fixed-point calculations for min-entropy quantitiesMichael Brown2018-03-204-9/+29
| | | | | | | | | | | | | | We currently perform various min-entropy calculations using build-time floating-point arithmetic. No floating-point code ends up in the final binary, since the results are eventually converted to integers and asserted to be compile-time constants. Though this mechanism is undoubtedly cute, it inhibits us from using "-mno-sse" to prevent the use of SSE registers by the compiler. Fix by using fixed-point arithmetic instead. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [time] Add support for the ACPI power management timerMichael Brown2018-03-201-0/+7
| | | | | | | | Allow the ACPI power management timer to be used if enabled via TIMER_ACPI in config/timer.h. This provides an alternative timer on systems where the standard 8254 PIT is unavailable or unreliable. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [ocsp] Allow OCSP checks to be disabledMichael Brown2018-03-181-0/+12
| | | | | | | | | Some CAs provide non-functional OCSP servers, and some clients are forced to operate on networks without access to the OCSP servers. Allow the user to explicitly disable the use of OCSP checks by undefining OCSP_CHECK in config/crypto.h. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [ocsp] Centralise test for whether or not an OCSP check is requiredMichael Brown2018-03-181-0/+15
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [lacp] Mark link as blocked if partner is not yet up and runningMichael Brown2018-03-181-0/+6
| | | | | | | | | | | | Mark the link as blocked if the LACP partner is not reporting itself as being in sync, collecting, and distributing. This matches the behaviour for STP: we mark the link as blocked if we detect that the switch is actively blocking traffic, in order to extend the DHCP discovery period and so prevent boot failures on switches that take an excessively long time to enable ports. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [process] Include process name in debug messagesMichael Brown2018-02-201-2/+7
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [http] Allow for domain names within NTLM user namesMichael Brown2018-02-191-0/+30
| | | | | | | | | Allow a NetBIOS domain name to be specified within a URL using a syntax such as: http://domain%5Cusername:password@server/path Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [ena] Add driver for Amazon ENA virtual function NICMichael Brown2018-01-131-0/+1
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [legal] Add missing FILE_LICENCE declarationsMichael Brown2017-12-292-0/+4
| | | | | | | Add missing FILE_LICENCE declarations to EFI headers based on the corresponding source file. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [http] Add support for NTLM authenticationMichael Brown2017-11-122-0/+26
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [http] Handle parsing of WWW-Authenticate header within authentication schemeMichael Brown2017-11-121-8/+47
| | | | | | | Allow individual authentication schemes to parse WWW-Authenticate headers that do not comply with RFC2617. Signed-off-by: Michael Brown <mcb30@ipxe.org>
* [ntlm] Add support for NTLM authentication mechanismMichael Brown2017-11-122-0/+200
| | | | Signed-off-by: Michael Brown <mcb30@ipxe.org>