User Tools

Site Tools


en:dev:284:security

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
en:dev:284:security [24.03.2016 20:21] – [Feste Einstellungen] translated mrbasemanen:dev:284:security [24.03.2016 21:41] (current) – finished translation and removed fixme mrbaseman
Line 1: Line 1:
-FIXME **This page is not fully translated, yet. Please help completing the translation.**\\ //(remove this paragraph once the translation is finished)// 
- 
 ====== System Security ====== ====== System Security ======
 (A whole package of individual elements. From password encryption to measurements to protect against cross-site scripting.) (A whole package of individual elements. From password encryption to measurements to protect against cross-site scripting.)
Line 25: Line 23:
  
 ==== Registry-Settings ==== ==== Registry-Settings ====
-//(Variable Einstellmöglichkeiten)//\\ +//(Variable settings)//\\ 
-Diese vier Werte können im Backend unter //Settings-Sicherheit// eingestellt werden.+These four values can be set in the backend under //Settings security//.
  
 **SecTokenLifeTime**\\ **SecTokenLifeTime**\\
-Die 'Lebensdauer' von Tokens kann in Schritten von LIFETIME_STEP-Sekunden von LIFETIME_MIN bis LIFETIME_MAX eingestellt werden.\\ +The 'life time' of tokens can be adjusted in increments of LIFETIME_STEP-seconds of LIFETIME_MIN to LIFETIME_MAX. \\ 
-Die Einstellung erfolgt durch einen entsprechenden Eintrag in der Registry mittels der Settings des Backends.\\ +The adjustment is made by a corresponding entry in the registry using the Settings of the backend. \\ 
-Wird ein negativer Wert (<0) eingegeben, so wird der Debug-Modus mit einer Lebensdauer von DEBUG_LIFTIME-Sekunden aktiviert.+If a negative value (<0) is entered, the debug mode is activated with a lifetime of DEBUG_LIFTIME-seconds.
  
 **SecTokenFingerprint**\\ **SecTokenFingerprint**\\
-Hiermit kann das Fingerprinting des Client vollständig eingeschaltet(**true**) oder ausgeschaltet(**false**) werden.\\ +Herewith the fingerprinting of the client can be turned completely on (**true**) or off (**false**). \\ 
-Die Abschaltung wird aus Sicherheitsgründen **nicht** empfohlen!+Turning it off for security reasons is **not** recommended!
  
 **SecTokenIpv4Netmask**\\ **SecTokenIpv4Netmask**\\
-Hiermit wird der zu überprüfende Netzanteil einer IPv4 Adresse festgelegt. Möglich sind Netzmaskenlängen von 1-32 Bit. Eine Länge von 0 Bit setzt die IPv4-Überprüfung ausser Funktion.+Herewith the IPv4 address network share to verify is specified. Allowed netmask lengths are 1-32 bit. A length of 0 bit logically disables IPv4 checking.
  
 **SecTokenIpv6Netmask**\\ **SecTokenIpv6Netmask**\\
-Hiermit wird der zu überprüfende Netzanteil einer IPv6 Adresse festgelegt. Möglich sind Netzmaskenlängen von 1-128 Bit. Eine Länge von 0 Bit setzt die IPv6-Überprüfung ausser Funktion.+Herewith the IPv6 address network share to verify is specified. Allowed netmask lengths are 1-128 bit. A length of 0 bit logically disables IPv6 checking.
 ---- ----
  
- +==== Available Methods ====
-==== Verfügbare Methoden ====+
 === ::getFTAN === === ::getFTAN ===
 **Prototype:** <php>mixed getFTAN(mixed $mMode = 'POST')</php>\\ **Prototype:** <php>mixed getFTAN(mixed $mMode = 'POST')</php>\\
-Gibt die FTAN des aktuellen Requests zurück. Beim ersten Aufruf von getFTAN() innerhalb eines Requests wird eine neue FTAN erzeugt, die dann während des laufenden Requests beliebig oft abgerufen werden kann. +Returns the FTAN for the current request. During the first call to getFTAN() within a request a new FTAN is generated, which can then be accessed during the current request several times. 
-Das Argument **//$mMode //** definiert das Rückgabeformat der Methode. +The argument **//$mMode //** defines the return format of the method. 
-  * 'POST' liefert einen HTML Input Tag zurück ( //<input type="hidden" name="FTAN-name" value="FTAN-wert" title="">// ) +  * 'POST'  returns an HTML input tag ( //<input type="hidden" name="FTAN-name" value="FTAN-value" title="">// ) 
-  * 'GET' liefert einen String, der in ein URL-Argument eingefügt werden kann ( //'FTAN-name=FTAN-wert'// ) +  * 'GET' returns a string that can be inserted in a URL argument ( //'FTAN-name=FTAN-value'// ) 
-  * 'RAW' liefert ein Array zur Übergabe an eine Template-Engine, wobei der Index '**name**' den //FTAN-name// und der Index '**value**' den //FTAN-wert// enthält. +  * 'RAW' returns an array to pass to a template engine, in which the index '**name**' points to the //FTAN-name// and the index '**value**' points to the //FTAN-value//.
  
 === ::checkFtan === === ::checkFtan ===
 **Prototype:** <php>bool checkFTAN(mixed $mMode = 'POST', bool $bPreserve = false)</php>\\ **Prototype:** <php>bool checkFTAN(mixed $mMode = 'POST', bool $bPreserve = false)</php>\\
-Es wird überprüft, ob im aktuellen Request eine gültige FTAN übergeben wurde. Das Argument $mMode bestimmt, wo nach der FTAN gesucht werden soll. Per default ist dies $_POST, bei jeder anderen Angabe $_GET, Jede gefundene, gültige FTAN wird danach sofort aus der Liste der aktiven FTANs gelöscht. Sie kann also grundsätzlich nur ein einziges Mal abgefragt werden. +It is checked whether a valid FTAN was passed in the current request. The argument $mMode determines where to look for the FTAN. By default this is $_POST, in any other case $_GET, each valid FTAN found will be immediately deleted from the list of active FTANs. So it can be interrogated strictly only once. 
-Bei gültiger FTAN ist der Rückgabewert TRUE andernfalls FALSE.+If the FTAN is valid the return value is TRUE or FALSE otherwise.
  
 === ::getIDKEY === === ::getIDKEY ===
 **Prototype:** <php>string getIDKEY(mixed $mValue)</php>\\ **Prototype:** <php>string getIDKEY(mixed $mValue)</php>\\
-Der an die Methode übergebene Wert wird gesichert und dafür ein einmaliger, 16-stelliger, alphanumerischer Schlüsselwert zurückgegeben. +The value passed to the method is saved and instead a value for a one-time, 16-digit alphanumeric key is returned. 
-Es können folgende Datentypen übergeben werden: **//String//**, **//Integer//** und **//Array//**. Der zurückgegebene Schlüsselwert wird einfach anstatt des Originalwertes an den Client gesendet.+The following data types can be passed: **//String//**, **//Integer//** and **//Array//**. The returned key value is simply transmitted to the client instead of the original value.
  
 === ::checkIDKEY === === ::checkIDKEY ===
 **Prototype:** <php>mixed checkIDKEY(string $sFieldname, mixed $mDefault = 0, string $sRequest = 'POST'. bool $bPreserve = false)</php>\\ **Prototype:** <php>mixed checkIDKEY(string $sFieldname, mixed $mDefault = 0, string $sRequest = 'POST'. bool $bPreserve = false)</php>\\
-  * **//$sRequest//** Enthält dieses Argument den Wert '**//POST//** oder **//GET//**, so wird der Inhalt von **//$sFieldname//** als Bezeichner eines POST oder GET Elementes, dessen Wert entschlüsselt werden soll, genutzt. Enthält es dagegen '**//RAW//**' so ist der Inhalt von **//$sFieldname//** selbst der zu decodierende Schlüsselwert. +  * **//$sRequest//** If this argument contains the value '**//POST//** or **//GET//**, the content of  **//$sFieldname//** is used as an identifier of a POST or GET element, whose value is to be decrypted. If it however contains '**//RAW//**' the content of **//$sFieldname//** directly contains the value to be decoded. 
-  * **//$mDefault//** ist der Wert, der zurückgegeben wird, falls der Schlüsselwert ungültig ist.+  * **//$mDefault//** is the value that is returned if the key value is invalid.
  
 === ::sanitizeLifeTime === === ::sanitizeLifeTime ===
 **Prototype:** <php>integer sanitizeLifeTime(integer $iLifeTime)</php>\\ **Prototype:** <php>integer sanitizeLifeTime(integer $iLifeTime)</php>\\
-Ein übergebener Integer-Wert wird auf eine verfügbare Intervallstufe zwischen LIFETIME_MIN und LIFETIME_MAX korrigiert. Ein negativer Wert bei aktiviertem DEBUG-Modus auf DEBUG_LIFETIME, ansonsten auf LIFETIME_MIN. Ein ungültiger Wert grundsätzlich auf LIFETIME_MIN. Der berechnete Wert wird zurückgegeben.+The supplied integer value is corrected to an available interval between LIFETIME_MIN and LIFETIME_MAX. A negative value when activated DEBUG mode is mapped on DEBUG_LIFETIME, otherwise on LIFETIME_MIN. An invalid value is mapped on LIFETIME_MIN. The calculated value is returned. 
 === ::getTokenLifeTime === === ::getTokenLifeTime ===
 **Prototype:** <php>array getTokenLifeTime(void)</php>\\ **Prototype:** <php>array getTokenLifeTime(void)</php>\\
-Gibt ein Array mit folgenden Schlüsseln zurück: +Returns an array with the following keys: 
-^Schlüssel ^ Beschreibung ^ +^Key   ^ Description                          ^ 
-| min  | minimale Lebensdauer in Sekunden     | +| min  | minimum lifetime in seconds          | 
-| max  | maximale Lebensdauer in Sekunden     | +| max  | maximum lifetime in seconds          | 
-| step | Schrittweite in Sekunden             | +| step | Increment in seconds                 | 
-| value| Eingestellte Laufzeit in Sekunden    | +| value| Set duration in seconds              | 
-Wozu werden diese Werte benötigt? An das Template übergeben, lässt sich z.B. eine Fortschrittsanzeige realisieren, die optisch die Zeit bis zum Timeout anzeigt.+What are these values needed for? Transfered to the template, one can for instance implement a progress bar that visually displays the time until timeout.
  
 ---- ----
-==== Anwendungsbeispiele ==== +==== Examples ==== 
-:!: **Achtung:** Requests müssen eindeutig sein! Der 'action' Parameter eines **//form//** Tags darf keine zusätzlichen URL-Argumente ( //*.php?x=1// ) enthalten. Eventuell notwendige Zusatzargumente müssen mit //<input type="hidden" …>// übergeben werden.+:!: **Warning** Requests must be unique! The 'action' parameter of a **//form//** tag must not contain any additional URL arguments ( //*.php?x=1// ). Any necessary additional arguments must be passed with //<input type="hidden" …>//.
  
-=== Formular ===+=== Form ===
 <PHP> <PHP>
 $sOutput = '<form method="post" action="index.php">' $sOutput = '<form method="post" action="index.php">'
Line 94: Line 91:
 echo $sOutput;     echo $sOutput;    
  
-// Auswertung+// Evaluation
  
-if ($oReg->App->checkFTAN('POST')) { /* alles OK */ }+if ($oReg->App->checkFTAN('POST')) { /* everythig OK */ }
  
 $iRecordId = $oReg->App->checkIDKEY('record_id', 0, 'POST'); $iRecordId = $oReg->App->checkIDKEY('record_id', 0, 'POST');
Line 106: Line 103:
 echo $sOutput;     echo $sOutput;    
  
-// Auswertung+// Evaluation
  
-if ($oReg->App->checkFTAN('GET')) { /* alles OK */ }+if ($oReg->App->checkFTAN('GET')) { /* everything OK */ }
  
 $iRecordId = $oReg->App->checkIDKEY('record_id', 0, 'GET'); $iRecordId = $oReg->App->checkIDKEY('record_id', 0, 'GET');
Line 123: Line 120:
 twig-template twig-template
  
-// Beispiel 1+// Example 1
  <form method="post" action="{{ TargetUrl }}">  <form method="post" action="{{ TargetUrl }}">
    <input type="hidden" name="{{ FTAN.name }}" value="{{ FTAN.value }}">    <input type="hidden" name="{{ FTAN.name }}" value="{{ FTAN.value }}">
Line 130: Line 127:
  </form>  </form>
  
-// Beispiel 2 +// Example 2 
- <a href="{{ TargetUrl }}?{{ FTAN.name }}={{ FTAN.value }}&record_id={{ RecordId }}" title="xx">Tu was</a>+ <a href="{{ TargetUrl }}?{{ FTAN.name }}={{ FTAN.value }}&record_id={{ RecordId }}" title="xx">Do something</a>
 </PHP> </PHP>
 <PHP> <PHP>
 save-script save-script
  
-// Beispiel 1+// Example 1
 if ($oReg->App->checkFTAN()) { if ($oReg->App->checkFTAN()) {
     $record_id = $oReg->App->checkIDKEY('record_id');     $record_id = $oReg->App->checkIDKEY('record_id');
     [...]     [...]
 }    }   
-// Beispiel 2+// Example 2
 if ($oReg->App->checkFTAN('GET')) { if ($oReg->App->checkFTAN('GET')) {
     $record_id = $oReg->App->checkIDKEY('record_id', 0, 'GET');     $record_id = $oReg->App->checkIDKEY('record_id', 0, 'GET');
en/dev/284/security.1458850871.txt.gz · Last modified: 24.03.2016 20:21 by mrbaseman