Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // YAPE_AU
- [LineNumberTable(new byte[]
- {
- 160,
- 211,
- 98,
- 112,
- 134,
- 109,
- 103,
- 113,
- 102,
- 58,
- 133,
- 98,
- 113,
- 110,
- 115,
- 17,
- 203,
- 105,
- 108,
- 116,
- 127,
- 10,
- 54,
- 165,
- 103,
- 127,
- 41,
- 98,
- 131,
- 127,
- 14,
- 161,
- 254,
- 58,
- 131,
- 127,
- 14,
- 193,
- 104,
- 135,
- 109,
- 99,
- 127,
- 54,
- 110,
- 113,
- 226,
- 61,
- 236,
- 70,
- 99,
- 100,
- 135,
- 135,
- 98,
- 39,
- 135,
- 98,
- 63,
- 4,
- 191,
- 30,
- 98,
- 132,
- 127,
- 15,
- 161,
- 254,
- 58,
- 132,
- 127,
- 15,
- 225,
- 69,
- 108,
- 127,
- 3,
- 105,
- 106,
- 127,
- 27,
- 127,
- 15,
- 226,
- 69,
- 98,
- 103,
- 106,
- 42,
- 101,
- 42,
- 135,
- 109,
- 103,
- 102,
- 54,
- 133,
- 99,
- 98,
- 98,
- 98,
- 130,
- 113,
- 121,
- 185,
- 135,
- 41,
- 199,
- 105,
- 101,
- 110,
- 125,
- 108,
- 54,
- 133,
- 108,
- 44,
- 133,
- 103,
- 245,
- 56,
- 236,
- 76,
- 125,
- 108,
- 58,
- 133,
- 108,
- 53,
- 133,
- 108,
- 103,
- 131,
- 104,
- 108,
- 100,
- 43,
- 175,
- 159,
- 45,
- 98,
- 132,
- 127,
- 32,
- 161,
- 255,
- 16,
- 58,
- 132,
- 127,
- 32,
- 193,
- 199,
- 127,
- 54,
- 98,
- 100,
- 135,
- 254,
- 61,
- 100,
- 167,
- 104,
- 104,
- 135,
- 98,
- 39,
- 135,
- 98,
- 63,
- 4,
- 191,
- 30,
- 98,
- 132,
- 127,
- 15,
- 161,
- 254,
- 58,
- 132,
- 127,
- 15,
- 193,
- 105,
- 98,
- 108,
- 114,
- 113,
- 101,
- 37,
- 131,
- 111,
- 55,
- 130,
- 127,
- 10,
- 54,
- 165,
- 42,
- 130,
- 125,
- 105,
- 159,
- 32,
- 127,
- 8,
- 162,
- 127,
- 6,
- 98,
- 98,
- 127,
- 17
- }), Throws(new string[]
- {
- "java.lang.Exception"
- })]
- [MethodImpl(MethodImplOptions.NoInlining)]
- private bool upload(File file, Proxy proxy)
- {
- URL.__<clinit>();
- URL uRL = new URL(YAPE_AU.submit_url);
- StringBuffer stringBuffer = new StringBuffer();
- HttpURLConnection httpURLConnection;
- OutputStream outputStream;
- Exception ex;
- Exception ex2;
- try
- {
- httpURLConnection = (HttpURLConnection)uRL.openConnection(proxy);
- httpURLConnection.setDoOutput(true);
- httpURLConnection.setRequestProperty("Accept-Charset", this.charset);
- httpURLConnection.setRequestProperty("Content-Type", new StringBuilder("application/x-www-form-urlencoded;charset=").append(this.charset).toString());
- outputStream = null;
- if (!String.instancehelper_equals(YAPE_AU.user, "-"))
- {
- stringBuffer.append(String.format("u=%s&p=%s", new object[]
- {
- URLEncoder.encode(YAPE_AU.user, this.charset),
- URLEncoder.encode(YAPE_AU.pass, this.charset)
- }));
- }
- string text = this.fileHash(file);
- stringBuffer.append("&id=");
- stringBuffer.append(URLEncoder.encode(text, this.charset));
- System.@out.println(new StringBuilder(String.valueOf(this.tname)).append(":querying ").append(YAPE_AU.submit_url).append("?id=").append(text).toString());
- try
- {
- outputStream = httpURLConnection.getOutputStream();
- outputStream.write(String.instancehelper_getBytes(stringBuffer.toString(), this.charset));
- }
- catch (Exception arg_142_0)
- {
- ex = ByteCodeHelper.MapException<Exception>(arg_142_0, ByteCodeHelper.MapFlags.None);
- goto IL_15F;
- }
- }
- catch (Exception arg_14C_0)
- {
- Exception expr_151 = ByteCodeHelper.MapException<Exception>(arg_14C_0, ByteCodeHelper.MapFlags.None);
- if (expr_151 == null)
- {
- throw;
- }
- ex2 = expr_151;
- goto IL_163;
- }
- Exception ex3;
- try
- {
- if (outputStream != null)
- {
- try
- {
- outputStream.close();
- }
- catch (IOException arg_1CC_0)
- {
- }
- }
- }
- catch (Exception arg_1D5_0)
- {
- Exception expr_1DA = ByteCodeHelper.MapException<Exception>(arg_1D5_0, ByteCodeHelper.MapFlags.None);
- if (expr_1DA == null)
- {
- throw;
- }
- ex3 = expr_1DA;
- goto IL_1E8;
- }
- goto Block_5;
- IL_1E8:
- Exception arg_A8B_0 = ex3;
- goto IL_A8B;
- Block_5:
- string text2;
- CharSequence charSequence;
- BufferedReader bufferedReader;
- StringBuffer stringBuffer2;
- Exception ex4;
- Exception ex5;
- try
- {
- InputStream inputStream = httpURLConnection.getInputStream();
- httpURLConnection.getResponseCode();
- string headerField = httpURLConnection.getHeaderField("Content-Type");
- text2 = null;
- string arg_243_0 = headerField;
- object arg_21D_0 = " ";
- object obj = "";
- object _<ref> = arg_21D_0;
- charSequence.__<ref> = _<ref>;
- CharSequence arg_243_1 = charSequence;
- _<ref> = obj;
- charSequence.__<ref> = _<ref>;
- string[] array;
- int num = (array = String.instancehelper_split(String.instancehelper_replace(arg_243_0, arg_243_1, charSequence), ";")).Length;
- for (int i = 0; i < num; i++)
- {
- string this2 = array[i];
- if (String.instancehelper_startsWith(this2, "charset="))
- {
- text2 = String.instancehelper_split(this2, "=", 2)[1];
- break;
- }
- }
- bufferedReader = null;
- if (text2 == null)
- {
- text2 = "ISO-8859-1";
- }
- stringBuffer2 = new StringBuffer();
- try
- {
- bufferedReader = new BufferedReader(new InputStreamReader(inputStream, text2));
- string obj2;
- while ((obj2 = bufferedReader.readLine()) != null)
- {
- stringBuffer2.append(new StringBuilder(String.valueOf(obj2)).append("\n").toString());
- }
- }
- catch (Exception arg_2EC_0)
- {
- ex4 = ByteCodeHelper.MapException<Exception>(arg_2EC_0, ByteCodeHelper.MapFlags.None);
- goto IL_309;
- }
- }
- catch (Exception arg_2F6_0)
- {
- Exception expr_2FB = ByteCodeHelper.MapException<Exception>(arg_2F6_0, ByteCodeHelper.MapFlags.None);
- if (expr_2FB == null)
- {
- throw;
- }
- ex5 = expr_2FB;
- goto IL_30D;
- }
- Exception ex6;
- try
- {
- if (bufferedReader != null)
- {
- try
- {
- bufferedReader.close();
- }
- catch (IOException arg_37A_0)
- {
- }
- }
- }
- catch (Exception arg_383_0)
- {
- Exception expr_388 = ByteCodeHelper.MapException<Exception>(arg_383_0, ByteCodeHelper.MapFlags.None);
- if (expr_388 == null)
- {
- throw;
- }
- ex6 = expr_388;
- goto IL_396;
- }
- goto Block_9;
- IL_396:
- arg_A8B_0 = ex6;
- goto IL_A8B;
- Block_9:
- Exception ex7;
- try
- {
- Pattern pattern = Pattern.compile(".*RESULT: (.*)\n.*");
- Pattern arg_3C5_0 = pattern;
- object _<ref> = stringBuffer2.toString();
- charSequence.__<ref> = _<ref>;
- Matcher matcher = arg_3C5_0.matcher(charSequence);
- if (matcher.find())
- {
- string text3 = matcher.group(1);
- System.@out.println(new StringBuilder(String.valueOf(this.tname)).append(":").append("query result: ").append(text3).toString());
- if (String.instancehelper_equals(text3, "SKIP"))
- {
- return true;
- }
- }
- }
- catch (Exception arg_42E_0)
- {
- Exception expr_433 = ByteCodeHelper.MapException<Exception>(arg_42E_0, ByteCodeHelper.MapFlags.None);
- if (expr_433 == null)
- {
- throw;
- }
- ex7 = expr_433;
- goto IL_440;
- }
- string str;
- PrintWriter printWriter;
- FileInputStream fileInputStream;
- Exception ex8;
- Exception ex9;
- Exception ex10;
- try
- {
- Hashtable hashtable = new Hashtable();
- str = new StringBuilder("LoLoLoL").append(Long.toHexString(System.currentTimeMillis())).append("LoLoLoL").toString();
- httpURLConnection = (HttpURLConnection)uRL.openConnection(proxy);
- httpURLConnection.setDoOutput(true);
- httpURLConnection.setRequestProperty("Content-Type", new StringBuilder("multipart/form-data; boundary=").append(str).toString());
- printWriter = null;
- if (!String.instancehelper_equals(YAPE_AU.user, "-"))
- {
- hashtable.put("u", URLEncoder.encode(YAPE_AU.user, text2));
- hashtable.put("p", URLEncoder.encode(YAPE_AU.pass, text2));
- }
- try
- {
- outputStream = httpURLConnection.getOutputStream();
- printWriter = new PrintWriter(new OutputStreamWriter(outputStream, text2), true);
- Enumeration enumeration = hashtable.keys();
- while (enumeration.hasMoreElements())
- {
- string text4 = (string)enumeration.nextElement();
- printWriter.println(new StringBuilder("--").append(str).toString());
- printWriter.println(new StringBuilder("Content-Disposition: form-data; name=\"").append(text4).append("\"").toString());
- printWriter.println(new StringBuilder("Content-Type: text/plain; charset=").append(text2).toString());
- printWriter.println();
- printWriter.println((string)hashtable.get(text4));
- }
- printWriter.println(new StringBuilder("--").append(str).toString());
- printWriter.println(new StringBuilder("Content-Disposition: form-data; name=\"userfile\"; filename=\"").append(file.getName()).append("\"").toString());
- printWriter.println(new StringBuilder("Content-Type: ").append(URLConnection.guessContentTypeFromName(file.getName())).toString());
- printWriter.println("Content-Transfer-Encoding: binary");
- printWriter.println();
- fileInputStream = null;
- try
- {
- fileInputStream = new FileInputStream(file);
- byte[] b = new byte[1024];
- int len;
- while ((len = fileInputStream.read(b)) > 0)
- {
- outputStream.write(b, 0, len);
- }
- outputStream.flush();
- }
- catch (Exception arg_67C_0)
- {
- ex8 = ByteCodeHelper.MapException<Exception>(arg_67C_0, ByteCodeHelper.MapFlags.None);
- goto IL_6A3;
- }
- }
- catch (Exception arg_686_0)
- {
- ex9 = ByteCodeHelper.MapException<Exception>(arg_686_0, ByteCodeHelper.MapFlags.None);
- goto IL_6A7;
- }
- }
- catch (Exception arg_690_0)
- {
- Exception expr_695 = ByteCodeHelper.MapException<Exception>(arg_690_0, ByteCodeHelper.MapFlags.None);
- if (expr_695 == null)
- {
- throw;
- }
- ex10 = expr_695;
- goto IL_6AE;
- }
- Exception ex11;
- Exception ex12;
- try
- {
- try
- {
- if (fileInputStream != null)
- {
- try
- {
- fileInputStream.close();
- }
- catch (IOException arg_741_0)
- {
- }
- }
- }
- catch (Exception arg_74A_0)
- {
- ex11 = ByteCodeHelper.MapException<Exception>(arg_74A_0, ByteCodeHelper.MapFlags.None);
- goto IL_767;
- }
- }
- catch (Exception arg_754_0)
- {
- Exception expr_759 = ByteCodeHelper.MapException<Exception>(arg_754_0, ByteCodeHelper.MapFlags.None);
- if (expr_759 == null)
- {
- throw;
- }
- ex12 = expr_759;
- goto IL_76E;
- }
- goto Block_14;
- IL_767:
- Exception arg_7CE_0 = ex11;
- goto IL_7CE;
- IL_76E:
- arg_A8B_0 = ex12;
- goto IL_A8B;
- Block_14:
- Exception ex13;
- Exception ex14;
- try
- {
- try
- {
- printWriter.println();
- printWriter.println(new StringBuilder("--").append(str).append("--").toString());
- }
- catch (Exception arg_7A9_0)
- {
- ex13 = ByteCodeHelper.MapException<Exception>(arg_7A9_0, ByteCodeHelper.MapFlags.None);
- goto IL_7C3;
- }
- }
- catch (Exception arg_7B3_0)
- {
- Exception expr_7B8 = ByteCodeHelper.MapException<Exception>(arg_7B3_0, ByteCodeHelper.MapFlags.None);
- if (expr_7B8 == null)
- {
- throw;
- }
- ex14 = expr_7B8;
- goto IL_7C7;
- }
- int responseCode;
- string text5;
- Exception ex15;
- Exception ex16;
- try
- {
- if (printWriter != null)
- {
- printWriter.close();
- }
- InputStream inputStream = httpURLConnection.getInputStream();
- responseCode = httpURLConnection.getResponseCode();
- stringBuffer2 = new StringBuffer();
- try
- {
- bufferedReader = new BufferedReader(new InputStreamReader(inputStream, text2));
- while ((text5 = bufferedReader.readLine()) != null)
- {
- stringBuffer2.append(new StringBuilder(String.valueOf(text5)).append("\n").toString());
- }
- }
- catch (Exception arg_865_0)
- {
- ex15 = ByteCodeHelper.MapException<Exception>(arg_865_0, ByteCodeHelper.MapFlags.None);
- goto IL_882;
- }
- }
- catch (Exception arg_86F_0)
- {
- Exception expr_874 = ByteCodeHelper.MapException<Exception>(arg_86F_0, ByteCodeHelper.MapFlags.None);
- if (expr_874 == null)
- {
- throw;
- }
- ex16 = expr_874;
- goto IL_886;
- }
- Exception ex17;
- try
- {
- if (bufferedReader != null)
- {
- try
- {
- bufferedReader.close();
- }
- catch (IOException arg_8F3_0)
- {
- }
- }
- }
- catch (Exception arg_8FC_0)
- {
- Exception expr_901 = ByteCodeHelper.MapException<Exception>(arg_8FC_0, ByteCodeHelper.MapFlags.None);
- if (expr_901 == null)
- {
- throw;
- }
- ex17 = expr_901;
- goto IL_90F;
- }
- goto Block_20;
- IL_90F:
- arg_A8B_0 = ex17;
- goto IL_A8B;
- Block_20:
- Exception ex18;
- try
- {
- text5 = stringBuffer2.toString();
- if (responseCode == 200 && String.instancehelper_indexOf(text5, "Thank you") != -1)
- {
- YAPE_AU.bytes += file.length();
- long num2 = System.currentTimeMillis() - YAPE_AU.start_time;
- long arg_984_0;
- if (num2 > (long)((ulong)1000))
- {
- long expr_968 = YAPE_AU.bytes;
- long expr_976 = num2 / (long)((ulong)1000);
- arg_984_0 = ((expr_976 != -1L) ? (expr_968 / expr_976) : (-expr_968));
- }
- else
- {
- arg_984_0 = 0L;
- }
- long lng = arg_984_0;
- System.@out.print(new StringBuilder(String.valueOf(this.tname)).append(":").append("OK, (Bps avg~=").append(lng).append(") ").toString());
- Pattern pattern2 = Pattern.compile(".*\"(././././.*)\".*");
- Pattern arg_9EC_0 = pattern2;
- object _<ref> = text5;
- charSequence.__<ref> = _<ref>;
- Matcher matcher2 = arg_9EC_0.matcher(charSequence);
- if (matcher2.find())
- {
- System.@out.print(new StringBuilder(String.valueOf(String.instancehelper_substring(YAPE_AU.submit_url, 0, String.instancehelper_lastIndexOf(YAPE_AU.submit_url, 47) + 1))).append(matcher2.group(1)).toString());
- }
- System.@out.println();
- return true;
- }
- }
- catch (Exception arg_A4C_0)
- {
- Exception expr_A51 = ByteCodeHelper.MapException<Exception>(arg_A4C_0, ByteCodeHelper.MapFlags.None);
- if (expr_A51 == null)
- {
- throw;
- }
- ex18 = expr_A51;
- goto IL_A5E;
- }
- Exception ex19;
- try
- {
- System.@out.println(text5);
- }
- catch (Exception arg_A75_0)
- {
- Exception expr_A7A = ByteCodeHelper.MapException<Exception>(arg_A75_0, ByteCodeHelper.MapFlags.None);
- if (expr_A7A == null)
- {
- throw;
- }
- ex19 = expr_A7A;
- goto IL_A85;
- }
- return false;
- IL_A85:
- arg_A8B_0 = ex19;
- goto IL_A8B;
- IL_A5E:
- arg_A8B_0 = ex18;
- goto IL_A8B;
- IL_882:
- Exception ex20 = ex15;
- Exception ex21;
- Exception ex22;
- try
- {
- ex21 = ex20;
- if (bufferedReader != null)
- {
- try
- {
- bufferedReader.close();
- }
- catch (IOException arg_8A2_0)
- {
- }
- }
- }
- catch (Exception arg_8AB_0)
- {
- Exception expr_8B0 = ByteCodeHelper.MapException<Exception>(arg_8AB_0, ByteCodeHelper.MapFlags.None);
- if (expr_8B0 == null)
- {
- throw;
- }
- ex22 = expr_8B0;
- goto IL_8BE;
- }
- goto Block_18;
- IL_8BE:
- arg_A8B_0 = ex22;
- goto IL_A8B;
- Block_18:
- Exception ex23;
- try
- {
- throw Throwable.__<unmap>(ex21);
- }
- catch (Exception arg_8CF_0)
- {
- Exception expr_8D4 = ByteCodeHelper.MapException<Exception>(arg_8CF_0, ByteCodeHelper.MapFlags.None);
- if (expr_8D4 == null)
- {
- throw;
- }
- ex23 = expr_8D4;
- }
- arg_A8B_0 = ex23;
- goto IL_A8B;
- IL_886:
- arg_A8B_0 = ex16;
- goto IL_A8B;
- IL_7C3:
- arg_7CE_0 = ex13;
- goto IL_7CE;
- IL_7C7:
- arg_A8B_0 = ex14;
- goto IL_A8B;
- IL_6A3:
- Exception ex24 = ex8;
- Exception ex25;
- Exception ex26;
- try
- {
- ex24 = ex24;
- try
- {
- ex25 = ex24;
- if (fileInputStream != null)
- {
- try
- {
- fileInputStream.close();
- }
- catch (IOException arg_6CE_0)
- {
- }
- }
- }
- catch (Exception arg_6D7_0)
- {
- ex24 = ByteCodeHelper.MapException<Exception>(arg_6D7_0, ByteCodeHelper.MapFlags.None);
- goto IL_6F4;
- }
- }
- catch (Exception arg_6E1_0)
- {
- Exception expr_6E6 = ByteCodeHelper.MapException<Exception>(arg_6E1_0, ByteCodeHelper.MapFlags.None);
- if (expr_6E6 == null)
- {
- throw;
- }
- ex26 = expr_6E6;
- goto IL_6FB;
- }
- goto Block_12;
- IL_6F4:
- arg_7CE_0 = ex24;
- goto IL_7CE;
- IL_6FB:
- arg_A8B_0 = ex26;
- goto IL_A8B;
- Block_12:
- Exception ex27;
- Exception ex28;
- try
- {
- try
- {
- throw Throwable.__<unmap>(ex25);
- }
- catch (Exception arg_70C_0)
- {
- ex27 = ByteCodeHelper.MapException<Exception>(arg_70C_0, ByteCodeHelper.MapFlags.None);
- }
- }
- catch (Exception arg_716_0)
- {
- Exception expr_71B = ByteCodeHelper.MapException<Exception>(arg_716_0, ByteCodeHelper.MapFlags.None);
- if (expr_71B == null)
- {
- throw;
- }
- ex28 = expr_71B;
- goto IL_72B;
- }
- arg_7CE_0 = ex27;
- goto IL_7CE;
- IL_72B:
- arg_A8B_0 = ex28;
- goto IL_A8B;
- IL_6A7:
- arg_7CE_0 = ex9;
- goto IL_7CE;
- IL_6AE:
- arg_A8B_0 = ex10;
- goto IL_A8B;
- IL_7CE:
- ex15 = arg_7CE_0;
- Exception ex30;
- try
- {
- Exception ex29 = ex15;
- if (printWriter != null)
- {
- printWriter.close();
- }
- throw Throwable.__<unmap>(ex29);
- }
- catch (Exception arg_7E8_0)
- {
- Exception expr_7ED = ByteCodeHelper.MapException<Exception>(arg_7E8_0, ByteCodeHelper.MapFlags.None);
- if (expr_7ED == null)
- {
- throw;
- }
- ex30 = expr_7ED;
- }
- arg_A8B_0 = ex30;
- goto IL_A8B;
- IL_440:
- arg_A8B_0 = ex7;
- goto IL_A8B;
- IL_309:
- ex8 = ex4;
- Exception ex31;
- Exception ex32;
- try
- {
- ex31 = ex8;
- if (bufferedReader != null)
- {
- try
- {
- bufferedReader.close();
- }
- catch (IOException arg_329_0)
- {
- }
- }
- }
- catch (Exception arg_332_0)
- {
- Exception expr_337 = ByteCodeHelper.MapException<Exception>(arg_332_0, ByteCodeHelper.MapFlags.None);
- if (expr_337 == null)
- {
- throw;
- }
- ex32 = expr_337;
- goto IL_345;
- }
- goto Block_7;
- IL_345:
- arg_A8B_0 = ex32;
- goto IL_A8B;
- Block_7:
- Exception ex33;
- try
- {
- throw Throwable.__<unmap>(ex31);
- }
- catch (Exception arg_356_0)
- {
- Exception expr_35B = ByteCodeHelper.MapException<Exception>(arg_356_0, ByteCodeHelper.MapFlags.None);
- if (expr_35B == null)
- {
- throw;
- }
- ex33 = expr_35B;
- }
- arg_A8B_0 = ex33;
- goto IL_A8B;
- IL_30D:
- arg_A8B_0 = ex5;
- goto IL_A8B;
- IL_15F:
- ex4 = ex;
- Exception ex34;
- Exception ex35;
- try
- {
- ex34 = ex4;
- if (outputStream != null)
- {
- try
- {
- outputStream.close();
- }
- catch (IOException arg_17D_0)
- {
- }
- }
- }
- catch (Exception arg_186_0)
- {
- Exception expr_18B = ByteCodeHelper.MapException<Exception>(arg_186_0, ByteCodeHelper.MapFlags.None);
- if (expr_18B == null)
- {
- throw;
- }
- ex35 = expr_18B;
- goto IL_199;
- }
- goto Block_3;
- IL_199:
- arg_A8B_0 = ex35;
- goto IL_A8B;
- Block_3:
- Exception ex36;
- try
- {
- throw Throwable.__<unmap>(ex34);
- }
- catch (Exception arg_1AA_0)
- {
- Exception expr_1AF = ByteCodeHelper.MapException<Exception>(arg_1AA_0, ByteCodeHelper.MapFlags.None);
- if (expr_1AF == null)
- {
- throw;
- }
- ex36 = expr_1AF;
- }
- arg_A8B_0 = ex36;
- goto IL_A8B;
- IL_163:
- arg_A8B_0 = ex2;
- IL_A8B:
- Exception obj3 = arg_A8B_0;
- System.@out.println(new StringBuilder(String.valueOf(this.tname)).append(":").append(obj3).toString());
- return false;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement