diff --git a/screendump/Makefile b/screendump/Makefile
index fb39fb4..6868bd0 100644
--- a/screendump/Makefile
+++ b/screendump/Makefile
@@ -1,18 +1,22 @@
-TARGET = iphone:14.4:10.0
+DEBUG=0
+FINALPACKAGE=1
+
+THEOS_PACKAGE_SCHEME = rootless
+
+TARGET = iphone:14.5:14.5
+ARCHS = arm64
include $(THEOS)/makefiles/common.mk
TOOL_NAME = screendumpd
-export ARCHS = arm64
$(TOOL_NAME)_ARCHS = arm64
$(TOOL_NAME)_FILES = main.mm
$(TOOL_NAME)_FRAMEWORKS := IOSurface IOKit
$(TOOL_NAME)_PRIVATE_FRAMEWORKS := IOMobileFramebuffer IOSurface
-$(TOOL_NAME)_OBJCFLAGS += -Ivncbuild/include -Iinclude
-$(TOOL_NAME)_LDFLAGS += -Wl,-segalign,4000 -Lvncbuild/lib -lvncserver -lpng -llzo2 -ljpeg -lssl -lcrypto -lz
+$(TOOL_NAME)_OBJCFLAGS += -I./vncbuild/include -Iinclude
+$(TOOL_NAME)_LDFLAGS += -Wl,-segalign,4000 -L./vncbuild/lib -lvncserver -lpng -llzo2 -ljpeg -lssl -lcrypto -lz
$(TOOL_NAME)_CFLAGS = -w
$(TOOL_NAME)_CODESIGN_FLAGS = "-Sen.plist"
$(TOOL_NAME)_INSTALL_PATH = /usr/libexec
-
include $(THEOS_MAKE_PATH)/tool.mk
diff --git a/screendump/en.plist b/screendump/en.plist
old mode 100644
new mode 100755
index 11f2d09..75e0c50
--- a/screendump/en.plist
+++ b/screendump/en.plist
@@ -7,6 +7,7 @@
IOSurfaceAcceleratorClient
IOMobileFramebufferUserClient
IOSurfaceRootUserClient
+ IOHIDLibUserClient
platform-application
diff --git a/screendump/layout/DEBIAN/control b/screendump/layout/DEBIAN/control
index c8f0ca6..f97665b 100644
--- a/screendump/layout/DEBIAN/control
+++ b/screendump/layout/DEBIAN/control
@@ -1,12 +1,11 @@
-Package: com.julioverne.screendump13
-Name: screendump (iOS 13)
+Package: com.m1337.screendump15
+Name: screendump (iOS 15+)
Depends: mobilesubstrate, preferenceloader
-Conflicts: com.cosmosgenius.screendump
-Architecture: iphoneos-arm
-Description: VNC for ios
-Maintainer: Julio
-Author: julioverne, Sharat M R
-Section: Tweaks
-Version: 0.0.3e
+Conflicts: com.cosmosgenius.screendump, com.cosmosgenius.screendump13, com.julioverne.screendump13
+Architecture: iphoneos-arm64
+Description: VNC for iOS15+ (rootless/Ellekit)
+Maintainer: m1337
+Author: m1337
+Version: 0.0.5
Depiction: http://julioverne.github.io/description.html?id=com.julioverne.screendump13
Icon: file:///Library/PreferenceLoader/Preferences/screendump/ScreenDump@2x.png
diff --git a/screendump/layout/DEBIAN/postinst b/screendump/layout/DEBIAN/postinst
index afc870c..d43c6bc 100755
--- a/screendump/layout/DEBIAN/postinst
+++ b/screendump/layout/DEBIAN/postinst
@@ -1,6 +1,6 @@
#!/bin/sh
-launchctl unload /Library/LaunchDaemons/com.julioverne.screendumpd.plist
-launchctl load /Library/LaunchDaemons/com.julioverne.screendumpd.plist
+launchctl unload /var/jb/Library/LaunchDaemons/com.julioverne.screendumpd.plist
+launchctl load /var/jb/Library/LaunchDaemons/com.julioverne.screendumpd.plist
exit 0;
diff --git a/screendump/layout/DEBIAN/postrm b/screendump/layout/DEBIAN/postrm
index 6f70c14..1c64984 100755
--- a/screendump/layout/DEBIAN/postrm
+++ b/screendump/layout/DEBIAN/postrm
@@ -1,5 +1,5 @@
#!/bin/sh
-launchctl unload /Library/LaunchDaemons/com.julioverne.screendumpd.plist
+launchctl unload /var/jb/Library/LaunchDaemons/com.julioverne.screendumpd.plist
exit 0;
diff --git a/screendump/main.mm b/screendump/main.mm
old mode 100644
new mode 100755
index c39aec4..7ba76ec
--- a/screendump/main.mm
+++ b/screendump/main.mm
@@ -1,8 +1,10 @@
#include
#include
#include
+#include
+#include
-#define kSettingsPath @"//var/mobile/Library/Preferences/com.cosmosgenius.screendump.plist"
+#define kSettingsPath @"/var/mobile/Library/Preferences/com.cosmosgenius.screendump.plist"
static bool CCSisEnabled = true;
static NSString *CCSPassword = nil;
@@ -49,7 +51,7 @@ typedef mach_port_t io_service_t;
typedef kern_return_t IOReturn;
typedef IOReturn IOMobileFramebufferReturn;
typedef io_service_t IOMobileFramebufferService;
-extern "C" mach_port_t mach_task_self(void);
+// extern "C" mach_port_t mach_task_self(void);
extern "C" void IOSurfaceFlushProcessorCaches(IOSurfaceRef buffer);
extern "C" int IOSurfaceLock(IOSurfaceRef surface, uint32_t options, uint32_t *seed);
extern "C" int IOSurfaceUnlock(IOSurfaceRef surface, uint32_t options, uint32_t *seed);
@@ -58,8 +60,10 @@ extern "C" CFMutableDictionaryRef IOServiceMatching(const char *name);
extern "C" const mach_port_t kIOMasterPortDefault;
extern "C" io_service_t IOServiceGetMatchingService(mach_port_t masterPort, CFDictionaryRef matching);
extern "C" IOMobileFramebufferReturn IOMobileFramebufferGetLayerDefaultSurface(IOMobileFramebufferRef pointer, int surface, IOSurfaceRef *buffer);
+extern "C" IOMobileFramebufferReturn IOMobileFramebufferCopyLayerDisplayedSurface(IOMobileFramebufferRef pointer, int surface, IOSurfaceRef *buffer);
extern "C" IOMobileFramebufferReturn IOMobileFramebufferOpen(IOMobileFramebufferService service, mach_port_t owningTask, unsigned int type, IOMobileFramebufferRef *pointer);
extern "C" IOMobileFramebufferReturn IOMobileFramebufferGetMainDisplay(IOMobileFramebufferRef *pointer);
+extern "C" mach_port_t mach_task_self(void);
static IOSurfaceAcceleratorRef accelerator;
static IOSurfaceRef static_buffer;
@@ -101,7 +105,10 @@ static void VNCSetup()
IOSurfaceAcceleratorCreate(kCFAllocatorDefault, 0, &accelerator);
IOMobileFramebufferGetMainDisplay(&framebufferConnection);
+
IOMobileFramebufferGetLayerDefaultSurface(framebufferConnection, 0, &screenSurface);
+ if(screenSurface == NULL)
+ IOMobileFramebufferCopyLayerDisplayedSurface(framebufferConnection, 0, &screenSurface);
//CGSize size;
//IOMobileFramebufferGetDisplaySize(framebufferConnection, &size);
@@ -528,3 +535,17 @@ static void handleVNCKeyboard(rfbBool down, rfbKeySym key, rfbClientPtr client)
static void handleVNCPointer(int buttons, int x, int y, rfbClientPtr client) {
VNCPointer(buttons, x, y, client);
}
+
+// 기본 22:11:52.331940+0900 kernel Corpse released, count at 0
+// 기본 22:11:52.414493+0900 kernel IOMFB: default_fb_surface: No Default FB Surface found. Return error
+// 기본 22:11:52.414536+0900 kernel screendumpd[43722] Corpse allowed 1 of 5
+// 기본 22:11:52.606790+0900 kernel Corpse released, count at 0
+// 기본 22:11:52.682856+0900 kernel IOMFB: default_fb_surface: No Default FB Surface found. Return error
+// 기본 22:11:52.682905+0900 kernel screendumpd[43723] Corpse allowed 1 of 5
+// 기본 22:11:52.876255+0900 kernel Corpse released, count at 0
+// 기본 22:11:52.915524+0900 kernel IOMFB: default_fb_surface: No Default FB Surface found. Return error
+// 기본 22:11:52.915570+0900 kernel screendumpd[43724] Corpse allowed 1 of 5
+// 기본 22:11:53.105917+0900 kernel Corpse released, count at 0
+// 기본 22:11:53.277579+0900 kernel IOMFB: default_fb_surface: No Default FB Surface found. Return error
+// 기본 22:11:53.277657+0900 kernel screendumpd[43725] Corpse allowed 1 of 5
+// 기본 22:11:53.407555+0900 kernel IOMFB: default_fb_surface: No Default FB Surface found. Return error
diff --git a/screendumpLowFrame/.DS_Store b/screendumpLowFrame/.DS_Store
new file mode 100644
index 0000000..5008ddf
Binary files /dev/null and b/screendumpLowFrame/.DS_Store differ
diff --git a/screendumpLowFrame/Makefile b/screendumpLowFrame/Makefile
index 03a9096..730e81b 100644
--- a/screendumpLowFrame/Makefile
+++ b/screendumpLowFrame/Makefile
@@ -16,15 +16,24 @@ ARCHS = arm64
$(TOOL_NAME)_VALID_ARCHS = arm64
$(TOOL_NAME)_FRAMEWORKS := IOSurface IOKit
$(TOOL_NAME)_PRIVATE_FRAMEWORKS := IOMobileFramebuffer IOSurface
-$(TOOL_NAME)_OBJCFLAGS += -Ivncbuild/include -Iinclude
-$(TOOL_NAME)_LDFLAGS += -Wl,-segalign,4000 -Lvncbuild/lib -lvncserver -lpng -llzo2 -ljpeg -lssl -lcrypto -lz
+
+ifeq ($(THEOS_PACKAGE_SCHEME),rootless)
+ # Rootless
+ $(TOOL_NAME)_OBJCFLAGS += -I/mnt/d/codes/screendumpLowFrame/vncbuild/include -Iinclude
+ $(TOOL_NAME)_LDFLAGS += -Wl,-segalign,4000 -L/mnt/d/codes/screendumpLowFrame/vncbuild/lib -lvncserver -lpng -llzo2 -ljpeg -lssl -lcrypto -lz
+ $(TOOL_NAME)_INSTALL_PATH = /usr/libexec
+else
+ # Rootful settings
+ $(TOOL_NAME)_OBJCFLAGS += -Ivncbuild/include -Iinclude
+ $(TOOL_NAME)_LDFLAGS += -Wl,-segalign,4000 -Lvncbuild/lib -lvncserver -lpng -llzo2 -ljpeg -lssl -lcrypto -lz
+ $(TOOL_NAME)_INSTALL_PATH = /usr/libexec
+endif
+
$(TOOL_NAME)_CFLAGS = -w
$(TOOL_NAME)_CODESIGN_FLAGS = "-Sen.plist"
-$(TOOL_NAME)_INSTALL_PATH = /usr/libexec
include $(THEOS_MAKE_PATH)/tool.mk
-
SUBPROJECTS += hooks
include $(THEOS_MAKE_PATH)/aggregate.mk
@@ -38,4 +47,4 @@ else
after-screendumpd-stage::
$(ECHO_NOTHING) rm $(THEOS_STAGING_DIR)/Library/LaunchDaemons/com.julioverne.screendumpd.rootless.plist$(ECHO_END)
$(ECHO_NOTHING)$(FAKEROOT) chown root:wheel $(THEOS_STAGING_DIR)/Library/LaunchDaemons/com.julioverne.screendumpd.plist$(ECHO_END)
-endif
+endif
\ No newline at end of file
diff --git a/screendumpLowFrame/build_packages.sh b/screendumpLowFrame/build_packages.sh
deleted file mode 100755
index 4a99d82..0000000
--- a/screendumpLowFrame/build_packages.sh
+++ /dev/null
@@ -1,11 +0,0 @@
-#!/bin/bash
-
-echo "Building package for ROOTFUL Jailbreak"
-
-make clean
-make package FINALPACKAGE=1
-
-echo "Building package for ROOTLESS Jailbreak"
-
-make clean
-make package FINALPACKAGE=1 THEOS_PACKAGE_SCHEME=rootless
diff --git a/screendumpLowFrame/en.plist b/screendumpLowFrame/en.plist
old mode 100644
new mode 100755
diff --git a/screendumpLowFrame/hooks/Makefile b/screendumpLowFrame/hooks/Makefile
index 9c6a8a6..a579b36 100644
--- a/screendumpLowFrame/hooks/Makefile
+++ b/screendumpLowFrame/hooks/Makefile
@@ -2,17 +2,16 @@ TARGET = iphone:16.5:14.0
include $(THEOS)/makefiles/common.mk
-
TWEAK_NAME = screendumpbb
-$(TWEAK_NAME)_FILES = Tweak.xm
+$(TWEAK_NAME)_FILES = /mnt/d/codes/screendumpLowFrame/hooks/Tweak.xm
$(TWEAK_NAME)_FRAMEWORKS := IOSurface IOKit
$(TWEAK_NAME)_PRIVATE_FRAMEWORKS := IOMobileFramebuffer IOSurface
-ADDITIONAL_OBJCFLAGS += -I../vncbuild/include -Iinclude
+ADDITIONAL_OBJCFLAGS += -I/mnt/d/codes/screendumpLowFrame/vncbuild/include -Iinclude
ADDITIONAL_LDFLAGS += -Wl,-segalign,4000
ADDITIONAL_CFLAGS = -w
-export ARCHS = arm64
-$(TWEAK_NAME)_ARCHS = arm64
+export ARCHS = arm64 arm64e
+$(TWEAK_NAME)_ARCHS = arm64 arm64e
include $(THEOS_MAKE_PATH)/tweak.mk
diff --git a/screendumpLowFrame/hooks/Tweak.xm b/screendumpLowFrame/hooks/Tweak.xm
index 7705452..a05deb1 100644
--- a/screendumpLowFrame/hooks/Tweak.xm
+++ b/screendumpLowFrame/hooks/Tweak.xm
@@ -7,6 +7,8 @@
#undef NSLog
+#define kSettingsPath @"/var/mobile/Library/Preferences/com.cosmosgenius.screendump.plist"
+
extern "C" UIImage* _UICreateScreenUIImage();
static BOOL isEnabled;
diff --git a/screendumpLowFrame/layout/DEBIAN/control b/screendumpLowFrame/layout/DEBIAN/control
index b0f1774..c685adc 100644
--- a/screendumpLowFrame/layout/DEBIAN/control
+++ b/screendumpLowFrame/layout/DEBIAN/control
@@ -1,9 +1,9 @@
-Package: com.cosmosgenius.screendump13
+Package: com.m1337.screendump15
Name: screendump
-Depends: preferenceloader
+Depends: mobilesubstrate, preferenceloader
Architecture: iphoneos-arm
Description: VNC for ios
-Maintainer: Sharat M R
-Author: Sharat M R
+Maintainer: m1337
+Author: m1337
Section: Tweaks
-Version: 0.0.4
+Version: 0.0.5
\ No newline at end of file
diff --git a/screendumpLowFrame/layout/DEBIAN/prerm b/screendumpLowFrame/layout/DEBIAN/postrm
similarity index 91%
rename from screendumpLowFrame/layout/DEBIAN/prerm
rename to screendumpLowFrame/layout/DEBIAN/postrm
index 0866b01..48114bb 100755
--- a/screendumpLowFrame/layout/DEBIAN/prerm
+++ b/screendumpLowFrame/layout/DEBIAN/postrm
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
if [ -L "/var/jb" ]; then
launchctl unload /var/jb/Library/LaunchDaemons/com.julioverne.screendumpd.plist
diff --git a/screendumpLowFrame/main.mm b/screendumpLowFrame/main.mm
old mode 100644
new mode 100755
index 1252761..7f64ff8
--- a/screendumpLowFrame/main.mm
+++ b/screendumpLowFrame/main.mm
@@ -1,9 +1,9 @@
#include
#include
#include
-#import
-#import
-#import
+#import
+
+#define kSettingsPath @"/var/mobile/Library/Preferences/com.cosmosgenius.screendump.plist"
static bool CCSisEnabled = true;
static NSString *CCSPassword = nil;
diff --git a/screendumpLowFrame/vncbuild/include/rfb/rfbclient.h b/screendumpLowFrame/vncbuild/include/rfb/rfbclient.h
old mode 100644
new mode 100755
index f633954..c727add
--- a/screendumpLowFrame/vncbuild/include/rfb/rfbclient.h
+++ b/screendumpLowFrame/vncbuild/include/rfb/rfbclient.h
@@ -81,7 +81,7 @@
#define TUNNEL_PORT_OFFSET 5500
#define SERVER_PORT_OFFSET 5900
-#define DEFAULT_SSH_CMD "/usr/bin/ssh"
+#define DEFAULT_SSH_CMD "/var/jb/usr/bin/ssh"
#define DEFAULT_TUNNEL_CMD \
(DEFAULT_SSH_CMD " -f -L %L:localhost:%R %H sleep 20")
#define DEFAULT_VIA_CMD \