summaryrefslogtreecommitdiffstats
path: root/src/detection/host/host_bsd.c
diff options
context:
space:
mode:
authorsumuel <samuel@yakubos.org>2026-08-17 20:44:55 +0000
committersumuel <samuel@yakubos.org>2026-08-17 20:44:55 +0000
commit76424950e373d3b04ac3dd13019151bfba3e8423 (patch)
tree4c3cfdbda039e592b9186be3e28f8d7cfd439e8a /src/detection/host/host_bsd.c
Add the files
Diffstat (limited to 'src/detection/host/host_bsd.c')
-rw-r--r--src/detection/host/host_bsd.c26
1 files changed, 26 insertions, 0 deletions
diff --git a/src/detection/host/host_bsd.c b/src/detection/host/host_bsd.c
new file mode 100644
index 0000000..3eb547d
--- /dev/null
+++ b/src/detection/host/host_bsd.c
@@ -0,0 +1,26 @@
+#include "host.h"
+#include "common/settings.h"
+#include "common/smbios.h"
+
+const char* ffDetectHost(FFHostResult* host) {
+ ffSettingsGetFreeBSDKenv("smbios.system.product", &host->name);
+ ffCleanUpSmbiosValue(&host->name);
+ ffSettingsGetFreeBSDKenv("smbios.system.family", &host->family);
+ ffCleanUpSmbiosValue(&host->family);
+ ffSettingsGetFreeBSDKenv("smbios.system.version", &host->version);
+ ffCleanUpSmbiosValue(&host->version);
+ ffSettingsGetFreeBSDKenv("smbios.system.sku", &host->sku);
+ ffCleanUpSmbiosValue(&host->sku);
+ ffSettingsGetFreeBSDKenv("smbios.system.serial", &host->serial);
+ ffCleanUpSmbiosValue(&host->serial);
+ ffSettingsGetFreeBSDKenv("smbios.system.uuid", &host->uuid);
+ ffCleanUpSmbiosValue(&host->uuid);
+ ffSettingsGetFreeBSDKenv("smbios.system.maker", &host->vendor);
+ ffCleanUpSmbiosValue(&host->vendor);
+
+#ifdef __x86_64__
+ ffHostDetectMac(host);
+#endif
+
+ return NULL;
+}