sickcodes / Docker-OSX

Run macOS VM in a Docker! Run near native OSX-KVM in Docker! X11 Forwarding! CI/CD for OS X Security Research! Docker mac Containers.
https://hub.docker.com/r/sickcodes/docker-osx
GNU General Public License v3.0
48.8k stars 2.72k forks source link

iMessage automatically logs out #544

Open acheong08 opened 2 years ago

acheong08 commented 2 years ago
Linux InsignificantV3 5.15.0-48-generic #54-Ubuntu SMP Fri Aug 26 13:26:29 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
:0
1
PRETTY_NAME="Ubuntu 22.04.1 LTS"
NAME="Ubuntu"
VERSION_CODENAME=jammy
UBUNTU_CODENAME=jammy
Filesystem      Size  Used Avail Use% Mounted on
/dev/nvme0n1p5  215G   85G  120G  42% /
QEMU emulator version 6.2.0 (Debian 1:6.2+dfsg-2ubuntu6.3)
Copyright (c) 2003-2021 Fabrice Bellard and the QEMU Project developers
libvirtd (libvirt) 8.0.0
               total        used        free      shared  buff/cache   available
Mem:            15Gi       2.0Gi       5.1Gi       689Mi       8.4Gi        12Gi
Swap:             0B          0B          0B
8
16
crw-rw----+ 1 root kvm 10, 232 Sep 28 14:29 /dev/kvm
total 16K
drwxrwxrwt  2 root    root    4.0K Sep 28 13:28 .
drwxrwxrwt 26 root    root     12K Sep 28 14:35 ..
srwxrwxr-x  1 acheong acheong    0 Sep 28 13:28 X0
srwxrwxr-x  1 acheong acheong    0 Sep 28 13:28 X1
srwxrwxr-x  1 gdm     gdm        0 Sep 28 13:28 X1024
srwxrwxr-x  1 gdm     gdm        0 Sep 28 13:28 X1025
root        3607  0.0  0.4 1810844 71616 ?       Ssl  13:28   0:02 /usr/bin/dockerd -H fd:// --containerd=/run/containerd/containerd.sock
acheong    25034  0.0  0.0  17868  2348 pts/2    S+   14:35   0:00 grep --color=auto --exclude-dir=.bzr --exclude-dir=CVS --exclude-dir=.git --exclude-dir=.hg --exclude-dir=.svn --exclude-dir=.idea --exclude-dir=.tox dockerd
kvm:x:109:
docker:x:999:acheong
libvirt:x:139:acheong
libvirt-qemu:x:64055:libvirt-qemu
libvirt-dnsmasq:x:140:

I am able to use all other i services but iMessage logs out a few seconds after I log in. No error messages show up.

acheong08 commented 2 years ago
 $ docker run -it \                                          
    --device /dev/kvm \
    -p 50922:10022 \
    -v /tmp/.X11-unix:/tmp/.X11-unix \
    -e "DISPLAY=${DISPLAY:-:0.0}" \
    -e GENERATE_UNIQUE=true \
    -e MASTER_PLIST_URL='https://raw.githubusercontent.com/sickcodes/osx-serial-generator/master/config-custom.plist' \
    sickcodes/docker-osx:monterey
ju-li commented 2 years ago

I experienced this before. What you need to do is generate specific serial numbers, keep logging in until an error message that says "You cannot sign into iMessage at this time ... contact Apple Support and provide the code below." shows up. Then follow the instructions here for contacting Apple Support (see section "Error Messages"): https://docs.bluebubbles.app/server/advanced/macos-virtualization/running-a-macos-vm/enabling-imessage-in-a-vm

And make sure you save those serial numbers so you don't have to contact Apple Support again