#
…

2021-01-09

00:02bear24rw_ has joined #asahi
00:02bear24rw has quit [Read error: Connection reset by peer]
00:06bear24rw_ has quit [Remote host closed the connection]
00:06bear24rw has joined #asahi
00:15bear24rw has quit [Remote host closed the connection]
00:16bear24rw has joined #asahi
00:18raster has joined #asahi
00:26bear24rw has quit [Remote host closed the connection]
00:27bear24rw has joined #asahi
00:30bear24rw has quit [Remote host closed the connection]
00:31bear24rw has joined #asahi
00:39modwizcode has quit [Quit: Later]
00:40stormclad has joined #asahi
00:47stormclad has quit [Remote host closed the connection]
00:47stormclad has joined #asahi
01:06amw1 has joined #asahi
01:07bear24rw has quit [Remote host closed the connection]
01:07bear24rw has joined #asahi
01:09jkkm has joined #asahi
01:12amw1 has quit [Ping timeout: 256 seconds]
01:15aratuk has quit [Read error: Connection reset by peer]
01:16aratuk has joined #asahi
01:20aratuk has quit [Read error: Connection reset by peer]
01:21aratuk has joined #asahi
01:26aratuk has quit [Read error: Connection reset by peer]
01:27aratuk has joined #asahi
01:41krbtgt has quit [Quit: leaving]
01:43choozy has quit [Remote host closed the connection]
01:46czero64 has joined #asahi
01:46krbtgt has joined #asahi
01:50robinpmarcan: I can get a remote shell using nc in 1TR
01:51robinpremotemachine: nc -l 9999
01:51stormclad has quit [Ping timeout: 264 seconds]
01:52robinp1TRmini: bash -i >& /dev/tcp/10.1.1.2/9999 0>&1
01:53robinpis that good enough ?
01:55marcanAlex[m]17: it is not. read the article about DFU.
01:55marcanApple Silicon devices cannot boot from external storage at all
01:56marcannot without recovery mode working anyway
01:56marcaniBoot does not support USB
01:56marcan"booting" from external storage is, apparently, actually a recovery feature where it copies the boot-related stuff from external storage into internal storage
01:56marcanso none of this is relevant for recovery
01:57marcanif 1TR is gone, and macOS is gone, you get to DFU
01:57tpw_ruleshow many kilobytes is iBoot?
01:58marcanrobinp: that's basically my plan, except copying screen and script from macOS so I can have a proper tty
02:16stormclad has joined #asahi
02:25rwhitbymarcan: do you think it would be useful to create a wiki page that tells people how to prepare their device to be able to participate in the project while still having access to macOS data (either in internal or external disk) and how to recover from worst case scenarios? Put all the various information into one place specific to this project?
02:26stormclad has quit [Ping timeout: 260 seconds]
02:26opticronthat sounds like a very convenient page
02:26davidrysk[m]The first part, we're not 100% on that yet
02:27davidrysk[m]The second part, a second Mac (relatively recent Intel Mac is fine) and a link to the DFU instructions, well that should recovery a worst case scenario
02:27opticronkind of a "newbies and desparate start here"
02:27rwhitbydavidrysk[m]: right, the first part is what I'm intending to help determine.
02:27opticron*desperate
02:28davidrysk[m]I'd start with seeing how to install multiple instances of macOS on the Mac
02:28davidrysk[m]e.g. 11.0.1 and 11.1, in separate APFS containers
02:28davidrysk[m]Are you familiar with installinstallmacos.py? That's another useful tool — it allows for the creation of a bootable install USB (though I'm not 100% sure it will boot on M1)
02:34rwhitbyI'm currently assuming that nothing that's not a utility that already exists on the M1 will be of any use for dual-booting etc.
02:37davidrysk[m]Apple claims that you're supposed to be able to have multiple macOS installs
02:37Alex[m]17<marcan "Alex: it is not. read the articl"> marcan: i dont know what article you are referring to. but good to hear there is a recovery mode irrelevant to booting from external storage.
02:37davidrysk[m]but people have reported problems with external boot (which doesn't appear to be direct external boot)
02:38rwhitbyok, so I successfully reinstalled macOS on an external TBT3 SSD according to https://discussions.apple.com/thread/252222611 and have been (as expected) able to select it as a startup disk. All this is of course expected. Next step is to DFU recover from scratch, and then see if it's still possible to boot from the external SSD after that.
02:38davidrysk[m]there is a startup disk preference panel in macOS
02:40roxfan has quit [Remote host closed the connection]
02:41rwhitbyYes, that's the normal way to select startup disks. The same options (internal SSD and external SSD) are also available in 1TR alongside the Options.
02:41aratuk has quit [Ping timeout: 246 seconds]
02:42davidrysk[m]do you have a usb-c drive you can test with?
02:42davidrysk[m]people report mixed success and failure
02:42rwhitbyI'm testing with TBT3 SSD (Samsung X5). I can also test with USB3 10Gb/s SSD (Sandisk Extreme 900).
02:43roxfan has joined #asahi
02:46aratuk has joined #asahi
02:47aratuk_ has joined #asahi
02:48aratuk_ has quit [Read error: Connection reset by peer]
02:48aratuk__ has joined #asahi
02:49aratuk__ has quit [Read error: Connection reset by peer]
02:49aratuk_ has joined #asahi
02:50aratuk has quit [Ping timeout: 246 seconds]
02:51rwhitbyAs expected, booting from internal SSD or external SSD also works from 1TR selection screen. Nothing new here.
02:56Namidairo has quit [Quit: ZNC - https://znc.in]
02:56Namidairo has joined #asahi
03:00rwhitbyLooks like it will take an hour to install macOS on the USBC SSD, will report results of booting from it after that.
03:04marcanrwhitby: sure! there is already https://github.com/AsahiLinux/docs/wiki/SW%3AGetting-started but that is *not* intended towards otherwise normal macOS end-users
03:04marcansince it kills a bunch of security
03:05marcanand probably increases the chances of macOS upgrades failing
03:05marcandavidrysk[m]: so one problem with the APFS containers which makes this finicky is that I already tried adding a partition and it broke recovery mode
03:05marcanI need to figure out what exactly happened and whether it can be fixed
03:06marcan(it didn't break macOS, so I was able to delete the partition and get it back without DFU)
03:06marcanprobably just the recovery partition getting referenced by index somewhere
03:06rwhitbymarcan: that's what I'm in a position to test now if you need anything tested. I have a fully expendable (as long as it can be recovered) macOS install at the moment.
03:06marcanso for dual-booting, of course, one way would be to have our bootloader be able to chainload macOS
03:06marcanbut if we can coax iBoot/recovery mode into doing it, that would be very convenient
03:07marcanand in principle multiple installs should indeed be supported AIUI
03:08marcanthere is clear evidence of support for that
03:08marcanone thing though. is that a lot of this might be broken
03:08marcan*lots* of things were broken in what shipped from the factory AIUI
03:08marcanwhich is why everyone said upgrade to 11.0.1 first
03:08marcanM1 was clearly a rush job, especially this whole firmware/boot thing
03:08marcanso I expect things to improve over time
03:09marcanbut we should expect to encounter bugs/problems at this stage I think
03:09marcanfeeling good about progress today, going to reply to an important email or two and get down to work
03:10rwhitbywell, if DFU restore doesn't work I can just take it back as DOA today ;-)
03:10marcanhahaha, I would be *very* surprised if any of us managed to brick the things so that they can't be DFU'd
03:10rwhitbyyeah, but I want to personally prove that process today before I start to rely on it working at some point in the future :-0
03:11marcanthough one interesting question is whether Apple can do product data repair in Apple Stores - probably not is my guess, so if we manage to nuke that they probably have to go back to the mothership for repair
03:11marcanbut there is no reason whatsoever for us to ever write to NOR flash as far as I can tell
03:11marcanand possibly even no way, it might be locked hard after iBoot
03:11robinpmarcan: streming ?
03:11marcanrobinp: probably
03:11* rwhitbyis in a position to watch today
03:12marcanrwhitby: feel free to hack around; I don't have anything specific to want to test right now, other than seeing if I can get recovery to work with an extra partition
03:12marcanwhat I did was use disk utility in macOS to partition the disk, splitting the macOS container into two. that's somewhat broken, you can pick HFS and then it goes and formats it as APFS anyway. it errored out for me, but actually did the split properly
03:12marcanthen I went back and formatted it as HFS+ as a placeholder
03:12marcanat that point macOS was fine, but recovery no longer worked
03:12marcandeleting the HFS+ partition (leaving the empty space) fixed it
03:12rwhitbyyeah, that's my goal - work out how to have an extra partition that Linux can use while macOS remains where it is
03:13marcanI remember diskutil (cmdline) showing recovery partition numbers in the apfs info
03:13marcanso I suspect it's stored somewhere
03:13marcanbut it might also be in iSC
03:13marcan(that's iBoot System Container btw)
03:13rwhitbyIf you like I'll document all the partitioning in the wiki too
03:13marcanI was actually about to do some of that, boot process/partitioning docs
03:13marcanlet me get to the emails and I'll stream some of that research
03:15rwhitbyplease paste a link here when you start streaming
03:16marcanoh yeah, one thing you can do
03:16marcanyou have that PD analyzer, right?
03:16rwhitbyEllisys C-Tracker, and also my own Saleae decoder.
03:16marcanI wonder if Apple Configurator 2 actually does any PD stuff against a target Mac, if you use a proper C-C cable
03:16rwhitby(and a Cypress analyser and a Twinkie, but I never use those)
03:16davidrysk[m]Back for a while
03:17davidrysk[m]marcan: you being on Japan time is kinda inconvenient for me :D
03:17marcanso maybe you can give that a whirl
03:17marcandavidrysk[m]: yeah...
03:17marcanunfortunate timezone issues
03:17rwhitbyyes, I intended to have full tracing in place for the DFU to capture all that
03:17davidrysk[m]rwhitby: It might be worth seeing if you can have multiple macOS APFS containers with different OS volumes on the internal disk
03:17davidrysk[m]and still have recovery function
03:17marcanI'm mostly interested in PD; I think we mostly know how DFU works, and I have a USB2 analyzer I can use for that bit
03:17marcanI do want to get idevicerestore (linux tool) to work with the M1
03:17marcannot sure what the current state is
03:18rwhitbyok, will check PD in particular
03:18marcanbut it should be mostly incremental additions to that
03:18davidrysk[m]marcan: unimplemented. I think it might support T2
03:18marcanyeah, but I mean, how close
03:18JTLmarcan: out of interest, what USB2 analyzer you use these days?
03:18marcanOpenVizsla
03:18marcanwhich I helped write the software for
03:18JTLah yeah
03:18JTLI remember the kickstarter for that from 10 years ago
03:18JTLand the delays
03:18marcanyeah that was one... rollercoaster ride
03:19JTLI remember that
03:19marcanlet's just say a certain someone is no longer welcome to work with us
03:19marcanand also Ben saved the project with his own personal money (R.I.P...)
03:19rwhitbyis that the one you would buy today, or is there something better (e.g. Luna?)
03:19marcanI think that kickstarter deserves an award for being the most delayed hardware project that actually shipped all rewards
03:19JTLRIP bushing
03:20JTLmarcan: *xbox 360 trophy thingy*
03:20czero64 has quit [Ping timeout: 260 seconds]
03:20JTL"Delayed but Shipped Project"
03:20davidrysk[m]I mean, between it and the Open Locksport kickstarter, for which Jason Scott stepped in to help complete
03:20marcanrwhitby: not sure tbh, haven't looked into it. OV is a nice architecture, but I also want to design Glasgow revD/E, and revE will be a perfectly fine backend for an analyzer
03:20marcanbut that's at least a couple years away most likely
03:20marcanactually I kinda wonder if a USB "hat" for revC would make sense... next to no buffer memory is a problem though
03:21marcan(OV has that)
03:21marcanbut revE will definitely support this use case with the right modules
03:21davidrysk[m]Some Apple documentation (IIRC WWDC2020 videos) hints that you can have multiple OS versions within the same APFS container, but that really doesn't help us
03:21davidrysk[m]I wish Apple didn't put so much of their documentation in videos
03:21davidrysk[m]it's awfully inconvenient
03:21rwhitbyLooks like OV is available to purchase at sysmocom
03:22stormclad has joined #asahi
03:22marcanthose are the units Ben had stashed away, we finally got them into good hands semi-recently
03:22marcan(bless his wife)
03:23JTLIt's what bushing would've wanted :(
03:23marcanseriously, I can't thank both of them enough for everything they've done for this project and so many others
03:23marcanit certainly is
03:23rwhitbyI've been looking for a good USB sniffer, was waiting for Luna but may push the button on that one earlier
03:24marcanjust keep in mind the software is a bit hacky, last I remember we were discussing how to properly integrate it with pcap/wireshark
03:24marcanhonestly the project needs a bit of software love
03:24marcanthe hardware is great
03:25rwhitbyktemkin is using it for Luna testing, right?
03:25marcanI think so? haven't followed her project
03:26marcanoh so I think end to end pcap support is actually in since a couple years back
03:26rwhitbyOpenVizsla USB Analyzer Spartan 6 ULPI (USB3343) Fully Supported
03:27marcanand yeah the luna stuff too
03:27marcanI haven't used it recently, last time I used it I was just dumping USB frames to stdout :)
03:28davidrysk[m]I think most of the time when I've needed to do USB tracing I've used the VMware facilities for it, but they're nowhere near as good as hardware
03:28* rwhitbyshuts up so marcan can get back to email and streaming
03:28marcanI should actually look into who github.com/openvizsla is, we should convert that to an organization
03:28marcan(I think this used to be hosted elsewhere)
03:29marcananyway, emails and work
03:32Necrosporusrwhitby, maybe this question is naive, but is it possible to boot OSX from $5 USB flash drive? Are you required to have something like thunderbolt SSD? Also... given it's supposedly super fast, how long does it take to get you from power on to login screen / desktop?
03:33davidrysk[m]Necrosporus: you're supposed to be able to boot from a $5 USB flash drive (but performance will suck, so you might not want to), but people were reporting it to be broken
03:33rwhitbyI'll be testing 10Gb/s USBC SSD soon, and have tested 20Gb/s TBT3 SSD. Can time both of them if you like.
03:33davidrysk[m]I've had okay performance on my intel macs with the sandisk extreme pro usb 3.1 (or 3.2) drives
03:34Necrosporusrwhitby, can you time internal storage?
03:34davidrysk[m]rwhitby: do you have any lower-end USB media like the drives I refer to?
03:34NecrosporusAlso you do already have working external medium, right? So can you just dd it over an USB flash?
03:35rwhitbydavidrysk[m]: not of sufficient size
03:35davidrysk[m]Necrosporus: you can't just dd it over a usb flash, you have to use the mac os installer app. now if you dd that, that probably can be portable to another usb flash
03:35NecrosporusI mean that thing, yes
03:36Necrosporususing installer, then dd whatever there is to other external drive
03:36NecrosporusHow much space is required by the installer?
03:36NecrosporusCan it install to 8Gb medium? Or 16Gb?
03:37davidrysk[m]the big sur installer is much more inefficient than previous ones
03:37Bastian[m]the hackintosh instructions say 8+GB
03:37davidrysk[m]16GB usde to work
03:38davidrysk[m]that's for the USB installer disk
03:39davidrysk[m]not for the target
03:39rwhitbyTarget looks like 200+GB
03:39Bastian[m]oh, misread my bad
03:39rwhitbyno, that can't be right, scratch that figure
03:39NecrosporusSo you cannot use $5 USB flash drive
03:39davidrysk[m]IIRC the minimum was around 60-70GB
03:40davidrysk[m]it used to be 16GB before big sur, but the big sur installer is extremely inefficient
03:40davidrysk[m]it unpacks itself twice over
03:40marcanNecrosporus: PM
03:46rwhitbyInstalling macOS to USBC Sandisk Extreme 900 480GB drive works.
03:46davidrysk[m]people reported difficulty with USBA drives
03:47Necrosporusrwhitby, and boooting from it too?
03:47davidrysk[m]I'm not sure if they meant using the USBA ports on mac minis, or USBC adapters for them
03:47davidrysk[m]the mac mini USBA ports are weird because they're behind those Fresco Logic controllers — it's possible that Apple didn't fully implement boot support for them
03:48davidrysk[m]I guess the next thing
03:48davidrysk[m]use Disk Utility to shrink the APFS container on the 480GB to 240GB and make a second one and name it differently
03:48davidrysk[m]install macOS onto it and see what the partition layout looks like
03:48rwhitby33s from 1TR to login for USBC.
03:48davidrysk[m]then try the same on the internal
03:49davidrysk[m]see if you can stuff two separate OS installs on the same disk... and see if recovery and all still work
03:50NecrosporusThat's quite a lot, I think
03:50NecrosporusI mean Windows XP on my old computer with slow 40GB ide HDD took about 30 seconds to boot
03:51rwhitbyThat's weird - I got a "The version of macOS on the selected disk needs to be reinstalled" when booting from the TBT3 SSD, even though it previously had no issue booting from it multiple times.
03:51davidrysk[m]rwhitby: if that happens, go back to the boot selector and try again
03:51davidrysk[m]that can mean the incorrect volume is selected
03:51davidrysk[m](and can also be triggered by bootchain related bugs, of which there are still some)
03:53rwhitbyhappened a second time from 1TR, trying from macOS prefs
03:54stormclad has quit [Ping timeout: 240 seconds]
03:57rwhitby32s from reboot to login for TBT3 SSD, roughly same as USBC SSD, so it's not transport or disk speed limited (I know that TBT3 SSD is at least twice as fast as USBC SSD using BlackMagic speed test.
03:57marcandavidrysk[m]: there is no boot support for *any* external storage; all of that is handled via macOS
03:57davidrysk[m]rwhitby: is it any faster on reboot?
03:58Shizmarcan: so I guess you saw `diskutil apfs list` right
03:58marcanso in principle "external" "boot" should work from anything macos supports
03:58davidrysk[m]marcan: via macOS in recovery?
03:58Shizwhere it assigns the partition role by partition number
03:58Shizthat probably is the cause of your breakage
03:58marcanShiz: yes
03:58marcanthat is what I saw after the breakage
03:58marcanbut I'm not sure how true that info is
03:58marcanor how it fits into everything else
03:58rwhitby14s for internal chime to login.
03:58marcanso I need to check if that really is the problem :)
03:58marcandiskutil is way too automagic
03:59davidrysk[m]marcan: that's why I wonder what will happen if you make a second APFS container with a second independent copy of macOS on the internal SSD
03:59marcanI don't even know what the GPT partition entries look like tbh
03:59davidrysk[m]I can dump my gpt :)
03:59davidrysk[m]but I think I can also make diskutil do that
03:59marcanactually I was having trouble with that, getting raw disk info
03:59marcanand then I realized bputil *re-enables* aspects of SIP, grumble
03:59marcanI think it will probably work now
03:59marcanthat's another thing on my TODO list today :p
04:00marcananyway, let me do the emails :)
04:00davidrysk[m]did y'all see that Apple got rid of old fashioned raw target mode?
04:00davidrysk[m]modern target mode is SMB server based
04:01rwhitbyfinal figures are 14s internal chime to login, 22s USBC chime to login, 22s TBT3 chime to login.
04:02marcandavidrysk[m]: same reason I think
04:02Shizthe GPT partition entries are pretty simple
04:02marcanit seems the philosophy here was "UEFI on Macs is an enourmous pile of junk"
04:02Shizdisk3 is a synthesized APFS volume
04:02marcanand they went full 180
04:02Shizlike btrfs subvolumes
04:02marcanand now iBoot is tiny, and everything else is done in macos
04:02davidrysk[m]marcan: well it *was* an enormous pile of junk
04:03davidrysk[m]and the updater was unreliable too
04:03marcanbtw, another useful thing: amfi_get_out_of_my_way=1 on boot-args should get rid of all of the entitlement junk I *think*
04:03marcan(if SIP is disabled)
04:03Shizthe GPT entries are just: [iBoot SC][APFS volume][Recovery]
04:03Shiz3 partitions :)
04:03marcanShiz: I wonder what they are in my GPT, after I created and deleted a partition
04:03davidrysk[m]what happens if you put a second apfs volume on the disk
04:04roxfanwhat's SC?
04:04marcanspecifically, whether it coalesced or not
04:04Shizsystem container
04:04marcaniBoot System Container
04:04Shizthe iboot pre-bootstrap
04:04Shizinfo container
04:04marcandavidrysk[m]: right now if you put a second anything on the disk recovery explodes :p
04:04marcanso I need to fix that first
04:04davidrysk[m]hm, disk utility won't let you
04:04marcandisk utility does let you partition the main container
04:05davidrysk[m]it lets you add volumes to the main container
04:05Shizhttps://txt.shiz.me/OWUyOWQwZG my current (very simplified) view of the boot process
04:05davidrysk[m]it does not let you add another main container
04:05Shizfor the curious
04:05marcanright now my mac mini looks like [iSC][macOS]<empty space>[Recovery] (I'm not sure what the physical partition entry indexes are in GPT at this point)
04:05rwhitbydavidrysk[m] 4s faster on TBT3 for reboot to same disk
04:05marcanthat works
04:05marcanbut with a partition filling the empty space, it breaks
04:05* davidrysk[m]uploaded an image: Screen Shot 2021-01-08 at 11.04.52 PM.png (1356KiB) < https://matrix.org/_matrix/media/r0/download/matrix.org/ySRJCOrkUBESDbvDfCoaRDwJ/Screen Shot 2021-01-08 at 11.04.52 PM.png >
04:06marcandavidrysk[m]: you need to enable some advanced option I forget
04:06marcanthen you can select the container and partition it
04:06marcando this from macos, it supports on-line partitioning
04:06Shizi'm very mddy on what happen once it found the preboot partition and next state img4 hash :)
04:06Shizbut the rest should be okay, misc signing & integrity verificaiton aside
04:06davidrysk[m]marcan: the window to do that is as above, it says the minimum is the size of the disk (2TB) and won't let me shrink it
04:07marcanyou need to click the add button
04:07marcanthen you get to drag the split around
04:07marcanthe disk utility UI is terrible
04:07davidrysk[m] the add button is greyed out
04:07davidrysk[m]I've done this in Intel
04:07marcanwell this worked for me...
04:08davidrysk[m]hm maybe it's because I haven't shut off all security :)
04:08marcanor different OS versions, I forget what I was on when I did it
04:08Shizi found out another thing to shut off the other day
04:08Shiz# csrutil authenticated-root disable
04:08davidrysk[m]Shiz: enabling verbose boot and capturing the boot log would be useful
04:08Shizif you wanna muck around on the macOS root volume
04:08marcanShiz: but you still need to bless a snapshot to use it
04:09marcanit's a major PITA
04:09rwhitbydavidrysk[m] install size is 30GB on internal disk, and 44GB on external disks. Not sure how much extra it needs during the process.
04:09davidrysk[m]yeah I think that's on the wiki
04:09marcancan't get proper RW mount root
04:09Shizyeah it's as
04:09davidrysk[m]rwhitby: wow. that's significantly larger than <=10.15
04:09davidrysk[m]it's a PITA, but they did it to improve security and update reliability
04:09Shizmarcan: right
04:09davidrysk[m](though the first few update versions were still unreliable)
04:09Shizi disabled all the sec features on mine the day i got it in :p
04:09Shiz(and that one today)
04:11rwhitbyI don't have a 64GB flash stick handy to test USBA install.
04:12davidrysk[m]what does the partition layout look like on these externally installed disks
04:12davidrysk[m](that'd be worth adding to the wiki)
04:12davidrysk[m](as would capturing the verbose boot log be, which would probably give away how it's copying stuff to recovery)
04:13rwhitbyM1 port, then C to A adapter, then A to C cable, to USBC SSD boots fine
04:13davidrysk[m]wonder if 11.1 fixed some of those bugs.
04:14rwhitby(of course that's not a flash stick, but means that it's not doing any USB-C/PD stuff, it's just all plain USB3.
04:14davidrysk[m]`sudo nvram boot-args=”-v”` (in recovery) to enable boot logging
04:14CamdenB[m] has joined #asahi
04:14Shizdavidrysk[m]: i think boot-args are ignored by default, btw
04:14* rwhitbyafk ~1h
04:15raster has quit [Quit: Gettin' stinky!]
04:15Shizso make sure to have done # bputil -a before
04:15Shiz(wasn't done yet :p)
04:15davidrysk[m]I'm EST so I'll have to get some sleep soon :/
04:33NecrosporusSomebody should dump nvram and post it on wiki I guess. nvram command should have some options to list all variables and values
04:34davidrysk[m]`nvram -p`, but note that some of the nvram contents includes wifi network details
04:34davidrysk[m]so you might want to redact that
04:35Necrosporus( I don't have any apple-made computers )
04:38aead has joined #asahi
04:47Shiznvram -p isn't too interesting
04:48Shiz:thinking:
04:58DarthCloud has quit [Remote host closed the connection]
04:58DarthCloud has joined #asahi
05:18Tokamak has quit [Ping timeout: 246 seconds]
05:29Tokamak has joined #asahi
05:31rwhitbyM1 doesn't like being told to boot from an external disk but then unplugging the external disk. Doesn't seem to default back to the internal disk automatically.
05:33ransom has quit [Quit: Textual IRC Client: www.textualapp.com]
05:34rwhitbydavidrysk[m] let me know if you want anything else recorded from that
05:34davidrysk[m]what's in the EFI?
05:34davidrysk[m]anything at all?
05:35davidrysk[m]those look like plain volumes that are set up in the same way intel mac bootable external volumes would be set up
05:37rwhitbydavidrysk[m] updated gist
05:37davidrysk[m]rwhitby: can you mount it as a FAT32 partition and recursively list the contents?
05:49rwhitbyyep, it's empty
05:50artemistIIRC Apple loves putting an ESP on every GPT thing, even if it's just a flash drive you don't intend to be bootable
05:51davidrysk[m]they use it for firmware updates and apparently a log of some sort, on pre-T1 Intel Macs
05:54Shizat least the internal drive has no ESP :p
05:54rwhitbyconfirmed - if you boot from an external drive, and then reboot without that drive attached, then you get into a boot loop that eventually results in a Recovery Assistant screen which says you have to reinstall and does not have the option to boot from the internal drive. you have to power cycle into 1TR to see the internal drive again and boot from it.
05:55Necrosporusrwhitby, thanks. Does EFI partition made by M1 have any files on it?
05:55Necrosporusis it fat32?
05:55Shizthat makes sense with my knowledge of how the boot process works so far
05:56NecrosporusAh, wait already answered
05:56aratuk has joined #asahi
05:57NecrosporusDo you know what are those volumes for? Like VM, and unlabeled disk9s2
05:58NecrosporusDo preboot and VM volumes have any files?
05:58ShizPreboot is used in the boot process and contains iBoot, the device tree and the kernel cache
05:59Shizalong with various other stuff
05:59NecrosporusSo, they are as files?
05:59Necrosporusdid anybody upload them?
05:59Shizprobably not? they're note very interesting
05:59Shizit's not much different than what is in the ipsw
05:59davidrysk[m]Necrosporus: you can extract them from an ipsw (also, -re)
06:00aratuk_ has quit [Ping timeout: 272 seconds]
06:00davidrysk[m]rwhitby: that sounds like a bug that should be filed with apple...
06:02rwhitbyso, next step is to try and add a partition to an external drive and see if it still boots from that drive?
06:02davidrysk[m]okay I really have to go
06:03rwhitbyactually, first would be to try to add an extra APFS volume rather than a partition
06:03Necrosporusdavidrysk[m], or to remove ESP
06:05rwhitby1TR still presents it as a boot option ...
06:06aratuk has quit [Remote host closed the connection]
06:06davidrysk[m]I would expect adding an APFS volume to not be a problem
06:06aratuk has joined #asahi
06:07rwhitbyyep, still boots
06:08marcanVM is the swap partition
06:09marcanNecrosporus: do not ask for file uploads, that is a copyright violation
06:09Shizi do wonder why VM is only 20kb for me
06:09marcandevicetrees and such are data-like enough to be probably okay, but we're not going to put iBoot executables on the internet
06:09Shizdo apfs subvolumes grow?
06:09marcanShiz: dynamically resizes
06:09marcanthey share space
06:09marcanthat's the point
06:10rwhitbyNow adding a FAT32 partition to the external disk while booted from that disk.
06:11marcanI wonder if I can install macos to an "external disk", then replace the kernel with mini, then just not plug in said disk. that should actually work, given what we know about how this works
06:11rwhitby(just using plain Disk Utility to do this, in the hope that it will keep everything blessed)
06:11marcanyeah let me try that
06:11aratuk has quit [Ping timeout: 264 seconds]
06:11marcanseems like the safest bet to mess with kernels
06:12marcanin principle doing that should result in the secondary install/kernel ending up in the internal storage anyway
06:13rwhitbyexternal disk booted with both Linux APFS volume and Linux FAT32 partition.
06:14rwhitby(not that I haven't disabled any security yet)
06:14rwhitbys/not/note/
06:20rwhitbymarcan https://gist.github.com/rwhitby/31527292d1b3dd9456e3604d32282967 at the end is the resulting partition map with a Linux APFS Volume and a Linux FAT32 Partition on a bootable external disk.
06:23rwhitbycan someone who knows add the commands to https://github.com/AsahiLinux/docs/wiki/SW:Getting-started to put the device back into the secure factory state? or is it a one-way modification?
06:24davidrysk[m]disabling the signed system volume is kinda a one way modification
06:24davidrysk[m]reinstalling macOS should restore that part
06:24davidrysk[m]the other things can be reverted
06:24davidrysk[m](without reinstall)
06:25davidrysk[m](signed system volume == authenticated-root)
06:25rwhitbyok, going to add the same volume and partition to the internal disk now and see if that still boots. if it doesn't, then I'll have an excuse to do a recovery :-)
06:25davidrysk[m]if you didn't mount it as read/write and edit the system volume, just re-enabling it might work
06:26davidrysk[m]rwhitby: also see if you can still access macOS Recovery
06:26rwhitbyIs it possible that the trick is simply to do the partitioning before disabling the security?
06:27davidrysk[m]and test the different combinations of [Apple_APFS_ISC] [Apple_APFS] [Apple_APFS_Recovery] [Linux], [Apple_APFS_ISC] [Apple_APFS] [Linux] [Apple_APFS_Recovery], and Apple_APFS_ISC] [Linux] [Apple_APFS_Recovery]
06:27davidrysk[m]I think OS firmware might be stored in [Apple_APFS] though :|
06:28rwhitbyoh, I'm just being a dumb end-user and using the Disk Utility GUI to add these things. I'm not placing the new partitions in specific places.
06:28davidrysk[m]which means testing with that partition in place, but with the large system and data volumes deleted and the partition itself shrunk, might be worth it
06:28davidrysk[m]disk utility is low on features but it does have better error handling
06:28davidrysk[m]anyway now I really need to go
06:28rwhitbyrestarting with new partition/volume on internal disk ...
06:31rwhitbyok, that's not looking as good as the external disk. boot loop city.
06:32rwhitbyso that's a clear macOS bug then. A user adds partitions using disk utility GUI and their device no longer boots as a result.
06:34rwhitbyhowever, going though 1TR allows it to boot again
06:35rwhitbybut a normal restart continues to result in a boot loop
06:42_whitelogger has joined #asahi
06:44rwhitbyyes, it was the other bug manifesting. there seems to be no issue with additional partition/volume on internal disk or external disk (note that security has not been disabled yet)
06:45marcanrwhitby: what exactly did you do on the internal disk to partition it?
06:45kkd has joined #asahi
06:45marcanwhen I split/added a partition (note: no actual macos install though) it broke 1TR
06:46marcanoh wait, you added a partition to the external disk you mean
06:47dstzdwhat is 1TR?
06:48rwhitbymarcan: I went into Disk Utility GUI, and first added an APFS volume, and then added a partition. All using the GUI only.
06:49rwhitbyI tested this both on external disk first, and now also on internal disk.
06:49marcanby adding a partition you mean selecting the main container, then clicking partition?
06:49rwhitbyYes, select Container disk3, click partition, say "yes, I do want partition, not volume", select the size and format type.
06:50marcanhuh, that's what broke it for me
06:50rwhitbythen wait as it resizes, after it warns you it can take a long time on a live filesystem (it didn't take more than 5 minutes)
06:50rwhitbyso the difference is that I have not yet removed security
06:50marcanmine actually failed at some point, but the resize worked, but I had chosen HFS+ and it decided to make it APFS anyway, then I reformatted it as HFS+, then rebooted, 1TR broken
06:50marcaneither that, or OS version
06:51rwhitbyI'm on 11.1, and I chose FAT32 to start, and have redone it with ExFAT just now.
06:52marcanoh lol, at some point an OSX update must've decided to remove my partitioning anyway. lovely.
06:52marcanwell, let's try that again
06:52marcanI made it FAT32
06:54rwhitbyI'm trying it again with a 128GB ExFAT
06:54rwhitby(half the disk)
07:02rwhitbyyep, no problem
07:06rwhitbymarcan: did it work for you?
07:09marcanwell it shows up as FAT32
07:10marcanyup, works now
07:10marcanwell okay then, either something went strangely wrong last time, or they fixed a bug
07:10marcanI might've been on 11.0.1 that time
07:10marcanvery good that this works then :)
07:10rwhitbyyes, very good.
07:11rwhitbyDoes it work from command line too? (for future scripting)
07:12marcanhaven't tried yet, but first I want to see how that apfs info looks
07:12marcanalso yay, raw disk access works (hadn't checked that yet)
07:12marcan(SIP coming back on after bputil *really* confused me)
07:13marcanlet's install some less-terrible tools with homebrew
07:21bear24rw has quit [Remote host closed the connection]
07:22bear24rw has joined #asahi
07:24marcanfunny, all the apple types here starts with ASCII, and so do iSC and recovery, *except* for APFS: https://en.wikipedia.org/wiki/GUID_Partition_Table
07:24marcanI wonder where 7C3457EF came from
07:26Shizsoftraid neither from the looks
07:27marcanthose look random
07:27marcanbut of the ones that end -11AA-AA11-00306543ECAC
07:31marcanI just realized that there is a Recovery volume in the macOS container. wat.
07:31marcanis that just garbage left over from the Intel macs?
07:31marcanor does it actually serve a purpose?
07:34Shizit seems to be a full env
07:34Shizwith iBoot and /usr/standalone/firmware/arm64eBaseSystem.dmg
07:36Shizmakes sense considering the difference between rOS and 1TF i've seen
07:36Shizrather, the distinction
07:36ShizrecoveryOS vs restoreOS vs 1TF...
07:39_alicearen’t big sur images universal anyways? so it’d make sense to have both the Intel and arm64 boot artifacts on disk
07:39Shizthere's no intel boot artifacts on my recovery partitions
07:39Shizand boot.efi is just an empty file
07:39marcanI wonder if you can *actually* boot it though
07:40_aliceiirc back in the day, you could take a universal OS X install from an Intel machine and go boot it on a PPC machine and vice versa
07:40Shizanother note: the APFS GPT partition that itself has multiple subvolumes is mounted too as /System/Volumes/xarts
07:41Shizwith a <uuid>.gl file in there that's unreadable
07:41Shizsome searching around says "Xart, used by iOS to manage OS access to secure user data;"
07:42Shizah, some more esarching around:
07:42Shizhttps://txt.shiz.me/NzA1MDk5NW.txt (cc marcan), from man diskutil
07:43_aliceafaik it’s used for apfs filevault, see the xartutil command
07:44ShizUUID: 00000000-0000-0000-0000-000000000000 ; Session seeds: 5 thonk
07:45Shiz_alice: apparently xartutil --erase-all also erases touchID data
07:45Shizso likely some SEP/T2 interaction
07:46Shiz>xartutil: ERROR: No supported link to the SEP Present yea
07:46marcanShiz: there are several subvolumes mounted
07:46marcan(from iSC)
07:46marcanthat is one of them
07:46marcanso things to keep in mind
07:47Shizxarts gets mounted from 1s2 though, that's not iSC
07:47Shizoh right, disk1 is synthesized
07:47ShizI off-by-oned myself :p
07:47marcan"effaceable storage": encrypted storage that is "quick-erasable" by nuking the keys
07:48marcanthey also do rollback protection, I believe there should be a secure EEPROM/element IC somewhere (could be in-package) that talks to the SEP
07:48marcanand the SEP has to store stuff too, so presumably that gets put somewhere
07:49marcanwe also don't *really* know for a fact that /dev/disk0 is really the whole storage, for all we know the SEP could have a partition behind the scenes at a lower level
07:51marcanShiz: but yeah this is looking like the SEP store, which presumably is actually proxied through the OS
07:51marcanI think this is a common scheme in android too, let the OS drive the eMMC and proxy e.g. baseband storage through
07:52marcanxartutil --list shows two "sessions"
07:52Shizi mean it makes sense, no need to add a bunch of storage to the SEP if you can just store it elsewhere encrypted :)
07:52Shizyeah, and the latter session is your Data volume
07:52marcantrying to read the .gl file gives operation not permitted :)
07:53Shizthrew me off that the synthesized disk1 didn't appear in diskutil, wonder what's up with that
07:54marcanit works in recovery
07:55marcanthey have some kind of BS to hide them in macOS
07:55marcanI'd really like to figure out how to disable that
07:56marcandiskutil list -plist does show everything (in plist form), ha
07:57ShizI just dumped the disk1 with dd and used hdiutil attach -imageKey CRawDiskImage -nomount, which also showed details :p
07:58marcangoing to grab lunch :)
07:58marcanalso I faked the header to that (I had already partitioned my disk), please sanity check that gdisk output
08:00JTLEnjoy lunch :)
08:06Shizthere was a small diff in free space in your GPT header, I replaced it with dumps from mine
08:06Shizas well as added the iSC info, and replaced the macOS info with mine (mostly small UUIDs and size diffrences, but eliminates the 256GB disclaimer)
08:07Shizon an unrelated note, glad someone else is using dokuwiki-style category:name titles
08:26bear24rw has quit [Remote host closed the connection]
08:26bear24rw has joined #asahi
08:32bear24rw has quit [Ping timeout: 260 seconds]
08:51Necrosporus_ has joined #asahi
08:51Necrosporus is now known as Guest90598
08:51Necrosporus_ is now known as Necrosporus
08:51Guest90598 has quit [Killed (card.freenode.net (Nickname regained by services))]
08:56bear24rw has joined #asahi
08:56jabashque has joined #asahi
09:02amw1 has joined #asahi
09:13Tokamak has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
09:14jaXvi has quit [Ping timeout: 246 seconds]
09:44bear24rw has quit [Remote host closed the connection]
09:44bear24rw has joined #asahi
09:49bear24rw has quit [Ping timeout: 265 seconds]
10:02amw1 has quit [Ping timeout: 246 seconds]
10:10maor26 has joined #asahi
10:56marcan changed the topic of #asahi to: Asahi Linux: porting Linux to Apple Silicon macs | General project discussion | Topics: #asahi-dev #asahi-re #asahi-gpu #asahi-offtopic | Keep things on topic | GitHub: https://alx.sh/g | Logs: https://alx.sh/l/asahi
10:59marcan changed the topic of #asahi to: Asahi Linux: porting Linux to Apple Silicon macs | General project discussion | GitHub: https://alx.sh/g | Wiki: https://alx.sh/w | Topics: #asahi-dev #asahi-re #asahi-gpu #asahi-offtopic | Keep things on topic | Logs: https://alx.sh/l/asahi
11:00j`eylook at you with your fancy short urls
11:01marcanI want to be able to throw https://alx.sh/w/Glossary and such at people quickly :)
11:01marcan(it's existing infra I had for mrcn.st, I just registered a domain and copypasta'd it; so far it's the only bit of AsahiLinux infra that's hosted on my personal infra, other than DNS, but I might figure some way to separate it later)
11:02marcanalso, eventually, the installer will probably be something like curl https://alx.sh | sh :p
11:06marcanalso, for your amusement, this is the backend: https://mrcn.st/p/4JYBD6Bh
11:06marcan(which means it can be kept in git!)
11:07j`eymakes sense, no point for a db for so few links :-)
11:07marcanI mean the filesystem already implements perfectly good b-trees and things like that
11:08marcansymlinks make for a perfectly fine key-value store
11:08marcan(even though ls gets angry at me and shows them bright red because it think symlinks should point to files, for some reason)
11:12mrasmusHuh. How does that check out on e.g. a windows system? That feels like something that could get munged by poor client assumptions, in some way.
11:12mrasmus(I'll be honest, have not worked extensively in the intersection of git and symlinks, heh.)
11:14marcanyeah, uh, I'm not sure what windows would do with that
11:14marcanapparently msysgit checks them out as text files?
11:16mrasmusBetter than trying to check them out as... what are they called in ntfs-land, junctions? Those map better to hard links iirc?
11:16marcanNTFS actually supports POSIX symlinks afaik
11:16mrasmusOh really? Huh! TIL.
11:16marcanwell, Windows NT has a UNIX subsystem so...
11:17mrasmusNo wait, I did know that. I was conflating when I had to work with junction crap for other reasons; my last gig actually involved mklink and the like.
11:20mrasmusLook, I try not to remember that gig. Got stuck as the build engineer for an eng org that didn't know Windows but was building entirely on a Windows stack. There's a lot of reasons I did not stick around. >.>
11:20mrasmusAnyway now I'm curious how other git clients handle the symlink thing, might have to hack around and find out at some point.
11:22konstater has joined #asahi
11:22raster has joined #asahi
11:31GrumbleTurtle has joined #asahi
12:05amw1 has joined #asahi
12:08aratuk has joined #asahi
12:12aratuk has quit [Ping timeout: 240 seconds]
12:38browzingdamn, missed the streaming annoucement for the 7th heh :(
12:41elkaps[m] has joined #asahi
12:50ronyrus[m] has joined #asahi
12:55marcanI don't announce work streams (at the moment)
12:57ohdii has joined #asahi
12:57ohdii has left #asahi [#asahi]
12:59rafaelmartins has quit [Quit: https://rgm.io/]
13:00rafaelmartins has joined #asahi
13:03marcanalso it seems diskutil in recovery no longer shows the iSC stuff? I could've sworn it used to, might be something else that changed
13:06frode_oxa has joined #asahi
13:07frode_oxa has quit [Client Quit]
13:07frode_oxa has joined #asahi
13:07frode_oxa has quit [Client Quit]
13:07frode0xa has joined #asahi
13:08frode0xa has quit [Client Quit]
13:08frode_oxa has joined #asahi
13:09frode_oxa has quit [Remote host closed the connection]
13:18amw1 has quit [Ping timeout: 256 seconds]
13:18jamadazi has joined #asahi
13:25marcanShiz: ok, so the UUID relationships actually matter, so I'm going to munge the info on that page to be consistent with my system :p
13:26ulaas has joined #asahi
13:29amw1 has joined #asahi
13:35davidrysk[m]diskutil in OS does show me the iSC stuff
13:35davidrysk[m]With all security still on
13:54amw1 has quit [Ping timeout: 256 seconds]
14:00aratuk has joined #asahi
14:00brinly has quit [Quit: Connection closed for inactivity]
14:05aratuk has quit [Ping timeout: 246 seconds]
14:18federico has joined #asahi
14:24davidrysk[m]The main recovery partition does have a hidden second volume called Update
14:24marcanin "diskutil list"?
14:25marcanlike /dev/disk1 and /dev/disk2?
14:41reispflanze[m] has joined #asahi
15:02marcanenjoy :)
15:03marcanso one takeaway from this is that iBoot2 (the OS loader) is packaged with macOS, and logically part of the "OS" install even though we can't touch it
15:04marcanthat means that if we want to "dual-boot" properly, we will need two partitions: an APFS container containing at least the Preboot stuff (and possibly other dummy volumes), where we copy over the Preboot part of a macOS install, and replace only the kernelcache
15:04marcanand then a proper linux partition
15:05marcanhopefully if we do it this way it will play nice with the macOS updater (and it also means it won't update our device firmwares for us, thus won't break our drivers when macOS gets updated)
15:05marcan(since each OS has a separate iBoot2/firmware blob set)
15:06marcanso the next thing to play around with is whether this is possible - whether I can manually copy over a macOS preboot layout and convince SFR to boot it
15:13davidrysk[m]I’ll paste my diskutil output in a bit
15:14davidrysk[m]then what loads the firmware for us?
15:14davidrysk[m]Or do we read it off recovery and load it from there?
15:14davidrysk[m]That would be one way to get around the firmware distribution problem
15:17raster has quit [Ping timeout: 240 seconds]
15:19GrumbleTurtle has quit [Quit: WeeChat 2.9]
15:25raster has joined #asahi
15:25czero64 has joined #asahi
15:30stemnic has quit [Quit: The Lounge - https://thelounge.chat]
15:31stemnic has joined #asahi
15:40stemnic has quit [Ping timeout: 256 seconds]
15:42TheJollyRoger has quit [Remote host closed the connection]
15:42davidrysk[m]ok right, diskutil only shows me the Apple_APFS_ISC partition (disk0s1), because the APFS container is unmounted, and the OS will not allow mounting it.
15:43davidrysk[m]However, I can use dd to create an image of it and then use hdiutil to mount that
15:43TheJollyRoger has joined #asahi
15:43davidrysk[m](with a bit of finagling -- I used `hdiutil attach -verbose -imagekey diskimage-class=CRawDiskImage -nomount -readonly imagename.img`
15:44davidrysk[m]The same is true with the Apple_APFS_Recovery partition, disk0s3
15:45davidrysk[m]the APFS volumes only get synthesized when the container is mounted
15:59czero64 has quit [Quit: Session terminated!]
16:01aratuk has joined #asahi
16:06aratuk has quit [Ping timeout: 272 seconds]
16:09marcaniBoot(2) loads the firmware
16:10marcanit is mounted
16:10marcandiskutil is just doing some stupid hiding thing
16:10marcandiskutil list -plist shows it
16:10davidrysk[m]hm yeah, then it is diskutil being silly
16:10marcanyou can get info for individual components
16:12jamadazi has quit [Ping timeout: 264 seconds]
16:13modwizcode has joined #asahi
16:16bear24rw has joined #asahi
16:20bear24rw has quit [Ping timeout: 265 seconds]
16:23marcanlol, I tried to do a mildly complex repartition with Disk Utility and of course it failed (after attempting to do it in a ridiculously inefficient way)
16:23marcanI should stop trying to use that UI, it's clearly terrible
16:24mah has joined #asahi
16:26davidrysk[m]the Disk Utility UI is terrible, and the CLI is clunky
16:26brentr123[m]i like how the windows partition manager is
16:26brentr123[m]in microsoft windows
16:36modwizcodeI don't, it gets annoyed if the disk isn't partitioned just right and refuses to work at all.
16:36davidrysk[m]UI wise it's fine, but I find it to be unstable and hang a lot
16:36jamadazi has joined #asahi
16:37davidrysk[m]it's also lacking knobs
16:37davidrysk[m]so I very often have to resort to using diskpart
16:37modwizcodeSometimes you just can't delete partitions that are on secondary disks even just because it's marked in such a way that windows thinks it should be protected. So you have to use diskpart which is way less safe
16:43mah has quit [Ping timeout: 246 seconds]
16:45mah has joined #asahi
16:51modwizcodemarcan: possibly slightly unrelated but do you have like an active copy of the codebase for mini that you start with somewhere? I assume the version you linked me from the SPMP isn't the most current
16:51marcanhttps://github.com/fail0verflow/mini should be pretty much up to date. it hasn't been touched in a looong time
16:52modwizcodeAh okay I figured you touched it since
16:52davidrysk[m]marcan: (you might know this already but) it's probably best to set it up as a new repo and not a fork on GitHub because forks lack some critical features
16:52j`eyit does?
16:52marcanmini? I wasn't planning on forking it, it's going to be mangled too much to be worth having history
16:53marcanbut what features are missing?
16:53davidrysk[m]for one, you cannot search the code of forks using the search box on the github website
16:53modwizcodeDid they change that?
16:53modwizcodeYou used to, I always get fork results and it was annoying
16:53jn__(not being able to search them is pretty terrible for the 30k linux kernel forks on github)
16:53davidrysk[m]I mean if you're searching for code within a specific repo
16:53j`ey"Sorry, forked repositories are not currently searchable.
16:53modwizcodeThat must be new
16:54modwizcodeBecause every time I tried to find strange code I'd get 30000x copies of the same forked repo
16:54j`eymodwizcode: searching *within* a repo
16:54modwizcodeI had it backwards for what wasn't working lol
17:03Bublik has joined #asahi
17:07ransom has joined #asahi
17:08Bublik has quit [Ping timeout: 264 seconds]
17:10mah has quit [Ping timeout: 256 seconds]
17:11jamadazi has quit [Ping timeout: 264 seconds]
17:15Shizmarcan: just whe ni had munged it to b econsistent with mine :D
17:17marcanhttps://mrcn.st/t/Screenshot_20210110_021701.png this is definitely going to work, right? :D
17:17ShizLinux macOS 11.2
17:17Shizmy favourite distro
17:18etamarcan: 🤔
17:18etaah yes, classic macos opaque error numbers
17:18Shizalso, diskutil cmdline is somewhat competent if you can get used to its weirdness
17:19marcanI like my 1TR facedancer hack
17:19davidrysk[m]marcan: it's probably trying to use the `bless` command
17:19marcanboot in recovery mode, `rec term rsh` then in another window `1trsh` and I get a nice shell with tty capabilities
17:20marcandavidrysk[m]: I already used `bless` and *that* worked :p
17:20marcanbut let's see if there are logs
17:20Shizoh nice, it works
17:20davidrysk[m]what invocation of bless?
17:20marcanI'm trying to see how much of osx I need to rip off (manually) to convince iBoot to launch
17:21marcanso far I copied the Preboot volume, /Library/CoreServices/, and /usr/standalone/, and did the bless and apfs preboot update stuff
17:21marcanand that got it to show up in the in-OS picker, but not the first stage boot picker
17:21marcanlet's see if there are logs
17:21marcaneventually we'll have to do this in our installer
17:21marcanbuild a "stub" macos volume with just iBoot and enough files to convince macOS that it's something that looks like an OS
17:22marcanand then we can dual-boot properly
17:22Shizwould be surprised if this works :p
17:22marcanwhy wouldn't it?
17:22marcanin principle it's like installing macOS to a separate partition, then just deleting most of macOS :p
17:22Shizi'm assuming there's some more weird sealing going on
17:23marcanthe root volume is sealed, but I *think* nothing should care about that pre-kernel
17:23marcaniBoot/etc, all that is sealed at the file level AIUI
17:23Shizalso what's interesting to me is that iBoot 2 seems encrypted
17:23davidrysk[m]Shiz: all the iBoot components on iOS are encrypted
17:23Bublik has joined #asahi
17:23davidrysk[m]and the only way to get the encryption keys is by exploiting iBoot
17:24Shiz:pensive:
17:24dffthis has probable been asked a million times, but does this involve a hack or will new gen macs allow an unsigned os to boot?
17:24dffprobably*
17:24Shizthere's a FAQ on the site :p
17:24dffwhen i read it all i saw was that it wasnt illegal
17:25dffnow how it worked
17:25dffi guess it's been updated
17:25marcanthat has been in the site all along
17:25marcanand the patreon
17:25marcanyou misread
17:25davidrysk[m]or one of the other pages
17:25etamarcan: can iBoot not just load an arbitrary macho file
17:25marcanalx.sh/nojb for future reference
17:26marcaneta: yes(ish)
17:26marcan(maybe soon)
17:26marcanbut that's iBoot2
17:26marcanobviously we could clobber an existing macOS install
17:26marcanbut what I'm trying to do is build a "fake" macOS install side by side, to avoid having to do that
17:27Shizdavidrysk[m]: bleh :(
17:27dffnice, does that open the door for other oses made for arm?
17:27dffoff topic perhaps sorry
17:28davidrysk[m]does bless --verbose provide any interesting output?
17:28dffi wish you good fortune on getting good trackpad integration. that has held me off linux on laptop since forever.
17:29Shizmarcan: think I'll set up a page to start documenting the standard boot chain, seem OK?
17:29Shizgoing off my notes so far from bputil/libbootpolicy
17:30davidrysk[m]Shiz: I think that's a good idea, referencing e.g. theiphonewiki and security research that has looked at the iOS bootchain when needed
17:30marcanShiz: sure
17:30davidrysk[m]dff: that's ... some ways down the road :)
17:30Shizj`ey: that's a comparison page, i think more about something like SW:Boot
17:31konstatera "fake" macOS: is ti on another disk, another APFS container or APFS volume?
17:32marcanoh, it wanted a Recovery volume
17:32marcangot further now
17:32marcananother APFS container
17:32marcan{Error Domain=OSPErrorDomain Code=104 "The given secure boot bundle doesn’t exist."
17:32marcanat least the logs are more useful
17:34lev[m]1 has joined #asahi
17:43bublik_ has joined #asahi
17:46marcanok, it really did want an APFS volume group
17:46marcangot further this time
17:46Bublik has quit [Ping timeout: 240 seconds]
17:48raster has quit [Remote host closed the connection]
17:48marcan2021-01-09 17:47:08.895765+0000 0x174e Default 0x0 418 0 storagekitd: (Bootability) [com.apple.mac.install:Bootability] BootPolicy: SEP command 18 (v2) returned 6: bpbc 1637, 0, 0, 0
17:48marcan2021-01-09 17:47:08.895800+0000 0x174e Default 0x0 418 0 storagekitd: (Bootability) [com.apple.mac.install:Bootability] BootPolicy: assert: bpe == 0 (/AppleInternal/BuildRoot/Library/Caches/com.apple.xbs/Sources/BootPolicy/BootPolicy-76.60.12/dylib/dylib.c:3050)
17:48marcanit actually got as far as talking to the mothership and getting an OK to boot this OS on this machine
17:48marcanbut now the SEP hates me :(
17:48ransom has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
17:50etawhy does it need to talk to the mothership?
17:50raster has joined #asahi
17:53davidrysk[m]it shouldn't need to talk to the mothership after you set the boot policy to permissive
17:54davidrysk[m]but that's specific to kmutil configure-boot which is not yet implemented
17:54marcanit still has to run personalization for iBoot etc
17:54j`ey'personalization'?
17:54marcan"are you allowed to boot this OS on this device"
17:54davidrysk[m]oh, this is for installing a new iBoot, rather than using the existing one to boot a third party kernel?
17:54davidrysk[m]think activation lock
17:54marcanit's how they implement anti-downgrade security and similar
17:55marcanotherwise you could just wipe a device and install any random vulnerable software and pwn it
17:55marcanso they stop signing old vulnerable versions after a while
17:55etamarcan: woah that's crazy
17:56etaI thought you could at least disable all of that a la android bootloader unlocking
17:56marcanno, apple opens the door later in the process
17:56marcanread up on iOS security
17:56etaI was gonna say that sounds like how iOS works
17:56marcanor rather, android security is kind of haphazard in this respect
17:56etaso sounds like it's pretty much copied
17:56marcantechnically both let you in at the kernel level
17:56marcanwell this *is* the iOS boot process
17:57marcanit's iBoot
17:57* etafeels stupid
17:57marcanyou can cache the tickets, fwiw
17:57marcanlike you can just cache the server response and such
17:58etais that the modern version of SHSH blobs
17:58marcanit's the same thing
17:58eta(which I last remember being a thing around iOS 4)
17:58etaI swear it's all apticket or something else now
17:58brentr123[m]for ios it is "shsh2"
17:58marcanbunch of apticket files lying around
17:59marcanmaybe you can't cache them now? not sure tbh
17:59svendidn't they at some point generate a random nonce during installation in the SEP(?) to prevent the ticket caching stuff?
17:59marcanyeah apparently they do that now
17:59Shizi think so yeah
17:59marcanbut I'm not sure where they store that nonce?
17:59davidrysk[m]they added anti-downgrade a few times
18:00marcanif it's in the SEP then yeah
18:00etathe aptickets were supposed to do that I swear
18:00etabut they fucked up
18:01davidrysk[m]eta: it's been patched since the newer chip models though right?
18:01etadavidrysk[m]: I would assume so
18:01mah has joined #asahi
18:01etathat's wild how you can't change your startup disk without internet though
18:03marcanI think you can, once it's already properly signed
18:03marcanfor your machine
18:03marcanbut in this case, since I just duct-taped this thing together, it's basically a new volume
18:03marcanI think once you do it once it no longer needs the internet to switch
18:04raster has quit [Quit: Gettin' stinky!]
18:08raster has joined #asahi
18:12davidrysk[m]marcan: ah damn, I totally missed that flag
18:12marcannot the UsePAM thing
18:12marcanthe master.passwd
18:12davidrysk[m]oh I got the master.passwd (and commented on it here) early on
18:12davidrysk[m]but I missed the UsePam=no
18:12marcanI must've missed the master.passwd thing...
18:12davidrysk[m]master.passwd is covered in the passwd(5) manpage
18:13marcanso now the problem is I have no host keys, and no ssh-keygen :D
18:13davidrysk[m]use ssh-keygen from a macOS volume, it works
18:13davidrysk[m]just note that anything you do will get reverted on reboot
18:14marcanthis is all going into a startup script
18:14marcananyway, I should sleep
18:14davidrysk[m]yes, you should :)
18:14davidrysk[m]this project is not good for my sleep patterns
18:14davidrysk[m]I end up stayingup way too late
18:14* etaentitled UTC noises
18:17alexx2[m] has joined #asahi
18:20mrgs has joined #asahi
18:24Shizwrote some prelminary stuff
18:24Shizmarcan: oh fuck, you didnt know the master.passwd file? yeah, that did work for me too :p
18:27jamadazi has joined #asahi
18:28marcansee this is why we called ourselves fail0verflow
18:28davidrysk[m]you didn't know about master.passwd, I didn't know about UsePAM=no
18:28marcan(I'm not even joking)
18:28Shizhahaha
18:35aead has joined #asahi
18:35aead has quit [Changing host]
18:37stormclad has joined #asahi
18:49stormclad has quit [Ping timeout: 256 seconds]
19:14flokk[m] has joined #asahi
19:24sib1234[m] has joined #asahi
19:30Finde has joined #asahi
19:32karthek has joined #asahi
19:34karthek has quit [Remote host closed the connection]
20:00bear24rw has joined #asahi
20:03aratuk has joined #asahi
20:07aratuk has quit [Ping timeout: 260 seconds]
20:07bear24rw has quit [Remote host closed the connection]
20:09TheJollyRoger has quit [Ping timeout: 240 seconds]
20:10TheJollyRoger has joined #asahi
20:14Shizreading an iboot pdf that says the SecureROM is "very small" at 150kb
20:14Shizthink we might have different opinions on 150kb code being small :p
20:23DarthCloud has quit [Read error: Connection reset by peer]
20:25DarthCloud has joined #asahi
20:27choozy has joined #asahi
20:28bitcoinr has joined #asahi
20:33Icewind[m] has joined #asahi
20:41klaus has joined #asahi
20:59ephe_meral has joined #asahi
21:19bitcoinr has quit [Ping timeout: 245 seconds]
21:37choozy has quit [Ping timeout: 260 seconds]
21:41aratuk has joined #asahi
21:47aratuk has quit [Ping timeout: 256 seconds]
22:03aratuk has joined #asahi
22:04stormclad has joined #asahi
22:07aratuk has quit [Ping timeout: 240 seconds]
22:09stormclad has quit [Ping timeout: 260 seconds]
22:10choozy has joined #asahi
22:23mah has quit [Quit: Lost terminal]
22:29jamadazi has quit [Ping timeout: 260 seconds]
22:49raster has quit [Quit: Gettin' stinky!]
23:22maor26 has quit [Ping timeout: 260 seconds]
23:29bear24rw has joined #asahi
23:33ephe_meral has quit [Ping timeout: 246 seconds]
23:34bear24rw has quit [Ping timeout: 240 seconds]
23:42federico has quit [Quit: WeeChat 2.8]
23:52raster has joined #asahi
…