mirror of
https://git.proxmox.com/git/efi-boot-shim
synced 2025-07-17 17:18:11 +00:00
httpboot: parse https prefix in the uri
This commit adds the check for "https://" in the uri to support HTTPs Boot. Signed-off-by: Gary Lin <glin@suse.com>
This commit is contained in:
parent
97022acd36
commit
3ee08dde9c
@ -184,6 +184,9 @@ generate_next_uri (CONST CHAR8 *current_uri, CONST CHAR8 *next_loader,
|
|||||||
if (strncmpa(current_uri, (CHAR8 *)"http://", 7) == 0) {
|
if (strncmpa(current_uri, (CHAR8 *)"http://", 7) == 0) {
|
||||||
ptr = current_uri + 7;
|
ptr = current_uri + 7;
|
||||||
count += 7;
|
count += 7;
|
||||||
|
} else if (strncmpa(current_uri, (CHAR8 *)"https://", 8) == 0) {
|
||||||
|
ptr = current_uri + 8;
|
||||||
|
count += 8;
|
||||||
} else {
|
} else {
|
||||||
return EFI_INVALID_PARAMETER;
|
return EFI_INVALID_PARAMETER;
|
||||||
}
|
}
|
||||||
@ -216,6 +219,8 @@ extract_hostname (CONST CHAR8 *url, CHAR8 **hostname)
|
|||||||
|
|
||||||
if (strncmpa(url, (CHAR8 *)"http://", 7) == 0)
|
if (strncmpa(url, (CHAR8 *)"http://", 7) == 0)
|
||||||
start = url + 7;
|
start = url + 7;
|
||||||
|
else if (strncmpa(url, (CHAR8 *)"https://", 8) == 0)
|
||||||
|
start = url + 8;
|
||||||
else
|
else
|
||||||
return EFI_INVALID_PARAMETER;
|
return EFI_INVALID_PARAMETER;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user