Hacking WBFUSE (WBFS for FUSE)

Cypherdias

Well-Known Member
Newcomer
Joined
Mar 31, 2009
Messages
60
Trophies
0
XP
49
Country
United States
Tried it out, but don't get it to mount my partition properly. This is what I get:

./wbfuse /dev/sdc1 testwbfs
Initializing WBFS Partition...
ERROR: Invalid WBFS partition.

./wbfuse /dev/sdc testwbfs
Initializing WBFS Partition...
hd num sector doesn't match: Success

Also tried it with sudo (just for the case), but that didn't help me either. The wbfs-tool as well as the Wii itself find the HDD without any problems:

wbfs -p /dev/sdc1 ls
using /dev/sdc
RM3P01 Metroid Prime 3: Corruption 4.09G
ROBPPL Obscure 2 3.58G
[...]

Any idea?
 

torito21

Member
OP
Newcomer
Joined
Aug 5, 2007
Messages
13
Trophies
0
XP
31
Country
Cypherdias said:
Tried it out, but don't get it to mount my partition properly. This is what I get:

./wbfuse /dev/sdc1 testwbfs
Initializing WBFS Partition...
ERROR: Invalid WBFS partition.
Any idea?

You need root privileges. Try "sudo adduser username disk", then reboot and mount it normally without sudo.
 

Venko

Well-Known Member
Member
Joined
Feb 16, 2007
Messages
159
Trophies
0
Location
England
XP
264
Country
Looks great. I'm a GNU/Linux user so I can take advantage of this. It's a real shame about the limitation concerning file sizes though, as madhutter says, it heavily decreases the number of games that can be stored using it.
 

torito21

Member
OP
Newcomer
Joined
Aug 5, 2007
Messages
13
Trophies
0
XP
31
Country
Version 0.7 released.

Changelog:
* Several bugs fixed.
* 64 bits support.

Includes the original wbfs app ported to 64 bits.

Download links on the first post.
 

djtaz

PM's Full - Wadder Me
Member
Joined
Sep 21, 2008
Messages
2,997
Trophies
0
Age
51
Website
Visit site
XP
101
Country
At least this can get the png images onto the drive - id like to see all PNG images stored next to the ISO so that the loaders can read the images from the drives instead of the SD cards - this is a start
 

proms

New Member
Newbie
Joined
Apr 11, 2009
Messages
4
Trophies
0
XP
30
Country
Taiwan
torito21 said:
Version 0.7 released.

Thank for your development. Now I can easy manage my wbfs. This program is very great. If this program can execute in window, I think it will be wonderful!!

I can't compile the version 0.7 in my linux (SLAMD64). I get some error message show as below:

Code:
gcc -Wall -W -Ilibwbfs -I. -DLARGE_FILES -D_FILE_OFFSET_BITS=64 -c wbfuse.c -o wbfuse.o 
wbfuse.c:235: warning: unused parameter 'data'
wbfuse.c:250: warning: unused parameter 'path'
wbfuse.c:309: warning: unused parameter 'offset'
wbfuse.c:309: warning: unused parameter 'fi'
wbfuse.c:335: warning: unused parameter 'fi'
wbfuse.c:360: warning: unused parameter 'mode'
wbfuse.c:360: warning: unused parameter 'dev'
wbfuse.c:400: warning: unused parameter 'fi'
wbfuse.c:428: warning: unused parameter 'fi'
wbfuse.c:497: warning: unused parameter 'path'
wbfuse.c:497: warning: unused parameter 'd'
wbfuse.c:497: warning: unused parameter 'fi'
wbfuse.c:505: warning: unused parameter 'fi'
wbfuse.c: In function 'main':
wbfuse.c:697: error: 'struct fuse_operations_compat2' has no member named 'readdir'
wbfuse.c:698: warning: assignment from incompatible pointer type
wbfuse.c:699: warning: assignment from incompatible pointer type
wbfuse.c:700: warning: assignment from incompatible pointer type
wbfuse.c:701: warning: assignment from incompatible pointer type
wbfuse.c:702: error: 'struct fuse_operations_compat2' has no member named 'destroy'
wbfuse.c:704: warning: assignment from incompatible pointer type
wbfuse.c:705: warning: assignment from incompatible pointer type
wbfuse.c:725: error: too many arguments to function 'fuse_main_compat2'
wbfuse.c:666: warning: unused variable 'usr_options'
wbfuse.c:665: warning: unused variable 'opt'
make: *** [wbfuse.o] Error 1

First I add "#define FUSE_USE_VERSION 26" into the "wbfuse.c". I will get other error message show as below:

CODEgcc -Wall -W -Ilibwbfs -I. -static wbfuse.o tools.o bn.o ec.o disc_usage_table.o libwbfs.o libwbfs_linux.o wiidisc.o rijndael.o -lcrypto -lfuse -lpthread -ldl -lrt -o wbfuse
/usr/lib64/gcc/x86_64-slamd64-linux/4.2.4/../../../../lib64/libfuse.a(fuse.o): In function `fuse_load_so_name':
/mnt/data/Download/Linux/myLinux/Base/file_system/fuse-2.7.4/lib/fuse.c:165: warning: Using 'dlopen' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
/usr/lib64/gcc/x86_64-slamd64-linux/4.2.4/../../../../lib64/libpthread.a(pthread_cond_timedwait.o): In function `pthread_cond_timedwait':
(.text+0xa7): undefined reference to `__vdso_clock_gettime'
collect2: ld returned 1 exit status
make: *** [wbfuse] Error 1

Second I remove "LDFLAGS = -static" in the makefile. Then I can compile it and execute it.

Could I remove "LDFLAGS = -static" in the makefile?
 

torito21

Member
OP
Newcomer
Joined
Aug 5, 2007
Messages
13
Trophies
0
XP
31
Country
proms said:
Second I remove "LDFLAGS = -static" in the makefile. Then I can compile it and execute it.

Could I remove "LDFLAGS = -static" in the makefile?

Your problem can be fixed changing #define FUSE_USE_VERSION 21 to #define FUSE_USE_VERSION 26 in /usr/include/fuse/fuse.h .
I don't know why fuse uses the old api by default. :S

But, don't worry, the dynamic compilation (-static flag removed) should work ok too.
 

proms

New Member
Newbie
Joined
Apr 11, 2009
Messages
4
Trophies
0
XP
30
Country
Taiwan
torito21 said:
Your problem can be fixed changing #define FUSE_USE_VERSION 21 to #define FUSE_USE_VERSION 26 in /usr/include/fuse/fuse.h .
I don't know why fuse uses the old api by default. :S

But, don't worry, the dynamic compilation (-static flag removed) should work ok too.

Thank for your reply!

When I don't give any parameter to wbfuse, I will get a error message.

Code:
bash-3.1# ./wbfuse
Initializing WBFS Partition...
????????? (segmentation fault)

Would you please change below source code in wbfuse.c?
CODEÂÂÂÂprintf("Initializing WBFS Partition...\n");
ÂÂÂÂint back = initFuseWbfs(argv[1]);
ÂÂÂÂif (back) {
ÂÂÂÂÂÂÂÂprintf("ERROR: Invalid WBFS partition.\n");
ÂÂÂÂÂÂÂÂreturn -1;
ÂÂÂÂ}
ÂÂÂÂprintf("OK\n");
ÂÂÂÂ/*ÂÂÂÂOptionsÂÂÂÂ */
ÂÂÂÂ
ÂÂÂÂif (argc
 

proms

New Member
Newbie
Joined
Apr 11, 2009
Messages
4
Trophies
0
XP
30
Country
Taiwan
When I terminate to copy a image, I will get some strange file in the target partition.

QUOTE said:
bash-3.1# ls -al
?? 4
drw-rw-rw- 2 root root 0 2006-12-08 08:00 .
drwxr-xr-x 16 root root 4096 2009-04-12 03:03 ..
-rw-rw-rw- 1 root root 524288000 2006-12-08 08:00 Let'sTAP [R2UJ8P].iso
-rw-rw-rw- 1 root root 2122317824 2006-12-08 08:00 SpongeBob06 [RQ4E78].iso
-rw-rw-rw- 1 root root 2122317824 2006-12-08 08:00 SpongeBob06 [RQ4E78].iso
-rw-rw-rw- 1 root root 2122317824 2006-12-08 08:00 SpongeBob06 [RQ4E78].iso
 

torito21

Member
OP
Newcomer
Joined
Aug 5, 2007
Messages
13
Trophies
0
XP
31
Country
Version 0.8 released.

Changelog:
* Minor bug fixes.
* Added an option to scrub images (-s option)
* Added an option to scrub previously written to the partition (rename to "scrub"(without quotes)).

Thanks for the bug reports.

About the mac port... I don't have a Mac xD
 

AllWiidUp

Well-Known Member
Newcomer
Joined
Dec 17, 2008
Messages
84
Trophies
0
XP
31
Country
Canada
torito21 said:
Version 0.8 released.

Changelog:
* Minor bug fixes.
* Added an option to scrub images (-s option)
* Added an option to scrub previously written to the partition (rename to "scrub"(without quotes)).

Thanks for the bug reports.

About the mac port... I don't have a Mac xD

Please add the delete corruption issue fix:

http://gbatemp.net/index.php?showtopic=147969&st=0
 

Dwaalspoor98

Well-Known Member
Member
Joined
May 28, 2003
Messages
217
Trophies
2
Age
43
Location
Earth
Website
Visit site
XP
1,648
Country
Netherlands
Thank you for the hard work and Linux support, this makes me happy
wink.gif
 

METZElmaennchen

New Member
Newbie
Joined
Apr 19, 2009
Messages
1
Trophies
0
XP
1
Country
Gambia, The
Hello!
Tried out your nice tool.
After setting the FUSE_USE_VERSION flag it compiled great on Jaunty 9.04
smile.gif

Just added a little udev rule and it gets mounted on the fly when I plugin the drive.

Thanks a lot !
 

derek.mf

Member
Newcomer
Joined
Apr 21, 2009
Messages
5
Trophies
0
XP
7
Country
France
Hi,

Firstly, thanks for your great work, it is very useful and so more intuitive than any "GUI" or command line tool (even if, as a Linux user, command line is not a problem
wink.gif
).

But (sorry, there is a "but"), I found a bug.

I explain you all I made and the context :

Distribution : Fedora Core 9.
WBFuse version used : "wbfuse_0_8_2b_i386"
Installation :
- All binaries are owned by root.
- I set the SUID on the binaries (root #> chmod u+s *)
-----------------------------------------------------------------------
Mount command used : ./wbfuse /dev/sdb1 $HOME/wbfs_part
Initializing WBFS Partition...
Number of files found: 2
OK
Image scrubbing enabled (all partitions).
Wii ISO found: Call of Duty (Wii) UK/FR [RVYP52].iso
Wii ISO found: Okami [ROWP08].iso
-----------------------------------------------------------------------

But when I make :

-----------------------------------------------------------------------
ls -l ~/wbfs_part
ls: ne peut accéder /home/me/wbfs_part/Call of Duty (Wii) UK/FR [RVYP52].iso: Aucun fichier ou dossier de ce type
total 0
-????????? ? ? ? ? ? Call of Duty (Wii) UK/FR [RVYP52].iso
-rw-rw-rw- 1 me me 4699979776 déc 8 2006 Okami [ROWP08].iso
-----------------------------------------------------------------------

The error message could be translated as :
ls: cannot access /home/me/wbfs_part/Call of Duty (Wii) UK/FR [RVYP52].iso: No such file or directory
The file does not appear in nautilus.

Is it due to the game name ?
I use my external hdd on my Wii with USB Loader v1.1 and this game is found and can be launched without problems.

I will try to have a look at your code but if you can try to fix this, would be great
wink.gif


One more time, thanks a lot for your work.

derek.mf
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • No one is chatting at the moment.
  • Quincy @ Quincy:
    Usually when such a big title leaks the Temp will be the first to report about it (going off of historical reports here, Pokemon SV being the latest one I can recall seeing pop up here)
  • K3Nv2 @ K3Nv2:
    I still like how a freaking mp3 file hacks webos all that security defeated by text yet again
  • BigOnYa @ BigOnYa:
    They have simulators for everything nowdays, cray cray. How about a sim that shows you playing the Switch.
  • K3Nv2 @ K3Nv2:
    That's called yuzu
    +1
  • BigOnYa @ BigOnYa:
    I want a 120hz 4k tv but crazy how more expensive the 120hz over the 60hz are. Or even more crazy is the price of 8k's.
  • K3Nv2 @ K3Nv2:
    No real point since movies are 30fps
  • BigOnYa @ BigOnYa:
    Not a big movie buff, more of a gamer tbh. And Series X is 120hz 8k ready, but yea only 120hz 4k games out right now, but thinking of in the future.
  • K3Nv2 @ K3Nv2:
    Mostly why you never see TV manufacturers going post 60hz
  • BigOnYa @ BigOnYa:
    I only watch tv when i goto bed, it puts me to sleep, and I have a nas drive filled w my fav shows so i can watch them in order, commercial free. I usually watch Married w Children, or South Park
  • K3Nv2 @ K3Nv2:
    Stremio ruined my need for nas
  • BigOnYa @ BigOnYa:
    I stream from Nas to firestick, one on every tv, and use Kodi. I'm happy w it, plays everything. (I pirate/torrent shows/movies on pc, and put on nas)
  • K3Nv2 @ K3Nv2:
    Kodi repost are still pretty popular
  • BigOnYa @ BigOnYa:
    What the hell is Kodi reposts? what do you mean, or "Wut?" -xdqwerty
  • K3Nv2 @ K3Nv2:
    Google them basically web crawlers to movie sites
  • BigOnYa @ BigOnYa:
    oh you mean the 3rd party apps on Kodi, yea i know what you mean, yea there are still a few cool ones, in fact watched the new planet of the apes movie other night w wifey thru one, was good pic surprisingly, not a cam
  • BigOnYa @ BigOnYa:
    Damn, only $2.06 and free shipping. Gotta cost more for them to ship than $2.06
    +1
  • BigOnYa @ BigOnYa:
    I got my Dad a firestick for Xmas and showed him those 3rd party sites on Kodi, he loves it, all he watches anymore. He said he has got 3 letters from AT&T already about pirating, but he says f them, let them shut my internet off (He wants out of his AT&T contract anyways)
  • K3Nv2 @ K3Nv2:
    That's where stremio comes to play never got a letter about it
  • BigOnYa @ BigOnYa:
    I just use a VPN, even give him my login and password so can use it also, and he refuses, he's funny.
  • BigOnYa @ BigOnYa:
    I had to find and get him an old style flip phone even without text, cause thats what he wanted. No text, no internet, only phone calls. Old, old school.
  • Psionic Roshambo @ Psionic Roshambo:
    @BigOnYa, Lol I bought a new USB card reader thing on AliExpress last month for I think like 87 cents. Free shipping from China... It arrived it works and honestly I don't understand how it was so cheap.
    +1
    Psionic Roshambo @ Psionic Roshambo: @BigOnYa, Lol I bought a new USB card reader thing on AliExpress last month for I think like 87... +1