/usr/lib/os-probes/mounted/efi/20microsoft is in os-prober 1.63ubuntu1.
This file is owned by root:root, with mode 0o755.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 | #!/bin/sh
# Detects Microsoft bootloader on a EFI System Partition
. /usr/share/os-prober/common.sh
efi="$1"
found=
for microsoft in $(item_in_dir microsoft "$efi"); do
for boot in $(item_in_dir boot "$efi/$microsoft"); do
bcd=$(item_in_dir bcd "$efi/$microsoft/$boot")
bootmgfw=$(item_in_dir bootmgfw.efi "$efi/$microsoft/$boot")
if [ -n "$bcd" -a -n "$bootmgfw" ]; then
long="Windows Boot Manager"
short=Windows
path="$microsoft/$boot/$bootmgfw"
found=true
break
fi
done
done
if [ -n "$found" ]; then
label="$(count_next_label "$short")"
result "${path}:${long}:${label}"
fi
exit 0
|