Board index FlightGear Support

**Solved** UFO export denied!!! since 1.9.1

All general support: help on flying, installation, hardware, getting online etc. There are lots of users and developers to help you out.
Forum rules
In order to help you, we need to know a lot of information. Make sure to include answers to at least the following questions in your initial post.

- what OS (Windows Xp/Vista, Mac etc.) are you running?
- what FlightGear version do you use?
- what graphics card do you have?
- does the problem occur with any aircraft, at any airport?
- where did you download your aircraft/scenery from?
- is there any output printed to the console (black window)?
- copy&paste your commandline (tick the "Show commandline box on the last page of FGRun or the "Others" section on the Mac launcher).

Please report any bugs not specific to an aircraft on the issue tracker.
To run FlightGear on old computers with bad OpenGL support, please take a look at this wiki article.

Note: If you did not get a reponse, even after 7 days, you may want to check out the FlightGear mailing lists to ask your question there.

**Solved** UFO export denied!!! since 1.9.1

Postby MaverickAlex » Fri Mar 06, 2009 8:09 pm

I have been having this problem since downloading 1.9.1.
Whenever i go to export from the UFO i get the following message.

Image

it appears to export to the ufo-export.xml but doesn't appear whatsoever.
I see there is an unauthorised access message but i havent changed anything and it isnt as though windows is stopping anything.
Its a pain having to input all the details by hand.

Any clues anyone?
running windows xp
Last edited by MaverickAlex on Sat Mar 07, 2009 12:55 am, edited 1 time in total.
http://www.atlasvirtualairlines.com
Modeller of: TNCM TBPB MDPP TFFF TJSJ FMEE TKPK TFFG TQPF KLAX KATL EGNJ EGGW APACHE, EUROFIGHTER, HP VICTOR, DHC8
FGcom 122.75
creator Terragear GUI
User avatar
MaverickAlex
 
Posts: 1204
Joined: Sun Mar 23, 2008 5:46 pm
Location: Kingston Upon Hull. UK

Re: UFO export denied!!! since 1.9.1

Postby gooneybird » Fri Mar 06, 2009 8:19 pm

Why don't you just copy from that window and paste into a text editor, that's what I do, it's much clearer than the export file.
My Github repository (mostly AI stuff) https://github.com/gooneybird47
User avatar
gooneybird
 
Posts: 3046
Joined: Sat May 31, 2008 2:57 pm

Re: UFO export denied!!! since 1.9.1

Postby MaverickAlex » Fri Mar 06, 2009 8:20 pm

i've tried, but i cant copy from the command window with right click?

and FG pays no attention whatsoever to roll or pitch inputs when placing objects.
Last edited by MaverickAlex on Fri Mar 06, 2009 8:24 pm, edited 1 time in total.
http://www.atlasvirtualairlines.com
Modeller of: TNCM TBPB MDPP TFFF TJSJ FMEE TKPK TFFG TQPF KLAX KATL EGNJ EGGW APACHE, EUROFIGHTER, HP VICTOR, DHC8
FGcom 122.75
creator Terragear GUI
User avatar
MaverickAlex
 
Posts: 1204
Joined: Sun Mar 23, 2008 5:46 pm
Location: Kingston Upon Hull. UK

Re: UFO export denied!!! since 1.9.1

Postby gooneybird » Fri Mar 06, 2009 8:23 pm

Select what you want to copy, click on the little black C:\ in the top left corner, edit, copy.
My Github repository (mostly AI stuff) https://github.com/gooneybird47
User avatar
gooneybird
 
Posts: 3046
Joined: Sat May 31, 2008 2:57 pm

Re: UFO export denied!!! since 1.9.1

Postby MaverickAlex » Fri Mar 06, 2009 8:26 pm

Got it,!!!

thanks Brett

But still doesnt answer the question regarding unauthorised access.
http://www.atlasvirtualairlines.com
Modeller of: TNCM TBPB MDPP TFFF TJSJ FMEE TKPK TFFG TQPF KLAX KATL EGNJ EGGW APACHE, EUROFIGHTER, HP VICTOR, DHC8
FGcom 122.75
creator Terragear GUI
User avatar
MaverickAlex
 
Posts: 1204
Joined: Sun Mar 23, 2008 5:46 pm
Location: Kingston Upon Hull. UK

Re: UFO export denied!!! since 1.9.1

Postby gooneybird » Fri Mar 06, 2009 8:31 pm

No sweat mate.

MaverickAlex wrote:But still doesnt answer the question regarding unauthorised access.


That I don't get, because you must have access rights to save FGRUN data etc.
I'll try it on mine later.
My Github repository (mostly AI stuff) https://github.com/gooneybird47
User avatar
gooneybird
 
Posts: 3046
Joined: Sat May 31, 2008 2:57 pm

Re: UFO export denied!!! since 1.9.1

Postby AndersG » Fri Mar 06, 2009 8:47 pm

MaverickAlex wrote:But still doesnt answer the question regarding unauthorised access.


You probably need to modify Nasal/IOrules to allow writing to that file or in that directory.

/Anders
Callsign: SE-AG
Aircraft (uhm...): Submarine Scout, Zeppelin NT, ZF Navy free balloon, Nordstern, Hindenburg, Short Empire flying-boat, ZNP-K, North Sea class, MTB T21 class, U.S.S. Monitor, MFI-9B, Type UB I submarine, Gokstad ship, Renault FT.
AndersG
 
Posts: 2527
Joined: Wed Nov 29, 2006 10:20 am
Location: Göteborg, Sweden
Callsign: SE-AG
OS: Debian GNU Linux

Re: UFO export denied!!! since 1.9.1

Postby MaverickAlex » Fri Mar 06, 2009 9:03 pm

i'm assuming it this part here, but i don't know what to change?

Code: Select all
 # validators
    var valid = func(path, rules) {
        var fpath = normpath(path);
        foreach (var d; rules)
            if (match(fpath, d[0]))
                return d[1] ? fpath : nil;
        return nil;
    }

    var read_validator = func(n) setValue(n, [valid(getValue(n, []), read_rules) or ""]);
    var write_validator = func(n) setValue(n, [valid(getValue(n, []), write_rules) or ""]);

    # validation listeners for load[xml]/save[xml]/parsexml()  (see utils.cxx:fgValidatePath)
    var n = props.globals.getNode("/sim/paths/validate", 1).remove();
    var rval = _setlistener(n.getNode("read", 1)._g, read_validator);
    var wval = _setlistener(n.getNode("write", 1)._g, write_validator);

 # wrap removelistener
    globals.removelistener = var remove_listener = (func {
        var _removelistener = globals.removelistener;
        func(n) {
            if (n != rval and n != wval)
                return _removelistener(n);

            die("removelistener(): removal of protected listener #'" ~ n ~ "' denied (unauthorized access)\n ");
        }
    })();
   

    # wrap io.open()
    io.open = var io_open = (func {
        var _open = io.open;
        func(path, mode = "rb") {
            var rules = write_rules;
            if (mode == "r" or mode == "rb" or mode == "br")
                rules = read_rules;

            if (var vpath = valid(path, rules))
                return _open(vpath, mode);

            die("io.open(): opening file '" ~ path ~ "' denied (unauthorized access)\n ");
        }
    })();

    # wrap closure() to prevent tampering with security related functions
    var thislistener = caller(0)[1];
    globals.closure = (func {
        var _closure = globals.closure;
        func(fn, level = 0) {
            var thisfunction = caller(0)[1];
            if (fn != thislistener and fn != io_open and fn != thisfunction
                    and fn != read_validator and fn != write_validator
                    and fn != remove_listener)
                return _closure(fn, level);

            die("closure(): query denied (unauthorized access)\n ");
        }
    })();
});


I never had a problem with previous versions
http://www.atlasvirtualairlines.com
Modeller of: TNCM TBPB MDPP TFFF TJSJ FMEE TKPK TFFG TQPF KLAX KATL EGNJ EGGW APACHE, EUROFIGHTER, HP VICTOR, DHC8
FGcom 122.75
creator Terragear GUI
User avatar
MaverickAlex
 
Posts: 1204
Joined: Sun Mar 23, 2008 5:46 pm
Location: Kingston Upon Hull. UK

Re: UFO export denied!!! since 1.9.1

Postby gooneybird » Fri Mar 06, 2009 9:13 pm

I have just tried it, but found i cannot place any objects at all, keep getting:

Nasal runtime error: non-objects have no members
at C:/Program Files/FlightGear109/data/Aircraft/ufo/cam.nas, line 308
called from: C:/Program Files/FlightGear109/data/Nasal/globals.nas, line 96

or

Nasal runtime error: undefined symbol: modellist
at C:/Program Files/FlightGear109/data/Aircraft/ufo/ufo.nas, line 836
called from: C:/Program Files/FlightGear109/data/Nasal/globals.nas, line 96

sometimes with different ufo.nas line numbers, tried the ufo from cvs with the same result
My Github repository (mostly AI stuff) https://github.com/gooneybird47
User avatar
gooneybird
 
Posts: 3046
Joined: Sat May 31, 2008 2:57 pm

Re: UFO export denied!!! since 1.9.1

Postby MaverickAlex » Fri Mar 06, 2009 9:22 pm

oh my!!!

Down Tools......

Lets have the union in..
http://www.atlasvirtualairlines.com
Modeller of: TNCM TBPB MDPP TFFF TJSJ FMEE TKPK TFFG TQPF KLAX KATL EGNJ EGGW APACHE, EUROFIGHTER, HP VICTOR, DHC8
FGcom 122.75
creator Terragear GUI
User avatar
MaverickAlex
 
Posts: 1204
Joined: Sun Mar 23, 2008 5:46 pm
Location: Kingston Upon Hull. UK

Re: UFO export denied!!! since 1.9.1

Postby gooneybird » Fri Mar 06, 2009 9:24 pm

You can never trust these alien workers :lol:
My Github repository (mostly AI stuff) https://github.com/gooneybird47
User avatar
gooneybird
 
Posts: 3046
Joined: Sat May 31, 2008 2:57 pm

Re: UFO export denied!!! since 1.9.1

Postby AndersG » Fri Mar 06, 2009 9:35 pm

MaverickAlex wrote:i'm assuming it this part here, but i don't know what to change?
I never had a problem with previous versions


No, that looks like a Nasal file. IOrules is a much simpler file. Here is the contents of mine (only one line different from the default):
Code: Select all
# This file defines which file paths can be opened for reading and/or
# writing using Nasal's io.open() and parsexml() functions, as well as
# the fgcommands load, save, loadxml, and savexml. The evaluation code
# can be found in $FG_ROOT/Nasal/io.nas.
#
# Empty lines and lines starting with '#' are ignored. All other entries
# must be of the form
#
#   {READ|WRITE} {ALLOW|DENY} <path-pattern>
#
# whereby fields must be separated by exactly one space. The pattern must
# not be quoted and may contain spaces. If a pattern starts with $FG_ROOT/
# or $FG_HOME/, then these parts are replaced by the respective system
# paths. See $FG_ROOT/Nasal/string.nas for the pattern syntax.
#
# Entries are considered from top down. If no entry matches, then file
# access is denied. A local rules file $FG_HOME/Nasal/IOrules using the
# same syntax takes precedence over this file. The default rules that
# apply if there's no Nasal/IOrules file at all, or there are no rules
# defined in it are equivalent to this:
#
#   READ DENY *
#   WRITE DENY *
#
# Read and write access to Nasal/IOrules files, however, is *always*
# prohibited and not configurable!

READ ALLOW $FG_ROOT/*
READ ALLOW $FG_HOME/*

WRITE ALLOW $FG_HOME/*.sav
WRITE ALLOW $FG_HOME/*.log
WRITE ALLOW $FG_HOME/Export/*
WRITE ALLOW $FG_HOME/*/*.xml
WRITE ALLOW $FG_HOME/state/*.xml
WRITE ALLOW $FG_HOME/aircraft-data/*.xml


/Anders
Callsign: SE-AG
Aircraft (uhm...): Submarine Scout, Zeppelin NT, ZF Navy free balloon, Nordstern, Hindenburg, Short Empire flying-boat, ZNP-K, North Sea class, MTB T21 class, U.S.S. Monitor, MFI-9B, Type UB I submarine, Gokstad ship, Renault FT.
AndersG
 
Posts: 2527
Joined: Wed Nov 29, 2006 10:20 am
Location: Göteborg, Sweden
Callsign: SE-AG
OS: Debian GNU Linux

Re: UFO export denied!!! since 1.9.1

Postby MaverickAlex » Fri Mar 06, 2009 10:34 pm

i changed mine to match your Anders and it still doesn't work. I guess i'll just do it by copying the command lines instead of using export.
http://www.atlasvirtualairlines.com
Modeller of: TNCM TBPB MDPP TFFF TJSJ FMEE TKPK TFFG TQPF KLAX KATL EGNJ EGGW APACHE, EUROFIGHTER, HP VICTOR, DHC8
FGcom 122.75
creator Terragear GUI
User avatar
MaverickAlex
 
Posts: 1204
Joined: Sun Mar 23, 2008 5:46 pm
Location: Kingston Upon Hull. UK

Re: UFO export denied!!! since 1.9.1

Postby AndersG » Fri Mar 06, 2009 10:46 pm

MaverickAlex wrote:i changed mine to match your Anders and it still doesn't work. I guess i'll just do it by copying the command lines instead of using export.


I think you need to add
WRITE ALLOW $FG_HOME/*.xml
or
WRITE ALLOW $FG_HOME/<file name>.xml
since the ufo file is directly in $FG_HOME.
(I didn't want the first since that would allow Nasal scripts to overwrite my user preference.xml file I have in $FG_HOME :)

/Anders
Callsign: SE-AG
Aircraft (uhm...): Submarine Scout, Zeppelin NT, ZF Navy free balloon, Nordstern, Hindenburg, Short Empire flying-boat, ZNP-K, North Sea class, MTB T21 class, U.S.S. Monitor, MFI-9B, Type UB I submarine, Gokstad ship, Renault FT.
AndersG
 
Posts: 2527
Joined: Wed Nov 29, 2006 10:20 am
Location: Göteborg, Sweden
Callsign: SE-AG
OS: Debian GNU Linux

Re: UFO export denied!!! since 1.9.1

Postby MaverickAlex » Sat Mar 07, 2009 12:54 am

ah success at last.

Thanks Anders, my read/write access now looks like this.

Code: Select all
READ ALLOW $FG_ROOT/*
READ ALLOW $FG_HOME/*

WRITE ALLOW $FG_HOME/*.log
WRITE ALLOW $FG_HOME/*ufo-model-export.xml    <--- needed to add this line
WRITE ALLOW $FG_HOME/*/*.xml
WRITE ALLOW $FG_HOME/*.sav
WRITE ALLOW $FG_HOME/Export/*
WRITE ALLOW $FG_HOME/state/*.xml
WRITE ALLOW $FG_HOME/aircraft-data/*.xml


and it exports properly as it should do.

Glad you knew about that, i would have never have found it.

For anyone else who has the same problem.
The IOrules file is found in FG/data/nasal

Thanks again, it makes things much simpler to be able to export things for later inclusion into the stg files. rather than having to do it all at the same time.

Alex
User avatar
MaverickAlex
 
Posts: 1204
Joined: Sun Mar 23, 2008 5:46 pm
Location: Kingston Upon Hull. UK

Next

Return to Support

Who is online

Users browsing this forum: No registered users and 2 guests