[ previous ] [ next ] [ threads ]
 From:  sai <sonicsai at gmail dot com>
 To:  MAALVAREZ at telefonica dot net
 Cc:  m0n0wall at lists dot m0n0 dot ch
 Subject:  Re: Writing a file CF Card
 Date:  Sat, 16 Jul 2005 10:09:10 +0500
You have to hack the executable image of m0n0  see
or the manual.


On 7/14/05, MAALVAREZ at telefonica dot net <maalvarez at telefonica dot net> wrote:
> Hi,I recently added a little hack to m0n0wall so I could upload and store
> locally a picture image in M0n0wall.
> Obviously it had to be written into the CF card but I can?t make it
> work.This is the code:
> /* mount flash_card to read and write */function cf_mount_rw() {    global
> $g;
>     mwexec("/sbin/umount -f {$g['cf_path']}");    mwexec("/sbin/mount -w -o
> noatime {$g['cf_path']}");}
> function cf_mount_ro() {    global $g;        mwexec("/sbin/umount -f
> {$g['cf_path']}");    mwexec("/sbin/mount -r {$g['cf_path']}");}
> function logo_install($logofile,$path) {    global $g;
>     cf_mount_rw();       copy($logofile,"{$g['www_path']}/$path");      
> cf_mount_ro();
>     return 0;}  
> Is there anything wrong? everytime I reboot m0n0 in my wrap box the logo
> file dissapears..
> Thank you!  File input Error for file:
> /internet/programas/tps/webapps/cp/WEB-INF/etc/blank.html