mirror of
https://github.com/github/codeql.git
synced 2026-01-31 07:12:57 +01:00
attempting to fix autoformat build error
This commit is contained in:
@@ -1,26 +1,26 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"crypto/des"
|
||||
"crypto/md5"
|
||||
"fmt"
|
||||
)
|
||||
|
||||
func main() {
|
||||
|
||||
password := []byte("password")
|
||||
|
||||
var tripleDESKey []byte
|
||||
tripleDESKey = append(tripleDESKey, password[:16]...)
|
||||
tripleDESKey = append(tripleDESKey, password[:8]...)
|
||||
|
||||
// BAD, des is a weak crypto algorithm
|
||||
_, err := des.NewTripleDESCipher(tripleDESKey)
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
||||
// BAD, md5 is a weak crypto algorithm
|
||||
fmt.Printf("%x", md5.Sum(password))
|
||||
|
||||
}
|
||||
package main
|
||||
|
||||
import (
|
||||
"crypto/des"
|
||||
"crypto/md5"
|
||||
"fmt"
|
||||
)
|
||||
|
||||
func main() {
|
||||
|
||||
password := []byte("password")
|
||||
|
||||
var tripleDESKey []byte
|
||||
tripleDESKey = append(tripleDESKey, password[:16]...)
|
||||
tripleDESKey = append(tripleDESKey, password[:8]...)
|
||||
|
||||
// BAD, des is a weak crypto algorithm
|
||||
_, err := des.NewTripleDESCipher(tripleDESKey)
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
||||
// BAD, md5 is a weak crypto algorithm
|
||||
fmt.Printf("%x", md5.Sum(password))
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user