Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public bool PerformA(Control cntrl, Rectangle rect, string strName, string userDetails, string iDetails, string tCntrlName, ref string txnID, bool isConfirmReq, bool isP, int SlotID, UpdateTStatus updtStatus, string fir)
- {
- bool result;
- if (!IRComm.bool_20)
- {
- if (!IRComm.bool_0)
- {
- MessageBox.Show("ABS has been Stopped Permanently!", "ABS Stopped", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
- }
- else
- {
- MessageBox.Show("Please use latest version of the Software", "Old Version", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
- }
- result = false;
- }
- else
- {
- frmCaptcha frmCaptcha = new frmCaptcha(this, null, "", "");
- Class3.dictionary_3 = null;
- Class3.dictionary_4 = null;
- Class3.dictionary_5 = null;
- string text = "";
- string text2 = "";
- string string_ = "";
- string string_2 = "";
- string text3 = "";
- this.LogInSite = "APP";
- this.LogInMethod = "CAP";
- double num = 0.0;
- this.control_0 = cntrl;
- this.rectangle_0 = rect;
- this.bool_7 = isConfirmReq;
- int count = cntrl.Controls["pnl"].Controls.Count;
- int count2 = cntrl.Controls["pnl"].Controls[0].Controls.Count;
- Control control = cntrl.Controls["pnl"].Controls[0];
- string text4 = ((ComboBox)control.Controls["lblGateway"]).SelectedItem.ToString();
- bool flag = false;
- bool flag2 = false;
- bool flag3 = false;
- bool flag4 = false;
- bool flag5 = false;
- bool flag6 = false;
- bool flag7 = false;
- string[] array = new string[1];
- List<Class9> list = new List<Class9>();
- string[] array2 = iDetails.Split(new string[]
- {
- "||"
- }, StringSplitOptions.None);
- string[] array3 = txnID.Split(new string[]
- {
- "-.-"
- }, StringSplitOptions.RemoveEmptyEntries);
- if (array3 != null && array3.Length > 0)
- {
- text = array3[0];
- }
- if (string.IsNullOrEmpty(text))
- {
- text = "1";
- }
- string text5 = "";
- if (!string.IsNullOrEmpty(fir) && SlotID > 2)
- {
- try
- {
- string[] array4 = fir.Split(new string[]
- {
- "||"
- }, StringSplitOptions.None);
- this.webProxy_0 = new WebProxy(array4[0].Trim(), int.Parse(array4[1].Trim()));
- this.webProxy_0.BypassProxyOnLocal = true;
- this.webProxy_0.Credentials = new NetworkCredential(array4[2].Trim(), array4[3].Trim());
- text3 = text3 + " Pxy:" + array4[0];
- text5 = "_Pxy:" + array4[0];
- this.method_30("Proxy Details: " + fir);
- goto IL_311;
- }
- catch (Exception ex)
- {
- this.method_31("Creating Proxy", ex.Message);
- MessageBox.Show("Error Occured while Setting IP, Please try in another slot.", "Proxy", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(53, "IP Issue, Try Another slot!", tCntrlName, null, null);
- }
- result = false;
- return result;
- }
- }
- this.webProxy_0 = null;
- IL_311:
- if (!string.IsNullOrEmpty(userDetails))
- {
- array = userDetails.Split(new string[]
- {
- "||"
- }, StringSplitOptions.None);
- if (array != null && array.Length > 2)
- {
- if (IRComm.string_20.Length < 1)
- {
- IRComm.string_20 = array[2];
- }
- int.TryParse(array[3], out IRComm.int_1);
- if (IRComm.int_1 < 2)
- {
- IRComm.int_1 = 2;
- }
- IRComm.int_1 *= 2;
- string string_3 = array[4];
- this.method_32(string_3);
- }
- }
- this.class6_0 = new Class6();
- this.class6_0.ipproxylist = fir;
- if (!this.class6_0.method_1(strName))
- {
- MessageBox.Show(IRComm.smethod_5(), "Error Occured while Reading Saved Ticket! ", "Error", MessageBoxButtons.OK, MessageBoxIcon.Hand);
- result = false;
- }
- else
- {
- this.class6_0.string_13 = array2[0];
- this.class6_0.string_14 = array2[1];
- if (array2.Length >= 3 && array2[2] != null)
- {
- if (IRComm.bool_0 && array2[2] != this.class6_0.string_8)
- {
- this.class6_0.string_8 = array2[2];
- }
- }
- this.BookingDtSetup();
- string text6 = this.class6_0.string_0;
- if (this.class6_0.dateTime_0 < new DateTime(DateTime.Now.Year, DateTime.Now.Month, DateTime.Now.Day))
- {
- MessageBox.Show(IRComm.smethod_5(), "Date of Journey cannot be less than Today!", "Error", MessageBoxButtons.OK, MessageBoxIcon.Hand);
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(53, "Date of Journey cannot less than Today!", tCntrlName, null, null);
- }
- result = false;
- }
- else if (this.class6_0.string_22 == "4")
- {
- MessageBox.Show(IRComm.smethod_5(), "You have not opt for Manual Payments! Please Select any Auto Payment Mode.", "Error", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(53, "Manual Payments not Allowed!", tCntrlName, null, null);
- }
- result = false;
- }
- else
- {
- if (array3 != null && array3.Length >= 2)
- {
- this.class6_0.string_23 = array3[1];
- if (this.class6_0.string_23.Contains("-+-"))
- {
- this.class6_0.string_233 = this.class6_0.string_23.Substring(this.class6_0.string_23.IndexOf("-+-") + 3);
- this.class6_0.string_23 = this.class6_0.string_23.Substring(0, this.class6_0.string_23.IndexOf("-+-"));
- }
- this.class6_0.string_24 = array3[2];
- if (this.class6_0.string_24.Contains("-+-"))
- {
- this.class6_0.string_244 = this.class6_0.string_24.Substring(this.class6_0.string_24.IndexOf("-+-") + 3);
- this.class6_0.string_24 = this.class6_0.string_24.Substring(0, this.class6_0.string_24.IndexOf("-+-"));
- }
- }
- this.webProxy_1 = null;
- if (this.class6_0.string_13.ToUpper() == this.string_19.ToUpper())
- {
- if (this.webProxy_0 == null)
- {
- MessageBox.Show("Without proxy not allowed.");
- result = false;
- return result;
- }
- this.webProxy_1 = this.webProxy_0;
- }
- try
- {
- if (!this.class6_0.string_23.Contains("SBI_") && !this.class6_0.string_23.Contains("HDFC_") && !this.class6_0.string_23.Contains("ICICI_") && !this.class6_0.string_23.Contains("IDBI_") && !this.class6_0.string_23.Contains("UNION_") && !this.class6_0.string_23.ToUpper().Contains("MOBIKWIK_") && !this.class6_0.string_23.ToUpper().Contains("_DC") && !this.class6_0.string_23.ToUpper().Contains("_CC"))
- {
- if (updtStatus != null)
- {
- }
- }
- if (this.class6_0.string_23.Contains("ICICI") && !this.class6_0.string_23.ToUpper().Contains("_DC") && !this.class6_0.string_23.ToUpper().Contains("_CC"))
- {
- if (this.class6_0.string_24.Split(new string[]
- {
- "||"
- }, StringSplitOptions.RemoveEmptyEntries).Length > 4)
- {
- text3 += " :ICIA: ";
- }
- else
- {
- this.XCordinate = cntrl.PointToScreen(rect.Location).X;
- this.YCordinate = cntrl.PointToScreen(rect.Location).Y;
- string text7 = Interaction.InputBox("Enter OTP Form ICICI Bank i-Safe Andriod APP. (If no i-Safe, Enter 12345 to receive OTP on Mobile)", "ICICI OTP", "", cntrl.PointToScreen(rect.Location).X, cntrl.PointToScreen(rect.Location).Y).Trim();
- if (text7.Length < 5)
- {
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(53, "Valid OTP Required!", tCntrlName, null, null);
- }
- result = false;
- return result;
- }
- this.class6_0.string_24 = this.class6_0.string_24 + "||" + text7;
- }
- }
- if (this.class6_0.string_23.Contains("MOBIKWIK"))
- {
- string[] array5 = this.class6_0.string_24.Split(new string[]
- {
- "||"
- }, StringSplitOptions.None);
- string text7 = array5[0].Trim();
- if (text7.Contains("@"))
- {
- string oldValue = text7;
- text7 = Interaction.InputBox("Enter Mobile No For OTP Of Mobikwik That Recive on Your Mobile no.", "Mobikwik OTP", "", cntrl.PointToScreen(rect.Location).X, cntrl.PointToScreen(rect.Location).Y).Trim();
- this.class6_0.string_24 = this.class6_0.string_24.Replace(oldValue, text7);
- }
- string text8 = "";
- string text9 = "";
- DialogResult dialogResult = MessageBox.Show("Do You Want to Bypass Mobikwik Now, else Enter Privious OTP?", "Mobikwik OTP", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult == DialogResult.Yes)
- {
- CookieContainer cookieContainer = null;
- if (!this.method_33("https://webapi.mobikwik.com/p/account/otp/cell?v=1.0.371", "{\"cell\":\"" + text7 + "\"}", "https://m.mobikwik.com/", this.webProxy_2, ref cookieContainer, true, true, 60000, 60000, ref text9, ref text8, ref this.webException_0))
- {
- }
- }
- string str = Interaction.InputBox("Enter OTP Of Mobikwik That Recive on Your Mobile no.", "Mobikwik OTP", "", cntrl.PointToScreen(rect.Location).X, cntrl.PointToScreen(rect.Location).Y).Trim();
- this.class6_0.string_24 = this.class6_0.string_24 + "||" + str;
- }
- if (array3 != null && array3.Length > 3)
- {
- if (array3[3] != "0.0")
- {
- double.TryParse(array3[3], out this.double_2);
- }
- if (array3.Length > 4)
- {
- bool.TryParse(array3[4], out flag5);
- }
- if (array3.Length > 5)
- {
- num = Conversion.Val(array3[5].Trim());
- if (num <= 0.0)
- {
- num = 0.0;
- }
- if (array3[5].Trim().Length > 1)
- {
- if (num > 0.0)
- {
- this.method_30("PTFare:" + num);
- }
- else
- {
- MessageBox.Show("Unable to set Fare limit.", "Fare Limit", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
- }
- }
- }
- }
- }
- catch
- {
- }
- string text10 = string.Concat(new object[]
- {
- "\r\n\r\nTrainNo: ",
- this.class6_0.string_2,
- " Form: ",
- this.class6_0.string_0,
- " To: ",
- this.class6_0.string_1,
- "\r\n\r\nNo. of Passengers: ",
- this.class6_0.list_0.Count,
- " Name of First Pax: ",
- this.class6_0.list_0[0].string_0
- });
- string_ = string.Concat(new string[]
- {
- "TrainNo: ",
- this.class6_0.string_2,
- " Form: ",
- this.class6_0.string_0,
- " To: ",
- this.class6_0.string_1
- });
- string_2 = "Pax: " + this.class6_0.list_0[0].string_0 + ((this.class6_0.list_0.Count <= 1) ? "" : (" and (" + (this.class6_0.list_0.Count - 1) + ") Others"));
- this.updateTStatus_0 = updtStatus;
- this.string_13 = tCntrlName;
- if (this.class6_0.string_3.ToUpper() == this.class6_0.string_1.ToUpper())
- {
- MessageBox.Show(IRComm.smethod_5(), "Boarding station can not be same as To Station!");
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(53, "Invalid Boarding Station", tCntrlName, null, null);
- }
- result = false;
- }
- else
- {
- object obj2;
- lock (obj2 = IRComm.object_4)
- {
- if (IRComm.list_2.Contains(this.class6_0.string_13))
- {
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(53, "Another Ticket is already active using this IRCTC ID.", tCntrlName, null, null);
- }
- this.method_30("Login Already Active ID = " + this.class6_0.string_13);
- result = false;
- return result;
- }
- IRComm.list_2.Add(this.class6_0.string_13);
- }
- lock (obj2 = IRComm.object_5)
- {
- if (IRComm.dictionary_1.ContainsKey(text))
- {
- Dictionary<string, int> dictionary;
- string key;
- (dictionary = IRComm.dictionary_1)[key = text] = dictionary[key] + 1;
- this.int_5 = IRComm.dictionary_1[text];
- }
- else
- {
- IRComm.dictionary_1.Add(text, 1);
- Interlocked.Increment(ref IRComm.int_2);
- this.int_5 = 1;
- }
- }
- try
- {
- this.class6_0.PhoneHash();
- this.class6_0.greq = this.class6_0.iss;
- this.class6_0.greq = "DM03AP11MS3-16b8a028-1213-4a1a-802a-75b205f44bfd";
- bool flag10 = false;
- if (IRComm.int_2 > IRComm.int_1)
- {
- MessageBox.Show(IRComm.smethod_5(), "You have already started " + IRComm.int_2 + " Ticket(s)! \r\n\r\nYou can not start more tickets at this time! \r\n\r\n If Message comes as an error, Click Start Again.", "Less Resources", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(53, IRComm.int_2.ToString() + " Tickets already started!", tCntrlName, null, null);
- }
- result = false;
- return result;
- }
- this.ConnectionGroupID = this.ClassID;
- this.bool_16 = false;
- this.method_30(string.Concat(new object[]
- {
- "Ticket Started isPair=",
- isP,
- " PairID=",
- text,
- " ActivePair=",
- IRComm.dictionary_1[text],
- " isCntrlPressed:",
- flag5
- }));
- int num2 = 0;
- if (this.class6_0.bool_0)
- {
- DateTime dateTime = new DateTime(DateTime.Now.Year, DateTime.Now.Month, DateTime.Now.Day, this.int_3, 47, 0, 0);
- TimeSpan timeSpan = new TimeSpan(dateTime.Ticks - DateTime.Now.Ticks);
- num2 = (int)timeSpan.TotalMilliseconds;
- }
- if (this.class6_0.bool_0 && num2 > 0)
- {
- if (DateTime.Now.Hour == this.int_3 && updtStatus != null)
- {
- updtStatus.BeginInvoke(1, "Waiting till " + this.int_3 + ":47 AM", tCntrlName, null, null);
- }
- this.Sleep_Thread(num2);
- }
- if (this.class6_0.bool_0 && ((DateTime.Now.Hour == this.int_4 && DateTime.Now.Minute < 10) || (DateTime.Now.Hour == this.int_3 && DateTime.Now.Minute > 45)))
- {
- this.class6_0.bool_6 = true;
- }
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(1, "Start Login...", tCntrlName, null, null);
- }
- int num3 = 0;
- if (num < 0.0)
- {
- num = 0.0;
- }
- this.webProxy_2 = null;
- this.string_8 = null;
- this.string_9 = "";
- this.string_10 = "";
- this.string_11 = "";
- this.cookieContainer_0 = new CookieContainer();
- this.webException_0 = null;
- this.method_34();
- this.bool_2 = isP;
- this.bool_10 = false;
- this.int_6 = 0;
- this.bool_4 = true;
- this.class6_0.bool_7 = true;
- string text13;
- string text15;
- string text18;
- frmPayment frmPayment2;
- Stopwatch stopwatch3;
- frmPayment frmPayment4;
- int num10;
- while (true)
- {
- num3++;
- this.method_30("Hitting Loading Home Page" + num3.ToString());
- string text11 = "https://www.irctc.co.in/eticketing/protected/mapps1/appVersion/ANDROID/2.0.9";
- string string_4 = "https://www.irctc.co.in/nget/train-search";
- string text12 = "";
- DateTime now = DateTime.Now;
- text13 = "";
- this.method_30("Staring Buffring Begin");
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(1, "Staring Buffring! ", tCntrlName, null, null);
- }
- this.class6_0.AvlThread = 0;
- text11 = string.Concat(new string[]
- {
- "https://www.irctc.co.in/eticketing/protected/mapps1/tbstns/",
- this.class6_0.string_0,
- "/",
- this.class6_0.string_1,
- "/",
- this.class6_0.jjdate.ToString("yyyMMdd"),
- "?dateSpecific=N&ftBooking=N&redemBooking=N"
- });
- text12 = "";
- if (this.ConnectWebHttp(text11, text12, string_4, "Plain13Other", false, this.webProxy_0, ref this.cookieContainer_0, true, true, 120000, 120000, ref this.string_10, ref this.string_11, ref this.webException_0))
- {
- this.dateTime_4 = DateTime.Now;
- this.timeSpan_0 = new TimeSpan(DateTime.Now.Ticks - this.dateTime_4.Ticks);
- TimeSpan timeSpan = new TimeSpan(this.dateTime_0.Ticks - DateTime.Now.Ticks);
- int num4 = (int)timeSpan.TotalMilliseconds;
- this.method_30(string.Concat(new object[]
- {
- "TmpDiff after Search for trains: tmpDiff = ",
- num4,
- " : timeDiff = ",
- this.int_6,
- " : tsTmp = ",
- this.timeSpan_0.TotalMilliseconds.ToString()
- }));
- this.int_6 = num4;
- if (this.timeSpan_0.TotalMilliseconds < 1200.0)
- {
- this.int_6 = num4;
- }
- else
- {
- int value = Math.Abs(num4) - Math.Abs(this.int_6);
- if (Math.Abs(value) >= 1000)
- {
- this.int_6 = num4;
- }
- }
- this.method_30("New TimeDiff : timeDiff = " + this.int_6);
- text3 = text3 + " diff:" + this.int_6;
- IRComm.int_Time3 = this.int_6;
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(900, this.int_6.ToString(), tCntrlName, null, null);
- }
- text11 = string.Concat(new string[]
- {
- "https://www.irctc.co.in/eticketing/protected/mapps1/avlFareenquiry/",
- this.class6_0.string_2,
- "/",
- this.class6_0.jjdate.ToString("yyyMMdd"),
- "/",
- this.class6_0.string_0,
- "/",
- this.class6_0.string_1,
- "/",
- this.class6_0.string_7,
- "/",
- this.class6_0.string_8,
- "/N"
- });
- text12 = "{\"AVLBLTY_ONLY\":\"1\",\"FARE_ONLY\":\"2\",\"FARE_AVLBLTY\":\"3\",\"enquiryType\":\"3\",\"clusterFlag\":\"N\",\"onwardFlag\":\"N\",\"cod\":false,\"reservationMode\":\"N_MOBILE_ANDROID\",\"autoUpgradationSelected\":false,\"gnToCkOpted\":false,\"ticketChoiceSameCoach\":false,\"reservationChoice\":99,\"ignoreChoiceIfWl\":true,\"concessionBooking\":false,\"generalistChildConfirm\":false,\"ftBooking\":false,\"moreThanOneDay\":true,\"ticketType\":\"E\"}";
- if (this.ConnectWebHttp(text11, text12, string_4, "Plain13json", false, this.webProxy_0, ref this.cookieContainer_0, true, true, 120000, 120000, ref this.string_10, ref this.string_11, ref this.webException_0))
- {
- while (true)
- {
- this.dateTime_3 = DateTime.Now;
- text11 = "https://www.irctc.co.in/eticketing/protected/mapps1/loginCaptcha?nlpCaptchaException=true";
- text12 = "";
- if (!this.ConnectWebHttp(text11, text12, string_4, "Plain13text", false, this.webProxy_0, ref this.cookieContainer_0, true, true, 120000, 120000, ref this.string_10, ref this.string_11, ref this.webException_0))
- {
- break;
- }
- if (this.string_10.IndexOf("captchaQuestion") > 0)
- {
- this.class6_0.method_Capt(this.string_10);
- this.class6_0.greq = Class6.jsonData_Serial(this.string_10, "status");
- }
- this.double_0 = this.double_1;
- this.image_0 = this.class6_0.image_0;
- frmCaptcha = new frmCaptcha(this, this.cookieContainer_0, this.string_7, this.string_9)
- {
- BackColor = Color.LightSteelBlue
- };
- if (flag10)
- {
- frmCaptcha.picOriginal.BackColor = Color.FromArgb(255, 192, 255, 192);
- }
- else
- {
- frmCaptcha.picOriginal.BackColor = Color.Lavender;
- }
- frmCaptcha.dateTime_0 = this.dateTime_3;
- if ((!flag && !flag3) || flag4)
- {
- frmCaptcha.lblWrongCaptcha.Text = "Enter Booking Captcha!";
- }
- else
- {
- if (flag3)
- {
- frmCaptcha.lblWrongCaptcha.Text = "Site Currently Unreachable!";
- }
- else
- {
- frmCaptcha.lblWrongCaptcha.Text = "Invalid Booking Captcha!";
- if (flag2)
- {
- frmCaptcha.lblWrongCaptcha.Text = "Early Submit Bkg Captcha!";
- }
- frmCaptcha.smethod_0(text2);
- }
- frmCaptcha.lblWrongCaptcha.ForeColor = Color.Red;
- }
- Stopwatch stopwatch = new Stopwatch();
- stopwatch.Start();
- frmCaptcha.method_0(cntrl, rect);
- if (frmCaptcha.DialogResult != DialogResult.OK)
- {
- goto Block_100;
- }
- stopwatch.Stop();
- num2 = 5000 - (int)stopwatch.ElapsedMilliseconds;
- if (num2 > 0)
- {
- Thread.Sleep(num2);
- }
- text2 = frmCaptcha.txtImageData.Text.Trim();
- this.dateTime_3 = frmCaptcha.dateTime_0;
- frmCaptcha.Dispose();
- this.method_30("Staring Login Begin");
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(1, "Login Proceed! ", tCntrlName, null, null);
- }
- text11 = "https://www.irctc.co.in/authprovider/webtoken";
- text12 = string.Concat(new string[]
- {
- "grant_type=password&username=",
- this.class6_0.string_13,
- "&password=",
- HttpUtility.UrlEncode(this.class6_0.string_14),
- "&captcha=",
- text2,
- "&uid=",
- HttpUtility.UrlEncode(this.class6_0.greq),
- "&otpLogin=false&nlpIdentifier=undefined&nlpAnswer=undefined&nlpToken=undefined"
- });
- if (!this.ConnectWebHttp(text11, text12, string_4, "Plain0Other", false, this.webProxy_0, ref this.cookieContainer_0, true, true, 120000, 120000, ref this.string_10, ref this.string_11, ref this.webException_0))
- {
- break;
- }
- if (this.string_10.IndexOf("Invalid Captcha") <= 0)
- {
- goto IL_19BA;
- }
- }
- continue;
- IL_19BA:
- this.class6_0.auth = this.string_10.Substring(this.string_10.IndexOf("access_token") + 15, 36);
- this.class6_0.bearer = "Bearer " + this.class6_0.auth;
- while (true)
- {
- this.class6_0.token = "1527614427275";
- text11 = "https://www.irctc.co.in/eticketing/protected/mapps1/validateUser?source=3";
- text12 = "";
- if (!this.ConnectWebHttp(text11, text12, string_4, "Plain123Other", false, this.webProxy_0, ref this.cookieContainer_0, true, true, 120000, 120000, ref this.string_10, ref this.string_11, ref this.webException_0))
- {
- break;
- }
- text11 = "https://www.irctc.co.in/eticketing/protected/ewallet/ewalletStatement";
- text12 = "d";
- if (!this.ConnectWebHttp(text11, text12, string_4, "Plain123json", false, this.webProxy_0, ref this.cookieContainer_0, true, true, 120000, 120000, ref this.string_10, ref this.string_11, ref this.webException_0))
- {
- break;
- }
- if (this.Errochk4_App(this.string_10, ref this.string_11))
- {
- text13 = this.string_11.Substring(this.string_11.IndexOf(":") + 1);
- if (this.string_11.Contains("GotoStart:"))
- {
- break;
- }
- if (this.string_11.Contains("GotoFinish:"))
- {
- goto Block_109;
- }
- if (text13.Contains("Unable to serve the response"))
- {
- continue;
- }
- }
- if (this.class6_0.bool_0)
- {
- DateTime dateTime = new DateTime(DateTime.Now.Year, DateTime.Now.Month, DateTime.Now.Day, this.int_4, 0, 0, 0);
- timeSpan = new TimeSpan(dateTime.Ticks - DateTime.Now.Ticks);
- num2 = (int)timeSpan.TotalMilliseconds - this.int_6;
- }
- if (array[0] == "1" || array[0] == "3")
- {
- if (!this.method_25_A())
- {
- goto Block_114;
- }
- }
- if (this.class6_0.bool_0 && num2 > 200)
- {
- if (this.class6_0.SLBooking)
- {
- num2 -= 5000;
- }
- else
- {
- num2 -= 1000;
- }
- num2 -= 300;
- Random random = new Random();
- int num5 = random.Next(2, 4) * 100;
- this.method_30("Sleeping sleep = " + num2);
- if (num2 > 0)
- {
- Thread.Sleep(num2);
- }
- this.method_30("After Sleeping ");
- Application.DoEvents();
- }
- while (true)
- {
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(1, "Selecting Trains! ", tCntrlName, null, null);
- }
- text11 = string.Concat(new string[]
- {
- "https://www.irctc.co.in/eticketing/protected/mapps1/avlFareenquiry/",
- this.class6_0.string_2,
- "/",
- this.class6_0.jjdate.ToString("yyyMMdd"),
- "/",
- this.class6_0.string_0,
- "/",
- this.class6_0.string_1,
- "/",
- this.class6_0.string_7,
- "/",
- this.class6_0.string_8,
- "/N"
- });
- text12 = "{\"AVLBLTY_ONLY\":\"1\",\"FARE_ONLY\":\"2\",\"FARE_AVLBLTY\":\"3\",\"enquiryType\":\"3\",\"clusterFlag\":\"N\",\"onwardFlag\":\"N\",\"cod\":false,\"reservationMode\":\"N_MOBILE_ANDROID\",\"autoUpgradationSelected\":false,\"gnToCkOpted\":false,\"ticketChoiceSameCoach\":false,\"reservationChoice\":99,\"ignoreChoiceIfWl\":true,\"concessionBooking\":false,\"generalistChildConfirm\":false,\"ftBooking\":false,\"loyaltyRedemptionBooking\":false,\"moreThanOneDay\":false,\"ticketType\":\"E\"}";
- if (!this.ConnectWebHttp(text11, text12, string_4, "Plain123json", false, this.webProxy_0, ref this.cookieContainer_0, true, true, 120000, 120000, ref this.string_10, ref this.string_11, ref this.webException_0))
- {
- goto Block_120;
- }
- if (string.IsNullOrEmpty(this.string_10))
- {
- break;
- }
- if (this.Errochk4_App(this.string_10, ref this.string_11))
- {
- text13 = this.string_11.Substring(this.string_11.IndexOf(":") + 1);
- if (this.string_11.Contains("GotoStart:"))
- {
- goto Block_123;
- }
- if (this.string_11.Contains("GotoFinish:"))
- {
- goto Block_124;
- }
- if (text13.Contains("Unable to serve the response"))
- {
- break;
- }
- }
- while (true)
- {
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(1, "Receving Bkg Captcha! ", tCntrlName, null, null);
- }
- text11 = string.Concat(new string[]
- {
- "https://www.irctc.co.in/eticketing/protected/mapps1/boardingstationenquiry/",
- this.class6_0.string_2,
- "/",
- this.class6_0.jjdate.ToString("yyyMMdd"),
- "/",
- this.class6_0.string_0,
- "/",
- this.class6_0.string_1,
- "/",
- this.class6_0.string_7,
- "?jrnQuota=",
- this.class6_0.string_8
- });
- text12 = "";
- if (!this.ConnectWebHttp(text11, text12, string_4, "Plain123json", false, this.webProxy_0, ref this.cookieContainer_0, true, true, 120000, 120000, ref this.string_10, ref this.string_11, ref this.webException_0))
- {
- goto Block_127;
- }
- if (string.IsNullOrEmpty(this.string_10))
- {
- goto Block_128;
- }
- if (this.Errochk4_App(this.string_10, ref this.string_11))
- {
- text13 = this.string_11.Substring(this.string_11.IndexOf(":") + 1);
- if (this.string_11.Contains("GotoStart:"))
- {
- goto Block_130;
- }
- if (this.string_11.Contains("GotoFinish:"))
- {
- goto Block_131;
- }
- if (text13.Contains("Booking not allowed. Please try again"))
- {
- break;
- }
- if (text13.Contains("Unable to serve the response"))
- {
- goto Block_133;
- }
- }
- this.dateTime_3 = DateTime.Now;
- this.double_0 = this.double_2;
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(1, "Wait 4 Submitting! ", tCntrlName, null, null);
- }
- while (true)
- {
- if (this.string_10.IndexOf("captchaQuestion") > 0)
- {
- this.class6_0.method_Capt(this.string_10);
- }
- this.image_0 = this.class6_0.image_0;
- frmCaptcha = new frmCaptcha(this, this.cookieContainer_0, this.string_7, this.string_9)
- {
- BackColor = Color.LightSteelBlue
- };
- if (flag10)
- {
- frmCaptcha.picOriginal.BackColor = Color.FromArgb(255, 192, 255, 192);
- }
- else
- {
- frmCaptcha.picOriginal.BackColor = Color.Lavender;
- }
- frmCaptcha.dateTime_0 = this.dateTime_3;
- if ((!flag && !flag3) || flag4)
- {
- frmCaptcha.lblWrongCaptcha.Text = "Enter Booking Captcha!";
- }
- else
- {
- if (flag3)
- {
- frmCaptcha.lblWrongCaptcha.Text = "Site Currently Unreachable!";
- }
- else
- {
- frmCaptcha.lblWrongCaptcha.Text = "Invalid Booking Captcha!";
- if (flag2)
- {
- frmCaptcha.lblWrongCaptcha.Text = "Early Submit Bkg Captcha!";
- }
- frmCaptcha.smethod_0(text2);
- }
- frmCaptcha.lblWrongCaptcha.ForeColor = Color.Red;
- }
- Stopwatch stopwatch3 = new Stopwatch();
- stopwatch3.Start();
- frmCaptcha.method_0(cntrl, rect);
- if (frmCaptcha.DialogResult != DialogResult.OK)
- {
- goto Block_141;
- }
- stopwatch3.Stop();
- num2 = 5000 - (int)stopwatch3.ElapsedMilliseconds;
- if (num2 > 0)
- {
- Thread.Sleep(num2);
- }
- text2 = frmCaptcha.txtImageData.Text.Trim();
- this.dateTime_3 = frmCaptcha.dateTime_0;
- frmCaptcha.Dispose();
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(1, "Passenger Validation! ", tCntrlName, null, null);
- }
- this.method_30("Passenger Validation Begin");
- text11 = string.Concat(new string[]
- {
- "https://www.irctc.co.in/eticketing/protected/mapps1/avlFareenquiry/",
- this.class6_0.string_2,
- "/",
- this.class6_0.jjdate.ToString("yyyMMdd"),
- "/",
- this.class6_0.string_0,
- "/",
- this.class6_0.string_1,
- "/",
- this.class6_0.string_7,
- "/",
- this.class6_0.string_8,
- "/Y"
- });
- text12 = this.class6_0.Pax_2(this.string_10, text2);
- if (!this.ConnectWebHttp(text11, text12, string_4, "Plain123json", false, this.webProxy_0, ref this.cookieContainer_0, true, true, 120000, 120000, ref this.string_10, ref this.string_11, ref this.webException_0))
- {
- goto Block_144;
- }
- if (string.IsNullOrEmpty(this.string_10))
- {
- goto Block_145;
- }
- if (this.string_10.IndexOf("Invalid Captcha") <= 0)
- {
- break;
- }
- this.double_0 = this.double_1;
- }
- text3 = string.Concat(new object[]
- {
- text3,
- " ",
- this.class6_0.string_8,
- " P:",
- this.int_5,
- " Log:",
- DateTime.Now.ToString("HH:mm:ss")
- });
- if (this.Errochk4_App(this.string_10, ref this.string_11))
- {
- text13 = this.string_11.Substring(this.string_11.IndexOf(":") + 1);
- if (this.string_11.Contains("GotoStart:"))
- {
- goto Block_148;
- }
- if (this.string_11.Contains("GotoFinish:"))
- {
- goto Block_149;
- }
- if (text13.Contains("Unable to serve the response"))
- {
- goto Block_150;
- }
- }
- if (this.string_10.IndexOf("bankDetailDTO") >= 0)
- {
- IRComm.bool_13 = true;
- string text14 = "";
- text15 = "";
- string text16 = "";
- flag = false;
- flag2 = false;
- flag3 = false;
- flag4 = false;
- this.method_30("Received Booking Captcha : " + text2);
- text3 = text3 + "-" + DateTime.Now.ToString("mm:ss");
- IAsyncResult asyncResult = null;
- Delegate1 @delegate = null;
- try
- {
- if (@delegate != null && asyncResult != null)
- {
- @delegate.EndInvoke(asyncResult);
- }
- }
- catch
- {
- }
- while (true)
- {
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(1, "Details Submitted! ", tCntrlName, null, null);
- }
- this.class6_0.fare = Class6.jsonData_Serial(this.string_10, "totalCollectibleAmount");
- text14 = this.class6_0.fare;
- bool flag11 = false;
- string text17 = "";
- text18 = "";
- string text19 = "";
- string text20 = "";
- bool flag12 = false;
- text10 = "\r\n\r\nFare: " + text14 + text10;
- if (num > 0.0)
- {
- this.method_30(string.Concat(new object[]
- {
- "PT Fare:",
- num,
- " Fare:",
- text14
- }));
- double num6 = Conversion.Val(text14.Trim());
- if (num6 > 0.0)
- {
- if (num6 > num)
- {
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(53, "Fare is higher then set limit", tCntrlName, null, null);
- }
- this.method_30("PT Fare higher");
- isConfirmReq = true;
- flag6 = true;
- }
- }
- else
- {
- isConfirmReq = true;
- }
- }
- if (this.class6_0.bool_3 && text15.ToUpper().Contains("WL"))
- {
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(253, "Train Has Gone Into Waiting", tCntrlName, null, null);
- }
- frmPayment frmPayment = new frmPayment
- {
- string_1 = this.class6_0.string_23,
- bool_7 = true,
- string_0 = string.Concat(new string[]
- {
- "Seat Are: ",
- text15,
- "\r\nFare Is: ",
- text14,
- "\r\nTime Was: ",
- text16
- })
- };
- frmPayment.method_0(cntrl, rect);
- DialogResult dialogResult2 = frmPayment.DialogResult;
- frmPayment.Dispose();
- if (dialogResult2 == DialogResult.Cancel)
- {
- goto Block_161;
- }
- this.class6_0.string_23 = ((ComboBox)control.Controls["lblGateway"]).SelectedItem.ToString();
- Class5 @class = new Class5();
- @class.method_3(this.string_17);
- this.class6_0.string_24 = @class.dictionary_3[this.class6_0.string_23];
- ((ComboBox)control.Controls["lblGateway"]).Enabled = false;
- }
- if (this.class6_0.string_23.Contains("_"))
- {
- string text21 = this.class6_0.string_23.Substring(this.class6_0.string_23.IndexOf("_") + 1).Trim();
- text18 = this.class6_0.string_23.Substring(0, this.class6_0.string_23.IndexOf("_")).Trim();
- if (text21.Contains("__"))
- {
- text18 = text18 + "_" + text21.Substring(0, text21.IndexOf("__")).Trim();
- text21 = text21.Substring(text21.IndexOf("__") + 2).Trim();
- if (text21.Contains("_"))
- {
- text18 = text18 + "__" + text21.Substring(0, text21.IndexOf("_")).Trim();
- text19 = text18;
- }
- }
- else if (text21.Contains("_"))
- {
- text18 = text18 + "_" + text21.Substring(0, text21.IndexOf("_")).Trim();
- text19 = text18;
- }
- else
- {
- text19 = text18;
- }
- text17 = Class4.smethod_13(text18, ref flag11);
- this.method_30("Received Bank ID : bankID = " + text17);
- if (text17.Length <= 0)
- {
- goto Block_166;
- }
- }
- this.method_30("Checking Bank ID Existence");
- bool flag13 = false;
- lock (obj2 = IRComm.object_6)
- {
- if (IRComm.list_3.Contains(strName))
- {
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(1, "Another Ticket already Proceed.", tCntrlName, null, null);
- }
- flag13 = false;
- }
- else
- {
- IRComm.list_3.Add(strName);
- flag13 = true;
- }
- }
- if (!flag13 && !flag12)
- {
- this.method_30("Another Ticket already Procced. Name = " + strName);
- frmPayment2 = new frmPayment
- {
- string_1 = this.class6_0.string_23,
- bool_3 = true,
- string_6 = "Rs." + text14 + " - " + text15
- };
- frmPayment2.method_0(cntrl, rect);
- if (frmPayment2.DialogResult != DialogResult.OK)
- {
- goto Block_170;
- }
- this.method_30("User Accepted Proceed choice");
- if (frmPayment2.string_1 != this.class6_0.string_23)
- {
- this.class6_0.string_24 = frmPayment2.string_2;
- this.class6_0.string_23 = frmPayment2.string_1;
- frmPayment2.Dispose();
- this.method_30("New Bank details set, re-hitting " + this.class6_0.string_23);
- flag12 = true;
- continue;
- }
- }
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(1, text15 + " - Trying for Payment! ", tCntrlName, null, null);
- }
- this.string_9 = this.string_7;
- this.string_8 = "";
- this.method_30("Hitting Make Payment: inp = " + this.string_7);
- text3 = text3 + " Pmt:" + DateTime.Now.ToString("mm:ss");
- Stopwatch stopwatch2 = new Stopwatch();
- stopwatch2.Start();
- DateTime d = DateTime.Now.AddMilliseconds(100.0);
- this.class6_0.App_BankId = "";
- string_4 = text11;
- text11 = "https://www.irctc.co.in/eticketing/protected/mapps1/bookingInitPayment/" + this.class6_0.cid;
- text12 = string.Concat(new string[]
- {
- "{\"bankId\":\"",
- text17,
- "\",\"txnType\":1,\"paramList\":[],\"amount\":\"",
- this.class6_0.fare,
- "\",\"transationId\":0,\"txnStatus\":1}"
- });
- if (!this.ConnectWebHttp(text11, text12, string_4, "Plain123json", false, this.webProxy_0, ref this.cookieContainer_0, true, true, 120000, 120000, ref this.string_10, ref this.string_11, ref this.webException_0))
- {
- goto Block_172;
- }
- if (string.IsNullOrEmpty(this.string_10))
- {
- goto Block_173;
- }
- if (this.Errochk4_App(this.string_10, ref this.string_11))
- {
- text13 = this.string_11.Substring(this.string_11.IndexOf(":") + 1);
- if (this.string_11.Contains("GotoStart:"))
- {
- goto Block_175;
- }
- if (this.string_11.Contains("GotoFinish:"))
- {
- goto Block_176;
- }
- if (text13.Contains("Unable to serve the response"))
- {
- goto Block_177;
- }
- }
- if (this.string_10.IndexOf("{\"key\":\"REDIRECT\",\"value\":\"TRUE\"}") < 0)
- {
- break;
- }
- string_4 = "https://www.irctc.co.in/nget/paymentredirect";
- text11 = "https://www.irctc.co.in/eticketing/PaymentRedirect";
- text12 = string.Concat(new string[]
- {
- "token=",
- this.class6_0.auth,
- "&txn=",
- this.class6_0.string_13,
- "%3A",
- this.class6_0.cid
- });
- if (!this.ConnectWebHttp(text11, text12, string_4, "Other", false, this.webProxy_0, ref this.cookieContainer_0, true, true, 120000, 120000, ref this.string_10, ref this.string_11, ref this.webException_0))
- {
- goto Block_179;
- }
- if (string.IsNullOrEmpty(this.string_10))
- {
- goto Block_180;
- }
- this.class6_0.string_588 = this.class6_0.string_58;
- this.class6_0.startTime = new DateTime(DateTime.Now.Year, DateTime.Now.Month, DateTime.Now.Day, DateTime.Now.Hour, DateTime.Now.Minute, DateTime.Now.Second);
- stopwatch2.Stop();
- d = DateTime.Now.AddMilliseconds(-60.0);
- bool flag15 = false;
- this.class6_0.ReBank = true;
- this.method_30("Output Make Payment: Htm = \r\n\r\n" + this.string_10);
- if (!this.string_10.Contains("Payment Redirect") || !this.string_10.Contains("Please Wait..."))
- {
- goto IL_2F57;
- }
- string text22 = text3;
- text3 = string.Concat(new string[]
- {
- text22,
- " PmtRet:",
- DateTime.Now.ToString("mm:ss"),
- "-",
- text18
- });
- flag = false;
- stopwatch3 = new Stopwatch();
- if (isConfirmReq)
- {
- frmPayment frmPayment3 = new frmPayment
- {
- bool_1 = true,
- bool_4 = flag6,
- string_3 = string_,
- string_4 = string_2,
- string_1 = this.class6_0.string_23,
- string_5 = "Bank: " + this.class6_0.string_23,
- string_6 = "Rs." + text14 + " - " + text15,
- string_7 = "Fare Limit: Rs." + num + "/-"
- };
- frmPayment3.method_0(cntrl, rect);
- DialogResult dialogResult3 = frmPayment3.DialogResult;
- frmPayment3.Dispose();
- if (dialogResult3 != DialogResult.OK)
- {
- goto Block_185;
- }
- isConfirmReq = false;
- }
- lock (obj2 = IRComm.object_8)
- {
- if (IRComm.list_5.Contains(strName))
- {
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(101, "PNR Booked in another Pair", tCntrlName, null, null);
- }
- result = false;
- return result;
- }
- }
- text3 = text3 + " BNK:" + DateTime.Now.ToString("mm:ss");
- this.webProxy_2 = null;
- if (this.class6_0.string_13.ToUpper() == this.string_19.ToUpper())
- {
- this.webProxy_2 = this.webProxy_0;
- }
- stopwatch3.Start();
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(1, "Processing " + text18 + " for Payment! ", tCntrlName, null, null);
- }
- text22 = text17.ToUpper().Trim();
- if (text22 != null)
- {
- string text23 = text22;
- switch (text23)
- {
- case "3":
- flag15 = this.method_45(this.string_10, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "69":
- flag15 = this.method_66(this.string_10, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "9":
- flag15 = this.method_62(this.string_10, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "19":
- flag15 = this.method_63(this.string_10, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "41":
- flag15 = this.method_43(this.string_10, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "57":
- flag15 = this.method_52(this.string_10, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "16":
- flag15 = this.method_69(this.string_10, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "15":
- flag15 = this.method_58(this.string_10, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "5":
- flag15 = this.method_81(this.string_10, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "66":
- flag15 = this.method_59(this.string_10, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "26":
- flag15 = this.method_61(this.string_10, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "31":
- flag15 = this.method_64(this.string_10, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "30":
- flag15 = this.method_74(this.string_10, this.class6_0.string_24, text18, text10, ref text20, ref text13, updtStatus);
- break;
- case "4":
- flag15 = this.method_73(this.string_10, this.class6_0.string_24, text18, text10, ref text20, ref text13, updtStatus);
- break;
- case "21":
- flag15 = this.method_83(this.string_10, this.class6_0.string_24, text18, text10, ref text20, ref text13, updtStatus);
- break;
- case "17":
- flag15 = this.method_79_2(this.string_10, this.class6_0.string_24, text18, text10, ref text20, ref text13, updtStatus);
- break;
- case "78":
- case "71":
- flag15 = this.method_78(this.string_10, this.class6_0.string_24, text18, text10, ref text20, ref text13, updtStatus);
- break;
- case "44":
- flag15 = this.method_55(this.string_10, this.class6_0.string_23, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "36":
- flag15 = this.method_51(this.string_10, this.class6_0.string_23, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "39":
- flag15 = this.method_42(this.string_10, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "52":
- flag15 = this.method_57(this.string_10, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "28":
- flag15 = this.method_70(this.string_10, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "45":
- flag15 = this.method_60(this.string_10, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "56":
- flag15 = this.method_71(this.string_10, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "60":
- flag15 = this.method_65(this.string_10, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "38":
- flag15 = this.method_56(this.string_10, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "64":
- flag15 = this.method_82(this.string_10, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "68":
- flag15 = this.method_67(this.string_10, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "79":
- flag15 = this.method_68(this.string_10, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "1":
- {
- CookieContainer cookieContainer = null;
- if (!(flag15 = this.method_48(this.string_10, this.class6_0.string_23, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus, ref cookieContainer)) && cookieContainer != null)
- {
- ThreadPool.QueueUserWorkItem(new WaitCallback(this.method_47), cookieContainer);
- }
- break;
- }
- case "94":
- flag15 = this.method_103(this.string_10, this.class6_0.string_23, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "55":
- flag15 = this.method_107(this.string_10, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "93":
- flag15 = this.Cash_AirtelMoney(this.string_10, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- case "97":
- flag15 = this.Bhim_UpIMoney(this.string_10, this.class6_0.string_24, text10, ref text20, ref text13, updtStatus);
- break;
- }
- }
- if (!flag15)
- {
- goto Block_196;
- }
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(1, "Payment Successful! ", tCntrlName, null, null);
- }
- this.string_9 = text13;
- text3 = text3 + " BNK-Ret:" + DateTime.Now.ToString("mm:ss");
- stopwatch3.Stop();
- this.method_29(string.Concat(new object[]
- {
- text18,
- flag11 ? "_Debit" : "_NB",
- "~1~",
- stopwatch3.ElapsedMilliseconds,
- "~",
- array[0]
- }));
- this.class6_0.method_11(true, "Payment Success", text14, "", this.ClassID);
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(1, "Redirect to Irctc.! ", tCntrlName, null, null);
- }
- if (text17 == "0")
- {
- frmCaptcha = new frmCaptcha(this, this.cookieContainer_0, "https://www.irctc.co.in/eticketing/captchaImage", this.string_9)
- {
- bool_2 = true
- };
- frmCaptcha.picOriginal.BackColor = Color.Goldenrod;
- if (!flag)
- {
- frmCaptcha.lblWrongCaptcha.Text = "AFTER PAYMENT CAPTCHA!";
- }
- else
- {
- frmCaptcha.lblWrongCaptcha.Text = "INVALID PAYMENT CAPTCHA!";
- }
- text2 = frmCaptcha.Captchaa_Nget();
- flag = false;
- frmCaptcha.Dispose();
- this.method_30("Received after payment Captcha : " + text2);
- this.string_27 = "https://www.irctc.co.in/eticketing/eWalletPaymentCnf.jsf?cid=1";
- this.string_28 = "eWalletPmtCnf=eWalletPmtCnf&j_captcha=" + text2 + "&eWalletPmtCnf%3AmakePmntModeId1=&javax.faces.ViewState=" + Class6.smethod_3(this.string_10, "", "javax.faces.ViewState");
- }
- else if (text20.IndexOf("https://www.irctc.co.in") == 0)
- {
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(1, "Wait 4 PNR_Flush! ", tCntrlName, null, null);
- }
- this.string_27 = text20;
- }
- else
- {
- this.string_27 = "https://www.irctc.co.in/eticketing/BankResponse";
- this.string_28 = this.class6_0.Method_SerialInp(text20, ref this.string_27, true);
- if (this.string_28 != "")
- {
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(1, "Wait 4 PNR_Flush! ", tCntrlName, null, null);
- }
- }
- }
- if (this.string_27.IndexOf("https://www.irctc.co.in/eticketing/BankResponse") < 0)
- {
- this.string_27 = "https://www.irctc.co.in/eticketing/BankResponse";
- }
- if (!this.ConnectWebHttp(this.string_27, this.string_28, this.string_29, "Other", false, this.webProxy_0, ref this.cookieContainer_0, true, true, 120000, 120000, ref this.string_10, ref this.string_11, ref this.webException_0))
- {
- goto Block_217;
- }
- this.class6_0.Bnkerror = 0;
- lock (obj2 = IRComm.object_8)
- {
- if (IRComm.list_5.Contains(strName))
- {
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(101, "PNR Booked in another Pair", tCntrlName, null, null);
- }
- result = false;
- return result;
- }
- }
- flag7 = false;
- lock (obj2 = IRComm.object_7)
- {
- if (IRComm.list_4.Contains(strName))
- {
- flag7 = true;
- isConfirmReq = true;
- }
- else
- {
- IRComm.list_4.Add(strName);
- }
- }
- try
- {
- string a;
- if (IRComm.dictionary_2.TryGetValue(tCntrlName, out a))
- {
- isConfirmReq = (a == "true");
- }
- goto IL_440E;
- }
- catch
- {
- goto IL_440E;
- }
- goto IL_3F62;
- IL_423D:
- lock (IRComm.object_7)
- {
- if (IRComm.list_4.Contains(strName))
- {
- IRComm.list_4.Remove(strName);
- }
- }
- string text24 = this.method_23(this.string_10);
- this.method_30("Choosing Another payment Option for Booking. Err = " + text24);
- if (!string.IsNullOrEmpty(this.class6_0.string_244))
- {
- this.class6_0.string_23 = this.class6_0.string_233;
- this.class6_0.string_24 = this.class6_0.string_244;
- this.class6_0.string_244 = "";
- flag12 = true;
- continue;
- }
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(1, "Choose another Payment.", tCntrlName, null, null);
- }
- frmPayment4 = new frmPayment();
- frmPayment4.string_1 = this.class6_0.string_23;
- if (!flag15 && text13.Length > 0)
- {
- frmPayment4.string_8 = text13;
- frmPayment4.lblError.Font = new Font("Microsoft Sans Serif", 9f);
- }
- else if (!string.IsNullOrEmpty(text24) && text24.Length > 1)
- {
- frmPayment4.string_8 = text24;
- }
- frmPayment4.method_0(cntrl, rect);
- if (frmPayment4.DialogResult != DialogResult.OK)
- {
- goto Block_237;
- }
- this.class6_0.string_24 = frmPayment4.string_2;
- this.class6_0.string_23 = frmPayment4.string_1;
- frmPayment4.Dispose();
- flag12 = true;
- this.method_30("New Bank details set, re-hitting " + this.class6_0.string_23);
- continue;
- IL_402C:
- int num8 = 10550 + new Random().Next(2, 5) * 100;
- timeSpan = DateTime.Now - d;
- int num9 = num8 - (int)timeSpan.TotalMilliseconds;
- if (num9 > 50)
- {
- Thread.Sleep(num9);
- }
- text22 = text3;
- text3 = string.Concat(new string[]
- {
- text22,
- " IR-Hit:",
- DateTime.Now.ToString("mm:ss"),
- "-",
- text18
- });
- this.method_30("Booking Hit after Payment : Inp = " + this.string_8);
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(1, "Flushing PNR Number.!", tCntrlName, null, null);
- }
- string_4 = text11;
- text11 = "https://www.irctc.co.in/eticketing/protected/mapps1/bookingData/" + this.class6_0.cid;
- text12 = "";
- if (!this.ConnectWebHttp(text11, text12, string_4, "Plain123json", false, this.webProxy_0, ref this.cookieContainer_0, true, true, 120000, 120000, ref this.string_10, ref this.string_11, ref this.webException_0))
- {
- goto Block_226;
- }
- this.method_30("Booking Output after Payment : htm = " + this.string_10);
- num10 = this.string_10.IndexOf("pnrNumber", StringComparison.CurrentCultureIgnoreCase);
- if (num10 > 0)
- {
- goto Block_227;
- }
- if (this.string_10.IndexOf("Choice of Confirm berths not met", StringComparison.CurrentCultureIgnoreCase) > 0)
- {
- goto Block_228;
- }
- if (!this.string_10.Contains("Invalid OTP"))
- {
- Thread.Sleep(2000);
- flag = true;
- goto IL_423D;
- }
- string text25 = Interaction.InputBox("Enter Correct OTP Of Mobikwik That Recive on Your Mobile no.", "Mobikwik OTP", "", cntrl.PointToScreen(rect.Location).X, cntrl.PointToScreen(rect.Location).Y).Trim();
- IL_3F62:
- if (!flag7)
- {
- if (text12 == "error")
- {
- this.class6_0.ReBank = true;
- goto IL_423D;
- }
- goto IL_402C;
- }
- IL_3F97:
- frmPayment frmPayment5 = new frmPayment();
- frmPayment5.bool_2 = true;
- frmPayment5.string_3 = string_;
- frmPayment5.string_4 = string_2;
- frmPayment5.string_1 = this.class6_0.string_23;
- frmPayment5.string_5 = "Bank: " + this.class6_0.string_23;
- frmPayment5.string_6 = "Rs." + text14 + " - " + text15;
- frmPayment5.method_0(cntrl, rect);
- DialogResult dialogResult = frmPayment5.DialogResult;
- frmPayment5.Dispose();
- if (dialogResult != DialogResult.OK)
- {
- goto Block_223;
- }
- goto IL_402C;
- IL_440E:
- if (isConfirmReq)
- {
- goto IL_3F97;
- }
- goto IL_3F62;
- }
- }
- }
- }
- Block_128:
- Block_133:
- Block_145:
- Block_150:
- Block_173:
- Block_177:
- Block_180:;
- }
- Block_120:
- Block_123:
- Block_127:
- Block_130:
- Block_144:
- Block_148:
- Block_172:
- Block_175:
- Block_179:
- Block_217:
- Block_226:;
- }
- }
- }
- Block_100:
- goto IL_47E6;
- Block_109:
- goto IL_4911;
- Block_114:
- this.method_31("PerformB.keepSessionActive", "keepSessionActive Returned -1");
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(53, "Request Failed.", tCntrlName, null, null);
- }
- result = false;
- return result;
- Block_124:
- Block_131:
- goto IL_4911;
- Block_141:
- goto IL_47E6;
- Block_149:
- goto IL_4911;
- Block_161:
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(53, "Availability: " + text15 + ", Ticket Stopped!", tCntrlName, null, null);
- }
- this.method_30("Confirm Only but Availability is: " + text15 + " Ticket Stopped.");
- result = false;
- return result;
- Block_166:
- this.method_30("Bank ID Not Found, Returning.");
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(53, "Technical Issue while Making Payment.", tCntrlName, null, null);
- }
- result = false;
- return result;
- Block_170:
- this.method_30("User Cancelled Proceed choice");
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(101, "Another Ticket already Proceed.! ", tCntrlName, null, null);
- }
- frmPayment2.Dispose();
- result = false;
- return result;
- Block_176:
- goto IL_4911;
- IL_2F57:
- string text26 = "Request Failed at Make Payment!";
- this.method_30("Return Make Payment : strErr = " + text26);
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(53, text26, tCntrlName, null, null);
- }
- result = false;
- return result;
- Block_185:
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(53, "User Select to Stop Payment! ", tCntrlName, null, null);
- }
- this.method_30("User Select to Stop Payment!");
- result = false;
- return result;
- Block_196:
- stopwatch3.Stop();
- if (stopwatch3.ElapsedMilliseconds > 800L)
- {
- bool flag11;
- this.method_29(string.Concat(new object[]
- {
- text18,
- flag11 ? "_Debit" : "_NB",
- "~0~",
- stopwatch3.ElapsedMilliseconds,
- "~",
- array[0]
- }));
- }
- this.method_30(text18 + " Failed : strErr = " + text13);
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(1, text13, tCntrlName, null, null);
- }
- string str2 = text18 + "_Fail: strErr_ " + text13;
- if (!text13.Contains("Invaild Bank's Details") && !text13.Contains("Clear Balance Funds not available") && !text13.Contains("Invaild Card's Details") && !text13.Contains("Payment Not Captured") && !text13.Contains("OTP Cancelled by User"))
- {
- if (!IRComm.list_7.Contains(text18 + "_Fail"))
- {
- if (updtStatus != null)
- {
- IRComm.list_7.Add(text18 + "_Fail");
- ThreadPool.QueueUserWorkItem(new WaitCallback(this.smethod_11), this.ClassID);
- updtStatus.BeginInvoke(3, str2 + "|" + this.ClassID, tCntrlName, null, null);
- }
- }
- }
- goto IL_4911;
- Block_223:
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(53, "User Select to Stop Booking! ", tCntrlName, null, null);
- }
- this.method_30("User Select to Stop Booking!");
- result = false;
- return result;
- Block_227:
- lock (IRComm.object_8)
- {
- if (!IRComm.list_5.Contains(strName))
- {
- IRComm.list_5.Add(strName);
- }
- }
- text3 = text3 + " IR-Ret:" + DateTime.Now.ToString("mm:ss");
- int num11 = this.string_10.IndexOf("pnrNumber", num10);
- if (num11 > 0)
- {
- string text27 = Class6.jsonData_Serial(this.string_10, "pnrNumber");
- string text28 = Class6.jsonData_Serial(this.string_10, "timeStamp");
- text28 = text28.Substring(text28.IndexOf("T") + 1, 8);
- string text29 = text28;
- string text14;
- this.class6_0.method_11(false, "Booking Success", text14, text27, this.ClassID);
- string text30 = text27 + "_";
- this.method_30("PNR Booking PNR : " + text27 + " - " + text28);
- bool flag11;
- string[] values = new string[]
- {
- text27,
- " - ",
- text18,
- flag11 ? "_Debit" : "_NB",
- " - ",
- this.class6_0.string_2,
- " - ",
- (this.double_0 / 1000.0).ToString(),
- " - ",
- text3
- };
- txnID = string.Concat(values);
- if (IRComm.bool_0)
- {
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(5, "OPEN PNR: " + text27.Substring(0, 5) + "XXXXX", tCntrlName, null, null);
- }
- }
- else if (updtStatus != null)
- {
- updtStatus.BeginInvoke(5, "PNR: " + text27.Substring(0, 5) + "XXXXX", tCntrlName, null, null);
- }
- string text19;
- string text31 = string.Concat(new string[]
- {
- text27,
- "|",
- text29,
- "|",
- text19,
- "|ABS|",
- this.class6_0.string_0,
- "-",
- this.class6_0.string_1,
- "-",
- this.class6_0.string_2,
- "-",
- this.class6_0.string_8,
- text5,
- "|",
- this.LogInSite
- });
- this.ResultSubmit(text31);
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(4, text31, tCntrlName, null, null);
- }
- }
- else
- {
- this.method_30("Ticket Booked Successfully");
- txnID = "BOOKED";
- string text14;
- this.class6_0.method_11(false, "Booking Success", text14, "", this.ClassID);
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(5, "Ticket Booked Successfully", tCntrlName, null, null);
- }
- }
- if (this.class6_0.string_26 != "" & !this.class6_0.RtrnJrny)
- {
- DialogResult dialogResult4 = MessageBox.Show("You Have Save Return Journey Detail! Do you want to Book Return Ticket?", "Return Ticket", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (dialogResult4 == DialogResult.Yes)
- {
- this.SwipeJourneyDetail();
- this.class6_0.RtrnJrny = true;
- }
- }
- try
- {
- }
- catch
- {
- }
- result = true;
- return result;
- Block_228:
- text13 = "Choice of Confirm berths not met";
- goto IL_4911;
- Block_237:
- this.method_30("User Cancelled Another payment choice");
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(53, "Paymnent Choice Cancelled by User! " + this.string_11, tCntrlName, null, null);
- }
- frmPayment4.Dispose();
- result = false;
- return result;
- IL_47E6:
- this.method_30("User Cancelled Booking Captcha");
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(53, "Booking Captcha Cancelled by User! ", tCntrlName, null, null);
- }
- frmCaptcha.Dispose();
- result = false;
- return result;
- IL_4911:
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(53, text13, tCntrlName, null, null);
- }
- result = false;
- return result;
- }
- catch (Exception ex2)
- {
- if (updtStatus != null)
- {
- updtStatus.BeginInvoke(53, "Send Log, Unexpected Error Occured! ", tCntrlName, null, null);
- }
- this.method_31("PerformB:OuterCatch", ex2.Message);
- }
- finally
- {
- if (this.cookieContainer_0 != null)
- {
- ThreadPool.QueueUserWorkItem(new WaitCallback(this.method_8A), false);
- }
- try
- {
- ServicePointManager.FindServicePoint(new Uri("https://www.irctc.co.in")).CloseConnectionGroup(this.ConnectionGroupID);
- if (this.class6_0 != null && this.bool_15)
- {
- string text32 = this.class6_0.string_23.Substring(0, this.class6_0.string_23.IndexOf('_')).Trim();
- bool bool_ = this.class6_0.string_23.ToUpper().Contains("_DC");
- if (this.class6_0.string_23.ToUpper().Contains("_CC"))
- {
- text32 += "_CC";
- bool_ = true;
- }
- ServicePointManager.FindServicePoint(new Uri(this.method_18(text32, bool_))).CloseConnectionGroup(this.ConnectionGroupID);
- }
- }
- catch
- {
- }
- lock (obj2 = IRComm.object_4)
- {
- if (IRComm.list_2.Contains(this.class6_0.string_13))
- {
- IRComm.list_2.Remove(this.class6_0.string_13);
- }
- }
- bool flag20 = false;
- lock (obj2 = IRComm.object_5)
- {
- if (IRComm.dictionary_1.ContainsKey(text))
- {
- int num12 = IRComm.dictionary_1[text] - 1;
- if (num12 > 0)
- {
- IRComm.dictionary_1[text] = num12;
- }
- else
- {
- Interlocked.Decrement(ref IRComm.int_2);
- IRComm.dictionary_1.Remove(text);
- flag20 = true;
- }
- }
- }
- if (flag20)
- {
- lock (obj2 = IRComm.object_6)
- {
- IRComm.list_3.Remove(strName);
- }
- lock (obj2 = IRComm.object_9)
- {
- if (IRComm.list_6.Contains(strName))
- {
- IRComm.list_6.Remove(strName);
- }
- }
- if (IRComm.list_2.Count <= 0)
- {
- lock (obj2 = IRComm.object_8)
- {
- IRComm.list_5.Clear();
- }
- }
- }
- if (IRComm.waitCallback_0 == null)
- {
- IRComm.waitCallback_0 = new WaitCallback(IRComm.smethod_25);
- }
- ThreadPool.QueueUserWorkItem(IRComm.waitCallback_0);
- }
- result = false;
- }
- }
- }
- }
- return result;
- }
Add Comment
Please, Sign In to add comment