1
Unityエンジンを使用してクライアント側のC#からサーバー側にJavaを送信する必要があるゲームを開発していますが、この問題に直面していますjava内のcookieContainer内のデータを取得します
私はこの
private HttpWebRequest request(){
try{
string url = "http://localhost:8080/...";
var request = (HttpWebRequest)WebRequest.Create(url);
request.Timeout = 15000;
request.KeepAlive = true ;
request.Method= "GET";
CookieContainer cookieContainer = new CookieContainer();
Cookie Authentication = new Cookie("Session" , "09iubasd");
Authentication.Domain = url;
cookieContainer.Add(Authentication);
request.CookieContainer = cookieContainer;
request.Headers.Add("testting", "hascome");
return request;
}catch(System.Exception ex){
Debug.Log("[Exception]" + ex);
throw ex;
}
}
のように、クライアント側のコードの束を作成し、サーバ側では、Javaの春に書いています。サーバーサイドでCookieContainer内のCookieデータを取得できません。誰も私にこの問題を解決するための提案や解決策を教えてもらえますか?または、JavaのCookieContainerに似たもの。私はグーグルではありませんが、これは愚かな質問ならば私に教えてください。どうもありがとう。 Vince