Merge branch 'fix_some_bugs' of https://github.com/Hurricanezwf/frp into Hurricanezwf-fix_some_bugs

Conflicts:
	cmd/frpc/config.go
	cmd/frpc/control.go
	cmd/frpc/main.go
	cmd/frps/config.go
	cmd/frps/control.go
	cmd/frps/main.go
	pkg/models/server.go
This commit is contained in:
fatedier
2016-02-18 11:42:31 +08:00
11 changed files with 185 additions and 68 deletions

View File

@ -6,7 +6,7 @@ import (
"testing"
)
func Test_Encrypto(t *testing.T) {
func TestEncrypto(t *testing.T) {
pp := new(Pcrypto)
pp.Init([]byte("Hana"))
res, err := pp.Encrypto([]byte("Just One Test!"))
@ -17,7 +17,7 @@ func Test_Encrypto(t *testing.T) {
fmt.Printf("[%x]\n", res)
}
func Test_Decrypto(t *testing.T) {
func TestDecrypto(t *testing.T) {
pp := new(Pcrypto)
pp.Init([]byte("Hana"))
res, err := pp.Encrypto([]byte("Just One Test!"))
@ -33,13 +33,13 @@ func Test_Decrypto(t *testing.T) {
fmt.Printf("[%s]\n", string(res))
}
func Test_PKCS7Padding(t *testing.T) {
func TestPKCS7Padding(t *testing.T) {
ltt := []byte("Test_PKCS7Padding")
ltt = PKCS7Padding(ltt, aes.BlockSize)
fmt.Printf("[%x]\n", (ltt))
}
func Test_PKCS7UnPadding(t *testing.T) {
func TestPKCS7UnPadding(t *testing.T) {
ltt := []byte("Test_PKCS7Padding")
ltt = PKCS7Padding(ltt, aes.BlockSize)
ltt = PKCS7UnPadding(ltt)