Partial Class ShowVid Inherits System.Web.UI.Page Dim var20, var16 Dim urll Dim Namee Dim Video ' this program only operates from a device running the web program. 'Running from here will create a runtime error of "Not Found" since this program does not use a link prepared by MakeUrl. 'This program does not produce a url therefore the runtime error 'This program is designed to extract visitor information from MyBeautifulDreamer.com/showvid.aspx Protected Sub Page_Load(sender As Object, e As System.EventArgs) Handles Me.Load 'Exit Sub ' SqlDataSource1.InsertParameters("Browser").DefaultValue = ("var1") 'ip address ' Me.SqlDataSource1.Insert() Me.TextBox4.Text = "troy Glen T" Me.TextBox3.Text = "troy Glen" 'var16 = HttpContext.Current.Request.Url.AbsolutePath 'Me.TextBox1.Text = var16 'Exit Sub 'Showit() VisitorData() End Sub Public Sub VisitorData() Dim var0, var1, var2, var3, var4, var5, var6, var7, var8, var9, var10, var11, var12, var13, var14, var15, os As String Dim ttt, tt var1 = HttpContext.Current.Request.UserHostAddress 'Host Address var2 = HttpContext.Current.Request.UserHostName ' 'Host Name If var2 = "ht" Then Exit Sub ttt = var2.IndexOf(":1") If ttt > 0 Then var15 = "http://localhost:53219/MyBeautifulDreamer/ShowVid.aspx" var3 = HttpContext.Current.Request.UserAgent 'User Agent, Browser list var4 = Date.Today 'Date Time var5 = HttpContext.Current.Request.FilePath var6 = HttpContext.Current.Request.Browser.Browser 'Browser var7 = HttpContext.Current.Request.FilePath 'Filepath var8 = HttpContext.Current.Server.MachineName ' server name var9 = HttpContext.Current.Request.Browser.IsMobileDevice ' Mobile var10 = HttpContext.Current.Request.LogonUserIdentity.Name var11 = HttpContext.Current.Request.Cookies.Count var12 = HttpContext.Current.Request.IsSecureConnection var13 = HttpContext.Current.Request.Browser.ScreenPixelsWidth var14 = HttpContext.Current.Request.Browser.ScreenPixelsHeight ' var15 = HttpContext.Current.Request.Url.AbsoluteUri : var15 = Replace(var15, "..", ".") : Me.TextBoxUrll.Text = var15 : var15 = Replace(var15, "..", ".") var15 = HttpContext.Current.Request.Url.AbsoluteUri : Me.TextBoxUrll.Text = var15 : var15 = Replace(var15, "..", ".") var20 = HttpContext.Current.Request.Url.AbsoluteUri var16 = HttpContext.Current.Request.Url.AbsolutePath ' var16 = "http://www.mybeautifuldreamer.com/showvid.aspx/j= www.carolandtroy.com/phone/Home%20form%20the%20Hospital.mp4" 'var16 = "http://www.mybeautifuldreamer.com/showvid.aspx/NBTroyNE/phone/Home%20form%20the%20Hospital.mp4" 'var16 = "http:/www.ctandtt.com/showvid.aspx/NBTroyEmailNE/phone/A%20few%20pics%20of%20jake%20growing%20up_HD.mp4" 'try and get name of sender 'A test to embed the utring inside the url If InStr(var16, "NB") > 0 Then Dim t = var16.IndexOf("NB") Dim j = var16.IndexOf("/", t + 1) Dim namee = Mid(var16, t + 3, j - t - 4) '+4 is offset from j namee = Replace(namee, "NE", Nothing) Session("Namee") = namee Session("JustFileName") = System.IO.Path.GetFileName(var16) ' End If ' routine to isolate user name from url urll = var15 Dim length = Len(urll) Dim pos = InStr(urll, "mp4") Dim diff = length - pos 'Namee = Mid(urll, pos + 4, 99) urll = Mid(urll, 1, length - diff + 2) Me.TextBoxUrll.Text = urll & " " & pos & " " & length Me.TextBoxUrll.Text = Namee var15 = urll TextBox1.Text = var15 var15 = Replace(var15, "http://", Nothing) var15 = Replace(var15, "www.", Nothing) var15 = Replace(var15, "mybeautifuldreamer.com/showvid.aspx/t=", Nothing) var15 = Replace(var15, " ", "%20") var15 = Replace(var15, "http://www.mybeautifuldreamer.com/localhost:53219/MyBeautifulDreamer/ShowVid.aspx", Nothing) GoTo there If InStr(Namee, "TroyATT") > 0 Then var15 = Replace(var15, "..", ".") End If urll = var15 TextBox2.Text = var16 If InStr(var3, "Android") > 0 Then os = "Android" End If If InStr(var3, "(Windows NT 10.0; Win64; x64)") > 0 Then os = "Windows 10" End If If InStr(var3, "iPhone OS") > 0 Then os = "IPhone" End If If InStr(var3, "Pad") > 0 Then os = "Ipad" End If If InStr(var3, " (Linux; Android") > 0 Then os = "Android" End If If var9 = "True" And InStr(var3, " (Linux; Android") > 0 Then os = "Phone" End If If InStr(var3, "stagefright") > 0 Then os = "Samsung IPad" End If If InStr(var1, "66.102") > 0 Then os = "Google Crawler" End If If InStr(var1, "72.14") > 0 Then os = "Google Crawler" End If If InStr(var1, "209.85") > 0 Then os = "Google Crawler" End If If InStr(var1, "66.249") > 0 Then os = "Google Crawler" End If If InStr(var1, "74.125") > 0 Then os = "Google Crawler" End If If InStr(var1, " 216.239") > 0 Then os = "Google Crawler" End If 'var2 = "Troy Thompson" If var1 = "107.77.106.91" Then var2 = "Troy Thompson Text" If var1 = "107.77.106.91" And var6 = "Safari" Then var2 = "Carols IPhone" If var1 = "::1" Then var2 = "Dreamer" If var1 = "66.249.83.30" Then var2 = "Google Crawler(Kansas)" If var1 = "73.61.20.103" Then var2 = "Lawrence Ma" If var1 = "34.229.251.79" Then var2 = "Ashburn VA" If var1 = "58.53.128.234" Then var2 = "China" If var1 = "50.198.95.137" Then var2 = "Salem NH" There: Dim val Dim Open = "(" Dim close = ")" Dim apos = "' " Dim comma = "," val = Nothing val = val & Open '( val = val & apos '' val = val & var1 'val = val & Session("Namee") 'IP Address val = val & apos val = val & comma ', val = val & apos var15 = Replace(var15, "phone/", Nothing) var15 = Replace(var15, "%20", " ") ' val = val & var15 ' Name val = val & Session("Namee") 'IP Address val = val & apos val = val & comma val = val & apos val = val & System.DateTime.Now val = val & apos val = val & comma val = val & apos val = val & var6 'Browser val = val & apos val = val & comma val = val & apos val = val & var9 'Mobile? val = val & apos val = val & comma val = val & apos val = val & os 'Operating system val = val & apos val = val & comma val = val & apos ' name = "Troy" ' val = val & var3 'UserAgent val = val & Session("JustFileName") val = val & apos val = val & close SqlDataSource1.InsertCommand = "Insert into SingleVidIp (visitorIpAddress, VisitorName, date, browser, mobile, OS, UserAgent) Values " & val SqlDataSource1.Insert() Me.TextBoxIP.Text = var3 Me.TextBoxName.Text = var13 Me.TextBoxMobile.Text = var14 Me.TextBoxUrll.Text = Me.TextBox3.Text & " " & Me.TextBox2.Text & " " & Me.TextBox1.Text Showit() End Sub Public Sub Showit() 'Exit Sub Dim t = var16 Me.TextBox3.Text = t 'var20 t = Replace(t, "ShowVid.aspx", Nothing) t = Replace(t, "showvid.aspx", Nothing) t = Replace(t, "/T=", Nothing) t = Replace(t, "/t=", Nothing) Me.TextBox2.Text = t 'var20 Dim JustFileName = System.IO.Path.GetFileName(t) ' t = "http://www.mybeautifuldreamer.com/phone/" & JustFileName t = "http://www.ctandtt.com/phone/" & JustFileName Me.TextBox3.Text = JustFileName Me.TextBox4.Text = "troy and Carol" Response.Redirect(t) End Sub End Class