• ¡Welcome to Square Theme!
  • This news are in header template.
  • Please ignore this message.
مهمان عزیز خوش‌آمدید. ورود عضــویت


امتیاز موضوع:
  • 34 رای - 2.88 میانگین
  • 1
  • 2
  • 3
  • 4
  • 5
Title: vb.net AntiVm new method
حالت موضوعی
#1
this was inspired from a none functional code i reworked it and come to this.

سورس کد انتی وی ام (ماشین مجازی ) به زبان وی بی دات نت

کد:
Function VmCheck() As Boolean



    Dim str20 As String = Environment.UserName



    Dim enumerator As IEnumerator

    Dim str19 As String = "SELECT * FROM Win32_VideoController"

    Dim arguments As Object() = New Object() {str19}

    Dim copyBack As Boolean() = New Boolean() {True}

    If copyBack(0) Then

      str19 = CStr(Microsoft.VisualBasic.CompilerServices.Conversions.ChangeType(System.Runtime.CompilerServices.RuntimeHelpers.GetObjectValue(arguments(0)), GetType(String)))

    End If

    Dim objectValue As Object = System.Runtime.CompilerServices.RuntimeHelpers.GetObjectValue(Microsoft.VisualBasic.CompilerServices.NewLateBinding.LateGet(Interaction.GetObject("winmgmts:", Nothing), Nothing, "ExecQuery", arguments, Nothing, Nothing, copyBack))

    Try

      enumerator = DirectCast(objectValue, IEnumerable).GetEnumerator

      Do While enumerator.MoveNext

        Dim left As Object = Microsoft.VisualBasic.CompilerServices.NewLateBinding.LateGet(System.Runtime.CompilerServices.RuntimeHelpers.GetObjectValue(enumerator.Current), Nothing, "Description", New Object(0 - 1) {}, Nothing, Nothing, Nothing)





        If InStr(left, "VM Additions S3 Trio32/64") Then

          VmCheck = True

          MsgBox(left)

          Exit Function

        End If

        If InStr(left, "S3 Trio32/64") Then

          VmCheck = True

          MsgBox(left)

          Exit Function

        End If

        If InStr(left, "VirtualBox Graphics Adapter") Then

          VmCheck = True

          MsgBox(left)

          Continue Do

          Exit Function

        End If

        If InStr(left, "VMware SVGA II") Then

          VmCheck = True

          MsgBox(left)

          Exit Function

          Continue Do

        End If

      Loop



      VmCheck = False

      Exit Function



    Finally



      If TypeOf enumerator Is IDisposable Then

        TryCast(enumerator, IDisposable).Dispose()

      End If



    End Try







  End Function
گروه دور همی پارسی کدرز
https://t.me/joinchat/GxVRww3ykLynHFsdCvb7eg
 
پاسخ
  


پرش به انجمن:


Browsing: 1 مهمان