Cafiine over Internet?

Discussion in 'Wii U - Hacking & Backup Loaders' started by Ray Koopa, Jun 6, 2016.

  1. Ray Koopa
    OP

    Ray Koopa Obviously a Koopaling

    Member
    320
    217
    Aug 18, 2015
    So let's say I want a buddy to play 300cc MK8 with me, but I don't fully trust him (he's not really technically talented but I still don't trust him), so I don't wanna give him the files.

    My idea was to make Cafiine capable of handling multiple clients, over the internet (with the server running on my side to which he then connects...).

    Has someone already done this? Doesn't it also need port forwarding on his side (or his router won't let him? Not the 100% network developer here).

    Otherwise I'd modify the Cafiine server to en- and decrypt files on the go (maybe in a single-file package). I give my buddy encrypted files (or that one package) then.
     
    Last edited by Ray Koopa, Jun 6, 2016
  2. SuperMarioDaBom

    SuperMarioDaBom Member

    Newcomer
    39
    10
    Jun 6, 2016
    United States
    Yes, actually - I've done it with my friends many times. Cafiine allows you to connect multiple clients natively. So, you would need to port-forward your router. You friend DOES NOT need to port-forward as you are hosting the file. Then, give your friend your public ip (find it here). They would use that ip in Cafiine on their Wii U. You use your computer's ip, which you have used previously when you have run Cafiine on your own.

    If anything is not clear or if you need help let me know. NOTE: When doing this, there can be large amounts of lag, as two consoles are connecting to one server on your computer.
     
    Ray Koopa likes this.
  3. Ray Koopa
    OP

    Ray Koopa Obviously a Koopaling

    Member
    320
    217
    Aug 18, 2015
    Amazing! I did not know it handles multiple clients already! Chaddy did a great job...!
     
  4. SuperMarioDaBom

    SuperMarioDaBom Member

    Newcomer
    39
    10
    Jun 6, 2016
    United States
    Glad I could help! :D
     
  5. Ray Koopa
    OP

    Ray Koopa Obviously a Koopaling

    Member
    320
    217
    Aug 18, 2015
    Oh, just one question, which specific ports to forward, just 7332?
     
  6. SuperMarioDaBom

    SuperMarioDaBom Member

    Newcomer
    39
    10
    Jun 6, 2016
    United States
    Just 7332, yeah.
     
  7. Ray Koopa
    OP

    Ray Koopa Obviously a Koopaling

    Member
    320
    217
    Aug 18, 2015
    I just tried it successfully. It's indeed a lil slower than expected. It feels like it's sending the files to me first so I can send them back in case I don't have modified versions?
    I don't know if the exploit could handle it (probably not, that's why), but just sending back "no, dont have" and then making the console use the original file would be better, wouldn't it?
    Or is it just always that slow? =3 *has to look into the code soon*
     
  8. NWPlayer123

    NWPlayer123 GBAtemp Addict

    Member
    2,629
    6,226
    Feb 17, 2012
    United States
    The Everfree Forest
    chadderz made TCPGecko use one port, 7331, and then Cafiine uses 7332, you'd port forward through your router and they should be able to connect to an external IP, instead of 192.168.X.X which is a local IP, it'd use the public external IP for your router (not giving an example cause that's what people use for DDoS), just Google "what's my IP"
    EDIT: huh, didn't know it always used 7332, I assumed it made a new port every client
     
    Last edited by NWPlayer123, Jun 7, 2016
  9. SuperMarioDaBom

    SuperMarioDaBom Member

    Newcomer
    39
    10
    Jun 6, 2016
    United States
    I think it goes like this:

    1) Wii U tries to load file
    2) Server checks to see if it has file
    3) If true, it sends the modified file from computer. If false, it uses original game disk files.

    You have to not only send large files over the internet to your wii u, but also send it to your friend's wii u. How fast the game runs depends on both of your internet speed, your computer speed, and the size of the file trying to be sent.

    This site can give you the ip - sometimes google gives you the IP6 instead, so I prefer this.

    And yes, it only uses port 7332 to my knowledge. That's what I port-forwarded and it worked fine.
     
    NWPlayer123 likes this.
  10. Ray Koopa
    OP

    Ray Koopa Obviously a Koopaling

    Member
    320
    217
    Aug 18, 2015
    yeah, that's how i thought it works too. however, just the_requests_ if i have a file (which i didn't) took longer for bigger files than small ones, so i was wondering what was going on.
     
  11. Touko White

    Touko White miqrojamie

    Member
    618
    1,261
    Jan 12, 2016
    United Kingdom
    England
    @AidanLumina done it but I forgot the link.
    Or something like that, I might be confused/
     
  12. Ray Koopa
    OP

    Ray Koopa Obviously a Koopaling

    Member
    320
    217
    Aug 18, 2015
    Well I had a look into the source and it's, as expected, of course not sending the files to me (except if I "-request" them with a flagging file, but that's logged too). Still wonder why it's so slow. Partly I'm not surprised since the code needs a lot of optimizations... (it's really trying to reverse a byte array byte by byte for big endian, which totally doesn't make sense, for example)...
     
  13. RafaLuigi

    RafaLuigi Advanced Member

    Newcomer
    86
    29
    Jun 19, 2015
    Mexico
    Mushroom City
    Also Play with me?
     
  14. Ray Koopa
    OP

    Ray Koopa Obviously a Koopaling

    Member
    320
    217
    Aug 18, 2015
    I just plan to share an encrypted and signed game data container file with some modded track tournament participants in MK8, timebombed so they can't dick around with them after the tournament ended (maybe I can even send bullshit to Cafiine to halt their Wii U some time after the data container expired; or just fake a file request to take forever >=D)

    (The participants have no clue about exploits and programming whatsoever, so that is safe enough. If they still think to dick around and removing the time bomb part, they get banned for using the mods online on their own. It's just that I don't want to share tools to people just like that; in case they turn out as script kiddies)
     
    Last edited by Ray Koopa, Jun 8, 2016
    SuperMarioDaBom likes this.
  15. SuperMarioDaBom

    SuperMarioDaBom Member

    Newcomer
    39
    10
    Jun 6, 2016
    United States
    lol :P or try and make it send an enormous file!! That you hex-edited to crash the console!

    If you are getting that much lag, try setting up the server on another computer. That might help a little bit. Then at least you don't have to give them the mods. :)
     
  16. Ray Koopa
    OP

    Ray Koopa Obviously a Koopaling

    Member
    320
    217
    Aug 18, 2015
    hmm, which other computer do you mean? it shouldn't be a problem with my home one since it's quite fast and connected to 10mbit/s upload, i think only a dedicated server would be better xD but i don't wanna host such stuffs on a dedicated one, unsure about how legal that is.

    so i just encrypt those mod files into one big package, which i then give to others for starting the server at their home with
     
  17. SuperMarioDaBom

    SuperMarioDaBom Member

    Newcomer
    39
    10
    Jun 6, 2016
    United States
    I meant if you happened to have another computer lying around where you live, that you could use that along with the computer you were already using.

    If you really think that giving them the files is the best thing to do, then go right on ahead and do it.
     
  18. SomeGamer

    SomeGamer Within Hyrule Castle

    Member
    5,729
    2,676
    Dec 19, 2014
    Hungary
    If you encrypt them, their computers will have to do on-the-fly decryption, won't they?
     
  19. Ray Koopa
    OP

    Ray Koopa Obviously a Koopaling

    Member
    320
    217
    Aug 18, 2015
    yeah, I'm not changing how the exploit works on the wii u. of course that kind of encryption is easily undone (especially since the source is public anyway). it's just an 'idiot safe' lazy encryption to not make it too easy for some script kiddies to abuse my mods online.
     
    SomeGamer likes this.
  20. Ray Koopa
    OP

    Ray Koopa Obviously a Koopaling

    Member
    320
    217
    Aug 18, 2015
    If you're interested, I fully implemented it now. Still working on the last tidbits (like dump mode and better log files), but you can compile and have a look here already: https://github.com/Syroot/CafiineServer
    I'll probably write more about it soon in a separate thread, if anyone is interested at all.
     
    SomeGamer likes this.