1. Allowed file types

    Artikel: AN0002396Aktualisiert: 24.03.2019
    Die vorgegebene Sprachenversion vom Artikeltext wird angezeigt, weil es kein Text von der ausgewählten Sprache und Version gibt.

    Allowed and forbidden suffixes can be defined in ObjectGears on two levels:

    • Settings on the level of the whole application - element BlockedFileExtensions in the file web.config.
    • Settings on the column level - property Allowed file suffixes.

    Administrator of the ObjectGears instance can define in the file  web.config file suffixes that cannot be attached in any case or that can be attached only in certain models, classes or columns.

    IT owner of a model can then enable file suffixes in the frame defined by the Administratorem.

    We can define more suffixes, use of which shall be limited on the level of the whole application, in the file web.config. Definitions of particular types of suffixes are separated by comma. We can have more definitions separated by a colon for each suffix.

    Definition Meaning Example
    Suffix Files of the given suffix cannot be attached anywhere in the ObjectGears instance. exe
    Suffix:* Files of the given suffix cannot be attached, unless they are explicitly enabled in the column definition. bat:*
    Suffix:model Files of the given suffix can be attached only in the given model. sql:it
    Suffix:model.class Files of the given suffix can be attached only in the given class of the given model. bak:it.change_requests
    Suffix:model.class.column Files of the given suffix can be attached only in the given column of the given class and model.. bas:it.change_requests.files

    Example:

    <setting name="BlockedFileExtensions" serializeAs="String">
       <value>exe,bat:*,sql:it,bak:it.change_requests,bas:easytask:it.change_requests.files</value>
    </setting>

    Above stated example has following implications:

    1. Files with the suffix exe cannot be inserted in any File type column of any model (not even in a situation when IT owner would explicitly state the suffix in the List of allowed suffixes).
    2. Files with the suffix bat can be inserted in all the models but only in those columns where IT owner explicitly states this suffix in the List of allowed suffixes.
    3. Files with suffix sql can be inserted in any File type column in the model it where IT owner will state it explictly or where no suffix is defined in the List of allowed suffixes.
    4. Files with suffix bak can be inserted in any File type column in the class change_requests in the model it where IT owner will state it explictly or where no suffix is defined in the List of allowed suffixes.
    5. Files with suffix bas can be inserted in any File type column in the model easytask and in the column files in the class change_requests in the model it where IT owner will state it explicitly or where no suffix is defined in the List of allowed suffixes.
×