| View previous topic :: View next topic |
| Author |
Message |
penguinflyer5234 Penguin King

Joined: 01 Feb 2008 Age: 15 Posts: 1682 Location: Somewhere
|
Posted: Tue May 20, 2008 11:25 pm Post subject: Question about Module Unlocking and the File System |
|
|
It seems that module unlocking (or the quest system, whichever) seems to use the module's menu.txt. This raises a problem in Linux:
Right now in Linux, we can only read the modules unless we are root. To solve that, we can use:
1. Local installation, installs to ~/.local
2. No symlinks in ~/.egoboo. (will take lots of space, especially with multiple users on the same system)
3. Make all the modules writable to everyone.
4. Make all the modules writable in the 'games' group. (This is only in Debian/Ubuntu)
What should we do about this?
Also, I didn't know where to put this in so move this if necessary. _________________ Donna Noble has left the library. Donna Noble has been saved.
|
|
| Back to top |
|
 |
Zefz Lead Designer


Joined: 16 Sep 2007 Posts: 2305 Location: Norway
|
Posted: Wed May 21, 2008 3:44 pm Post subject: |
|
|
Solution 1 an 3 would be the best ones methinks. Is there any problem with Local installation?
And the unlock system using menu.txt might be unnecessary with the new quest system (Which uses quest.txt located in each of the players folder). _________________ http://egoboo.sourceforge.net
"The pen is mightier than the sword- IF it is sharpened, dipped in poison and thrown really really hard at your target. But seriously, you are better off with a sword." |
|
| Back to top |
|
 |
bgbirdsey Developer

Joined: 25 Sep 2007 Posts: 873 Location: Minnesota
|
Posted: Wed May 21, 2008 7:33 pm Post subject: |
|
|
Right now, the filesystem searches for a "save directory". This is not used at all right now. It should actually save these names into the logfile.txt.
If these files are not ~/user/... or ~/local/... we could correct this and then just write all the temp, import, and player files to this directory.
This should be done in windows, too, so that different profiles can have different characters. I'm not sure if we should store the files in "C:\Documents and Settings\...\Application Data\Egoboo" or in "C:\Documents and Settings\...\My Documents\Egoboo". Storing it in Application Data will make it "invisible" to novice users which is a decent way of keeping the cheating down  |
|
| Back to top |
|
 |
Zefz Lead Designer


Joined: 16 Sep 2007 Posts: 2305 Location: Norway
|
Posted: Wed May 21, 2008 8:50 pm Post subject: |
|
|
Yeah if we are worried about cheating
But cheating around with your player is the first step to learning Egoboo development.
Saving stuff in "C:\Documents and Settings\...\Application Data\Egoboo" will make unique save games for each Login User. _________________ http://egoboo.sourceforge.net
"The pen is mightier than the sword- IF it is sharpened, dipped in poison and thrown really really hard at your target. But seriously, you are better off with a sword." |
|
| Back to top |
|
 |
penguinflyer5234 Penguin King

Joined: 01 Feb 2008 Age: 15 Posts: 1682 Location: Somewhere
|
Posted: Wed May 21, 2008 9:45 pm Post subject: |
|
|
Local installation: One user gets that only.
I think that there should be a main folder for the things that come with Egoboo and a user folder for everything that the user adds.
The user can overwrite the modules that came with the game by putting it in their user folder. _________________ Donna Noble has left the library. Donna Noble has been saved.
|
|
| Back to top |
|
 |
bgbirdsey Developer

Joined: 25 Sep 2007 Posts: 873 Location: Minnesota
|
Posted: Wed May 21, 2008 11:11 pm Post subject: |
|
|
yes, that was what I was getting at. install all of the executables and egoboo data in a globally accessible directory and put all the save files and temp files in usr/local/egoboo, or something like that
Last edited by bgbirdsey on Wed May 21, 2008 11:15 pm; edited 1 time in total |
|
| Back to top |
|
 |
penguinflyer5234 Penguin King

Joined: 01 Feb 2008 Age: 15 Posts: 1682 Location: Somewhere
|
Posted: Mon May 26, 2008 6:30 pm Post subject: |
|
|
| egore911 on The Linux Game Tome wrote: | One thing egoboo really needs is a usable build system. I wrote an ebuild for egoboo recently and I needed to patch it heavily (see http://bugs.gentoo.org/show_bug.cgi?id=193403 if you are interested).
To get it into a usable state one needs:
* drop the startup script and correctly implement config loading (like: first look in ~/.egoboo/ and if that does not exist look in /usr/share/egoboo)
* think about replacing enet since it is no longer supported and has security issues
* switch to autotools? |
Do we really want to do this? _________________ Donna Noble has left the library. Donna Noble has been saved.
|
|
| Back to top |
|
 |
bgbirdsey Developer

Joined: 25 Sep 2007 Posts: 873 Location: Minnesota
|
Posted: Mon May 26, 2008 9:29 pm Post subject: |
|
|
If egore911 wants to contribute he is welcome here.
?"drop the startup script"? - is the current implementation on linux started with a *.sh script?
Using autoconfig might be OK if someone wants to maintain the autoconfig file.
However, I would like to see what "security issues" enet has and what he wants to replace it with. I have never seen any network game code that does anything more than using enet, SDL_net, and raw winsock reads and writes.
I had a look, and the lin_file.c does not implement any special directories. Windows is initializing directories called win32_tempPath, win32_importPath, win32_savePath, and win32_gamePath, with the obvious uses. Once some *nix person decides on how to look for files, we could implement some generic fs_* functions that use the correct directories for files. |
|
| Back to top |
|
 |
penguinflyer5234 Penguin King

Joined: 01 Feb 2008 Age: 15 Posts: 1682 Location: Somewhere
|
Posted: Mon May 26, 2008 9:32 pm Post subject: |
|
|
| bgbirdsey wrote: | ?"drop the startup script"? - is the current implementation on linux started with a *.sh script?
|
Yes, it is started with the egoboo.sh in the game subdirectory. _________________ Donna Noble has left the library. Donna Noble has been saved.
|
|
| Back to top |
|
 |
bgbirdsey Developer

Joined: 25 Sep 2007 Posts: 873 Location: Minnesota
|
Posted: Mon May 26, 2008 9:35 pm Post subject: |
|
|
ahhhh that makes some sense now.
What is that script doing? Setting up environment variables? |
|
| Back to top |
|
 |
penguinflyer5234 Penguin King

Joined: 01 Feb 2008 Age: 15 Posts: 1682 Location: Somewhere
|
Posted: Mon May 26, 2008 9:37 pm Post subject: |
|
|
Creating the ~/.egoboo folder and setting the folder up for egoboo, and then egoboo runs in that folder. (~/.egoboo) _________________ Donna Noble has left the library. Donna Noble has been saved.
|
|
| Back to top |
|
 |
penguinflyer5234 Penguin King

Joined: 01 Feb 2008 Age: 15 Posts: 1682 Location: Somewhere
|
Posted: Sun Jun 01, 2008 7:22 pm Post subject: |
|
|
| egore911 from the Linux Game Tome wrote: | | bgbirdsey wrote: | If egore911 wants to contribute he is welcome here.
?"drop the startup script"? - is the current implementation on linux started with a *.sh script? |
From what I understand: Yes. The script is used to copy over the config files from the /usr/share (which is not user writeable) to the home directory (which is user writeable). I think using a vfs (like physfs) could be used to simplify that. I'm not sure how good the common vfs are but from what I know physfs does a really good job. Also the API is rather simple.
| bgbirdsey wrote: |
Using autoconfig might be OK if someone wants to maintain the autoconfig file. |
Creating the auto-foo stuff isn't that hard. I recently used anjuta for this task very often. It really does a good job as long as you don't do "crazy stuff".
| bgbirdsey wrote: |
However, I would like to see what "security issues" enet has and what he wants to replace it with. I have never seen any network game code that does anything more than using enet, SDL_net, and raw winsock reads and writes. |
I asked google for "enet network library" and the second entry was http://securityvulns.com/Fnews887.html
| bgbirdsey wrote: |
I had a look, and the lin_file.c does not implement any special directories. Windows is initializing directories called win32_tempPath, win32_importPath, win32_savePath, and win32_gamePath, with the obvious uses. Once some *nix person decides on how to look for files, we could implement some generic fs_* functions that use the correct directories for files. |
As I said: use an existing vfs. No need to reinvent the wheel here.
| penguinflyer (me) from the Linux Game Tome wrote: |
If you want to help, go to the Egoboo forums like PurpleSquerkle said. |
I don't have much free time left and I can't really help out here. I'd really love to see egoboo evolve into a game I would play on a daily basis, but I can't help out right now, sorry. |
Guess I'll start learning API for PhysFS... _________________ Donna Noble has left the library. Donna Noble has been saved.
|
|
| Back to top |
|
 |
bgbirdsey Developer

Joined: 25 Sep 2007 Posts: 873 Location: Minnesota
|
Posted: Sun Jun 01, 2008 8:20 pm Post subject: |
|
|
This is not a "security flaw" in any classical sense. An attacker cannot use it to gain access to your system. An attacker cannot use it to damage any files.
At most, what will happen is that the ENet library will call abort() and terminate in a not polite way.
| Quote: | | As I said: use an existing vfs. No need to reinvent the wheel here. |
Looking at PhysFS, it may be a generic solution to some other problems in Egoboo. I implemented a directory searching algorithm already, but PhysFS might be better.
The only thing might be the license. We'll have to check it out. |
|
| Back to top |
|
 |
bgbirdsey Developer

Joined: 25 Sep 2007 Posts: 873 Location: Minnesota
|
Posted: Sun Jun 01, 2008 9:01 pm Post subject: |
|
|
| I took a look at the license. We basically just need to attribute the library to the guy and attribute zlib if we want to have zip file access. |
|
| Back to top |
|
 |
|