first commit
This commit is contained in:
@@ -0,0 +1,69 @@
|
||||
Imports System.Net
|
||||
Imports System.Net.Mail
|
||||
Imports System.Reflection.Emit
|
||||
Imports System.Security.Cryptography
|
||||
Imports System.Text
|
||||
Imports System.Windows.Forms.VisualStyles.VisualStyleElement
|
||||
Public Class Form16
|
||||
Private Sub Form16_Load(sender As Object, e As EventArgs) Handles MyBase.Load
|
||||
Gencode()
|
||||
End Sub
|
||||
Function Gencode() As Integer
|
||||
Dim NumRandom As Integer
|
||||
Dim Rand As Random = New Random
|
||||
Dim NumStr As String
|
||||
Try
|
||||
NumRandom = (Rand.Next(1, 999999))
|
||||
NumStr = Strings.Right("" & NumRandom.ToString(), 6)
|
||||
Label1.Text = "ED-" & NumStr
|
||||
mail()
|
||||
Catch ex As Exception
|
||||
|
||||
End Try
|
||||
|
||||
End Function
|
||||
|
||||
Sub mail()
|
||||
Dim maj As New WebClient
|
||||
Dim vri As String = maj.DownloadString(ipsite & "extrème downloaders/utilisateur/" & Form2.TextBox8.Text & "/mail.txt")
|
||||
Dim Resultatbytes() As Byte = Convert.FromBase64String(vri)
|
||||
Dim keyBytes() As Byte = Encoding.UTF8.GetBytes("Jj@msms7")
|
||||
Dim Crypto As New DESCryptoServiceProvider()
|
||||
Crypto.Key = keyBytes
|
||||
Crypto.IV = keyBytes
|
||||
Dim Icrypto As ICryptoTransform = Crypto.CreateDecryptor()
|
||||
Dim donné() As Byte = Icrypto.TransformFinalBlock(Resultatbytes, 0, Resultatbytes.Length)
|
||||
Dim maildecrypt = Encoding.UTF8.GetString(donné)
|
||||
|
||||
Dim t2 = Label1.Text
|
||||
Dim MyMailMessage As New MailMessage()
|
||||
Dim SMTPServer As New SmtpClient("mail51.lwspanel.com")
|
||||
Dim mail = maildecrypt
|
||||
Dim message = "le code de vérification est le: " & t2
|
||||
|
||||
MyMailMessage.From = New MailAddress("noreply@extreme-downloaders.fr")
|
||||
MyMailMessage.To.Add(mail)
|
||||
MyMailMessage.Subject = ("vérification de connection")
|
||||
MyMailMessage.Body = (message)
|
||||
|
||||
SMTPServer.Port = ("587") 'Port
|
||||
SMTPServer.Credentials = New System.Net.NetworkCredential("noreply@extreme-downloaders.fr", "yR9$sGrjZDwDMdA")
|
||||
SMTPServer.EnableSsl = True
|
||||
|
||||
SMTPServer.Send(MyMailMessage) 'Envoi
|
||||
|
||||
MsgBox("Le code de vérification" & " " & "a été envoyé a l'addresse mail", MsgBoxStyle.Information)
|
||||
End Sub
|
||||
|
||||
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
|
||||
If TextBox1.Text = Label1.Text Then
|
||||
Form2.vérification = 1
|
||||
Form2.ChromeCheckbox4.Checked = True
|
||||
Form2.co3()
|
||||
Close()
|
||||
Else
|
||||
MsgBox("la code de vérification incorecte", MsgBoxStyle.Exclamation)
|
||||
TextBox1.Clear()
|
||||
End If
|
||||
End Sub
|
||||
End Class
|
||||
Reference in New Issue
Block a user