Page MenuHomeFeedback Tracker

new command for server config: onServerStart
New, WishlistPublic

Description

Would be nice to have this command for the server config to start server side scripts instead of via init.sqf in the mission.

onServerStart is familar to existing commands (onUserConnected, onUserDisconnected, doubleIdDetected, onUnsignedData, onHackedData, onDifferentData)

onServerStart should be executed once on server start.

Example:
onServerStart = "[] execVM 'myServerFolder\serverInit.sqf'"; //call compile this string on serverstart

Details

Legacy ID
771103070
Severity
None
Resolution
Open
Reproducibility
N/A
Category
Server

Event Timeline

Skaronator edited Additional Information. (Show Details)
Skaronator set Category to Server.
Skaronator set Reproducibility to N/A.
Skaronator set Severity to None.
Skaronator set Resolution to Open.
Skaronator set Legacy ID to 771103070.May 7 2016, 7:34 PM

Ah completely forgot that but in case of remote execution could that be loaded as well from a hacker. Server config cannot loaded since we can block file types via this commands:
allowedLoadFileExtensions[] = {:};
allowedPreprocessFileExtensions[] = {"sqf"};
allowedHTMLLoadExtensions[] = {"htm","html","xml"};

you can just as well

0 = [] spawn compile preprocessFileLineNumbers 'myServerFolder\serverInit.sqf';

from initServer.sqf

should be no different to

onServerStart = "[] execVM 'myServerFolder\serverInit.sqf'";

a hacker can "read" that files with a remote execution on the server.

ABC = preprocessFileLineNumbers 'initServer.sqf';
publicVariable "ABC";
ABC would be the content of the initServer file.

That wouldn't work with the server config way cause the server cfg can't be loaded

Why do you need to allow preprocess .sqf extension? initServer.sqf is probably execVM called, so if you disallow it, no one can read it. If you need call compile preprocess yourself own files you can make up your own extensions

initServer.sqf is called via execVM but ArmA need the preprocess for .sqf extensions. The function compiler use it and when I block .sqf would not a single function work.

Agree with Skaronator - If I block .sqf via allowedPreprocessFileExtensions, then Arma can't read it's own files:

Could not load 'A3\functions_f\systems\fn_locations.sqf'. Extension not listed in allowedPreprocessFileExtensions
Could not load 'A3\functions_f\variables\fn_areEqual.sqf'. Extension not listed in allowedPreprocessFileExtensions
Could not load 'A3\functions_f\variables\fn_swapVars.sqf'. Extension not listed in allowedPreprocessFileExtensions
Could not load 'A3\functions_f\variables\fn_variableSpaceAdd.sqf'. Extension not listed in allowedPreprocessFileExtensions
Could not load 'A3\functions_f\variables\fn_variableSpaceRemove.sqf'. Extension not listed in allowedPreprocessFileExtensions
Could not load 'A3\functions_f\vectors\fn_crossProduct.sqf'. Extension not listed in allowedPreprocessFileExtensions
Could not load 'A3\functions_f\vectors\fn_dotProduct.sqf'. Extension not listed in allowedPreprocessFileExtensions
Could not load 'A3\functions_f\vectors\fn_magnitude.sqf'. Extension not listed in allowedPreprocessFileExtensions
Could not load 'A3\functions_f\vectors\fn_magnitudeSqr.sqf'. Extension not listed in allowedPreprocessFileExtensions
Could not load 'A3\functions_f\vectors\fn_unitVector.sqf'. Extension not listed in allowedPreprocessFileExtensions
Could not load 'A3\functions_f\vectors\fn_vectorMultiply.sqf'. Extension not listed in allowedPreprocessFileExtensions
Could not load 'A3\functions_f\vectors\fn_vectorDiff.sqf'. Extension not listed in allowedPreprocessFileExtensions
Could not load 'A3\functions_f\vectors\fn_vectorAdd.sqf'. Extension not listed in allowedPreprocessFileExtensions
Could not load 'A3\functions_f\vectors\fn_vectorFromXToY.sqf'. Extension not listed in allowedPreprocessFileExtensions
Could not load 'A3\functions_f\vectors\fn_rotateVector2D.sqf'. Extension not listed in allowedPreprocessFileExtensions

G00golplexian added a subscriber: G00golplexian.EditedSep 5 2016, 7:46 AM

Oh yeah, BI need to fix that, so we can disable sqf preprocessing for serverside sniffing. It's still undone... :/