https://foro.gambas-es.org/viewtopic.php?f=15&t=4502&p=25885#p25885
-----------------------------------
v3ctor
Domingo, 19 Abril 2015, 04:58

Re: Reto 4(v3ctor) Pablo Olvido La Contraseña
-----------------------------------
mi solución: 

[code linenumbers=false syntax=gambas]' Gambas class file

'by postapase

Public Sub Form_Open()
Dim a, b, c, d As Integer
Dim ClaveEncriptada As String = "$6$R1x89rL8XKUYy$ZCkH66gRlBlgzrmPjso82AlYSVjmR2Wea0FYoq9ErJasRo2/BaNg3GskfQHT4oe93hjbvvgK5T7vN9c4H16ho/"
Dim claveES As String

  For a = 0 To 9 
    For b = 0 To 9
      For c = 0 To 9
        For d = 0 To 9
           If Crypt.Check(CStr(a & b & c & d), ClaveEncriptada) = False Then 
              claveES = CStr(a & b & c & d)
              Goto ClaveEncontrada
           Endif
           Print CStr(a & b & c & d)
        Next
      Next
    Next
  Next
  
  ClaveEncontrada:
    Print "La contraseña es=" & claveES

End[/code]


