Domanda

Abbiamo un problema strano che si verifica con ColdFusion su BlueDragon.NET. Chiedendo qui a causa della vasta esperienza di utenti StackOverflow.

Tag all'interno Pubblicato il contenuto di fuori del server BlueDragon.NET viene rimosso, e non siamo sicuri di dove nello stack è sempre rimosso. Così, per esempio, se abbiamo posto questi dati

[CORE]
Lesson_Status=Incomplete
Lesson_Location=comm_13_a02_bs_enus_t17s06v01
score=
time=00:00:56
[Core_Lesson]
<sd ac="" pc="7.0" at="1289834380459" ct="" ><t id="lo8" sc=";;" st="c" /></sd>
<sd ac='' pc='7.0' at='1289834380459' ct='' ><t id='lo8' sc=';;' st='c' /></sd>
<sd ac="" pc="7.0" at="1289834380459" ct="" ><t id="lo8" sc=";;" st="c" /></sd>
<sd ac="" pc="7.0" at="1289834380459" ct="" ><t id="lo8" sc=";;" st="c" /></sd>
<b>hello1</b>
<i>hello2</i>
<table border><td>hello3</td></table>
<sd>hello4</sd>
<sd ac="1">hello5</sd>
<t>hello6</t>
<t />
<t attr="hello8" />
<strong>hello10</strong>
<img>
><>

Quello che torniamo è questa:

[CORE]
Lesson_Status=Incomplete
Lesson_Location=comm_13_a02_bs_enus_t17s06v01
score=
time=00:00:56
[Core_Lesson]



hello1
hello2
hello3
hello4
hello5
hello6


hello10

>

Cioè, tutto ciò che inizia con < e finisce con > sta ottenendo spogliato o filtrati e non appare più a portata FORM di ColdFusion quando è inviato.

Il nostro server con BlueDragon JX non soffre di questo problema.

Se bypass utilizza l'ambito predefinito FORM e utilizzando questo codice, il tag come appare contenuti:

<cfscript>
    // get the content string of the raw HTTP headers, will include all POST content as a long querystring
    RAWREQUEST = GetHttpRequestData();
    // split the string on "&" character, each variable should now be separate
    // note that at this point duplicate variables will get clobbered
    RAWFORMFIELDS = ListToArray(RAWREQUEST.content, "&");
    // We're creating a structure like "FORM", but better
    BetterFORM = StructNew();
    // Go over each of the raw form fields, take the key
    // and add it as a key, and decode the value into the value field
    // and trap the whole thing if for some reason garbage gets in there
    for(i=1;i LTE ArrayLen(RAWFORMFIELDS);i = i + 1) {
        temp = ListToArray(RAWFORMFIELDS[i], "=");
        try {
            tempkey = temp[1];
            tempval = URLDecode(temp[2]);                 
            StructInsert(BetterFORM, tempkey, tempval);
        } catch(Any e) {
            tempThisError = "Malformed Data: " & RAWFORMFIELDS[i];
            // Log the value of tempThisError here?         
            // WriteOutput(tempThisError);
        }
    }
</cfscript>
<cfdump var="#BetterFORM#">

Se facciamo questo, e utilizzare la variabile BetterFORM creato, è lì, in modo che non sembra essere un problema con le richieste di essere filtrati in qualche altro punto nella pila. Stavo pensando che forse era URLScan, ma che non sembra essere installato. Dal momento che BD.NET viene eseguito su .NET come il motore, forse c'è qualche impostazione sanificazione che viene utilizzato su tutte le variabili in qualche modo?

suggerimenti, idee, ecc sono i benvenuti su questo tema.

È stato utile?

Soluzione 2

Si è rivelato essere molto banale.

Abbiamo avuto un tag personalizzato che ha personalizzato le sostituzioni di stringa. Su un server, è stato modificato in modo da non sostituire tutti i tag. Su questo server, stavamo usando una versione precedente che ha fatto. Quindi la colpa non era una differenza tra BlueDragon JX e BlueDragon.NET -. È stato l'errore team di sviluppo

Altri suggerimenti

Non avere un'istanza BD.NET a portata di mano per controllare, ma Adobe ColdFusion ha una regolazione nel all'amministratore cf mettere a nudo "tag non validi". Questa è la mia ipotesi migliore. Adobe CF li sostituisce con "invalidTag", la mia ipotesi è che BD.Net solo spoglia in silenzio.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top