Bluedragon.netでのColdFusionによる独特のエラー
-
11-10-2019 - |
質問
Bluedragon.netでColdFusionで奇妙な問題が発生しています。 Stackoverflowユーザーの幅広い経験のためにここで尋ねます。
bluedragon.netサーバーに掲載されたコンテンツ内のタグが削除されますが、スタックのどこに削除されているのかはわかりません。たとえば、このデータを投稿する場合
[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>
><>
私たちが取り戻すのはこれです:
[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
>
つまり、始まるものは何でも <
で終わります >
剥がされたりフィルタリングされたりして、coldfusionのものには表示されなくなりました FORM
投稿したときのスコープ。
Bluedragon JXを搭載したサーバーは、この問題に苦しむことはありません。
デフォルトを使用してバイパスする場合 FORM
スコープとこのコードを使用すると、タグのようなコンテンツが表示されます。
<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#">
これを行い、作成されたものを使用します BetterFORM
変数、それはそこにあるので、スタックの他のポイントでフィルタリングされているリクエストが問題ではないようです。多分それはurlscanだと思っていましたが、それはインストールされていないようです。 bd.netはエンジンとして.netで実行されるため、おそらくすべての変数で使用されているサニタイゼーション設定がありますか?
この問題については、提案やアイデアなどを歓迎します。
解決 2
それは非常にありふれたものであることが判明しました。
カスタマイズされた文字列交換を行うカスタムタグがありました。 1つのサーバーでは、すべてのタグを置き換えないように変更されました。このサーバーでは、古いバージョンを使用していました。したがって、障害はBluedragon JXとBluedragon.netの違いではありませんでした - それは開発者チームエラーでした。
他のヒント
チェックするのに便利なBD.NETインスタンスはありませんが、Adobe ColdFusionにはCF管理者に「無効なタグ」を剥がす設定があります。それが私の最高の推測です。 Adobe CFはそれらを「Invalidtag」に置き換えます。私の推測では、bd.netは静かにストリップするだけだと思います。