webMAN-MOD
webMAN-MOD copied to clipboard
ps3netsrv "invalid open64 call" when trying to write to server
When trying to move a file to the server from a PS3, seemingly any file (tried a screenshot, dumping a dvd and also moving an iso), I get this:
katt@main ~ » ps3netsrv test 38008 192.168.1.\*
ps3netsrv build 20220330 (mod by aldostools)
Path: test
Host IP #1: 192.168.1.2:38008
Waiting for client...
[0] Connection from 192.168.1.205
*** invalid open64 call: O_CREAT or O_TMPFILE without mode ***: terminated
[1] 685960 IOT instruction (core dumped) ps3netsrv test 38008 192.168.1.\*
backtrace:
[Switching to thread 1 (Thread 0x7ff56cfb6640 (LWP 685993))]
#0 0x00007ff56d44f34c in __pthread_kill_implementation () from /usr/lib/libc.so.6
(gdb) bt full
#0 0x00007ff56d44f34c in __pthread_kill_implementation () from /usr/lib/libc.so.6
No symbol table info available.
#1 0x00007ff56d4024b8 in raise () from /usr/lib/libc.so.6
No symbol table info available.
#2 0x00007ff56d3ec534 in abort () from /usr/lib/libc.so.6
No symbol table info available.
#3 0x00007ff56d443397 in __libc_message () from /usr/lib/libc.so.6
No symbol table info available.
#4 0x00007ff56d4e22fa in __fortify_fail () from /usr/lib/libc.so.6
No symbol table info available.
#5 0x00007ff56d4c200c in __open64_2 () from /usr/lib/libc.so.6
No symbol table info available.
#6 0x000055bf1d370d8b in open64 (__oflag=<optimized out>, __path=<optimized out>) at /usr/include/bits/fcntl2.h:57
No locals.
#7 0x000055bf1d3715b3 in File::open (this=0x7ff568000fd0, path=path@entry=0x7ff568000da0 "test/screenshot_2022_03_21_00_41_51.bmp", flags=flags@entry=577) at ../src/File.cpp:78
plen = <optimized out>
flen = <optimized out>
path_ps3iso_loc = <optimized out>
path_ext_loc = <optimized out>
key_fd = <optimized out>
key_path = <optimized out>
st = {file_size = 0, mtime = 0, ctime = 0, atime = 0, mode = 0}
sec0sec1 = '\000' <repeats 20 times>, "\001\000\000\000Ç7\035\277U\000\000\000\000\000\000\000\000\000\000\006\000\000\000\000\000\000\000\377\377\377\377\377\377\377\377\000\000\000\000\000\000\000\000\002", '\000' <repeats 31 times>, "ɇ7\035\277U", '\000' <repeats 66 times>, "\260Q\373l\365\177", '\000' <repeats 26 times>, " \000\000\000"...
k3k3yEnWatermark = "Encrypted 3K BLD"
k3k3yDecWatermark = "Dncrypted 3K BLD"
k3k3yEnWatermark = <optimized out>
k3k3yDecWatermark = <optimized out>
key = <optimized out>
key_d1 = <optimized out>
iv_d1 = <optimized out>
aes_d1 = <optimized out>
#8 0x000055bf1d373e84 in process_create_cmd (cmd=0x7ff56cfb5d70, client=0x55bf1d37b040 <clients>) at ../src/main.cpp:775
result = {create_result = 0}
fp_len = <optimized out>
filepath = 0x7ff568000da0 "test/screenshot_2022_03_21_00_41_51.bmp"
ret = <optimized out>
result = <optimized out>
fp_len = <optimized out>
filepath = <optimized out>
ret = <optimized out>
#9 client_thread (arg=0x55bf1d37b040 <clients>) at ../src/main.cpp:1616
cmd = {opcode = 10258, data = "\000#", '\000' <repeats 11 times>}
ret = <optimized out>
client = 0x55bf1d37b040 <clients>
#10 0x00007ff56d44d5c2 in start_thread () from /usr/lib/libc.so.6
No symbol table info available.
#11 0x00007ff56d4d2584 in clone () from /usr/lib/libc.so.6
No symbol table info available.
[Switching to thread 2 (Thread 0x7ff56d2b8740 (LWP 685960))]
#0 0x00007ff56d4d3f2f in accept () from /usr/lib/libc.so.6
(gdb) bt full
#0 0x00007ff56d4d3f2f in accept () from /usr/lib/libc.so.6
No symbol table info available.
#1 0x000055bf1d370367 in main (argc=<optimized out>, argv=<optimized out>) at ../src/main.cpp:1947
addr = {sin_family = 2, sin_port = 36349, sin_addr = {s_addr = 3439438016}, sin_zero = "\000\000\000\000\000\000\000"}
size = 16
cs = <optimized out>
i = <optimized out>
s = 3
port = <optimized out>
whitelist_start = 3232235776
whitelist_end = 3232236031
fs = {file_size = 640, mtime = 18446744073709551512, ctime = 0, atime = 140692077006178, mode = 0}
last_ip = "192.168.1.205\000\000"
conn_ip = "192.168.1.205\000\000"
Running ps3netsrv build 20220330 on Arch Linux.
How are you moving the file? From webMAN MOD, using multiMAN or a custom application?
webMAN does not have implemented copy to ps3netsrv. The mounted remote folder is created as /dev_bdvd on PS3. The file listing is generated by the Virtual ISO in ps3netsrv. That folder is read only and the files cannot be modified.
ps3netsrv allows writing to the server, but it requires an application that talk with ps3netsrv using its proprietary protocol.
I was using multiMAN for all these tasks.
Try using the ps3netsrv released by deank. My fork is supposed to be compatible with multiMAN. ps3netsrv-src-deank.7z ps3netsrv-src-cobra.7z
If it doesn't work with deank's or cobra versions if ps3netsrv, then it could be a bug in multiMAN.
Unfortunately neither of those can be compiled due to a a missing file:
katt@main Downloads/ps3netsrv-src-cobra » make
g++ -c -o main.o main.cpp
gcc -Wall -I. -std=gnu99 -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -static -c -o compat.o compat.c
g++ -c -o File.o File.cpp
g++ -c -o VIsoFile.o VIsoFile.cpp
gcc -Wall -I. -std=gnu99 -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -static -c -o scandir.o scandir.c
In file included from scandir.c:6:
dirent2.h:30:10: fatal error: io.h: No such file or directory
30 | #include <io.h>
| ^~~~~~
compilation terminated.
make: *** [<builtin>: scandir.o] Error 1
katt@main Downloads/ps3netsrv-src-deank » make
g++ -c -o main.o main.cpp
gcc -Wall -I. -std=gnu99 -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -static -c -o compat.o compat.c
g++ -c -o File.o File.cpp
g++ -c -o VIsoFile.o VIsoFile.cpp
gcc -Wall -I. -std=gnu99 -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -static -c -o scandir.o scandir.c
In file included from scandir.c:6:
dirent2.h:30:10: fatal error: io.h: No such file or directory
30 | #include <io.h>
| ^~~~~~
compilation terminated.
make: *** [<builtin>: scandir.o] Error 1
You need to change the OS in the first line of Makefile to linux.
OS = linux
Right, with that changed both of them work, though the files they create have weird permissions, but that might be expected.
Access: (1101/---x-----t) Uid: ( 1000/ katt) Gid: ( 1000/ katt)
Can always just chmod them later so it can be opened, but still seems odd.
I was able to copy files to the server with both -deank and -cobra
Thank you for your feedback. I will investigate.
@kattjevfel I have fixed the compatibility issue of ps3netsrv copying files from PS3 to PC with multiMAN in this commit 66c4df9b0e4bea433eaba1edaafa17d9e70a521c You can grab the updated build and source code from this ps3netsrv_20220421.zip
Doesn't seem to work for me with 20220421 unfortunately. If it's of relevance Arch Linux is on glibc 2.35, maybe your test system is using another version?
My PS3 is running Evilnat 4.88.2 with multiMAN 4.85
EDIT: I tried the pre-compiled executable which works, but I see it's compiled on Ubuntu 20.04 which seems to use glibc 2.31.
Yes, I compiled it on Windows using WSL2 with Ubuntu 20.04.4 LTS installed. I updated it before build ps3netsrv. It has Ubuntu GLIBC 2.31-0ubuntu9.7