From 2cd3052da170a8d1bfa1107af332bd8c99ab7483 Mon Sep 17 00:00:00 2001 From: kannn Date: Fri, 29 May 2026 09:05:34 +0000 Subject: [PATCH] rebrand: frp -> kanhole (kanhole server, kanholec client) --- Makefile | 57 +++++-------- client/api_router.go | 8 +- client/config_manager.go | 14 ++-- client/config_manager_test.go | 6 +- client/configmgmt/types.go | 4 +- client/connector.go | 12 +-- client/control.go | 20 ++--- client/control_session.go | 14 ++-- client/control_session_test.go | 10 +-- client/event/event.go | 2 +- client/gui/app.go | 10 +-- client/health/health.go | 4 +- client/http/controller.go | 10 +-- client/http/controller_test.go | 10 +-- client/http/model/proxy_definition.go | 2 +- client/http/model/visitor_definition.go | 2 +- client/proxy/general_tcp.go | 2 +- client/proxy/proxy.go | 18 ++-- client/proxy/proxy_manager.go | 12 +-- client/proxy/proxy_wrapper.go | 16 ++-- client/proxy/sudp.go | 8 +- client/proxy/udp.go | 8 +- client/proxy/xtcp.go | 12 +-- client/proxy/xtcp_test.go | 4 +- client/service.go | 26 +++--- client/service_test.go | 4 +- client/visitor/stcp.go | 4 +- client/visitor/sudp.go | 10 +-- client/visitor/visitor.go | 18 ++-- client/visitor/visitor_manager.go | 10 +-- client/visitor/xtcp.go | 16 ++-- cmd/{frps => kanhole}/main.go | 6 +- cmd/{frps => kanhole}/root.go | 34 ++++---- cmd/{frps => kanhole}/verify.go | 10 +-- cmd/{frpc => kanholec}/main.go | 6 +- cmd/{frpc => kanholec}/sub/admin.go | 12 +-- cmd/{frpc => kanholec}/sub/auth.go | 22 ++--- cmd/{frpc => kanholec}/sub/gui.go | 6 +- cmd/{frpc => kanholec}/sub/gui_stub.go | 8 +- cmd/{frpc => kanholec}/sub/nathole.go | 8 +- cmd/{frpc => kanholec}/sub/proxy.go | 16 ++-- cmd/{frpc => kanholec}/sub/root.go | 36 ++++---- cmd/{frpc => kanholec}/sub/verify.go | 12 +-- go.mod | 2 +- packaging/windows/frpc.default.toml | 10 --- packaging/windows/install.ps1 | 84 +++++++++---------- packaging/windows/kanholec.default.toml | 10 +++ packaging/windows/{frpc.nsi => kanholec.nsi} | 54 ++++++------ packaging/windows/{frpc.wxs => kanholec.wxs} | 24 +++--- packaging/windows/license.rtf | 8 +- packaging/windows/license.txt | 6 +- pkg/auth/auth.go | 4 +- pkg/auth/oidc.go | 6 +- pkg/auth/oidc_test.go | 6 +- pkg/auth/pass.go | 2 +- pkg/auth/token.go | 6 +- pkg/config/flags.go | 12 +-- pkg/config/legacy/client.go | 4 +- pkg/config/legacy/conversion.go | 4 +- pkg/config/legacy/proxy.go | 2 +- pkg/config/legacy/server.go | 4 +- pkg/config/legacy/value.go | 2 +- pkg/config/load.go | 14 ++-- pkg/config/load_test.go | 2 +- pkg/config/source/aggregator.go | 2 +- pkg/config/source/aggregator_test.go | 2 +- pkg/config/source/base_source.go | 2 +- pkg/config/source/base_source_test.go | 2 +- pkg/config/source/clone.go | 2 +- pkg/config/source/config_source.go | 2 +- pkg/config/source/config_source_test.go | 2 +- pkg/config/source/source.go | 2 +- pkg/config/source/store.go | 4 +- pkg/config/source/store_test.go | 4 +- pkg/config/source/validation.go | 2 +- pkg/config/template.go | 2 +- pkg/config/v1/client.go | 2 +- pkg/config/v1/common.go | 2 +- pkg/config/v1/decode.go | 2 +- pkg/config/v1/proxy.go | 8 +- pkg/config/v1/proxy_plugin.go | 4 +- pkg/config/v1/server.go | 6 +- pkg/config/v1/validation/auth.go | 4 +- pkg/config/v1/validation/auth_test.go | 4 +- pkg/config/v1/validation/client.go | 6 +- pkg/config/v1/validation/common.go | 2 +- pkg/config/v1/validation/oidc.go | 2 +- pkg/config/v1/validation/oidc_test.go | 2 +- pkg/config/v1/validation/plugin.go | 2 +- pkg/config/v1/validation/proxy.go | 2 +- pkg/config/v1/validation/server.go | 2 +- pkg/config/v1/validation/validation.go | 4 +- pkg/config/v1/validation/validator.go | 2 +- pkg/config/v1/validation/visitor.go | 2 +- pkg/config/v1/visitor.go | 4 +- pkg/config/v1/visitor_plugin.go | 2 +- pkg/db/config.go | 4 +- pkg/db/db.go | 2 +- pkg/db/ent/client.go | 10 +-- pkg/db/ent/ent.go | 8 +- pkg/db/ent/enttest/enttest.go | 6 +- pkg/db/ent/frpcclient.go | 2 +- pkg/db/ent/frpcclient/where.go | 2 +- pkg/db/ent/frpcclient_create.go | 2 +- pkg/db/ent/frpcclient_delete.go | 4 +- pkg/db/ent/frpcclient_query.go | 4 +- pkg/db/ent/frpcclient_update.go | 4 +- pkg/db/ent/hook/hook.go | 2 +- pkg/db/ent/mutation.go | 10 +-- pkg/db/ent/proxy.go | 2 +- pkg/db/ent/proxy/where.go | 2 +- pkg/db/ent/proxy_create.go | 2 +- pkg/db/ent/proxy_delete.go | 4 +- pkg/db/ent/proxy_query.go | 4 +- pkg/db/ent/proxy_update.go | 4 +- pkg/db/ent/runtime.go | 8 +- pkg/db/ent/runtime/runtime.go | 2 +- pkg/db/ent/serverconfig.go | 2 +- pkg/db/ent/serverconfig/where.go | 2 +- pkg/db/ent/serverconfig_create.go | 2 +- pkg/db/ent/serverconfig_delete.go | 4 +- pkg/db/ent/serverconfig_query.go | 4 +- pkg/db/ent/serverconfig_update.go | 4 +- pkg/db/ent/user.go | 2 +- pkg/db/ent/user/where.go | 2 +- pkg/db/ent/user_create.go | 2 +- pkg/db/ent/user_delete.go | 4 +- pkg/db/ent/user_query.go | 4 +- pkg/db/ent/user_update.go | 4 +- pkg/metrics/aggregate/server.go | 6 +- pkg/metrics/mem/server.go | 6 +- pkg/metrics/mem/types.go | 2 +- pkg/metrics/metrics.go | 2 +- pkg/metrics/prometheus/server.go | 4 +- pkg/msg/conn_test.go | 2 +- pkg/msg/handler.go | 2 +- pkg/msg/wire_v2.go | 2 +- pkg/msg/wire_v2_test.go | 2 +- pkg/nathole/controller.go | 8 +- pkg/nathole/nathole.go | 6 +- pkg/nathole/utils.go | 2 +- pkg/plugin/client/http2http.go | 2 +- pkg/plugin/client/http2https.go | 2 +- pkg/plugin/client/http_common.go | 8 +- pkg/plugin/client/http_proxy.go | 6 +- pkg/plugin/client/http_proxy_test.go | 2 +- pkg/plugin/client/https2http.go | 2 +- pkg/plugin/client/https2https.go | 2 +- .../client/internal/httpsserver/server.go | 4 +- pkg/plugin/client/plugin.go | 4 +- pkg/plugin/client/socks5.go | 4 +- pkg/plugin/client/static_file.go | 4 +- pkg/plugin/client/tls2raw.go | 8 +- pkg/plugin/client/unix_domain_socket.go | 4 +- pkg/plugin/client/virtual_net.go | 2 +- pkg/plugin/server/http.go | 2 +- pkg/plugin/server/manager.go | 4 +- pkg/plugin/server/manager_test.go | 4 +- pkg/plugin/server/types.go | 2 +- pkg/plugin/visitor/plugin.go | 4 +- pkg/plugin/visitor/virtual_net.go | 6 +- pkg/proto/udp/udp.go | 4 +- pkg/sdk/client/client.go | 4 +- pkg/ssh/gateway.go | 8 +- pkg/ssh/server.go | 18 ++-- pkg/ssh/terminal.go | 6 +- pkg/transport/message.go | 2 +- pkg/util/http/handler.go | 2 +- pkg/util/http/middleware.go | 2 +- pkg/util/http/server.go | 6 +- pkg/util/net/conn.go | 2 +- pkg/util/net/conn_test.go | 2 +- pkg/util/net/http.go | 2 +- pkg/util/tcpmux/httpconnect.go | 4 +- pkg/util/vhost/http.go | 4 +- pkg/util/vhost/http_test.go | 2 +- pkg/util/vhost/resource.go | 8 +- pkg/util/vhost/vhost.go | 6 +- pkg/util/wait/backoff.go | 2 +- pkg/util/xlog/xlog.go | 2 +- pkg/virtual/client.go | 10 +-- pkg/vnet/controller.go | 6 +- server/admin/handler.go | 30 +++---- server/admin/templates/client_provision.html | 2 +- server/api_router.go | 6 +- server/control.go | 28 +++---- server/controller/resource.go | 14 ++-- server/group/http.go | 2 +- server/group/https.go | 2 +- server/group/tcp.go | 2 +- server/group/tcpmux.go | 6 +- server/http/controller.go | 18 ++-- server/http/controller_test.go | 6 +- server/http/model/types.go | 2 +- server/ports/ports.go | 2 +- server/ports/ports_test.go | 2 +- server/proxy/http.go | 12 +-- server/proxy/https.go | 6 +- server/proxy/proxy.go | 18 ++-- server/proxy/proxy_test.go | 6 +- server/proxy/stcp.go | 2 +- server/proxy/sudp.go | 2 +- server/proxy/tcp.go | 2 +- server/proxy/tcpmux.go | 6 +- server/proxy/udp.go | 12 +-- server/proxy/xtcp.go | 4 +- server/proxy/xtcp_test.go | 4 +- server/registry/registry_test.go | 2 +- server/service.go | 50 +++++------ server/visitor/visitor.go | 4 +- test/e2e/compatibility/compatibility_test.go | 10 +-- test/e2e/e2e.go | 4 +- test/e2e/e2e_test.go | 16 ++-- test/e2e/examples.go | 4 +- test/e2e/framework/client.go | 2 +- test/e2e/framework/consts/consts.go | 2 +- test/e2e/framework/framework.go | 6 +- test/e2e/framework/mockservers.go | 10 +-- test/e2e/framework/process.go | 8 +- test/e2e/framework/request.go | 6 +- test/e2e/legacy/basic/basic.go | 14 ++-- test/e2e/legacy/basic/client.go | 6 +- test/e2e/legacy/basic/client_server.go | 8 +- test/e2e/legacy/basic/cmd.go | 4 +- test/e2e/legacy/basic/config.go | 6 +- test/e2e/legacy/basic/http.go | 8 +- test/e2e/legacy/basic/server.go | 8 +- test/e2e/legacy/basic/tcpmux.go | 12 +-- test/e2e/legacy/basic/xtcp.go | 8 +- test/e2e/legacy/features/bandwidth_limit.go | 12 +-- test/e2e/legacy/features/chaos.go | 2 +- test/e2e/legacy/features/group.go | 10 +-- test/e2e/legacy/features/heartbeat.go | 2 +- test/e2e/legacy/features/monitor.go | 8 +- test/e2e/legacy/features/real_ip.go | 14 ++-- test/e2e/legacy/plugin/client.go | 14 ++-- test/e2e/legacy/plugin/server.go | 10 +-- test/e2e/mock/server/streamserver/server.go | 4 +- test/e2e/pkg/plugin/plugin.go | 6 +- test/e2e/pkg/request/request.go | 4 +- test/e2e/v1/basic/annotations.go | 4 +- test/e2e/v1/basic/basic.go | 14 ++-- test/e2e/v1/basic/client.go | 6 +- test/e2e/v1/basic/client_server.go | 8 +- test/e2e/v1/basic/cmd.go | 4 +- test/e2e/v1/basic/config.go | 6 +- test/e2e/v1/basic/http.go | 8 +- test/e2e/v1/basic/oidc.go | 8 +- test/e2e/v1/basic/server.go | 8 +- test/e2e/v1/basic/tcpmux.go | 12 +-- test/e2e/v1/basic/token_source.go | 6 +- test/e2e/v1/basic/wire.go | 6 +- test/e2e/v1/basic/xtcp.go | 8 +- test/e2e/v1/features/bandwidth_limit.go | 12 +-- test/e2e/v1/features/chaos.go | 2 +- test/e2e/v1/features/group.go | 12 +-- test/e2e/v1/features/heartbeat.go | 2 +- test/e2e/v1/features/monitor.go | 8 +- test/e2e/v1/features/real_ip.go | 16 ++-- test/e2e/v1/features/ssh_tunnel.go | 14 ++-- test/e2e/v1/features/store.go | 6 +- test/e2e/v1/plugin/client.go | 14 ++-- test/e2e/v1/plugin/server.go | 10 +-- web/frpc/embed.go | 2 +- web/frps/embed.go | 2 +- 265 files changed, 949 insertions(+), 962 deletions(-) rename cmd/{frps => kanhole}/main.go (85%) rename cmd/{frps => kanhole}/root.go (81%) rename cmd/{frps => kanhole}/verify.go (83%) rename cmd/{frpc => kanholec}/main.go (85%) rename cmd/{frpc => kanholec}/sub/admin.go (92%) rename cmd/{frpc => kanholec}/sub/auth.go (88%) rename cmd/{frpc => kanholec}/sub/gui.go (67%) rename cmd/{frpc => kanholec}/sub/gui_stub.go (57%) rename cmd/{frpc => kanholec}/sub/nathole.go (94%) rename cmd/{frpc => kanholec}/sub/proxy.go (91%) rename cmd/{frpc => kanholec}/sub/root.go (88%) rename cmd/{frpc => kanholec}/sub/verify.go (81%) delete mode 100644 packaging/windows/frpc.default.toml create mode 100644 packaging/windows/kanholec.default.toml rename packaging/windows/{frpc.nsi => kanholec.nsi} (71%) rename packaging/windows/{frpc.wxs => kanholec.wxs} (50%) diff --git a/Makefile b/Makefile index 686fc208..20425d24 100644 --- a/Makefile +++ b/Makefile @@ -1,25 +1,26 @@ export PATH := $(PATH):`go env GOPATH`/bin export GO111MODULE=on LDFLAGS := -s -w -NOWEB_TAG = $(shell [ ! -d web/frps/dist ] || [ ! -d web/frpc/dist ] && echo ',noweb') +NOWEB_TAG = $(shell [ ! -d web/kanhole/dist ] || [ ! -d web/kanholec/dist ] && echo ',noweb') +KANHOLE_VERSION ?= 0.1.0 FRP_COMPAT_BASELINE_COUNT ?= 8 FRP_COMPAT_FLOOR_VERSION ?= 0.61.0 -.PHONY: web frps-web frpc-web frps frpc frpc-gui e2e-compatibility-smoke e2e-compatibility e2e-compatibility-floor +.PHONY: web kanhole-web kanholec-web kanhole kanholec kanholec-gui e2e-compatibility-smoke e2e-compatibility e2e-compatibility-floor all: env fmt web build -build: frps frpc +build: kanhole kanholec env: @go version -web: frps-web frpc-web +web: kanhole-web kanholec-web -frps-web: +kanhole-web: $(MAKE) -C web/frps build -frpc-web: +kanholec-web: $(MAKE) -C web/frpc build fmt: @@ -29,30 +30,30 @@ fmt-more: gofumpt -l -w . gci: - gci write -s standard -s default -s "prefix(github.com/fatedier/frp/)" ./ + gci write -s standard -s default -s "prefix(kanhole/)" ./ vet: go vet -tags "$(NOWEB_TAG)" ./... -frps: - env CGO_ENABLED=0 go build -trimpath -ldflags "$(LDFLAGS)" -tags "frps$(NOWEB_TAG)" -o bin/frps ./cmd/frps +kanhole: + env CGO_ENABLED=0 go build -trimpath -ldflags "$(LDFLAGS)" -tags "kanhole$(NOWEB_TAG)" -o bin/kanhole ./cmd/kanhole -frpc: - env CGO_ENABLED=0 go build -trimpath -ldflags "$(LDFLAGS)" -tags "frpc$(NOWEB_TAG)" -o bin/frpc ./cmd/frpc +kanholec: + env CGO_ENABLED=0 go build -trimpath -ldflags "$(LDFLAGS)" -tags "kanholec$(NOWEB_TAG)" -o bin/kanholec ./cmd/kanholec -frpc-windows: - env CGO_ENABLED=0 GOOS=windows GOARCH=amd64 go build -trimpath -ldflags "$(LDFLAGS)" -tags "frpc$(NOWEB_TAG)" -o bin/frpc-windows-amd64.exe ./cmd/frpc +kanholec-windows: + env CGO_ENABLED=0 GOOS=windows GOARCH=amd64 go build -trimpath -ldflags "$(LDFLAGS)" -tags "kanholec$(NOWEB_TAG)" -o bin/kanholec-windows-amd64.exe ./cmd/kanholec -frpc-windows-arm64: - env CGO_ENABLED=0 GOOS=windows GOARCH=arm64 go build -trimpath -ldflags "$(LDFLAGS)" -tags "frpc$(NOWEB_TAG)" -o bin/frpc-windows-arm64.exe ./cmd/frpc +kanholec-windows-arm64: + env CGO_ENABLED=0 GOOS=windows GOARCH=arm64 go build -trimpath -ldflags "$(LDFLAGS)" -tags "kanholec$(NOWEB_TAG)" -o bin/kanholec-windows-arm64.exe ./cmd/kanholec -frpc-windows-msi: frpc-windows - wixl -o bin/frpc-0.62.0.msi packaging/windows/frpc.wxs 2>/dev/null \ +kanholec-windows-msi: kanholec-windows + wixl -o bin/kanholec-$(KANHOLE_VERSION).msi packaging/windows/kanholec.wxs 2>/dev/null \ || { echo "wixl failed. Try: apt install msitools"; \ - echo "Or on Windows: candle frpc.wxs -o frpc.wixobj && light frpc.wixobj -o frpc.msi"; \ + echo "Or on Windows: candle kanholec.wxs -o kanholec.wixobj && light kanholec.wixobj -o kanholec.msi"; \ exit 1; } -.PHONY: frpc-windows frpc-windows-arm64 frpc-windows-msi +.PHONY: kanholec-windows kanholec-windows-arm64 kanholec-windows-msi test: gotest @@ -78,25 +79,11 @@ e2e-compatibility: build e2e-compatibility-floor: build FRP_COMPAT_BASELINE_VERSIONS="$(FRP_COMPAT_FLOOR_VERSION)" ./hack/run-e2e-compatibility.sh -e2e-compatibility-last-frpc: - if [ ! -d "./lastversion" ]; then \ - TARGET_DIRNAME=lastversion ./hack/download.sh; \ - fi - FRPC_PATH="`pwd`/lastversion/frpc" ./hack/run-e2e.sh - rm -r ./lastversion - -e2e-compatibility-last-frps: - if [ ! -d "./lastversion" ]; then \ - TARGET_DIRNAME=lastversion ./hack/download.sh; \ - fi - FRPS_PATH="`pwd`/lastversion/frps" ./hack/run-e2e.sh - rm -r ./lastversion - alltest: vet gotest e2e clean: - rm -f ./bin/frpc - rm -f ./bin/frps + rm -f ./bin/kanhole + rm -f ./bin/kanholec rm -rf ./lastversion rm -rf ./.cache rm -rf ./.compat diff --git a/client/api_router.go b/client/api_router.go index 82b73046..c8a440fb 100644 --- a/client/api_router.go +++ b/client/api_router.go @@ -17,10 +17,10 @@ package client import ( "net/http" - adminapi "github.com/fatedier/frp/client/http" - "github.com/fatedier/frp/client/proxy" - httppkg "github.com/fatedier/frp/pkg/util/http" - netpkg "github.com/fatedier/frp/pkg/util/net" + adminapi "kanhole/client/http" + "kanhole/client/proxy" + httppkg "kanhole/pkg/util/http" + netpkg "kanhole/pkg/util/net" ) func (svr *Service) registerRouteHandlers(helper *httppkg.RouterRegisterHelper) { diff --git a/client/config_manager.go b/client/config_manager.go index 24512e9f..2df18b2c 100644 --- a/client/config_manager.go +++ b/client/config_manager.go @@ -6,13 +6,13 @@ import ( "os" "time" - "github.com/fatedier/frp/client/configmgmt" - "github.com/fatedier/frp/client/proxy" - "github.com/fatedier/frp/pkg/config" - "github.com/fatedier/frp/pkg/config/source" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/config/v1/validation" - "github.com/fatedier/frp/pkg/util/log" + "kanhole/client/configmgmt" + "kanhole/client/proxy" + "kanhole/pkg/config" + "kanhole/pkg/config/source" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/config/v1/validation" + "kanhole/pkg/util/log" ) type serviceConfigManager struct { diff --git a/client/config_manager_test.go b/client/config_manager_test.go index 07ae3297..608822c2 100644 --- a/client/config_manager_test.go +++ b/client/config_manager_test.go @@ -5,9 +5,9 @@ import ( "path/filepath" "testing" - "github.com/fatedier/frp/client/configmgmt" - "github.com/fatedier/frp/pkg/config/source" - v1 "github.com/fatedier/frp/pkg/config/v1" + "kanhole/client/configmgmt" + "kanhole/pkg/config/source" + v1 "kanhole/pkg/config/v1" ) func newTestRawTCPProxyConfig(name string) *v1.TCPProxyConfig { diff --git a/client/configmgmt/types.go b/client/configmgmt/types.go index 5a51a5e5..f51d9e71 100644 --- a/client/configmgmt/types.go +++ b/client/configmgmt/types.go @@ -4,8 +4,8 @@ import ( "errors" "time" - "github.com/fatedier/frp/client/proxy" - v1 "github.com/fatedier/frp/pkg/config/v1" + "kanhole/client/proxy" + v1 "kanhole/pkg/config/v1" ) var ( diff --git a/client/connector.go b/client/connector.go index 34b24f0d..1b98c5c0 100644 --- a/client/connector.go +++ b/client/connector.go @@ -28,12 +28,12 @@ import ( quic "github.com/quic-go/quic-go" "github.com/samber/lo" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/msg" - "github.com/fatedier/frp/pkg/proto/wire" - "github.com/fatedier/frp/pkg/transport" - netpkg "github.com/fatedier/frp/pkg/util/net" - "github.com/fatedier/frp/pkg/util/xlog" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/msg" + "kanhole/pkg/proto/wire" + "kanhole/pkg/transport" + netpkg "kanhole/pkg/util/net" + "kanhole/pkg/util/xlog" ) // Connector is an interface for establishing connections to the server. diff --git a/client/control.go b/client/control.go index 6e3002bc..821c837b 100644 --- a/client/control.go +++ b/client/control.go @@ -20,16 +20,16 @@ import ( "sync/atomic" "time" - "github.com/fatedier/frp/client/proxy" - "github.com/fatedier/frp/client/visitor" - "github.com/fatedier/frp/pkg/auth" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/msg" - "github.com/fatedier/frp/pkg/naming" - "github.com/fatedier/frp/pkg/transport" - "github.com/fatedier/frp/pkg/util/wait" - "github.com/fatedier/frp/pkg/util/xlog" - "github.com/fatedier/frp/pkg/vnet" + "kanhole/client/proxy" + "kanhole/client/visitor" + "kanhole/pkg/auth" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/msg" + "kanhole/pkg/naming" + "kanhole/pkg/transport" + "kanhole/pkg/util/wait" + "kanhole/pkg/util/xlog" + "kanhole/pkg/vnet" ) type SessionContext struct { diff --git a/client/control_session.go b/client/control_session.go index d533ba2d..95e19e50 100644 --- a/client/control_session.go +++ b/client/control_session.go @@ -26,13 +26,13 @@ import ( "github.com/samber/lo" - "github.com/fatedier/frp/pkg/auth" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/msg" - "github.com/fatedier/frp/pkg/proto/wire" - netpkg "github.com/fatedier/frp/pkg/util/net" - "github.com/fatedier/frp/pkg/util/version" - "github.com/fatedier/frp/pkg/vnet" + "kanhole/pkg/auth" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/msg" + "kanhole/pkg/proto/wire" + netpkg "kanhole/pkg/util/net" + "kanhole/pkg/util/version" + "kanhole/pkg/vnet" ) type controlSessionDialer struct { diff --git a/client/control_session_test.go b/client/control_session_test.go index a0778fba..eec81cbf 100644 --- a/client/control_session_test.go +++ b/client/control_session_test.go @@ -25,11 +25,11 @@ import ( "github.com/stretchr/testify/require" - "github.com/fatedier/frp/pkg/auth" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/msg" - "github.com/fatedier/frp/pkg/proto/wire" - netpkg "github.com/fatedier/frp/pkg/util/net" + "kanhole/pkg/auth" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/msg" + "kanhole/pkg/proto/wire" + netpkg "kanhole/pkg/util/net" ) type testConnector struct { diff --git a/client/event/event.go b/client/event/event.go index acdc96ba..0bbcb1c1 100644 --- a/client/event/event.go +++ b/client/event/event.go @@ -3,7 +3,7 @@ package event import ( "errors" - "github.com/fatedier/frp/pkg/msg" + "kanhole/pkg/msg" ) var ErrPayloadType = errors.New("error payload type") diff --git a/client/gui/app.go b/client/gui/app.go index d6f2b8b4..7a56e86a 100644 --- a/client/gui/app.go +++ b/client/gui/app.go @@ -1,4 +1,4 @@ -//go:build frpc_gui +//go:build kanholec_gui package gui @@ -17,9 +17,9 @@ import ( "fyne.io/fyne/v2/theme" "fyne.io/fyne/v2/widget" - "github.com/fatedier/frp/pkg/config" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/util/log" + "kanhole/pkg/config" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/util/log" ) type App struct { @@ -44,7 +44,7 @@ type App struct { func New() *App { a := &App{} a.fyneApp = app.New() - a.window = a.fyneApp.NewWindow("frpc GUI") + a.window = a.fyneApp.NewWindow("kanholec GUI") a.window.Resize(fyne.NewSize(850, 620)) a.window.SetMaster() a.setupUI() diff --git a/client/health/health.go b/client/health/health.go index d298e615..1cbc8131 100644 --- a/client/health/health.go +++ b/client/health/health.go @@ -24,8 +24,8 @@ import ( "strings" "time" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/util/xlog" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/util/xlog" ) var ErrHealthCheckType = errors.New("error health check type") diff --git a/client/http/controller.go b/client/http/controller.go index 57e8165d..106dad29 100644 --- a/client/http/controller.go +++ b/client/http/controller.go @@ -24,11 +24,11 @@ import ( "strconv" "time" - "github.com/fatedier/frp/client/configmgmt" - "github.com/fatedier/frp/client/http/model" - "github.com/fatedier/frp/client/proxy" - httppkg "github.com/fatedier/frp/pkg/util/http" - "github.com/fatedier/frp/pkg/util/jsonx" + "kanhole/client/configmgmt" + "kanhole/client/http/model" + "kanhole/client/proxy" + httppkg "kanhole/pkg/util/http" + "kanhole/pkg/util/jsonx" ) // Controller handles HTTP API requests for frpc. diff --git a/client/http/controller_test.go b/client/http/controller_test.go index 719fbcd4..abcb45ed 100644 --- a/client/http/controller_test.go +++ b/client/http/controller_test.go @@ -12,11 +12,11 @@ import ( "github.com/gorilla/mux" - "github.com/fatedier/frp/client/configmgmt" - "github.com/fatedier/frp/client/http/model" - "github.com/fatedier/frp/client/proxy" - v1 "github.com/fatedier/frp/pkg/config/v1" - httppkg "github.com/fatedier/frp/pkg/util/http" + "kanhole/client/configmgmt" + "kanhole/client/http/model" + "kanhole/client/proxy" + v1 "kanhole/pkg/config/v1" + httppkg "kanhole/pkg/util/http" ) type fakeConfigManager struct { diff --git a/client/http/model/proxy_definition.go b/client/http/model/proxy_definition.go index dae4b4b8..e9df4585 100644 --- a/client/http/model/proxy_definition.go +++ b/client/http/model/proxy_definition.go @@ -4,7 +4,7 @@ import ( "fmt" "strings" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) type ProxyDefinition struct { diff --git a/client/http/model/visitor_definition.go b/client/http/model/visitor_definition.go index a108982d..44a64553 100644 --- a/client/http/model/visitor_definition.go +++ b/client/http/model/visitor_definition.go @@ -4,7 +4,7 @@ import ( "fmt" "strings" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) type VisitorDefinition struct { diff --git a/client/proxy/general_tcp.go b/client/proxy/general_tcp.go index c3923085..043c7030 100644 --- a/client/proxy/general_tcp.go +++ b/client/proxy/general_tcp.go @@ -17,7 +17,7 @@ package proxy import ( "reflect" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) func init() { diff --git a/client/proxy/proxy.go b/client/proxy/proxy.go index 84ff49a1..9bdf5fc2 100644 --- a/client/proxy/proxy.go +++ b/client/proxy/proxy.go @@ -28,15 +28,15 @@ import ( libnet "github.com/fatedier/golib/net" "golang.org/x/time/rate" - "github.com/fatedier/frp/pkg/config/types" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/msg" - plugin "github.com/fatedier/frp/pkg/plugin/client" - "github.com/fatedier/frp/pkg/transport" - "github.com/fatedier/frp/pkg/util/limit" - netpkg "github.com/fatedier/frp/pkg/util/net" - "github.com/fatedier/frp/pkg/util/xlog" - "github.com/fatedier/frp/pkg/vnet" + "kanhole/pkg/config/types" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/msg" + plugin "kanhole/pkg/plugin/client" + "kanhole/pkg/transport" + "kanhole/pkg/util/limit" + netpkg "kanhole/pkg/util/net" + "kanhole/pkg/util/xlog" + "kanhole/pkg/vnet" ) var proxyFactoryRegistry = map[reflect.Type]func(*BaseProxy, v1.ProxyConfigurer) Proxy{} diff --git a/client/proxy/proxy_manager.go b/client/proxy/proxy_manager.go index 42f9f589..07ff5184 100644 --- a/client/proxy/proxy_manager.go +++ b/client/proxy/proxy_manager.go @@ -23,12 +23,12 @@ import ( "github.com/samber/lo" - "github.com/fatedier/frp/client/event" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/msg" - "github.com/fatedier/frp/pkg/transport" - "github.com/fatedier/frp/pkg/util/xlog" - "github.com/fatedier/frp/pkg/vnet" + "kanhole/client/event" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/msg" + "kanhole/pkg/transport" + "kanhole/pkg/util/xlog" + "kanhole/pkg/vnet" ) type Manager struct { diff --git a/client/proxy/proxy_wrapper.go b/client/proxy/proxy_wrapper.go index 718c02e6..aa72d85f 100644 --- a/client/proxy/proxy_wrapper.go +++ b/client/proxy/proxy_wrapper.go @@ -25,14 +25,14 @@ import ( "github.com/fatedier/golib/errors" - "github.com/fatedier/frp/client/event" - "github.com/fatedier/frp/client/health" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/msg" - "github.com/fatedier/frp/pkg/naming" - "github.com/fatedier/frp/pkg/transport" - "github.com/fatedier/frp/pkg/util/xlog" - "github.com/fatedier/frp/pkg/vnet" + "kanhole/client/event" + "kanhole/client/health" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/msg" + "kanhole/pkg/naming" + "kanhole/pkg/transport" + "kanhole/pkg/util/xlog" + "kanhole/pkg/vnet" ) const ( diff --git a/client/proxy/sudp.go b/client/proxy/sudp.go index 21e34a41..c488fcb9 100644 --- a/client/proxy/sudp.go +++ b/client/proxy/sudp.go @@ -25,10 +25,10 @@ import ( "github.com/fatedier/golib/errors" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/msg" - "github.com/fatedier/frp/pkg/proto/udp" - netpkg "github.com/fatedier/frp/pkg/util/net" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/msg" + "kanhole/pkg/proto/udp" + netpkg "kanhole/pkg/util/net" ) func init() { diff --git a/client/proxy/udp.go b/client/proxy/udp.go index 110c01ac..a87bfa40 100644 --- a/client/proxy/udp.go +++ b/client/proxy/udp.go @@ -24,10 +24,10 @@ import ( "github.com/fatedier/golib/errors" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/msg" - "github.com/fatedier/frp/pkg/proto/udp" - netpkg "github.com/fatedier/frp/pkg/util/net" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/msg" + "kanhole/pkg/proto/udp" + netpkg "kanhole/pkg/util/net" ) func init() { diff --git a/client/proxy/xtcp.go b/client/proxy/xtcp.go index aef66780..810b7960 100644 --- a/client/proxy/xtcp.go +++ b/client/proxy/xtcp.go @@ -25,12 +25,12 @@ import ( fmux "github.com/hashicorp/yamux" "github.com/quic-go/quic-go" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/msg" - "github.com/fatedier/frp/pkg/naming" - "github.com/fatedier/frp/pkg/nathole" - "github.com/fatedier/frp/pkg/transport" - netpkg "github.com/fatedier/frp/pkg/util/net" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/msg" + "kanhole/pkg/naming" + "kanhole/pkg/nathole" + "kanhole/pkg/transport" + netpkg "kanhole/pkg/util/net" ) func init() { diff --git a/client/proxy/xtcp_test.go b/client/proxy/xtcp_test.go index bd295a07..91a0459a 100644 --- a/client/proxy/xtcp_test.go +++ b/client/proxy/xtcp_test.go @@ -23,8 +23,8 @@ import ( "github.com/stretchr/testify/require" - "github.com/fatedier/frp/pkg/msg" - "github.com/fatedier/frp/pkg/proto/wire" + "kanhole/pkg/msg" + "kanhole/pkg/proto/wire" ) func TestReadNatHoleSidUsesSelectedWireProtocol(t *testing.T) { diff --git a/client/service.go b/client/service.go index 3cff773e..43f86a05 100644 --- a/client/service.go +++ b/client/service.go @@ -28,19 +28,19 @@ import ( "github.com/fatedier/golib/crypto" "github.com/samber/lo" - "github.com/fatedier/frp/client/proxy" - "github.com/fatedier/frp/pkg/auth" - "github.com/fatedier/frp/pkg/config" - "github.com/fatedier/frp/pkg/config/source" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/msg" - "github.com/fatedier/frp/pkg/policy/security" - httppkg "github.com/fatedier/frp/pkg/util/http" - "github.com/fatedier/frp/pkg/util/log" - netpkg "github.com/fatedier/frp/pkg/util/net" - "github.com/fatedier/frp/pkg/util/wait" - "github.com/fatedier/frp/pkg/util/xlog" - "github.com/fatedier/frp/pkg/vnet" + "kanhole/client/proxy" + "kanhole/pkg/auth" + "kanhole/pkg/config" + "kanhole/pkg/config/source" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/msg" + "kanhole/pkg/policy/security" + httppkg "kanhole/pkg/util/http" + "kanhole/pkg/util/log" + netpkg "kanhole/pkg/util/net" + "kanhole/pkg/util/wait" + "kanhole/pkg/util/xlog" + "kanhole/pkg/vnet" ) func init() { diff --git a/client/service_test.go b/client/service_test.go index 29f141a1..e2bfe3c8 100644 --- a/client/service_test.go +++ b/client/service_test.go @@ -11,8 +11,8 @@ import ( "github.com/samber/lo" - "github.com/fatedier/frp/pkg/config/source" - v1 "github.com/fatedier/frp/pkg/config/v1" + "kanhole/pkg/config/source" + v1 "kanhole/pkg/config/v1" ) type failingConnector struct { diff --git a/client/visitor/stcp.go b/client/visitor/stcp.go index 03ec51fe..8919fa63 100644 --- a/client/visitor/stcp.go +++ b/client/visitor/stcp.go @@ -20,8 +20,8 @@ import ( libio "github.com/fatedier/golib/io" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/util/xlog" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/util/xlog" ) type STCPVisitor struct { diff --git a/client/visitor/sudp.go b/client/visitor/sudp.go index 6014161c..45be1c28 100644 --- a/client/visitor/sudp.go +++ b/client/visitor/sudp.go @@ -23,11 +23,11 @@ import ( "github.com/fatedier/golib/errors" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/msg" - "github.com/fatedier/frp/pkg/proto/udp" - netpkg "github.com/fatedier/frp/pkg/util/net" - "github.com/fatedier/frp/pkg/util/xlog" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/msg" + "kanhole/pkg/proto/udp" + netpkg "kanhole/pkg/util/net" + "kanhole/pkg/util/xlog" ) type SUDPVisitor struct { diff --git a/client/visitor/visitor.go b/client/visitor/visitor.go index dff0bb94..943bab7f 100644 --- a/client/visitor/visitor.go +++ b/client/visitor/visitor.go @@ -24,15 +24,15 @@ import ( libio "github.com/fatedier/golib/io" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/msg" - "github.com/fatedier/frp/pkg/naming" - plugin "github.com/fatedier/frp/pkg/plugin/visitor" - "github.com/fatedier/frp/pkg/transport" - netpkg "github.com/fatedier/frp/pkg/util/net" - "github.com/fatedier/frp/pkg/util/util" - "github.com/fatedier/frp/pkg/util/xlog" - "github.com/fatedier/frp/pkg/vnet" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/msg" + "kanhole/pkg/naming" + plugin "kanhole/pkg/plugin/visitor" + "kanhole/pkg/transport" + netpkg "kanhole/pkg/util/net" + "kanhole/pkg/util/util" + "kanhole/pkg/util/xlog" + "kanhole/pkg/vnet" ) // Helper wraps some functions for visitor to use. diff --git a/client/visitor/visitor_manager.go b/client/visitor/visitor_manager.go index 1ca194bd..69d103d8 100644 --- a/client/visitor/visitor_manager.go +++ b/client/visitor/visitor_manager.go @@ -24,11 +24,11 @@ import ( "github.com/samber/lo" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/msg" - "github.com/fatedier/frp/pkg/transport" - "github.com/fatedier/frp/pkg/util/xlog" - "github.com/fatedier/frp/pkg/vnet" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/msg" + "kanhole/pkg/transport" + "kanhole/pkg/util/xlog" + "kanhole/pkg/vnet" ) type Manager struct { diff --git a/client/visitor/xtcp.go b/client/visitor/xtcp.go index e7a60895..9df060ea 100644 --- a/client/visitor/xtcp.go +++ b/client/visitor/xtcp.go @@ -29,14 +29,14 @@ import ( quic "github.com/quic-go/quic-go" "golang.org/x/time/rate" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/msg" - "github.com/fatedier/frp/pkg/naming" - "github.com/fatedier/frp/pkg/nathole" - "github.com/fatedier/frp/pkg/transport" - netpkg "github.com/fatedier/frp/pkg/util/net" - "github.com/fatedier/frp/pkg/util/util" - "github.com/fatedier/frp/pkg/util/xlog" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/msg" + "kanhole/pkg/naming" + "kanhole/pkg/nathole" + "kanhole/pkg/transport" + netpkg "kanhole/pkg/util/net" + "kanhole/pkg/util/util" + "kanhole/pkg/util/xlog" ) var ErrNoTunnelSession = errors.New("no tunnel session") diff --git a/cmd/frps/main.go b/cmd/kanhole/main.go similarity index 85% rename from cmd/frps/main.go rename to cmd/kanhole/main.go index 4eda4f1f..a3751e27 100644 --- a/cmd/frps/main.go +++ b/cmd/kanhole/main.go @@ -15,9 +15,9 @@ package main import ( - _ "github.com/fatedier/frp/pkg/metrics" - "github.com/fatedier/frp/pkg/util/system" - _ "github.com/fatedier/frp/web/frps" + _ "kanhole/pkg/metrics" + "kanhole/pkg/util/system" + _ "kanhole/web/frps" ) func main() { diff --git a/cmd/frps/root.go b/cmd/kanhole/root.go similarity index 81% rename from cmd/frps/root.go rename to cmd/kanhole/root.go index 90233ede..477d984f 100644 --- a/cmd/frps/root.go +++ b/cmd/kanhole/root.go @@ -8,14 +8,14 @@ import ( "github.com/spf13/cobra" - "github.com/fatedier/frp/pkg/config" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/config/v1/validation" - "github.com/fatedier/frp/pkg/db" - "github.com/fatedier/frp/pkg/policy/security" - "github.com/fatedier/frp/pkg/util/log" - "github.com/fatedier/frp/pkg/util/version" - "github.com/fatedier/frp/server" + "kanhole/pkg/config" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/config/v1/validation" + "kanhole/pkg/db" + "kanhole/pkg/policy/security" + "kanhole/pkg/util/log" + "kanhole/pkg/util/version" + "kanhole/server" ) var ( @@ -28,8 +28,8 @@ var ( ) func init() { - rootCmd.PersistentFlags().StringVarP(&cfgFile, "config", "c", "", "config file of frps") - rootCmd.PersistentFlags().BoolVarP(&showVersion, "version", "v", false, "version of frps") + rootCmd.PersistentFlags().StringVarP(&cfgFile, "config", "c", "", "config file of kanhole") + rootCmd.PersistentFlags().BoolVarP(&showVersion, "version", "v", false, "version of kanhole") rootCmd.PersistentFlags().BoolVarP(&strictConfigMode, "strict_config", "", true, "strict config parsing mode, unknown fields will cause errors") rootCmd.PersistentFlags().StringSliceVarP(&allowUnsafe, "allow-unsafe", "", []string{}, fmt.Sprintf("allowed unsafe features, one or more of: %s", strings.Join(security.ServerUnsafeFeatures, ", "))) @@ -38,8 +38,8 @@ func init() { } var rootCmd = &cobra.Command{ - Use: "frps", - Short: "frps is the server of frp (https://github.com/fatedier/frp)", + Use: "kanhole", + Short: "kanhole is the server component of kanhole", RunE: func(cmd *cobra.Command, args []string) error { if showVersion { fmt.Println(version.Full()) @@ -114,7 +114,7 @@ func loadConfigFromDB() (*v1.ServerConfig, error) { if err := cfg.Complete(); err != nil { return nil, fmt.Errorf("failed to complete server config: %w", err) } - log.Infof("frps uses database configuration") + log.Infof("kanhole uses database configuration") return cfg, nil } @@ -125,7 +125,7 @@ func loadConfigFromDB() (*v1.ServerConfig, error) { if err := db.SaveServerConfig(cfg); err != nil { log.Warnf("failed to save default config to db: %v", err) } - log.Infof("frps started with default configuration (first run)") + log.Infof("kanhole started with default configuration (first run)") return cfg, nil } @@ -133,16 +133,16 @@ func runServer(cfg *v1.ServerConfig) (err error) { log.InitLogger(cfg.Log.To, cfg.Log.Level, int(cfg.Log.MaxDays), cfg.Log.DisablePrintColor) if cfgFile != "" { - log.Infof("frps uses config file: %s", cfgFile) + log.Infof("kanhole uses config file: %s", cfgFile) } else { - log.Infof("frps uses database configuration") + log.Infof("kanhole uses database configuration") } svr, err := server.NewService(cfg) if err != nil { return err } - log.Infof("frps started successfully") + log.Infof("kanhole started successfully") svr.Run(context.Background()) return } diff --git a/cmd/frps/verify.go b/cmd/kanhole/verify.go similarity index 83% rename from cmd/frps/verify.go rename to cmd/kanhole/verify.go index 7ddef1ab..98451c48 100644 --- a/cmd/frps/verify.go +++ b/cmd/kanhole/verify.go @@ -20,9 +20,9 @@ import ( "github.com/spf13/cobra" - "github.com/fatedier/frp/pkg/config" - "github.com/fatedier/frp/pkg/config/v1/validation" - "github.com/fatedier/frp/pkg/policy/security" + "kanhole/pkg/config" + "kanhole/pkg/config/v1/validation" + "kanhole/pkg/policy/security" ) func init() { @@ -34,7 +34,7 @@ var verifyCmd = &cobra.Command{ Short: "Verify that the configures is valid", RunE: func(cmd *cobra.Command, args []string) error { if cfgFile == "" { - fmt.Println("frps: the configuration file is not specified") + fmt.Println("kanhole: the configuration file is not specified") return nil } svrCfg, _, err := config.LoadServerConfig(cfgFile, strictConfigMode) @@ -53,7 +53,7 @@ var verifyCmd = &cobra.Command{ fmt.Println(err) os.Exit(1) } - fmt.Printf("frps: the configuration file %s syntax is ok\n", cfgFile) + fmt.Printf("kanhole: the configuration file %s syntax is ok\n", cfgFile) return nil }, } diff --git a/cmd/frpc/main.go b/cmd/kanholec/main.go similarity index 85% rename from cmd/frpc/main.go rename to cmd/kanholec/main.go index c4421667..4a125fb0 100644 --- a/cmd/frpc/main.go +++ b/cmd/kanholec/main.go @@ -15,9 +15,9 @@ package main import ( - "github.com/fatedier/frp/cmd/frpc/sub" - "github.com/fatedier/frp/pkg/util/system" - _ "github.com/fatedier/frp/web/frpc" + "kanhole/cmd/kanholec/sub" + "kanhole/pkg/util/system" + _ "kanhole/web/frpc" ) func main() { diff --git a/cmd/frpc/sub/admin.go b/cmd/kanholec/sub/admin.go similarity index 92% rename from cmd/frpc/sub/admin.go rename to cmd/kanholec/sub/admin.go index abe80635..1477e3f2 100644 --- a/cmd/frpc/sub/admin.go +++ b/cmd/kanholec/sub/admin.go @@ -1,4 +1,4 @@ -// Copyright 2023 The frp Authors +// Copyright 2023 The kanhole Authors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -24,9 +24,9 @@ import ( "github.com/rodaine/table" "github.com/spf13/cobra" - "github.com/fatedier/frp/pkg/config" - v1 "github.com/fatedier/frp/pkg/config/v1" - clientsdk "github.com/fatedier/frp/pkg/sdk/client" + "kanhole/pkg/config" + v1 "kanhole/pkg/config/v1" + clientsdk "kanhole/pkg/sdk/client" ) var adminAPITimeout = 30 * time.Second @@ -37,9 +37,9 @@ func init() { description string handler func(*v1.ClientCommonConfig) error }{ - {"reload", "Hot-Reload frpc configuration", ReloadHandler}, + {"reload", "Hot-Reload kanholec configuration", ReloadHandler}, {"status", "Overview of all proxies status", StatusHandler}, - {"stop", "Stop the running frpc", StopHandler}, + {"stop", "Stop the running kanholec", StopHandler}, } for _, cmdConfig := range commands { diff --git a/cmd/frpc/sub/auth.go b/cmd/kanholec/sub/auth.go similarity index 88% rename from cmd/frpc/sub/auth.go rename to cmd/kanholec/sub/auth.go index 94e98cc5..6b55a62c 100644 --- a/cmd/frpc/sub/auth.go +++ b/cmd/kanholec/sub/auth.go @@ -11,7 +11,7 @@ import ( "github.com/spf13/cobra" - "github.com/fatedier/frp/pkg/util/log" + "kanhole/pkg/util/log" ) var ( @@ -22,14 +22,14 @@ var ( func init() { authCmd := &cobra.Command{ Use: "auth", - Short: "Authenticate frpc with a frp server", - Long: `Authenticate this frpc instance with a frp server. + Short: "Authenticate kanholec with a kanhole server", + Long: `Authenticate this kanholec instance with a kanhole server. One-time token: - frpc auth token --server http://server:7500 + kanholec auth token --server http://server:7500 Interactive login: - frpc auth login --server http://server:7500 --client-name myclient + kanholec auth login --server http://server:7500 --client-name myclient `, } @@ -39,16 +39,16 @@ Interactive login: Args: cobra.ExactArgs(1), RunE: runAuthToken, } - tokenCmd.Flags().StringVarP(&authServer, "server", "s", "http://localhost:7500", "frp server admin URL") - tokenCmd.Flags().StringVarP(&authOutput, "output", "o", "", "output config file path (default: ./frpc-.toml)") + tokenCmd.Flags().StringVarP(&authServer, "server", "s", "http://localhost:7500", "kanhole server admin URL") + tokenCmd.Flags().StringVarP(&authOutput, "output", "o", "", "output config file path (default: ./kanholec-.toml)") loginCmd := &cobra.Command{ Use: "login", Short: "Authenticate using admin credentials", RunE: runAuthLogin, } - loginCmd.Flags().StringVarP(&authServer, "server", "s", "http://localhost:7500", "frp server admin URL") - loginCmd.Flags().StringVarP(&authOutput, "output", "o", "", "output config file path (default: ./frpc-.toml)") + loginCmd.Flags().StringVarP(&authServer, "server", "s", "http://localhost:7500", "kanhole server admin URL") + loginCmd.Flags().StringVarP(&authOutput, "output", "o", "", "output config file path (default: ./kanholec-.toml)") loginCmd.Flags().String("username", "", "admin username (prompts if empty)") loginCmd.Flags().String("password", "", "admin password (prompts if empty)") loginCmd.Flags().String("client-name", "", "client name (fetches list if empty)") @@ -161,7 +161,7 @@ func saveConfig(data []byte) error { outputPath := authOutput if outputPath == "" { // Try to extract client name from config - outputPath = "frpc.toml" + outputPath = "kanholec.toml" } if err := os.MkdirAll(filepath.Dir(outputPath), 0755); err != nil { @@ -174,7 +174,7 @@ func saveConfig(data []byte) error { log.Infof("config saved to %s", outputPath) fmt.Printf("Config saved to %s\n", outputPath) - fmt.Printf("Run: frpc -c %s\n", outputPath) + fmt.Printf("Run: kanholec -c %s\n", outputPath) return nil } diff --git a/cmd/frpc/sub/gui.go b/cmd/kanholec/sub/gui.go similarity index 67% rename from cmd/frpc/sub/gui.go rename to cmd/kanholec/sub/gui.go index 82a31bc9..cf08c291 100644 --- a/cmd/frpc/sub/gui.go +++ b/cmd/kanholec/sub/gui.go @@ -1,17 +1,17 @@ -//go:build frpc_gui +//go:build kanholec_gui package sub import ( "github.com/spf13/cobra" - "github.com/fatedier/frp/client/gui" + "kanhole/client/gui" ) func init() { guiCmd := &cobra.Command{ Use: "gui", - Short: "Start the frpc graphical user interface", + Short: "Start the kanholec graphical user interface", RunE: func(cmd *cobra.Command, args []string) error { gui.Run() return nil diff --git a/cmd/frpc/sub/gui_stub.go b/cmd/kanholec/sub/gui_stub.go similarity index 57% rename from cmd/frpc/sub/gui_stub.go rename to cmd/kanholec/sub/gui_stub.go index 99ce8827..48ce898f 100644 --- a/cmd/frpc/sub/gui_stub.go +++ b/cmd/kanholec/sub/gui_stub.go @@ -1,4 +1,4 @@ -//go:build !frpc_gui +//go:build !kanholec_gui package sub @@ -11,11 +11,11 @@ import ( func init() { guiCmd := &cobra.Command{ Use: "gui", - Short: "Start the frpc graphical user interface", + Short: "Start the kanholec graphical user interface", RunE: func(cmd *cobra.Command, args []string) error { - fmt.Println("frpc GUI is not available in this build.") + fmt.Println("kanholec GUI is not available in this build.") fmt.Println("To build with GUI support, install OpenGL and X11 dev libraries, then:") - fmt.Println(" CGO_ENABLED=1 go build -tags frpc_gui -o frpc ./cmd/frpc") + fmt.Println(" CGO_ENABLED=1 go build -tags kanholec_gui -o kanholec ./cmd/kanholec") return nil }, } diff --git a/cmd/frpc/sub/nathole.go b/cmd/kanholec/sub/nathole.go similarity index 94% rename from cmd/frpc/sub/nathole.go rename to cmd/kanholec/sub/nathole.go index b76c8ab7..5e1d1262 100644 --- a/cmd/frpc/sub/nathole.go +++ b/cmd/kanholec/sub/nathole.go @@ -1,4 +1,4 @@ -// Copyright 2023 The frp Authors +// Copyright 2023 The kanhole Authors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -20,9 +20,9 @@ import ( "github.com/spf13/cobra" - "github.com/fatedier/frp/pkg/config" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/nathole" + "kanhole/pkg/config" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/nathole" ) var ( diff --git a/cmd/frpc/sub/proxy.go b/cmd/kanholec/sub/proxy.go similarity index 91% rename from cmd/frpc/sub/proxy.go rename to cmd/kanholec/sub/proxy.go index 8651f0b3..6ea1457b 100644 --- a/cmd/frpc/sub/proxy.go +++ b/cmd/kanholec/sub/proxy.go @@ -1,4 +1,4 @@ -// Copyright 2023 The frp Authors +// Copyright 2023 The kanhole Authors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -21,11 +21,11 @@ import ( "github.com/spf13/cobra" - "github.com/fatedier/frp/pkg/config" - "github.com/fatedier/frp/pkg/config/source" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/config/v1/validation" - "github.com/fatedier/frp/pkg/policy/security" + "kanhole/pkg/config" + "kanhole/pkg/config/source" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/config/v1/validation" + "kanhole/pkg/policy/security" ) var proxyTypes = []v1.ProxyType{ @@ -73,7 +73,7 @@ func init() { func NewProxyCommand(name string, c v1.ProxyConfigurer, clientCfg *v1.ClientCommonConfig) *cobra.Command { return &cobra.Command{ Use: name, - Short: fmt.Sprintf("Run frpc with a single %s proxy", name), + Short: fmt.Sprintf("Run kanholec with a single %s proxy", name), Run: func(cmd *cobra.Command, args []string) { if err := clientCfg.Complete(); err != nil { fmt.Println(err) @@ -106,7 +106,7 @@ func NewProxyCommand(name string, c v1.ProxyConfigurer, clientCfg *v1.ClientComm func NewVisitorCommand(name string, c v1.VisitorConfigurer, clientCfg *v1.ClientCommonConfig) *cobra.Command { return &cobra.Command{ Use: "visitor", - Short: fmt.Sprintf("Run frpc with a single %s visitor", name), + Short: fmt.Sprintf("Run kanholec with a single %s visitor", name), Run: func(cmd *cobra.Command, args []string) { if err := clientCfg.Complete(); err != nil { fmt.Println(err) diff --git a/cmd/frpc/sub/root.go b/cmd/kanholec/sub/root.go similarity index 88% rename from cmd/frpc/sub/root.go rename to cmd/kanholec/sub/root.go index 4345d66a..3fcbdc43 100644 --- a/cmd/frpc/sub/root.go +++ b/cmd/kanholec/sub/root.go @@ -30,15 +30,15 @@ import ( "github.com/spf13/cobra" - "github.com/fatedier/frp/client" - "github.com/fatedier/frp/pkg/config" - "github.com/fatedier/frp/pkg/config/source" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/config/v1/validation" - "github.com/fatedier/frp/pkg/policy/featuregate" - "github.com/fatedier/frp/pkg/policy/security" - "github.com/fatedier/frp/pkg/util/log" - "github.com/fatedier/frp/pkg/util/version" + "kanhole/client" + "kanhole/pkg/config" + "kanhole/pkg/config/source" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/config/v1/validation" + "kanhole/pkg/policy/featuregate" + "kanhole/pkg/policy/security" + "kanhole/pkg/util/log" + "kanhole/pkg/util/version" ) var ( @@ -51,9 +51,9 @@ var ( ) func init() { - rootCmd.PersistentFlags().StringVarP(&cfgFile, "config", "c", "./frpc.ini", "config file of frpc") - rootCmd.PersistentFlags().StringVarP(&cfgDir, "config_dir", "", "", "config directory, run one frpc service for each file in config directory") - rootCmd.PersistentFlags().BoolVarP(&showVersion, "version", "v", false, "version of frpc") + rootCmd.PersistentFlags().StringVarP(&cfgFile, "config", "c", "./kanholec.toml", "config file of kanholec") + rootCmd.PersistentFlags().StringVarP(&cfgDir, "config_dir", "", "", "config directory, run one kanholec service for each file in config directory") + rootCmd.PersistentFlags().BoolVarP(&showVersion, "version", "v", false, "version of kanholec") rootCmd.PersistentFlags().BoolVarP(&strictConfigMode, "strict_config", "", true, "strict config parsing mode, unknown fields will cause an errors") rootCmd.PersistentFlags().StringVarP(&serverConfigURL, "server-config", "", "", "fetch config from frps server URL (auto-reloads on change)") @@ -62,8 +62,8 @@ func init() { } var rootCmd = &cobra.Command{ - Use: "frpc", - Short: "frpc is the client of frp (https://github.com/fatedier/frp)", + Use: "kanholec", + Short: "kanholec is the client component of kanhole", RunE: func(cmd *cobra.Command, args []string) error { if showVersion { fmt.Println(version.Full()) @@ -72,7 +72,7 @@ var rootCmd = &cobra.Command{ unsafeFeatures := security.NewUnsafeFeatures(allowUnsafe) - // If cfgDir is not empty, run multiple frpc service for each config file in cfgDir. + // If cfgDir is not empty, run multiple kanholec service for each config file in cfgDir. // Note that it's only designed for testing. It's not guaranteed to be stable. if cfgDir != "" { _ = runMultipleClients(cfgDir, unsafeFeatures) @@ -111,7 +111,7 @@ func runMultipleClients(cfgDir string, unsafeFeatures *security.UnsafeFeatures) defer wg.Done() err := runClient(path, unsafeFeatures) if err != nil { - fmt.Printf("frpc service error for config file [%s]\n", path) + fmt.Printf("kanholec service error for config file [%s]\n", path) } }() return nil @@ -243,8 +243,8 @@ func startServiceWithAggregator( log.InitLogger(cfg.Log.To, cfg.Log.Level, int(cfg.Log.MaxDays), cfg.Log.DisablePrintColor) if cfgFile != "" { - log.Infof("start frpc service for config file [%s] with aggregated configuration", cfgFile) - defer log.Infof("frpc service for config file [%s] stopped", cfgFile) + log.Infof("start kanholec service for config file [%s] with aggregated configuration", cfgFile) + defer log.Infof("kanholec service for config file [%s] stopped", cfgFile) } svr, err := client.NewService(client.ServiceOptions{ Common: cfg, diff --git a/cmd/frpc/sub/verify.go b/cmd/kanholec/sub/verify.go similarity index 81% rename from cmd/frpc/sub/verify.go rename to cmd/kanholec/sub/verify.go index 830f7bf1..4b86bab8 100644 --- a/cmd/frpc/sub/verify.go +++ b/cmd/kanholec/sub/verify.go @@ -1,4 +1,4 @@ -// Copyright 2021 The frp Authors +// Copyright 2021 The kanhole Authors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -20,9 +20,9 @@ import ( "github.com/spf13/cobra" - "github.com/fatedier/frp/pkg/config" - "github.com/fatedier/frp/pkg/config/v1/validation" - "github.com/fatedier/frp/pkg/policy/security" + "kanhole/pkg/config" + "kanhole/pkg/config/v1/validation" + "kanhole/pkg/policy/security" ) func init() { @@ -34,7 +34,7 @@ var verifyCmd = &cobra.Command{ Short: "Verify that the configures is valid", RunE: func(cmd *cobra.Command, args []string) error { if cfgFile == "" { - fmt.Println("frpc: the configuration file is not specified") + fmt.Println("kanholec: the configuration file is not specified") return nil } @@ -53,7 +53,7 @@ var verifyCmd = &cobra.Command{ os.Exit(1) } - fmt.Printf("frpc: the configuration file %s syntax is ok\n", cfgFile) + fmt.Printf("kanholec: the configuration file %s syntax is ok\n", cfgFile) return nil }, } diff --git a/go.mod b/go.mod index f63d7ead..790ca801 100644 --- a/go.mod +++ b/go.mod @@ -1,4 +1,4 @@ -module github.com/fatedier/frp +module kanhole go 1.25.0 diff --git a/packaging/windows/frpc.default.toml b/packaging/windows/frpc.default.toml deleted file mode 100644 index b109e019..00000000 --- a/packaging/windows/frpc.default.toml +++ /dev/null @@ -1,10 +0,0 @@ -# frpc configuration -# Generated by frpc installer -# Edit this file to configure your frp client. - -serverAddr = "127.0.0.1" -serverPort = 7000 -auth.token = "" - -# Uncomment and set the URL to auto-fetch config from frps: -# configURL = "http://your-server:7500/admin/api/frpc/proxy-config/YOUR_KEY" diff --git a/packaging/windows/install.ps1 b/packaging/windows/install.ps1 index 6d36b1fb..b4034162 100644 --- a/packaging/windows/install.ps1 +++ b/packaging/windows/install.ps1 @@ -1,13 +1,13 @@ <# .SYNOPSIS - frpc Windows Setup Wizard (Interactive PowerShell Installer) + kanholec Windows Setup Wizard (Interactive PowerShell Installer) .DESCRIPTION - Interactive installer for frpc with EULA acceptance, directory selection, + Interactive installer for kanholec with EULA acceptance, directory selection, and optional features (PATH, shortcuts, desktop icon). .PARAMETER Unattended Run in silent mode with defaults. .PARAMETER InstallDir - Installation directory (default: $env:ProgramFiles\frpc). + Installation directory (default: $env:ProgramFiles\kanholec). .EXAMPLE .\install.ps1 .\install.ps1 -Unattended @@ -15,17 +15,17 @@ param( [switch]$Unattended, - [string]$InstallDir = "$env:ProgramFiles\frpc" + [string]$InstallDir = "$env:ProgramFiles\kanholec" ) $ErrorActionPreference = "Stop" -$host.UI.RawUI.WindowTitle = "frpc Setup Wizard" -$env:FRPC_VERSION = "0.62.0" +$host.UI.RawUI.WindowTitle = "kanholec Setup Wizard" +$env:KANHOLEC_VERSION = "0.62.0" function Write-Banner { Clear-Host Write-Host "========================================" -ForegroundColor Cyan - Write-Host " frpc - frp Client v$env:FRPC_VERSION" -ForegroundColor Cyan + Write-Host " kanholec - kanhole Client v$env:KANHOLEC_VERSION" -ForegroundColor Cyan Write-Host " Setup Wizard" -ForegroundColor Cyan Write-Host "========================================" -ForegroundColor Cyan Write-Host "" @@ -40,7 +40,7 @@ function Show-License { if (Test-Path $Path) { Get-Content $Path | ForEach-Object { Write-Host $_ } } else { - Write-Host "frpc is licensed under the Apache License, Version 2.0." + Write-Host "kanholec is licensed under the Apache License, Version 2.0." Write-Host "See http://www.apache.org/licenses/LICENSE-2.0" } Write-Host "" @@ -86,7 +86,7 @@ function Select-Components { Write-Host "" $components = @{ - "Main" = @{Desc="frpc binary and config"; Default=$true} + "Main" = @{Desc="kanholec binary and config"; Default=$true} "Path" = @{Desc="Add to system PATH"; Default=$true} "StartMenu" = @{Desc="Start Menu shortcuts"; Default=$true} "Desktop" = @{Desc="Desktop shortcut"; Default=$false} @@ -144,42 +144,42 @@ function Install-Frpc { ) Write-Banner - Write-Host "Installing frpc..." -ForegroundColor Yellow + Write-Host "Installing kanholec..." -ForegroundColor Yellow Write-Host "==================" -ForegroundColor Yellow Write-Host "" # Create directories Write-Host " Creating directories..." -NoNewline New-Item -Path $InstallDir -ItemType Directory -Force | Out-Null - $configDir = "$env:ProgramData\frpc" + $configDir = "$env:ProgramData\kanholec" New-Item -Path $configDir -ItemType Directory -Force | Out-Null Write-Host " OK" -ForegroundColor Green # Copy binary - Write-Host " Copying frpc.exe..." -NoNewline + Write-Host " Copying kanholec.exe..." -NoNewline if ($BinarySource -and (Test-Path $BinarySource)) { - Copy-Item -Path $BinarySource -Destination "$InstallDir\frpc.exe" -Force + Copy-Item -Path $BinarySource -Destination "$InstallDir\kanholec.exe" -Force } else { # Download from GitHub - $url = "https://github.com/fatedier/frp/releases/download/v$env:FRPC_VERSION/frp_${env:FRPC_VERSION}_windows_amd64.zip" - $zipPath = "$env:TEMP\frpc.zip" + $url = "https://github.com/fatedier/kanhole/releases/download/v$env:KANHOLEC_VERSION/kanhole_${env:KANHOLEC_VERSION}_windows_amd64.zip" + $zipPath = "$env:TEMP\kanholec.zip" Write-Host "" Write-Host " Downloading from GitHub..." -NoNewline Invoke-WebRequest -Uri $url -OutFile $zipPath -UseBasicParsing - Expand-Archive -Path $zipPath -DestinationPath "$env:TEMP\frpc" -Force - $exePath = Get-ChildItem -Path "$env:TEMP\frpc" -Recurse -Filter "frpc.exe" | Select-Object -First 1 -ExpandProperty FullName - if (-not $exePath) { throw "frpc.exe not found in archive" } - Copy-Item -Path $exePath -Destination "$InstallDir\frpc.exe" -Force + Expand-Archive -Path $zipPath -DestinationPath "$env:TEMP\kanholec" -Force + $exePath = Get-ChildItem -Path "$env:TEMP\kanholec" -Recurse -Filter "kanholec.exe" | Select-Object -First 1 -ExpandProperty FullName + if (-not $exePath) { throw "kanholec.exe not found in archive" } + Copy-Item -Path $exePath -Destination "$InstallDir\kanholec.exe" -Force } Write-Host " OK" -ForegroundColor Green # Config file Write-Host " Creating config..." -NoNewline - $configFile = "$configDir\frpc.toml" + $configFile = "$configDir\kanholec.toml" if (-not (Test-Path $configFile)) { @" -# frpc configuration -# Edit this file to configure your frp client. +# kanholec configuration +# Edit this file to configure your kanhole client. serverAddr = "127.0.0.1" serverPort = 7000 @@ -203,13 +203,13 @@ auth.token = "" # Start Menu if ($Components["StartMenu"]) { Write-Host " Creating Start Menu shortcuts..." -NoNewline - $startMenu = "$([Environment]::GetFolderPath('CommonStartMenu'))\Programs\frpc" + $startMenu = "$([Environment]::GetFolderPath('CommonStartMenu'))\Programs\kanholec" New-Item -Path $startMenu -ItemType Directory -Force | Out-Null $wshell = New-Object -ComObject WScript.Shell - $shortcut = $wshell.CreateShortcut("$startMenu\frpc.lnk") - $shortcut.TargetPath = "$InstallDir\frpc.exe" + $shortcut = $wshell.CreateShortcut("$startMenu\kanholec.lnk") + $shortcut.TargetPath = "$InstallDir\kanholec.exe" $shortcut.Save() - $unlink = $wshell.CreateShortcut("$startMenu\Uninstall frpc.lnk") + $unlink = $wshell.CreateShortcut("$startMenu\Uninstall kanholec.lnk") $unlink.TargetPath = "$InstallDir\uninstall.ps1" $unlink.Save() Write-Host " OK" -ForegroundColor Green @@ -220,8 +220,8 @@ auth.token = "" Write-Host " Creating desktop shortcut..." -NoNewline $desktop = [Environment]::GetFolderPath('Desktop') $wshell = New-Object -ComObject WScript.Shell - $shortcut = $wshell.CreateShortcut("$desktop\frpc.lnk") - $shortcut.TargetPath = "$InstallDir\frpc.exe" + $shortcut = $wshell.CreateShortcut("$desktop\kanholec.lnk") + $shortcut.TargetPath = "$InstallDir\kanholec.exe" $shortcut.Save() Write-Host " OK" -ForegroundColor Green } @@ -232,17 +232,17 @@ auth.token = "" param([switch]`$Silent) `$InstallDir = "$InstallDir" if (-not `$Silent) { - `$choice = `$host.UI.PromptForChoice("Uninstall frpc", "Remove frpc from this computer?", @(@{Label="&Yes"; Help=""}, @{Label="&No"; Help=""}), 1) + `$choice = `$host.UI.PromptForChoice("Uninstall kanholec", "Remove kanholec from this computer?", @(@{Label="&Yes"; Help=""}, @{Label="&No"; Help=""}), 1) if (`$choice -ne 0) { exit } } # Remove files -Remove-Item -Path "`$InstallDir\frpc.exe" -Force -ErrorAction SilentlyContinue +Remove-Item -Path "`$InstallDir\kanholec.exe" -Force -ErrorAction SilentlyContinue Remove-Item -Path "`$InstallDir\uninstall.ps1" -Force -ErrorAction SilentlyContinue Remove-Item -Path "`$InstallDir" -Force -ErrorAction SilentlyContinue # Remove shortcuts -Remove-Item -Path "$([Environment]::GetFolderPath('CommonStartMenu'))\Programs\frpc" -Recurse -Force -ErrorAction SilentlyContinue -Remove-Item -Path "$([Environment]::GetFolderPath('Desktop'))\frpc.lnk" -Force -ErrorAction SilentlyContinue -Write-Host "frpc has been uninstalled." +Remove-Item -Path "$([Environment]::GetFolderPath('CommonStartMenu'))\Programs\kanholec" -Recurse -Force -ErrorAction SilentlyContinue +Remove-Item -Path "$([Environment]::GetFolderPath('Desktop'))\kanholec.lnk" -Force -ErrorAction SilentlyContinue +Write-Host "kanholec has been uninstalled." "@ | Out-File -FilePath "$InstallDir\uninstall.ps1" -Encoding utf8 Write-Host " OK" -ForegroundColor Green @@ -250,21 +250,21 @@ Write-Host "frpc has been uninstalled." Write-Host "Installation complete!" -ForegroundColor Green Write-Host "" Write-Host "Quick start:" -ForegroundColor Yellow - Write-Host " frpc --help" - Write-Host " frpc --server-config http://your-server:7500/admin/api/frpc/proxy-config/YOUR_KEY" - Write-Host " frpc -c $configFile" + Write-Host " kanholec --help" + Write-Host " kanholec --server-config http://your-server:7500/admin/api/kanholec/proxy-config/YOUR_KEY" + Write-Host " kanholec -c $configFile" Write-Host "" Write-Host "Auth with provisioning token:" -ForegroundColor Yellow - Write-Host " frpc auth login --server http://your-server:7500 --client-name myclient" + Write-Host " kanholec auth login --server http://your-server:7500 --client-name myclient" Write-Host "" } # ===== Main ===== $scriptDir = Split-Path -Parent $PSCommandPath -$binarySource = Join-Path $scriptDir "..\bin\frpc-windows-amd64.exe" +$binarySource = Join-Path $scriptDir "..\bin\kanholec-windows-amd64.exe" if (-not (Test-Path $binarySource)) { - $binarySource = Join-Path $scriptDir "frpc-windows-amd64.exe" + $binarySource = Join-Path $scriptDir "kanholec-windows-amd64.exe" } if (-not (Test-Path $binarySource)) { $binarySource = $null @@ -296,14 +296,14 @@ if ($Unattended) { Write-Host "" $runNow = $host.UI.PromptForChoice( "Setup Complete", - "Run frpc now?", + "Run kanholec now?", [System.Management.Automation.Host.ChoiceDescription[]]@( - @{Label="&Yes"; Help="Run frpc"}, + @{Label="&Yes"; Help="Run kanholec"}, @{Label="&No"; Help="Close"} ), 0 ) if ($runNow -eq 0) { - Start-Process "$dir\frpc.exe" + Start-Process "$dir\kanholec.exe" } } diff --git a/packaging/windows/kanholec.default.toml b/packaging/windows/kanholec.default.toml new file mode 100644 index 00000000..92749f48 --- /dev/null +++ b/packaging/windows/kanholec.default.toml @@ -0,0 +1,10 @@ +# kanholec configuration +# Generated by kanholec installer +# Edit this file to configure your kanhole client. + +serverAddr = "127.0.0.1" +serverPort = 7000 +auth.token = "" + +# Uncomment and set the URL to auto-fetch config from kanholes: +# configURL = "http://your-server:7500/admin/api/kanholec/proxy-config/YOUR_KEY" diff --git a/packaging/windows/frpc.nsi b/packaging/windows/kanholec.nsi similarity index 71% rename from packaging/windows/frpc.nsi rename to packaging/windows/kanholec.nsi index 2af53de4..4ebffb04 100644 --- a/packaging/windows/frpc.nsi +++ b/packaging/windows/kanholec.nsi @@ -1,16 +1,16 @@ -; frpc Windows Installer (NSIS) -; Build: makensis frpc.nsi +; kanholec Windows Installer (NSIS) +; Build: makensis kanholec.nsi ; Requires: NSIS 3.x (https://nsis.sourceforge.io) -!define PRODUCT_NAME "frpc" +!define PRODUCT_NAME "kanholec" !define PRODUCT_VERSION "0.62.0" -!define PRODUCT_PUBLISHER "frp Contributors" -!define PRODUCT_WEB_SITE "https://github.com/fatedier/frp" +!define PRODUCT_PUBLISHER "kanhole Contributors" +!define PRODUCT_WEB_SITE "https://github.com/kanhole/kanhole" !define PRODUCT_DIR "$PROGRAMFILES64\${PRODUCT_NAME}" !define PRODUCT_UNINSTALL_KEY "Software\Microsoft\Windows\CurrentVersion\Uninstall\${PRODUCT_NAME}" Name "${PRODUCT_NAME} ${PRODUCT_VERSION}" -OutFile "..\..\bin\frpc-${PRODUCT_VERSION}-setup.exe" +OutFile "..\..\bin\kanholec-${PRODUCT_VERSION}-setup.exe" InstallDir "${PRODUCT_DIR}" InstallDirRegKey HKLM "${PRODUCT_UNINSTALL_KEY}" "InstallLocation" RequestExecutionLevel admin @@ -53,7 +53,7 @@ Function setFinishPage ${NSD_CreateLabel} 0 0 100% 24 "Setup Complete" Pop $0 - ${NSD_CreateCheckbox} 0 30 100% 12 "Run frpc now" + ${NSD_CreateCheckbox} 0 30 100% 12 "Run kanholec now" Pop $RunNowCheckbox ${NSD_Check} $RunNowCheckbox @@ -68,24 +68,24 @@ Function .onGUIEnd ${NSD_GetState} $ShowReadmeCheckbox $ReadmeState ${If} $RunNowState == ${BST_CHECKED} - ExecShell "open" "$INSTDIR\frpc.exe" + ExecShell "open" "$INSTDIR\kanholec.exe" ${EndIf} ${If} $ReadmeState == ${BST_CHECKED} - ExecShell "open" "$PROGRAMDATA\frpc" + ExecShell "open" "$PROGRAMDATA\kanholec" ${EndIf} FunctionEnd -Section "frpc (required)" SEC_FRPC +Section "kanholec (required)" SEC_KANHOLEC SectionIn RO SetOutPath "$INSTDIR" - File "..\..\bin\frpc-windows-amd64.exe" - Rename "$INSTDIR\frpc-windows-amd64.exe" "$INSTDIR\frpc.exe" + File "..\..\bin\kanholec-windows-amd64.exe" + Rename "$INSTDIR\kanholec-windows-amd64.exe" "$INSTDIR\kanholec.exe" ; Config directory - CreateDirectory "$PROGRAMDATA\frpc" - SetOutPath "$PROGRAMDATA\frpc" - File "/oname=frpc.toml" "..\..\packaging\windows\frpc.default.toml" + CreateDirectory "$PROGRAMDATA\kanholec" + SetOutPath "$PROGRAMDATA\kanholec" + File "/oname=kanholec.toml" "..\..\packaging\windows\kanholec.default.toml" WriteUninstaller "$INSTDIR\uninstall.exe" @@ -95,7 +95,7 @@ Section "frpc (required)" SEC_FRPC WriteRegStr HKLM "${PRODUCT_UNINSTALL_KEY}" "DisplayVersion" "${PRODUCT_VERSION}" WriteRegStr HKLM "${PRODUCT_UNINSTALL_KEY}" "Publisher" "${PRODUCT_PUBLISHER}" WriteRegStr HKLM "${PRODUCT_UNINSTALL_KEY}" "URLInfoAbout" "${PRODUCT_WEB_SITE}" - WriteRegStr HKLM "${PRODUCT_UNINSTALL_KEY}" "DisplayIcon" "$INSTDIR\frpc.exe,0" + WriteRegStr HKLM "${PRODUCT_UNINSTALL_KEY}" "DisplayIcon" "$INSTDIR\kanholec.exe,0" WriteRegStr HKLM "${PRODUCT_UNINSTALL_KEY}" "InstallLocation" "$INSTDIR" WriteRegDWORD HKLM "${PRODUCT_UNINSTALL_KEY}" "NoModify" 1 WriteRegDWORD HKLM "${PRODUCT_UNINSTALL_KEY}" "NoRepair" 1 @@ -103,8 +103,8 @@ SectionEnd Section "Start Menu Shortcuts" SEC_SHORTCUTS CreateDirectory "$SMPROGRAMS\${PRODUCT_NAME}" - CreateShortCut "$SMPROGRAMS\${PRODUCT_NAME}\frpc.lnk" "$INSTDIR\frpc.exe" "" "$INSTDIR\frpc.exe" 0 - CreateShortCut "$SMPROGRAMS\${PRODUCT_NAME}\Config Directory.lnk" "$PROGRAMDATA\frpc" + CreateShortCut "$SMPROGRAMS\${PRODUCT_NAME}\kanholec.lnk" "$INSTDIR\kanholec.exe" "" "$INSTDIR\kanholec.exe" 0 + CreateShortCut "$SMPROGRAMS\${PRODUCT_NAME}\Config Directory.lnk" "$PROGRAMDATA\kanholec" CreateShortCut "$SMPROGRAMS\${PRODUCT_NAME}\Uninstall.lnk" "$INSTDIR\uninstall.exe" SectionEnd @@ -114,33 +114,33 @@ Section "Add to PATH" SEC_PATH SectionEnd Section "Desktop Shortcut" SEC_DESKTOP - CreateShortCut "$DESKTOP\frpc.lnk" "$INSTDIR\frpc.exe" "" "$INSTDIR\frpc.exe" 0 + CreateShortCut "$DESKTOP\kanholec.lnk" "$INSTDIR\kanholec.exe" "" "$INSTDIR\kanholec.exe" 0 SectionEnd ; Descriptions -LangString DESC_SEC_FRPC ${LANG_ENGLISH} "frpc binary and default configuration." -LangString DESC_SEC_SHORTCUTS ${LANG_ENGLISH} "Start menu shortcuts for frpc." -LangString DESC_SEC_PATH ${LANG_ENGLISH} "Add frpc installation directory to system PATH." -LangString DESC_SEC_DESKTOP ${LANG_ENGLISH} "Create a desktop shortcut for frpc." +LangString DESC_SEC_KANHOLEC ${LANG_ENGLISH} "kanholec binary and default configuration." +LangString DESC_SEC_SHORTCUTS ${LANG_ENGLISH} "Start menu shortcuts for kanholec." +LangString DESC_SEC_PATH ${LANG_ENGLISH} "Add kanholec installation directory to system PATH." +LangString DESC_SEC_DESKTOP ${LANG_ENGLISH} "Create a desktop shortcut for kanholec." !insertmacro MUI_FUNCTION_DESCRIPTION_BEGIN - !insertmacro MUI_DESCRIPTION_TEXT ${SEC_FRPC} $(DESC_SEC_FRPC) + !insertmacro MUI_DESCRIPTION_TEXT ${SEC_KANHOLEC} $(DESC_SEC_KANHOLEC) !insertmacro MUI_DESCRIPTION_TEXT ${SEC_SHORTCUTS} $(DESC_SEC_SHORTCUTS) !insertmacro MUI_DESCRIPTION_TEXT ${SEC_PATH} $(DESC_SEC_PATH) !insertmacro MUI_DESCRIPTION_TEXT ${SEC_DESKTOP} $(DESC_SEC_DESKTOP) !insertmacro MUI_FUNCTION_DESCRIPTION_END Section "Uninstall" - Delete "$INSTDIR\frpc.exe" + Delete "$INSTDIR\kanholec.exe" Delete "$INSTDIR\uninstall.exe" RMDir "$INSTDIR" - Delete "$SMPROGRAMS\${PRODUCT_NAME}\frpc.lnk" + Delete "$SMPROGRAMS\${PRODUCT_NAME}\kanholec.lnk" Delete "$SMPROGRAMS\${PRODUCT_NAME}\Config Directory.lnk" Delete "$SMPROGRAMS\${PRODUCT_NAME}\Uninstall.lnk" RMDir "$SMPROGRAMS\${PRODUCT_NAME}" - Delete "$DESKTOP\frpc.lnk" + Delete "$DESKTOP\kanholec.lnk" EnVar::DeleteValue "PATH" "$INSTDIR" diff --git a/packaging/windows/frpc.wxs b/packaging/windows/kanholec.wxs similarity index 50% rename from packaging/windows/frpc.wxs rename to packaging/windows/kanholec.wxs index 6ae56e7f..33214bb6 100644 --- a/packaging/windows/frpc.wxs +++ b/packaging/windows/kanholec.wxs @@ -1,45 +1,45 @@ + Manufacturer="kanhole Contributors"> + Description="kanhole Client" + Comments="kanholec is the client component of kanhole - a fast reverse proxy." /> - + - + - + - + - - + + - + - + diff --git a/packaging/windows/license.rtf b/packaging/windows/license.rtf index 00f2ba68..46523213 100644 --- a/packaging/windows/license.rtf +++ b/packaging/windows/license.rtf @@ -1,14 +1,14 @@ {\rtf1\ansi\ansicpg1252\deff0\deflang1033\deftab720{\fonttbl{\f0\fnil\fcharset0 Arial;}{\f1\fmodern\fcharset0 Courier New;}} {\colortbl\red0\green0\blue0;\red255\green255\blue255;} -\viewkind4\uc1\pard\qc\b\fs28 frpc - frp Client\par -\b0\fs20 Version 0.62.0\par +\viewkind4\uc1\pard\qc\b\fs28 kanholec\par +\b0\fs20 Version 0.1.0\par \pard\sa200\sl240\slmult1\fs20\par \pard\sa200\sl240\slmult1\b\fs24 License Agreement\b0\fs20\par \pard\sa200\sl240\slmult1\par -\pard\sa200\sl240\slmult1\fs20 This is a legal agreement between you (the "Licensee") and the frp project contributors ("Licensor"). By installing or using frpc, you agree to the following terms and conditions.\par +\pard\sa200\sl240\slmult1\fs20 This is a legal agreement between you (the "Licensee") and the kanhole project contributors ("Licensor"). By installing or using kanholec, you agree to the following terms and conditions.\par \pard\sa200\sl240\slmult1\par \pard\sa200\sl240\slmult1\b 1. Grant of License\b0\par -\pard\sa200\sl240\slmult1 The frpc software is licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with the License. You may obtain a copy of the License at:\par +\pard\sa200\sl240\slmult1 The kanholec software is licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with the License. You may obtain a copy of the License at:\par \pard\sa200\sl240\slmult1 http://www.apache.org/licenses/LICENSE-2.0\par \pard\sa200\sl240\slmult1\par \pard\sa200\sl240\slmult1\b 2. Distribution\b0\par diff --git a/packaging/windows/license.txt b/packaging/windows/license.txt index ab1669ee..d8cb286f 100644 --- a/packaging/windows/license.txt +++ b/packaging/windows/license.txt @@ -1,6 +1,6 @@ -frpc - frp Client (version 0.62.0) -===================================== -Copyright (c) frp project contributors. +kanholec - kanhole Client (version 0.1.0) +============================================ +Copyright (c) kanhole project contributors. Licensed under the Apache License, Version 2.0. TERMS AND CONDITIONS diff --git a/pkg/auth/auth.go b/pkg/auth/auth.go index 366b62ef..df6c1c6f 100644 --- a/pkg/auth/auth.go +++ b/pkg/auth/auth.go @@ -18,8 +18,8 @@ import ( "context" "fmt" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/msg" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/msg" ) type Setter interface { diff --git a/pkg/auth/oidc.go b/pkg/auth/oidc.go index 826a6715..1897c9cf 100644 --- a/pkg/auth/oidc.go +++ b/pkg/auth/oidc.go @@ -29,9 +29,9 @@ import ( "golang.org/x/oauth2" "golang.org/x/oauth2/clientcredentials" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/config/v1/validation" - "github.com/fatedier/frp/pkg/msg" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/config/v1/validation" + "kanhole/pkg/msg" ) // createOIDCHTTPClient creates an HTTP client with custom TLS and proxy configuration for OIDC token requests diff --git a/pkg/auth/oidc_test.go b/pkg/auth/oidc_test.go index 70e59883..7df5aefe 100644 --- a/pkg/auth/oidc_test.go +++ b/pkg/auth/oidc_test.go @@ -12,9 +12,9 @@ import ( "github.com/coreos/go-oidc/v3/oidc" "github.com/stretchr/testify/require" - "github.com/fatedier/frp/pkg/auth" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/msg" + "kanhole/pkg/auth" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/msg" ) type mockTokenVerifier struct{} diff --git a/pkg/auth/pass.go b/pkg/auth/pass.go index 2eaf3f0b..11377e8d 100644 --- a/pkg/auth/pass.go +++ b/pkg/auth/pass.go @@ -15,7 +15,7 @@ package auth import ( - "github.com/fatedier/frp/pkg/msg" + "kanhole/pkg/msg" ) var AlwaysPassVerifier = &alwaysPass{} diff --git a/pkg/auth/token.go b/pkg/auth/token.go index 9ee993f9..a423dff5 100644 --- a/pkg/auth/token.go +++ b/pkg/auth/token.go @@ -19,9 +19,9 @@ import ( "slices" "time" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/msg" - "github.com/fatedier/frp/pkg/util/util" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/msg" + "kanhole/pkg/util/util" ) type TokenAuthSetterVerifier struct { diff --git a/pkg/config/flags.go b/pkg/config/flags.go index e1f2251d..363604dd 100644 --- a/pkg/config/flags.go +++ b/pkg/config/flags.go @@ -22,9 +22,9 @@ import ( "github.com/spf13/cobra" "github.com/spf13/pflag" - "github.com/fatedier/frp/pkg/config/types" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/config/v1/validation" + "kanhole/pkg/config/types" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/config/v1/validation" ) // WordSepNormalizeFunc changes all flags that contain "_" separators @@ -154,8 +154,8 @@ func RegisterClientCommonConfigFlags(cmd *cobra.Command, c *v1.ClientCommonConfi } if !options.sshMode { - cmd.PersistentFlags().StringVarP(&c.ServerAddr, "server_addr", "s", "127.0.0.1", "frp server's address") - cmd.PersistentFlags().IntVarP(&c.ServerPort, "server_port", "P", 7000, "frp server's port") + cmd.PersistentFlags().StringVarP(&c.ServerAddr, "server_addr", "s", "127.0.0.1", "kanhole server's address") + cmd.PersistentFlags().IntVarP(&c.ServerPort, "server_port", "P", 7000, "kanhole server's port") cmd.PersistentFlags().StringVarP(&c.Transport.Protocol, "protocol", "p", "tcp", fmt.Sprintf("optional values are %v", validation.SupportedTransportProtocols)) cmd.PersistentFlags().StringVarP(&c.Log.Level, "log_level", "", "info", "log level") @@ -248,7 +248,7 @@ func RegisterServerConfigFlags(cmd *cobra.Command, c *v1.ServerConfig, opts ...R cmd.PersistentFlags().StringVarP(&c.SubDomainHost, "subdomain_host", "", "", "subdomain host") cmd.PersistentFlags().VarP(&PortsRangeSliceFlag{V: &c.AllowPorts}, "allow_ports", "", "allow ports") cmd.PersistentFlags().Int64VarP(&c.MaxPortsPerClient, "max_ports_per_client", "", 0, "max ports per client") - cmd.PersistentFlags().BoolVarP(&c.Transport.TLS.Force, "tls_only", "", false, "frps tls only") + cmd.PersistentFlags().BoolVarP(&c.Transport.TLS.Force, "tls_only", "", false, "kanhole tls only") webServerTLS := v1.TLSConfig{} cmd.PersistentFlags().StringVarP(&webServerTLS.CertFile, "dashboard_tls_cert_file", "", "", "dashboard tls cert file") diff --git a/pkg/config/legacy/client.go b/pkg/config/legacy/client.go index 8cc02614..d9cce12a 100644 --- a/pkg/config/legacy/client.go +++ b/pkg/config/legacy/client.go @@ -23,8 +23,8 @@ import ( "gopkg.in/ini.v1" - legacyauth "github.com/fatedier/frp/pkg/auth/legacy" - "github.com/fatedier/frp/pkg/util/util" + legacyauth "kanhole/pkg/auth/legacy" + "kanhole/pkg/util/util" ) // ClientCommonConf is the configuration parsed from ini. diff --git a/pkg/config/legacy/conversion.go b/pkg/config/legacy/conversion.go index ec8d0698..f43984e5 100644 --- a/pkg/config/legacy/conversion.go +++ b/pkg/config/legacy/conversion.go @@ -19,8 +19,8 @@ import ( "github.com/samber/lo" - "github.com/fatedier/frp/pkg/config/types" - v1 "github.com/fatedier/frp/pkg/config/v1" + "kanhole/pkg/config/types" + v1 "kanhole/pkg/config/v1" ) func Convert_ClientCommonConf_To_v1(conf *ClientCommonConf) *v1.ClientCommonConfig { diff --git a/pkg/config/legacy/proxy.go b/pkg/config/legacy/proxy.go index 8d7cf9a0..d81c0b8e 100644 --- a/pkg/config/legacy/proxy.go +++ b/pkg/config/legacy/proxy.go @@ -20,7 +20,7 @@ import ( "gopkg.in/ini.v1" - "github.com/fatedier/frp/pkg/config/types" + "kanhole/pkg/config/types" ) type ProxyType string diff --git a/pkg/config/legacy/server.go b/pkg/config/legacy/server.go index 1cfa1bdc..2d0880b2 100644 --- a/pkg/config/legacy/server.go +++ b/pkg/config/legacy/server.go @@ -19,7 +19,7 @@ import ( "gopkg.in/ini.v1" - legacyauth "github.com/fatedier/frp/pkg/auth/legacy" + legacyauth "kanhole/pkg/auth/legacy" ) type HTTPPluginOptions struct { @@ -131,7 +131,7 @@ type ServerCommonConf struct { // SubDomainHost specifies the domain that will be attached to sub-domains // requested by the client when using Vhost proxying. For example, if this - // value is set to "frps.com" and the client requested the subdomain + // value is set to "kanhole.com" and the client requested the subdomain // "test", the resulting URL would be "test.frps.com". By default, this // value is "". SubDomainHost string `ini:"subdomain_host" json:"subdomain_host"` diff --git a/pkg/config/legacy/value.go b/pkg/config/legacy/value.go index ecf805c9..32e593b4 100644 --- a/pkg/config/legacy/value.go +++ b/pkg/config/legacy/value.go @@ -46,7 +46,7 @@ func GetValues() *Values { } func RenderContent(in []byte) (out []byte, err error) { - tmpl, errRet := template.New("frp").Parse(string(in)) + tmpl, errRet := template.New("kanhole").Parse(string(in)) if errRet != nil { err = errRet return diff --git a/pkg/config/load.go b/pkg/config/load.go index 38634fc5..61ff6376 100644 --- a/pkg/config/load.go +++ b/pkg/config/load.go @@ -30,12 +30,12 @@ import ( "k8s.io/apimachinery/pkg/util/sets" "k8s.io/apimachinery/pkg/util/yaml" - "github.com/fatedier/frp/pkg/config/legacy" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/config/v1/validation" - "github.com/fatedier/frp/pkg/msg" - "github.com/fatedier/frp/pkg/util/jsonx" - "github.com/fatedier/frp/pkg/util/util" + "kanhole/pkg/config/legacy" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/config/v1/validation" + "kanhole/pkg/msg" + "kanhole/pkg/util/jsonx" + "kanhole/pkg/util/util" ) var glbEnvs map[string]string @@ -82,7 +82,7 @@ func DetectLegacyINIFormatFromFile(path string) bool { } func RenderWithTemplate(in []byte, values *Values) ([]byte, error) { - tmpl, err := template.New("frp").Funcs(template.FuncMap{ + tmpl, err := template.New("kanhole").Funcs(template.FuncMap{ "parseNumberRange": parseNumberRange, "parseNumberRangePair": parseNumberRangePair, }).Parse(string(in)) diff --git a/pkg/config/load_test.go b/pkg/config/load_test.go index b711a5c1..ada2e4d5 100644 --- a/pkg/config/load_test.go +++ b/pkg/config/load_test.go @@ -22,7 +22,7 @@ import ( "github.com/stretchr/testify/require" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) const tomlServerContent = ` diff --git a/pkg/config/source/aggregator.go b/pkg/config/source/aggregator.go index 58496932..15c7e9ea 100644 --- a/pkg/config/source/aggregator.go +++ b/pkg/config/source/aggregator.go @@ -22,7 +22,7 @@ import ( "slices" "sync" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) type Aggregator struct { diff --git a/pkg/config/source/aggregator_test.go b/pkg/config/source/aggregator_test.go index 380c05cf..4a035c82 100644 --- a/pkg/config/source/aggregator_test.go +++ b/pkg/config/source/aggregator_test.go @@ -20,7 +20,7 @@ import ( "github.com/stretchr/testify/require" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) // mockProxy creates a TCP proxy config for testing diff --git a/pkg/config/source/base_source.go b/pkg/config/source/base_source.go index ab1f59fe..b7faa45a 100644 --- a/pkg/config/source/base_source.go +++ b/pkg/config/source/base_source.go @@ -17,7 +17,7 @@ package source import ( "sync" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) // baseSource provides shared state and behavior for Source implementations. diff --git a/pkg/config/source/base_source_test.go b/pkg/config/source/base_source_test.go index 34ea9d9d..83736cd6 100644 --- a/pkg/config/source/base_source_test.go +++ b/pkg/config/source/base_source_test.go @@ -5,7 +5,7 @@ import ( "github.com/stretchr/testify/require" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) func TestBaseSourceLoadReturnsClonedConfigurers(t *testing.T) { diff --git a/pkg/config/source/clone.go b/pkg/config/source/clone.go index cacd5dbb..63dca10f 100644 --- a/pkg/config/source/clone.go +++ b/pkg/config/source/clone.go @@ -17,7 +17,7 @@ package source import ( "fmt" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) func cloneConfigurers( diff --git a/pkg/config/source/config_source.go b/pkg/config/source/config_source.go index 95c8cfa1..8316971e 100644 --- a/pkg/config/source/config_source.go +++ b/pkg/config/source/config_source.go @@ -14,7 +14,7 @@ package source -import v1 "github.com/fatedier/frp/pkg/config/v1" +import v1 "kanhole/pkg/config/v1" // ConfigSource implements Source for in-memory configuration. // All operations are thread-safe. diff --git a/pkg/config/source/config_source_test.go b/pkg/config/source/config_source_test.go index 793284e1..9588dd6a 100644 --- a/pkg/config/source/config_source_test.go +++ b/pkg/config/source/config_source_test.go @@ -19,7 +19,7 @@ import ( "github.com/stretchr/testify/require" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) func TestNewConfigSource(t *testing.T) { diff --git a/pkg/config/source/source.go b/pkg/config/source/source.go index a6cff226..400a91fb 100644 --- a/pkg/config/source/source.go +++ b/pkg/config/source/source.go @@ -15,7 +15,7 @@ package source import ( - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) // Source is the interface for configuration sources. diff --git a/pkg/config/source/store.go b/pkg/config/source/store.go index f568f885..b7ffb36e 100644 --- a/pkg/config/source/store.go +++ b/pkg/config/source/store.go @@ -20,8 +20,8 @@ import ( "os" "path/filepath" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/util/jsonx" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/util/jsonx" ) type StoreSourceConfig struct { diff --git a/pkg/config/source/store_test.go b/pkg/config/source/store_test.go index 8bb107c5..5a900e7c 100644 --- a/pkg/config/source/store_test.go +++ b/pkg/config/source/store_test.go @@ -22,8 +22,8 @@ import ( "github.com/stretchr/testify/require" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/util/jsonx" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/util/jsonx" ) func TestStoreSource_AddProxyAndVisitor_DoesNotApplyRuntimeDefaults(t *testing.T) { diff --git a/pkg/config/source/validation.go b/pkg/config/source/validation.go index 55bc4220..b2026e0d 100644 --- a/pkg/config/source/validation.go +++ b/pkg/config/source/validation.go @@ -17,7 +17,7 @@ package source import ( "fmt" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) func validateProxyName(proxy v1.ProxyConfigurer) (string, error) { diff --git a/pkg/config/template.go b/pkg/config/template.go index 16fe069f..7818f2ec 100644 --- a/pkg/config/template.go +++ b/pkg/config/template.go @@ -17,7 +17,7 @@ package config import ( "fmt" - "github.com/fatedier/frp/pkg/util/util" + "kanhole/pkg/util/util" ) type NumberPair struct { diff --git a/pkg/config/v1/client.go b/pkg/config/v1/client.go index 0a5c77af..fe8aa456 100644 --- a/pkg/config/v1/client.go +++ b/pkg/config/v1/client.go @@ -19,7 +19,7 @@ import ( "github.com/samber/lo" - "github.com/fatedier/frp/pkg/util/util" + "kanhole/pkg/util/util" ) type ClientConfig struct { diff --git a/pkg/config/v1/common.go b/pkg/config/v1/common.go index 41bd9a4c..a0d559a2 100644 --- a/pkg/config/v1/common.go +++ b/pkg/config/v1/common.go @@ -17,7 +17,7 @@ package v1 import ( "maps" - "github.com/fatedier/frp/pkg/util/util" + "kanhole/pkg/util/util" ) type AuthScope string diff --git a/pkg/config/v1/decode.go b/pkg/config/v1/decode.go index 427cea7f..5901c77a 100644 --- a/pkg/config/v1/decode.go +++ b/pkg/config/v1/decode.go @@ -19,7 +19,7 @@ import ( "fmt" "reflect" - "github.com/fatedier/frp/pkg/util/jsonx" + "kanhole/pkg/util/jsonx" ) type DecodeOptions struct { diff --git a/pkg/config/v1/proxy.go b/pkg/config/v1/proxy.go index e7d1a6b7..ec5f31b3 100644 --- a/pkg/config/v1/proxy.go +++ b/pkg/config/v1/proxy.go @@ -19,10 +19,10 @@ import ( "reflect" "slices" - "github.com/fatedier/frp/pkg/config/types" - "github.com/fatedier/frp/pkg/msg" - "github.com/fatedier/frp/pkg/util/jsonx" - "github.com/fatedier/frp/pkg/util/util" + "kanhole/pkg/config/types" + "kanhole/pkg/msg" + "kanhole/pkg/util/jsonx" + "kanhole/pkg/util/util" ) type ProxyTransport struct { diff --git a/pkg/config/v1/proxy_plugin.go b/pkg/config/v1/proxy_plugin.go index 0d6ca3d0..a4869335 100644 --- a/pkg/config/v1/proxy_plugin.go +++ b/pkg/config/v1/proxy_plugin.go @@ -19,8 +19,8 @@ import ( "github.com/samber/lo" - "github.com/fatedier/frp/pkg/util/jsonx" - "github.com/fatedier/frp/pkg/util/util" + "kanhole/pkg/util/jsonx" + "kanhole/pkg/util/util" ) const ( diff --git a/pkg/config/v1/server.go b/pkg/config/v1/server.go index a92aac97..f938317d 100644 --- a/pkg/config/v1/server.go +++ b/pkg/config/v1/server.go @@ -17,8 +17,8 @@ package v1 import ( "github.com/samber/lo" - "github.com/fatedier/frp/pkg/config/types" - "github.com/fatedier/frp/pkg/util/util" + "kanhole/pkg/config/types" + "kanhole/pkg/util/util" ) type ServerConfig struct { @@ -60,7 +60,7 @@ type ServerConfig struct { TCPMuxPassthrough bool `json:"tcpmuxPassthrough,omitempty"` // SubDomainHost specifies the domain that will be attached to sub-domains // requested by the client when using Vhost proxying. For example, if this - // value is set to "frps.com" and the client requested the subdomain + // value is set to "kanhole.com" and the client requested the subdomain // "test", the resulting URL would be "test.frps.com". SubDomainHost string `json:"subDomainHost,omitempty"` // Custom404Page specifies a path to a custom 404 page to display. If this diff --git a/pkg/config/v1/validation/auth.go b/pkg/config/v1/validation/auth.go index c70235dc..a8ecddee 100644 --- a/pkg/config/v1/validation/auth.go +++ b/pkg/config/v1/validation/auth.go @@ -17,8 +17,8 @@ package validation import ( "fmt" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/policy/security" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/policy/security" ) func (v *ConfigValidator) validateAuthTokenSource(token string, tokenSource *v1.ValueSource) error { diff --git a/pkg/config/v1/validation/auth_test.go b/pkg/config/v1/validation/auth_test.go index 4e90b44c..92c5a259 100644 --- a/pkg/config/v1/validation/auth_test.go +++ b/pkg/config/v1/validation/auth_test.go @@ -19,8 +19,8 @@ import ( "github.com/stretchr/testify/require" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/policy/security" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/policy/security" ) const ( diff --git a/pkg/config/v1/validation/client.go b/pkg/config/v1/validation/client.go index 77004317..a8876bb4 100644 --- a/pkg/config/v1/validation/client.go +++ b/pkg/config/v1/validation/client.go @@ -22,9 +22,9 @@ import ( "github.com/samber/lo" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/policy/featuregate" - "github.com/fatedier/frp/pkg/policy/security" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/policy/featuregate" + "kanhole/pkg/policy/security" ) func (v *ConfigValidator) ValidateClientCommonConfig(c *v1.ClientCommonConfig) (Warning, error) { diff --git a/pkg/config/v1/validation/common.go b/pkg/config/v1/validation/common.go index c7b93a32..1e05cf38 100644 --- a/pkg/config/v1/validation/common.go +++ b/pkg/config/v1/validation/common.go @@ -18,7 +18,7 @@ import ( "fmt" "slices" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) func validateWebServerConfig(c *v1.WebServerConfig) error { diff --git a/pkg/config/v1/validation/oidc.go b/pkg/config/v1/validation/oidc.go index c905e8e5..ec4ea83c 100644 --- a/pkg/config/v1/validation/oidc.go +++ b/pkg/config/v1/validation/oidc.go @@ -19,7 +19,7 @@ import ( "net/url" "strings" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) func ValidateOIDCClientCredentialsConfig(c *v1.AuthOIDCClientConfig) error { diff --git a/pkg/config/v1/validation/oidc_test.go b/pkg/config/v1/validation/oidc_test.go index bc21da6e..e025951b 100644 --- a/pkg/config/v1/validation/oidc_test.go +++ b/pkg/config/v1/validation/oidc_test.go @@ -21,7 +21,7 @@ import ( "github.com/stretchr/testify/require" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) func TestValidateOIDCClientCredentialsConfig(t *testing.T) { diff --git a/pkg/config/v1/validation/plugin.go b/pkg/config/v1/validation/plugin.go index 30a66d83..20854e29 100644 --- a/pkg/config/v1/validation/plugin.go +++ b/pkg/config/v1/validation/plugin.go @@ -17,7 +17,7 @@ package validation import ( "errors" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) func ValidateClientPluginOptions(c v1.ClientPluginOptions) error { diff --git a/pkg/config/v1/validation/proxy.go b/pkg/config/v1/validation/proxy.go index 744620f0..56104ade 100644 --- a/pkg/config/v1/validation/proxy.go +++ b/pkg/config/v1/validation/proxy.go @@ -22,7 +22,7 @@ import ( "k8s.io/apimachinery/pkg/util/validation" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) func validateProxyBaseConfigForClient(c *v1.ProxyBaseConfig) error { diff --git a/pkg/config/v1/validation/server.go b/pkg/config/v1/validation/server.go index 8be740aa..4d1b66ea 100644 --- a/pkg/config/v1/validation/server.go +++ b/pkg/config/v1/validation/server.go @@ -20,7 +20,7 @@ import ( "github.com/samber/lo" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) func (v *ConfigValidator) ValidateServerConfig(c *v1.ServerConfig) (Warning, error) { diff --git a/pkg/config/v1/validation/validation.go b/pkg/config/v1/validation/validation.go index 417cec0f..0de6981c 100644 --- a/pkg/config/v1/validation/validation.go +++ b/pkg/config/v1/validation/validation.go @@ -17,8 +17,8 @@ package validation import ( "errors" - v1 "github.com/fatedier/frp/pkg/config/v1" - splugin "github.com/fatedier/frp/pkg/plugin/server" + v1 "kanhole/pkg/config/v1" + splugin "kanhole/pkg/plugin/server" ) var ( diff --git a/pkg/config/v1/validation/validator.go b/pkg/config/v1/validation/validator.go index 1cfe3b21..b97fa53e 100644 --- a/pkg/config/v1/validation/validator.go +++ b/pkg/config/v1/validation/validator.go @@ -3,7 +3,7 @@ package validation import ( "fmt" - "github.com/fatedier/frp/pkg/policy/security" + "kanhole/pkg/policy/security" ) // ConfigValidator holds the context dependencies for configuration validation. diff --git a/pkg/config/v1/validation/visitor.go b/pkg/config/v1/validation/visitor.go index 50efc47d..d832b9f3 100644 --- a/pkg/config/v1/validation/visitor.go +++ b/pkg/config/v1/validation/visitor.go @@ -19,7 +19,7 @@ import ( "fmt" "slices" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) func ValidateVisitorConfigurer(c v1.VisitorConfigurer) error { diff --git a/pkg/config/v1/visitor.go b/pkg/config/v1/visitor.go index d1035d4f..0eb78f8f 100644 --- a/pkg/config/v1/visitor.go +++ b/pkg/config/v1/visitor.go @@ -17,8 +17,8 @@ package v1 import ( "reflect" - "github.com/fatedier/frp/pkg/util/jsonx" - "github.com/fatedier/frp/pkg/util/util" + "kanhole/pkg/util/jsonx" + "kanhole/pkg/util/util" ) type VisitorTransport struct { diff --git a/pkg/config/v1/visitor_plugin.go b/pkg/config/v1/visitor_plugin.go index 6541e3de..0e41b022 100644 --- a/pkg/config/v1/visitor_plugin.go +++ b/pkg/config/v1/visitor_plugin.go @@ -17,7 +17,7 @@ package v1 import ( "reflect" - "github.com/fatedier/frp/pkg/util/jsonx" + "kanhole/pkg/util/jsonx" ) const ( diff --git a/pkg/db/config.go b/pkg/db/config.go index cc17867d..c175a33e 100644 --- a/pkg/db/config.go +++ b/pkg/db/config.go @@ -5,8 +5,8 @@ import ( "encoding/json" "fmt" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/db/ent/serverconfig" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/db/ent/serverconfig" ) const configKey = "server_config" diff --git a/pkg/db/db.go b/pkg/db/db.go index 02cfff86..98af13c7 100644 --- a/pkg/db/db.go +++ b/pkg/db/db.go @@ -12,7 +12,7 @@ import ( entsql "entgo.io/ent/dialect/sql" "golang.org/x/crypto/bcrypt" - "github.com/fatedier/frp/pkg/db/ent" + "kanhole/pkg/db/ent" ) var ( diff --git a/pkg/db/ent/client.go b/pkg/db/ent/client.go index e1c68722..035674bf 100644 --- a/pkg/db/ent/client.go +++ b/pkg/db/ent/client.go @@ -9,15 +9,15 @@ import ( "log" "reflect" - "github.com/fatedier/frp/pkg/db/ent/migrate" + "kanhole/pkg/db/ent/migrate" "entgo.io/ent" "entgo.io/ent/dialect" "entgo.io/ent/dialect/sql" - "github.com/fatedier/frp/pkg/db/ent/frpcclient" - "github.com/fatedier/frp/pkg/db/ent/proxy" - "github.com/fatedier/frp/pkg/db/ent/serverconfig" - "github.com/fatedier/frp/pkg/db/ent/user" + "kanhole/pkg/db/ent/frpcclient" + "kanhole/pkg/db/ent/proxy" + "kanhole/pkg/db/ent/serverconfig" + "kanhole/pkg/db/ent/user" ) // Client is the client that holds all ent builders. diff --git a/pkg/db/ent/ent.go b/pkg/db/ent/ent.go index f7af97a6..7eca906d 100644 --- a/pkg/db/ent/ent.go +++ b/pkg/db/ent/ent.go @@ -12,10 +12,10 @@ import ( "entgo.io/ent" "entgo.io/ent/dialect/sql" "entgo.io/ent/dialect/sql/sqlgraph" - "github.com/fatedier/frp/pkg/db/ent/frpcclient" - "github.com/fatedier/frp/pkg/db/ent/proxy" - "github.com/fatedier/frp/pkg/db/ent/serverconfig" - "github.com/fatedier/frp/pkg/db/ent/user" + "kanhole/pkg/db/ent/frpcclient" + "kanhole/pkg/db/ent/proxy" + "kanhole/pkg/db/ent/serverconfig" + "kanhole/pkg/db/ent/user" ) // ent aliases to avoid import conflicts in user's code. diff --git a/pkg/db/ent/enttest/enttest.go b/pkg/db/ent/enttest/enttest.go index 1f527c3d..047c642b 100644 --- a/pkg/db/ent/enttest/enttest.go +++ b/pkg/db/ent/enttest/enttest.go @@ -5,12 +5,12 @@ package enttest import ( "context" - "github.com/fatedier/frp/pkg/db/ent" + "kanhole/pkg/db/ent" // required by schema hooks. - _ "github.com/fatedier/frp/pkg/db/ent/runtime" + _ "kanhole/pkg/db/ent/runtime" "entgo.io/ent/dialect/sql/schema" - "github.com/fatedier/frp/pkg/db/ent/migrate" + "kanhole/pkg/db/ent/migrate" ) type ( diff --git a/pkg/db/ent/frpcclient.go b/pkg/db/ent/frpcclient.go index b8625b3c..0708e50c 100644 --- a/pkg/db/ent/frpcclient.go +++ b/pkg/db/ent/frpcclient.go @@ -9,7 +9,7 @@ import ( "entgo.io/ent" "entgo.io/ent/dialect/sql" - "github.com/fatedier/frp/pkg/db/ent/frpcclient" + "kanhole/pkg/db/ent/frpcclient" ) // FrpcClient is the model entity for the FrpcClient schema. diff --git a/pkg/db/ent/frpcclient/where.go b/pkg/db/ent/frpcclient/where.go index 26fce8ea..2d1618ae 100644 --- a/pkg/db/ent/frpcclient/where.go +++ b/pkg/db/ent/frpcclient/where.go @@ -6,7 +6,7 @@ import ( "time" "entgo.io/ent/dialect/sql" - "github.com/fatedier/frp/pkg/db/ent/predicate" + "kanhole/pkg/db/ent/predicate" ) // ID filters vertices based on their ID field. diff --git a/pkg/db/ent/frpcclient_create.go b/pkg/db/ent/frpcclient_create.go index 006f6f65..6b66eb9f 100644 --- a/pkg/db/ent/frpcclient_create.go +++ b/pkg/db/ent/frpcclient_create.go @@ -10,7 +10,7 @@ import ( "entgo.io/ent/dialect/sql/sqlgraph" "entgo.io/ent/schema/field" - "github.com/fatedier/frp/pkg/db/ent/frpcclient" + "kanhole/pkg/db/ent/frpcclient" ) // FrpcClientCreate is the builder for creating a FrpcClient entity. diff --git a/pkg/db/ent/frpcclient_delete.go b/pkg/db/ent/frpcclient_delete.go index 9de16200..b5817cec 100644 --- a/pkg/db/ent/frpcclient_delete.go +++ b/pkg/db/ent/frpcclient_delete.go @@ -8,8 +8,8 @@ import ( "entgo.io/ent/dialect/sql" "entgo.io/ent/dialect/sql/sqlgraph" "entgo.io/ent/schema/field" - "github.com/fatedier/frp/pkg/db/ent/frpcclient" - "github.com/fatedier/frp/pkg/db/ent/predicate" + "kanhole/pkg/db/ent/frpcclient" + "kanhole/pkg/db/ent/predicate" ) // FrpcClientDelete is the builder for deleting a FrpcClient entity. diff --git a/pkg/db/ent/frpcclient_query.go b/pkg/db/ent/frpcclient_query.go index 694d450d..92650bda 100644 --- a/pkg/db/ent/frpcclient_query.go +++ b/pkg/db/ent/frpcclient_query.go @@ -11,8 +11,8 @@ import ( "entgo.io/ent/dialect/sql" "entgo.io/ent/dialect/sql/sqlgraph" "entgo.io/ent/schema/field" - "github.com/fatedier/frp/pkg/db/ent/frpcclient" - "github.com/fatedier/frp/pkg/db/ent/predicate" + "kanhole/pkg/db/ent/frpcclient" + "kanhole/pkg/db/ent/predicate" ) // FrpcClientQuery is the builder for querying FrpcClient entities. diff --git a/pkg/db/ent/frpcclient_update.go b/pkg/db/ent/frpcclient_update.go index fedecbe6..2225aa47 100644 --- a/pkg/db/ent/frpcclient_update.go +++ b/pkg/db/ent/frpcclient_update.go @@ -11,8 +11,8 @@ import ( "entgo.io/ent/dialect/sql" "entgo.io/ent/dialect/sql/sqlgraph" "entgo.io/ent/schema/field" - "github.com/fatedier/frp/pkg/db/ent/frpcclient" - "github.com/fatedier/frp/pkg/db/ent/predicate" + "kanhole/pkg/db/ent/frpcclient" + "kanhole/pkg/db/ent/predicate" ) // FrpcClientUpdate is the builder for updating FrpcClient entities. diff --git a/pkg/db/ent/hook/hook.go b/pkg/db/ent/hook/hook.go index 9c429e8c..9684171a 100644 --- a/pkg/db/ent/hook/hook.go +++ b/pkg/db/ent/hook/hook.go @@ -6,7 +6,7 @@ import ( "context" "fmt" - "github.com/fatedier/frp/pkg/db/ent" + "kanhole/pkg/db/ent" ) // The FrpcClientFunc type is an adapter to allow the use of ordinary diff --git a/pkg/db/ent/mutation.go b/pkg/db/ent/mutation.go index 5c48a018..67d33e8f 100644 --- a/pkg/db/ent/mutation.go +++ b/pkg/db/ent/mutation.go @@ -11,11 +11,11 @@ import ( "entgo.io/ent" "entgo.io/ent/dialect/sql" - "github.com/fatedier/frp/pkg/db/ent/frpcclient" - "github.com/fatedier/frp/pkg/db/ent/predicate" - "github.com/fatedier/frp/pkg/db/ent/proxy" - "github.com/fatedier/frp/pkg/db/ent/serverconfig" - "github.com/fatedier/frp/pkg/db/ent/user" + "kanhole/pkg/db/ent/frpcclient" + "kanhole/pkg/db/ent/predicate" + "kanhole/pkg/db/ent/proxy" + "kanhole/pkg/db/ent/serverconfig" + "kanhole/pkg/db/ent/user" ) const ( diff --git a/pkg/db/ent/proxy.go b/pkg/db/ent/proxy.go index e816f1ba..b3955701 100644 --- a/pkg/db/ent/proxy.go +++ b/pkg/db/ent/proxy.go @@ -9,7 +9,7 @@ import ( "entgo.io/ent" "entgo.io/ent/dialect/sql" - "github.com/fatedier/frp/pkg/db/ent/proxy" + "kanhole/pkg/db/ent/proxy" ) // Proxy is the model entity for the Proxy schema. diff --git a/pkg/db/ent/proxy/where.go b/pkg/db/ent/proxy/where.go index 2cd11137..570dd46d 100644 --- a/pkg/db/ent/proxy/where.go +++ b/pkg/db/ent/proxy/where.go @@ -6,7 +6,7 @@ import ( "time" "entgo.io/ent/dialect/sql" - "github.com/fatedier/frp/pkg/db/ent/predicate" + "kanhole/pkg/db/ent/predicate" ) // ID filters vertices based on their ID field. diff --git a/pkg/db/ent/proxy_create.go b/pkg/db/ent/proxy_create.go index ae7755be..968ee878 100644 --- a/pkg/db/ent/proxy_create.go +++ b/pkg/db/ent/proxy_create.go @@ -10,7 +10,7 @@ import ( "entgo.io/ent/dialect/sql/sqlgraph" "entgo.io/ent/schema/field" - "github.com/fatedier/frp/pkg/db/ent/proxy" + "kanhole/pkg/db/ent/proxy" ) // ProxyCreate is the builder for creating a Proxy entity. diff --git a/pkg/db/ent/proxy_delete.go b/pkg/db/ent/proxy_delete.go index 000f6871..332b54b6 100644 --- a/pkg/db/ent/proxy_delete.go +++ b/pkg/db/ent/proxy_delete.go @@ -8,8 +8,8 @@ import ( "entgo.io/ent/dialect/sql" "entgo.io/ent/dialect/sql/sqlgraph" "entgo.io/ent/schema/field" - "github.com/fatedier/frp/pkg/db/ent/predicate" - "github.com/fatedier/frp/pkg/db/ent/proxy" + "kanhole/pkg/db/ent/predicate" + "kanhole/pkg/db/ent/proxy" ) // ProxyDelete is the builder for deleting a Proxy entity. diff --git a/pkg/db/ent/proxy_query.go b/pkg/db/ent/proxy_query.go index 5a4cf116..60a935aa 100644 --- a/pkg/db/ent/proxy_query.go +++ b/pkg/db/ent/proxy_query.go @@ -11,8 +11,8 @@ import ( "entgo.io/ent/dialect/sql" "entgo.io/ent/dialect/sql/sqlgraph" "entgo.io/ent/schema/field" - "github.com/fatedier/frp/pkg/db/ent/predicate" - "github.com/fatedier/frp/pkg/db/ent/proxy" + "kanhole/pkg/db/ent/predicate" + "kanhole/pkg/db/ent/proxy" ) // ProxyQuery is the builder for querying Proxy entities. diff --git a/pkg/db/ent/proxy_update.go b/pkg/db/ent/proxy_update.go index 42b57a34..e1c1193e 100644 --- a/pkg/db/ent/proxy_update.go +++ b/pkg/db/ent/proxy_update.go @@ -11,8 +11,8 @@ import ( "entgo.io/ent/dialect/sql" "entgo.io/ent/dialect/sql/sqlgraph" "entgo.io/ent/schema/field" - "github.com/fatedier/frp/pkg/db/ent/predicate" - "github.com/fatedier/frp/pkg/db/ent/proxy" + "kanhole/pkg/db/ent/predicate" + "kanhole/pkg/db/ent/proxy" ) // ProxyUpdate is the builder for updating Proxy entities. diff --git a/pkg/db/ent/runtime.go b/pkg/db/ent/runtime.go index 47e86aed..dee21563 100644 --- a/pkg/db/ent/runtime.go +++ b/pkg/db/ent/runtime.go @@ -5,10 +5,10 @@ package ent import ( "time" - "github.com/fatedier/frp/pkg/db/ent/frpcclient" - "github.com/fatedier/frp/pkg/db/ent/proxy" - "github.com/fatedier/frp/pkg/db/ent/schema" - "github.com/fatedier/frp/pkg/db/ent/user" + "kanhole/pkg/db/ent/frpcclient" + "kanhole/pkg/db/ent/proxy" + "kanhole/pkg/db/ent/schema" + "kanhole/pkg/db/ent/user" ) // The init function reads all schema descriptors with runtime code diff --git a/pkg/db/ent/runtime/runtime.go b/pkg/db/ent/runtime/runtime.go index 02c1bb6f..9d360984 100644 --- a/pkg/db/ent/runtime/runtime.go +++ b/pkg/db/ent/runtime/runtime.go @@ -2,7 +2,7 @@ package runtime -// The schema-stitching logic is generated in github.com/fatedier/frp/pkg/db/ent/runtime.go +// The schema-stitching logic is generated in kanhole/pkg/db/ent/runtime.go const ( Version = "v0.14.6" // Version of ent codegen. diff --git a/pkg/db/ent/serverconfig.go b/pkg/db/ent/serverconfig.go index 1206d581..33b48d43 100644 --- a/pkg/db/ent/serverconfig.go +++ b/pkg/db/ent/serverconfig.go @@ -8,7 +8,7 @@ import ( "entgo.io/ent" "entgo.io/ent/dialect/sql" - "github.com/fatedier/frp/pkg/db/ent/serverconfig" + "kanhole/pkg/db/ent/serverconfig" ) // ServerConfig is the model entity for the ServerConfig schema. diff --git a/pkg/db/ent/serverconfig/where.go b/pkg/db/ent/serverconfig/where.go index efa639ed..5e932eff 100644 --- a/pkg/db/ent/serverconfig/where.go +++ b/pkg/db/ent/serverconfig/where.go @@ -4,7 +4,7 @@ package serverconfig import ( "entgo.io/ent/dialect/sql" - "github.com/fatedier/frp/pkg/db/ent/predicate" + "kanhole/pkg/db/ent/predicate" ) // ID filters vertices based on their ID field. diff --git a/pkg/db/ent/serverconfig_create.go b/pkg/db/ent/serverconfig_create.go index 09327b71..c650c624 100644 --- a/pkg/db/ent/serverconfig_create.go +++ b/pkg/db/ent/serverconfig_create.go @@ -9,7 +9,7 @@ import ( "entgo.io/ent/dialect/sql/sqlgraph" "entgo.io/ent/schema/field" - "github.com/fatedier/frp/pkg/db/ent/serverconfig" + "kanhole/pkg/db/ent/serverconfig" ) // ServerConfigCreate is the builder for creating a ServerConfig entity. diff --git a/pkg/db/ent/serverconfig_delete.go b/pkg/db/ent/serverconfig_delete.go index eb8c2183..44ce0114 100644 --- a/pkg/db/ent/serverconfig_delete.go +++ b/pkg/db/ent/serverconfig_delete.go @@ -8,8 +8,8 @@ import ( "entgo.io/ent/dialect/sql" "entgo.io/ent/dialect/sql/sqlgraph" "entgo.io/ent/schema/field" - "github.com/fatedier/frp/pkg/db/ent/predicate" - "github.com/fatedier/frp/pkg/db/ent/serverconfig" + "kanhole/pkg/db/ent/predicate" + "kanhole/pkg/db/ent/serverconfig" ) // ServerConfigDelete is the builder for deleting a ServerConfig entity. diff --git a/pkg/db/ent/serverconfig_query.go b/pkg/db/ent/serverconfig_query.go index 5a219407..b6dd7f8b 100644 --- a/pkg/db/ent/serverconfig_query.go +++ b/pkg/db/ent/serverconfig_query.go @@ -11,8 +11,8 @@ import ( "entgo.io/ent/dialect/sql" "entgo.io/ent/dialect/sql/sqlgraph" "entgo.io/ent/schema/field" - "github.com/fatedier/frp/pkg/db/ent/predicate" - "github.com/fatedier/frp/pkg/db/ent/serverconfig" + "kanhole/pkg/db/ent/predicate" + "kanhole/pkg/db/ent/serverconfig" ) // ServerConfigQuery is the builder for querying ServerConfig entities. diff --git a/pkg/db/ent/serverconfig_update.go b/pkg/db/ent/serverconfig_update.go index 6c00c6ab..5ca79ba5 100644 --- a/pkg/db/ent/serverconfig_update.go +++ b/pkg/db/ent/serverconfig_update.go @@ -10,8 +10,8 @@ import ( "entgo.io/ent/dialect/sql" "entgo.io/ent/dialect/sql/sqlgraph" "entgo.io/ent/schema/field" - "github.com/fatedier/frp/pkg/db/ent/predicate" - "github.com/fatedier/frp/pkg/db/ent/serverconfig" + "kanhole/pkg/db/ent/predicate" + "kanhole/pkg/db/ent/serverconfig" ) // ServerConfigUpdate is the builder for updating ServerConfig entities. diff --git a/pkg/db/ent/user.go b/pkg/db/ent/user.go index 385efc87..137783aa 100644 --- a/pkg/db/ent/user.go +++ b/pkg/db/ent/user.go @@ -9,7 +9,7 @@ import ( "entgo.io/ent" "entgo.io/ent/dialect/sql" - "github.com/fatedier/frp/pkg/db/ent/user" + "kanhole/pkg/db/ent/user" ) // User is the model entity for the User schema. diff --git a/pkg/db/ent/user/where.go b/pkg/db/ent/user/where.go index c4f8fa2b..79d725a6 100644 --- a/pkg/db/ent/user/where.go +++ b/pkg/db/ent/user/where.go @@ -6,7 +6,7 @@ import ( "time" "entgo.io/ent/dialect/sql" - "github.com/fatedier/frp/pkg/db/ent/predicate" + "kanhole/pkg/db/ent/predicate" ) // ID filters vertices based on their ID field. diff --git a/pkg/db/ent/user_create.go b/pkg/db/ent/user_create.go index ab4b8a4d..9ec2a17b 100644 --- a/pkg/db/ent/user_create.go +++ b/pkg/db/ent/user_create.go @@ -10,7 +10,7 @@ import ( "entgo.io/ent/dialect/sql/sqlgraph" "entgo.io/ent/schema/field" - "github.com/fatedier/frp/pkg/db/ent/user" + "kanhole/pkg/db/ent/user" ) // UserCreate is the builder for creating a User entity. diff --git a/pkg/db/ent/user_delete.go b/pkg/db/ent/user_delete.go index 45ebf49c..06763c51 100644 --- a/pkg/db/ent/user_delete.go +++ b/pkg/db/ent/user_delete.go @@ -8,8 +8,8 @@ import ( "entgo.io/ent/dialect/sql" "entgo.io/ent/dialect/sql/sqlgraph" "entgo.io/ent/schema/field" - "github.com/fatedier/frp/pkg/db/ent/predicate" - "github.com/fatedier/frp/pkg/db/ent/user" + "kanhole/pkg/db/ent/predicate" + "kanhole/pkg/db/ent/user" ) // UserDelete is the builder for deleting a User entity. diff --git a/pkg/db/ent/user_query.go b/pkg/db/ent/user_query.go index d4a35fb5..a14caba6 100644 --- a/pkg/db/ent/user_query.go +++ b/pkg/db/ent/user_query.go @@ -11,8 +11,8 @@ import ( "entgo.io/ent/dialect/sql" "entgo.io/ent/dialect/sql/sqlgraph" "entgo.io/ent/schema/field" - "github.com/fatedier/frp/pkg/db/ent/predicate" - "github.com/fatedier/frp/pkg/db/ent/user" + "kanhole/pkg/db/ent/predicate" + "kanhole/pkg/db/ent/user" ) // UserQuery is the builder for querying User entities. diff --git a/pkg/db/ent/user_update.go b/pkg/db/ent/user_update.go index 4976230f..17cc1af9 100644 --- a/pkg/db/ent/user_update.go +++ b/pkg/db/ent/user_update.go @@ -11,8 +11,8 @@ import ( "entgo.io/ent/dialect/sql" "entgo.io/ent/dialect/sql/sqlgraph" "entgo.io/ent/schema/field" - "github.com/fatedier/frp/pkg/db/ent/predicate" - "github.com/fatedier/frp/pkg/db/ent/user" + "kanhole/pkg/db/ent/predicate" + "kanhole/pkg/db/ent/user" ) // UserUpdate is the builder for updating User entities. diff --git a/pkg/metrics/aggregate/server.go b/pkg/metrics/aggregate/server.go index 9ef70ebd..d1a7ab13 100644 --- a/pkg/metrics/aggregate/server.go +++ b/pkg/metrics/aggregate/server.go @@ -15,9 +15,9 @@ package aggregate import ( - "github.com/fatedier/frp/pkg/metrics/mem" - "github.com/fatedier/frp/pkg/metrics/prometheus" - "github.com/fatedier/frp/server/metrics" + "kanhole/pkg/metrics/mem" + "kanhole/pkg/metrics/prometheus" + "kanhole/server/metrics" ) // EnableMem start to mark metrics to memory monitor system. diff --git a/pkg/metrics/mem/server.go b/pkg/metrics/mem/server.go index a3c2bb65..4ba3c898 100644 --- a/pkg/metrics/mem/server.go +++ b/pkg/metrics/mem/server.go @@ -20,9 +20,9 @@ import ( "k8s.io/utils/clock" - "github.com/fatedier/frp/pkg/util/log" - "github.com/fatedier/frp/pkg/util/metric" - server "github.com/fatedier/frp/server/metrics" + "kanhole/pkg/util/log" + "kanhole/pkg/util/metric" + server "kanhole/server/metrics" ) var ( diff --git a/pkg/metrics/mem/types.go b/pkg/metrics/mem/types.go index b7661ba8..37e37ee8 100644 --- a/pkg/metrics/mem/types.go +++ b/pkg/metrics/mem/types.go @@ -17,7 +17,7 @@ package mem import ( "time" - "github.com/fatedier/frp/pkg/util/metric" + "kanhole/pkg/util/metric" ) const ( diff --git a/pkg/metrics/metrics.go b/pkg/metrics/metrics.go index 12c388a5..25d79022 100644 --- a/pkg/metrics/metrics.go +++ b/pkg/metrics/metrics.go @@ -15,7 +15,7 @@ package metrics import ( - "github.com/fatedier/frp/pkg/metrics/aggregate" + "kanhole/pkg/metrics/aggregate" ) var ( diff --git a/pkg/metrics/prometheus/server.go b/pkg/metrics/prometheus/server.go index 6a300ffe..e615f5ac 100644 --- a/pkg/metrics/prometheus/server.go +++ b/pkg/metrics/prometheus/server.go @@ -3,11 +3,11 @@ package prometheus import ( "github.com/prometheus/client_golang/prometheus" - "github.com/fatedier/frp/server/metrics" + "kanhole/server/metrics" ) const ( - namespace = "frp" + namespace = "kanhole" serverSubsystem = "server" ) diff --git a/pkg/msg/conn_test.go b/pkg/msg/conn_test.go index f3498f03..6e83a8ee 100644 --- a/pkg/msg/conn_test.go +++ b/pkg/msg/conn_test.go @@ -20,7 +20,7 @@ import ( "github.com/stretchr/testify/require" - "github.com/fatedier/frp/pkg/proto/wire" + "kanhole/pkg/proto/wire" ) func TestConnReadWriteMsg(t *testing.T) { diff --git a/pkg/msg/handler.go b/pkg/msg/handler.go index 1f2775c9..d637c5c5 100644 --- a/pkg/msg/handler.go +++ b/pkg/msg/handler.go @@ -20,7 +20,7 @@ import ( "net" "reflect" - "github.com/fatedier/frp/pkg/proto/wire" + "kanhole/pkg/proto/wire" ) type ReadWriter interface { diff --git a/pkg/msg/wire_v2.go b/pkg/msg/wire_v2.go index 8d2cd88d..706b75ac 100644 --- a/pkg/msg/wire_v2.go +++ b/pkg/msg/wire_v2.go @@ -21,7 +21,7 @@ import ( "io" "reflect" - "github.com/fatedier/frp/pkg/proto/wire" + "kanhole/pkg/proto/wire" ) const ( diff --git a/pkg/msg/wire_v2_test.go b/pkg/msg/wire_v2_test.go index f6f25e55..002dec8e 100644 --- a/pkg/msg/wire_v2_test.go +++ b/pkg/msg/wire_v2_test.go @@ -21,7 +21,7 @@ import ( "github.com/stretchr/testify/require" - "github.com/fatedier/frp/pkg/proto/wire" + "kanhole/pkg/proto/wire" ) func TestV2ReadWriterRoundTrip(t *testing.T) { diff --git a/pkg/nathole/controller.go b/pkg/nathole/controller.go index 22a5ec53..92401fd7 100644 --- a/pkg/nathole/controller.go +++ b/pkg/nathole/controller.go @@ -29,10 +29,10 @@ import ( "github.com/samber/lo" "golang.org/x/sync/errgroup" - "github.com/fatedier/frp/pkg/msg" - "github.com/fatedier/frp/pkg/transport" - "github.com/fatedier/frp/pkg/util/log" - "github.com/fatedier/frp/pkg/util/util" + "kanhole/pkg/msg" + "kanhole/pkg/transport" + "kanhole/pkg/util/log" + "kanhole/pkg/util/util" ) // NatHoleTimeout seconds. diff --git a/pkg/nathole/nathole.go b/pkg/nathole/nathole.go index bea3d371..42156c0f 100644 --- a/pkg/nathole/nathole.go +++ b/pkg/nathole/nathole.go @@ -28,9 +28,9 @@ import ( "golang.org/x/net/ipv4" "k8s.io/apimachinery/pkg/util/sets" - "github.com/fatedier/frp/pkg/msg" - "github.com/fatedier/frp/pkg/transport" - "github.com/fatedier/frp/pkg/util/xlog" + "kanhole/pkg/msg" + "kanhole/pkg/transport" + "kanhole/pkg/util/xlog" ) var ( diff --git a/pkg/nathole/utils.go b/pkg/nathole/utils.go index 2a882830..41f8b705 100644 --- a/pkg/nathole/utils.go +++ b/pkg/nathole/utils.go @@ -23,7 +23,7 @@ import ( "github.com/fatedier/golib/crypto" "github.com/pion/stun/v3" - "github.com/fatedier/frp/pkg/msg" + "kanhole/pkg/msg" ) func EncodeMessage(m msg.Message, key []byte) ([]byte, error) { diff --git a/pkg/plugin/client/http2http.go b/pkg/plugin/client/http2http.go index f92daddd..70fc2df7 100644 --- a/pkg/plugin/client/http2http.go +++ b/pkg/plugin/client/http2http.go @@ -19,7 +19,7 @@ package client import ( "net/http/httputil" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) func init() { diff --git a/pkg/plugin/client/http2https.go b/pkg/plugin/client/http2https.go index f5a61602..1adaa0e5 100644 --- a/pkg/plugin/client/http2https.go +++ b/pkg/plugin/client/http2https.go @@ -21,7 +21,7 @@ import ( "net/http" "net/http/httputil" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) func init() { diff --git a/pkg/plugin/client/http_common.go b/pkg/plugin/client/http_common.go index 5010a4e9..eff6b609 100644 --- a/pkg/plugin/client/http_common.go +++ b/pkg/plugin/client/http_common.go @@ -25,10 +25,10 @@ import ( "github.com/fatedier/golib/pool" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/plugin/client/internal/httpsserver" - "github.com/fatedier/frp/pkg/util/log" - netpkg "github.com/fatedier/frp/pkg/util/net" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/plugin/client/internal/httpsserver" + "kanhole/pkg/util/log" + netpkg "kanhole/pkg/util/net" ) const httpBridgeReadHeaderTimeout = 60 * time.Second diff --git a/pkg/plugin/client/http_proxy.go b/pkg/plugin/client/http_proxy.go index 0145f444..6fd894ea 100644 --- a/pkg/plugin/client/http_proxy.go +++ b/pkg/plugin/client/http_proxy.go @@ -29,9 +29,9 @@ import ( libio "github.com/fatedier/golib/io" libnet "github.com/fatedier/golib/net" - v1 "github.com/fatedier/frp/pkg/config/v1" - netpkg "github.com/fatedier/frp/pkg/util/net" - "github.com/fatedier/frp/pkg/util/util" + v1 "kanhole/pkg/config/v1" + netpkg "kanhole/pkg/util/net" + "kanhole/pkg/util/util" ) func init() { diff --git a/pkg/plugin/client/http_proxy_test.go b/pkg/plugin/client/http_proxy_test.go index c4557ece..39047b88 100644 --- a/pkg/plugin/client/http_proxy_test.go +++ b/pkg/plugin/client/http_proxy_test.go @@ -27,7 +27,7 @@ import ( "github.com/stretchr/testify/require" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) func TestHTTPProxyHandleFragmentedConnectMethod(t *testing.T) { diff --git a/pkg/plugin/client/https2http.go b/pkg/plugin/client/https2http.go index 8722bec9..b2c2dde4 100644 --- a/pkg/plugin/client/https2http.go +++ b/pkg/plugin/client/https2http.go @@ -19,7 +19,7 @@ package client import ( "net/http/httputil" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) func init() { diff --git a/pkg/plugin/client/https2https.go b/pkg/plugin/client/https2https.go index 7b9e455e..06841703 100644 --- a/pkg/plugin/client/https2https.go +++ b/pkg/plugin/client/https2https.go @@ -21,7 +21,7 @@ import ( "net/http" "net/http/httputil" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) func init() { diff --git a/pkg/plugin/client/internal/httpsserver/server.go b/pkg/plugin/client/internal/httpsserver/server.go index a2047b90..42caaa9e 100644 --- a/pkg/plugin/client/internal/httpsserver/server.go +++ b/pkg/plugin/client/internal/httpsserver/server.go @@ -24,8 +24,8 @@ import ( "github.com/samber/lo" - "github.com/fatedier/frp/pkg/transport" - httppkg "github.com/fatedier/frp/pkg/util/http" + "kanhole/pkg/transport" + httppkg "kanhole/pkg/util/http" ) func New(handler http.Handler, crtPath, keyPath string, enableHTTP2 *bool) (*http.Server, error) { diff --git a/pkg/plugin/client/plugin.go b/pkg/plugin/client/plugin.go index 7bcd0489..160a77a7 100644 --- a/pkg/plugin/client/plugin.go +++ b/pkg/plugin/client/plugin.go @@ -24,8 +24,8 @@ import ( "github.com/fatedier/golib/errors" pp "github.com/pires/go-proxyproto" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/vnet" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/vnet" ) type PluginContext struct { diff --git a/pkg/plugin/client/socks5.go b/pkg/plugin/client/socks5.go index 752dd1e1..6e74d05d 100644 --- a/pkg/plugin/client/socks5.go +++ b/pkg/plugin/client/socks5.go @@ -23,8 +23,8 @@ import ( gosocks5 "github.com/armon/go-socks5" - v1 "github.com/fatedier/frp/pkg/config/v1" - netpkg "github.com/fatedier/frp/pkg/util/net" + v1 "kanhole/pkg/config/v1" + netpkg "kanhole/pkg/util/net" ) func init() { diff --git a/pkg/plugin/client/static_file.go b/pkg/plugin/client/static_file.go index 0bab120a..5b85ff3b 100644 --- a/pkg/plugin/client/static_file.go +++ b/pkg/plugin/client/static_file.go @@ -23,8 +23,8 @@ import ( "github.com/gorilla/mux" - v1 "github.com/fatedier/frp/pkg/config/v1" - netpkg "github.com/fatedier/frp/pkg/util/net" + v1 "kanhole/pkg/config/v1" + netpkg "kanhole/pkg/util/net" ) func init() { diff --git a/pkg/plugin/client/tls2raw.go b/pkg/plugin/client/tls2raw.go index ccb75149..3baea178 100644 --- a/pkg/plugin/client/tls2raw.go +++ b/pkg/plugin/client/tls2raw.go @@ -23,10 +23,10 @@ import ( libio "github.com/fatedier/golib/io" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/transport" - netpkg "github.com/fatedier/frp/pkg/util/net" - "github.com/fatedier/frp/pkg/util/xlog" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/transport" + netpkg "kanhole/pkg/util/net" + "kanhole/pkg/util/xlog" ) func init() { diff --git a/pkg/plugin/client/unix_domain_socket.go b/pkg/plugin/client/unix_domain_socket.go index 3046aade..a6efbe13 100644 --- a/pkg/plugin/client/unix_domain_socket.go +++ b/pkg/plugin/client/unix_domain_socket.go @@ -22,8 +22,8 @@ import ( libio "github.com/fatedier/golib/io" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/util/xlog" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/util/xlog" ) func init() { diff --git a/pkg/plugin/client/virtual_net.go b/pkg/plugin/client/virtual_net.go index 53570035..ece7fd99 100644 --- a/pkg/plugin/client/virtual_net.go +++ b/pkg/plugin/client/virtual_net.go @@ -21,7 +21,7 @@ import ( "io" "sync" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) func init() { diff --git a/pkg/plugin/server/http.go b/pkg/plugin/server/http.go index b05b909e..e05f3077 100644 --- a/pkg/plugin/server/http.go +++ b/pkg/plugin/server/http.go @@ -27,7 +27,7 @@ import ( "slices" "strings" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) type httpPlugin struct { diff --git a/pkg/plugin/server/manager.go b/pkg/plugin/server/manager.go index 6f1061c6..02e97376 100644 --- a/pkg/plugin/server/manager.go +++ b/pkg/plugin/server/manager.go @@ -20,8 +20,8 @@ import ( "fmt" "strings" - "github.com/fatedier/frp/pkg/util/util" - "github.com/fatedier/frp/pkg/util/xlog" + "kanhole/pkg/util/util" + "kanhole/pkg/util/xlog" ) type Manager struct { diff --git a/pkg/plugin/server/manager_test.go b/pkg/plugin/server/manager_test.go index 92391d4b..6c9981d4 100644 --- a/pkg/plugin/server/manager_test.go +++ b/pkg/plugin/server/manager_test.go @@ -25,8 +25,8 @@ import ( goliblog "github.com/fatedier/golib/log" - "github.com/fatedier/frp/pkg/msg" - frplog "github.com/fatedier/frp/pkg/util/log" + "kanhole/pkg/msg" + frplog "kanhole/pkg/util/log" ) type testPlugin struct { diff --git a/pkg/plugin/server/types.go b/pkg/plugin/server/types.go index 4a5b7527..ce7b5483 100644 --- a/pkg/plugin/server/types.go +++ b/pkg/plugin/server/types.go @@ -15,7 +15,7 @@ package server import ( - "github.com/fatedier/frp/pkg/msg" + "kanhole/pkg/msg" ) type Request struct { diff --git a/pkg/plugin/visitor/plugin.go b/pkg/plugin/visitor/plugin.go index 27eecc82..46080226 100644 --- a/pkg/plugin/visitor/plugin.go +++ b/pkg/plugin/visitor/plugin.go @@ -19,8 +19,8 @@ import ( "fmt" "net" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/vnet" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/vnet" ) // PluginContext provides the necessary context and callbacks for visitor plugins. diff --git a/pkg/plugin/visitor/virtual_net.go b/pkg/plugin/visitor/virtual_net.go index fa8c700e..40a023fd 100644 --- a/pkg/plugin/visitor/virtual_net.go +++ b/pkg/plugin/visitor/virtual_net.go @@ -24,9 +24,9 @@ import ( "sync" "time" - v1 "github.com/fatedier/frp/pkg/config/v1" - netutil "github.com/fatedier/frp/pkg/util/net" - "github.com/fatedier/frp/pkg/util/xlog" + v1 "kanhole/pkg/config/v1" + netutil "kanhole/pkg/util/net" + "kanhole/pkg/util/xlog" ) func init() { diff --git a/pkg/proto/udp/udp.go b/pkg/proto/udp/udp.go index 70b51900..d912c0eb 100644 --- a/pkg/proto/udp/udp.go +++ b/pkg/proto/udp/udp.go @@ -22,8 +22,8 @@ import ( "github.com/fatedier/golib/errors" "github.com/fatedier/golib/pool" - "github.com/fatedier/frp/pkg/msg" - netpkg "github.com/fatedier/frp/pkg/util/net" + "kanhole/pkg/msg" + netpkg "kanhole/pkg/util/net" ) func NewUDPPacket(buf []byte, laddr, raddr *net.UDPAddr) *msg.UDPPacket { diff --git a/pkg/sdk/client/client.go b/pkg/sdk/client/client.go index 088d3f8f..09a7c10a 100644 --- a/pkg/sdk/client/client.go +++ b/pkg/sdk/client/client.go @@ -11,8 +11,8 @@ import ( "strconv" "strings" - "github.com/fatedier/frp/client/http/model" - httppkg "github.com/fatedier/frp/pkg/util/http" + "kanhole/client/http/model" + httppkg "kanhole/pkg/util/http" ) type Client struct { diff --git a/pkg/ssh/gateway.go b/pkg/ssh/gateway.go index 4d90f338..a6f52bd3 100644 --- a/pkg/ssh/gateway.go +++ b/pkg/ssh/gateway.go @@ -23,10 +23,10 @@ import ( "golang.org/x/crypto/ssh" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/transport" - "github.com/fatedier/frp/pkg/util/log" - netpkg "github.com/fatedier/frp/pkg/util/net" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/transport" + "kanhole/pkg/util/log" + netpkg "kanhole/pkg/util/net" ) type Gateway struct { diff --git a/pkg/ssh/server.go b/pkg/ssh/server.go index bffc40bc..6fa7b124 100644 --- a/pkg/ssh/server.go +++ b/pkg/ssh/server.go @@ -30,15 +30,15 @@ import ( flag "github.com/spf13/pflag" "golang.org/x/crypto/ssh" - "github.com/fatedier/frp/client/proxy" - "github.com/fatedier/frp/pkg/config" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/msg" - "github.com/fatedier/frp/pkg/util/log" - netpkg "github.com/fatedier/frp/pkg/util/net" - "github.com/fatedier/frp/pkg/util/util" - "github.com/fatedier/frp/pkg/util/xlog" - "github.com/fatedier/frp/pkg/virtual" + "kanhole/client/proxy" + "kanhole/pkg/config" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/msg" + "kanhole/pkg/util/log" + netpkg "kanhole/pkg/util/net" + "kanhole/pkg/util/util" + "kanhole/pkg/util/xlog" + "kanhole/pkg/virtual" ) const ( diff --git a/pkg/ssh/terminal.go b/pkg/ssh/terminal.go index a2e9a6ff..91769ff8 100644 --- a/pkg/ssh/terminal.go +++ b/pkg/ssh/terminal.go @@ -15,14 +15,14 @@ package ssh import ( - "github.com/fatedier/frp/client/proxy" - v1 "github.com/fatedier/frp/pkg/config/v1" + "kanhole/client/proxy" + v1 "kanhole/pkg/config/v1" ) func createSuccessInfo(user string, pc v1.ProxyConfigurer, ps *proxy.WorkingStatus) string { base := pc.GetBaseConfig() out := "\n" - out += "frp (via SSH) (Ctrl+C to quit)\n\n" + out += "kanhole (via SSH) (Ctrl+C to quit)\n\n" out += "User: " + user + "\n" out += "ProxyName: " + base.Name + "\n" out += "Type: " + base.Type + "\n" diff --git a/pkg/transport/message.go b/pkg/transport/message.go index 40165f5d..184eeffa 100644 --- a/pkg/transport/message.go +++ b/pkg/transport/message.go @@ -21,7 +21,7 @@ import ( "github.com/fatedier/golib/errors" - "github.com/fatedier/frp/pkg/msg" + "kanhole/pkg/msg" ) type MessageTransporter interface { diff --git a/pkg/util/http/handler.go b/pkg/util/http/handler.go index d6c7be18..d54cddce 100644 --- a/pkg/util/http/handler.go +++ b/pkg/util/http/handler.go @@ -18,7 +18,7 @@ import ( "encoding/json" "net/http" - "github.com/fatedier/frp/pkg/util/log" + "kanhole/pkg/util/log" ) type GeneralResponse struct { diff --git a/pkg/util/http/middleware.go b/pkg/util/http/middleware.go index 40009a40..0d3f0f56 100644 --- a/pkg/util/http/middleware.go +++ b/pkg/util/http/middleware.go @@ -17,7 +17,7 @@ package http import ( "net/http" - "github.com/fatedier/frp/pkg/util/log" + "kanhole/pkg/util/log" ) type responseWriter struct { diff --git a/pkg/util/http/server.go b/pkg/util/http/server.go index 0bca8993..e40a3b22 100644 --- a/pkg/util/http/server.go +++ b/pkg/util/http/server.go @@ -24,9 +24,9 @@ import ( "github.com/gorilla/mux" - "github.com/fatedier/frp/assets" - v1 "github.com/fatedier/frp/pkg/config/v1" - netpkg "github.com/fatedier/frp/pkg/util/net" + "kanhole/assets" + v1 "kanhole/pkg/config/v1" + netpkg "kanhole/pkg/util/net" ) var ( diff --git a/pkg/util/net/conn.go b/pkg/util/net/conn.go index 5dd605a5..10c71143 100644 --- a/pkg/util/net/conn.go +++ b/pkg/util/net/conn.go @@ -27,7 +27,7 @@ import ( quic "github.com/quic-go/quic-go" "golang.org/x/crypto/hkdf" - "github.com/fatedier/frp/pkg/util/xlog" + "kanhole/pkg/util/xlog" ) type ContextGetter interface { diff --git a/pkg/util/net/conn_test.go b/pkg/util/net/conn_test.go index 42d3c06b..71d2bd55 100644 --- a/pkg/util/net/conn_test.go +++ b/pkg/util/net/conn_test.go @@ -23,7 +23,7 @@ import ( "github.com/stretchr/testify/require" - "github.com/fatedier/frp/pkg/proto/wire" + "kanhole/pkg/proto/wire" ) func TestNewAEADCryptoReadWriterRoundTrip(t *testing.T) { diff --git a/pkg/util/net/http.go b/pkg/util/net/http.go index e9fc5260..ec423b02 100644 --- a/pkg/util/net/http.go +++ b/pkg/util/net/http.go @@ -21,7 +21,7 @@ import ( "strings" "time" - "github.com/fatedier/frp/pkg/util/util" + "kanhole/pkg/util/util" ) type HTTPAuthMiddleware struct { diff --git a/pkg/util/tcpmux/httpconnect.go b/pkg/util/tcpmux/httpconnect.go index d43b5904..18d9e3b6 100644 --- a/pkg/util/tcpmux/httpconnect.go +++ b/pkg/util/tcpmux/httpconnect.go @@ -24,8 +24,8 @@ import ( libnet "github.com/fatedier/golib/net" - httppkg "github.com/fatedier/frp/pkg/util/http" - "github.com/fatedier/frp/pkg/util/vhost" + httppkg "kanhole/pkg/util/http" + "kanhole/pkg/util/vhost" ) type HTTPConnectTCPMuxer struct { diff --git a/pkg/util/vhost/http.go b/pkg/util/vhost/http.go index 865ff9d5..d226426d 100644 --- a/pkg/util/vhost/http.go +++ b/pkg/util/vhost/http.go @@ -31,8 +31,8 @@ import ( "golang.org/x/net/http2" "golang.org/x/net/http2/h2c" - httppkg "github.com/fatedier/frp/pkg/util/http" - "github.com/fatedier/frp/pkg/util/log" + httppkg "kanhole/pkg/util/http" + "kanhole/pkg/util/log" ) var ErrNoRouteFound = errors.New("no route found") diff --git a/pkg/util/vhost/http_test.go b/pkg/util/vhost/http_test.go index 237ae903..e0c25131 100644 --- a/pkg/util/vhost/http_test.go +++ b/pkg/util/vhost/http_test.go @@ -6,7 +6,7 @@ import ( "github.com/stretchr/testify/require" - httppkg "github.com/fatedier/frp/pkg/util/http" + httppkg "kanhole/pkg/util/http" ) func TestCheckRouteAuthByRequest(t *testing.T) { diff --git a/pkg/util/vhost/resource.go b/pkg/util/vhost/resource.go index a65e2997..79df832a 100644 --- a/pkg/util/vhost/resource.go +++ b/pkg/util/vhost/resource.go @@ -20,8 +20,8 @@ import ( "net/http" "os" - "github.com/fatedier/frp/pkg/util/log" - "github.com/fatedier/frp/pkg/util/version" + "kanhole/pkg/util/log" + "kanhole/pkg/util/version" ) var NotFoundPagePath = "" @@ -43,7 +43,7 @@ const (

The page you requested was not found.

Sorry, the page you are looking for is currently unavailable.
Please try again later.

-

The server is powered by frp.

+

The server is powered by frp.

Faithfully yours, frp.

@@ -69,7 +69,7 @@ func getNotFoundPageContent() []byte { func NotFoundResponse() *http.Response { header := make(http.Header) - header.Set("server", "frp/"+version.Full()) + header.Set("server", "kanhole/"+version.Full()) header.Set("Content-Type", "text/html") content := getNotFoundPageContent() diff --git a/pkg/util/vhost/vhost.go b/pkg/util/vhost/vhost.go index 637c8dcf..cad36a9a 100644 --- a/pkg/util/vhost/vhost.go +++ b/pkg/util/vhost/vhost.go @@ -21,9 +21,9 @@ import ( "github.com/fatedier/golib/errors" - "github.com/fatedier/frp/pkg/util/log" - netpkg "github.com/fatedier/frp/pkg/util/net" - "github.com/fatedier/frp/pkg/util/xlog" + "kanhole/pkg/util/log" + netpkg "kanhole/pkg/util/net" + "kanhole/pkg/util/xlog" ) type RouteInfo string diff --git a/pkg/util/wait/backoff.go b/pkg/util/wait/backoff.go index 0ee5db71..6b9ae914 100644 --- a/pkg/util/wait/backoff.go +++ b/pkg/util/wait/backoff.go @@ -20,7 +20,7 @@ import ( "k8s.io/utils/clock" - "github.com/fatedier/frp/pkg/util/util" + "kanhole/pkg/util/util" ) type BackoffFunc func(previousDuration time.Duration, previousConditionError bool) time.Duration diff --git a/pkg/util/xlog/xlog.go b/pkg/util/xlog/xlog.go index f8f4116a..03d0fb1d 100644 --- a/pkg/util/xlog/xlog.go +++ b/pkg/util/xlog/xlog.go @@ -18,7 +18,7 @@ import ( "cmp" "slices" - "github.com/fatedier/frp/pkg/util/log" + "kanhole/pkg/util/log" ) type LogPrefix struct { diff --git a/pkg/virtual/client.go b/pkg/virtual/client.go index c7006ce7..31e13492 100644 --- a/pkg/virtual/client.go +++ b/pkg/virtual/client.go @@ -18,11 +18,11 @@ import ( "context" "net" - "github.com/fatedier/frp/client" - "github.com/fatedier/frp/pkg/config/source" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/msg" - netpkg "github.com/fatedier/frp/pkg/util/net" + "kanhole/client" + "kanhole/pkg/config/source" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/msg" + netpkg "kanhole/pkg/util/net" ) type ClientOptions struct { diff --git a/pkg/vnet/controller.go b/pkg/vnet/controller.go index 348d50d2..1be67cbe 100644 --- a/pkg/vnet/controller.go +++ b/pkg/vnet/controller.go @@ -27,9 +27,9 @@ import ( "golang.org/x/net/ipv4" "golang.org/x/net/ipv6" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/util/log" - "github.com/fatedier/frp/pkg/util/xlog" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/util/log" + "kanhole/pkg/util/xlog" ) const ( diff --git a/server/admin/handler.go b/server/admin/handler.go index ca5001ec..32946863 100644 --- a/server/admin/handler.go +++ b/server/admin/handler.go @@ -15,12 +15,12 @@ import ( "github.com/gorilla/mux" "golang.org/x/crypto/bcrypt" - "github.com/fatedier/frp/pkg/db" - "github.com/fatedier/frp/pkg/db/ent" - "github.com/fatedier/frp/pkg/db/ent/frpcclient" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/db/ent/proxy" - "github.com/fatedier/frp/pkg/db/ent/user" + "kanhole/pkg/db" + "kanhole/pkg/db/ent" + "kanhole/pkg/db/ent/frpcclient" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/db/ent/proxy" + "kanhole/pkg/db/ent/user" ) type sessionInfo struct { @@ -536,7 +536,7 @@ serverPort = %d auth.token = %q `, serverAddr, serverPort, authToken) - oneLiner := fmt.Sprintf(`curl -sL https://github.com/fatedier/frp/releases/latest/download/frp_linux_amd64.tar.gz | tar xz && cat > frpc.toml << 'EOF' + oneLiner := fmt.Sprintf(`curl -sL https://kanhole/releases/latest/download/frp_linux_amd64.tar.gz | tar xz && cat > frpc.toml << 'EOF' %s EOF ./frp_*/frpc -c frpc.toml`, frpcConfig) @@ -578,8 +578,8 @@ func (h *Handler) handleClientConfigDownload(w http.ResponseWriter, r *http.Requ proxies, _ := db.Client().Proxy.Query().Where(proxy.ClientIDEQ(c.ID)).All(ctx) - content := fmt.Sprintf(`# frpc config for %s -# Auto-generated by frp admin dashboard + content := fmt.Sprintf(`# kanholec config for %s +# Auto-generated by kanhole admin dashboard serverAddr = %q serverPort = %d @@ -624,11 +624,11 @@ func (h *Handler) handleClientProvisionScript(w http.ResponseWriter, r *http.Req serverHost := r.Host script := fmt.Sprintf(`#!/bin/bash -# frp auto-provisioning for: %s +# kanhole auto-provisioning for: %s set -e CONFIG_URL="http://%s/admin/api/frpc/proxy-config/%s" echo "==> Downloading frpc with server-config support..." -curl -sL https://github.com/fatedier/frp/releases/latest/download/frp_linux_amd64.tar.gz | tar xz +curl -sL https://kanhole/releases/latest/download/frp_linux_amd64.tar.gz | tar xz FRPC_DIR=$(ls -d frp_* 2>/dev/null | head -1) echo "==> Starting frpc for %s..." "$FRPC_DIR/frpc" --server-config "$CONFIG_URL" @@ -790,8 +790,8 @@ func (h *Handler) writeClientConfig(w http.ResponseWriter, ctx context.Context, proxies, _ := db.Client().Proxy.Query().Where(proxy.ClientIDEQ(c.ID)).All(ctx) - content := fmt.Sprintf(`# frpc config for %s -# Auto-generated by frp admin server + content := fmt.Sprintf(`# kanholec config for %s +# Auto-generated by kanhole admin server serverAddr = %q serverPort = %d @@ -839,8 +839,8 @@ func (h *Handler) handleFrpcProxyConfig(w http.ResponseWriter, r *http.Request) proxies, _ := db.Client().Proxy.Query().Where(proxy.ClientIDEQ(client.ID)).All(ctx) - content := fmt.Sprintf(`# frpc config for %s -# Auto-generated by frp admin server + content := fmt.Sprintf(`# kanholec config for %s +# Auto-generated by kanhole admin server serverAddr = %q serverPort = %d diff --git a/server/admin/templates/client_provision.html b/server/admin/templates/client_provision.html index 3ce2e01c..a2bf0b09 100644 --- a/server/admin/templates/client_provision.html +++ b/server/admin/templates/client_provision.html @@ -15,7 +15,7 @@

One-Liner Setup

Run this on your client machine. It downloads frpc and auto-updates from this server:

-
curl -sL https://github.com/fatedier/frp/releases/latest/download/frp_linux_amd64.tar.gz | tar xz \
+  
curl -sL https://github.com/kanhole/kanhole/releases/latest/download/frp_linux_amd64.tar.gz | tar xz \
   && ./frp_*/frpc --server-config http://{{.ServerAddr}}:{{.ServerPort}}/admin/api/frpc/proxy-config/{{.Client.Key}}
diff --git a/server/api_router.go b/server/api_router.go index 5f580c35..190418c8 100644 --- a/server/api_router.go +++ b/server/api_router.go @@ -5,9 +5,9 @@ import ( "github.com/prometheus/client_golang/prometheus/promhttp" - httppkg "github.com/fatedier/frp/pkg/util/http" - netpkg "github.com/fatedier/frp/pkg/util/net" - adminapi "github.com/fatedier/frp/server/http" + httppkg "kanhole/pkg/util/http" + netpkg "kanhole/pkg/util/net" + adminapi "kanhole/server/http" ) func (svr *Service) registerRouteHandlers(helper *httppkg.RouterRegisterHelper) { diff --git a/server/control.go b/server/control.go index 084b4eea..3f80bfae 100644 --- a/server/control.go +++ b/server/control.go @@ -24,20 +24,20 @@ import ( "github.com/samber/lo" - "github.com/fatedier/frp/pkg/auth" - "github.com/fatedier/frp/pkg/config" - v1 "github.com/fatedier/frp/pkg/config/v1" - pkgerr "github.com/fatedier/frp/pkg/errors" - "github.com/fatedier/frp/pkg/msg" - plugin "github.com/fatedier/frp/pkg/plugin/server" - "github.com/fatedier/frp/pkg/transport" - "github.com/fatedier/frp/pkg/util/util" - "github.com/fatedier/frp/pkg/util/wait" - "github.com/fatedier/frp/pkg/util/xlog" - "github.com/fatedier/frp/server/controller" - "github.com/fatedier/frp/server/metrics" - "github.com/fatedier/frp/server/proxy" - "github.com/fatedier/frp/server/registry" + "kanhole/pkg/auth" + "kanhole/pkg/config" + v1 "kanhole/pkg/config/v1" + pkgerr "kanhole/pkg/errors" + "kanhole/pkg/msg" + plugin "kanhole/pkg/plugin/server" + "kanhole/pkg/transport" + "kanhole/pkg/util/util" + "kanhole/pkg/util/wait" + "kanhole/pkg/util/xlog" + "kanhole/server/controller" + "kanhole/server/metrics" + "kanhole/server/proxy" + "kanhole/server/registry" ) type ControlManager struct { diff --git a/server/controller/resource.go b/server/controller/resource.go index 717c9616..7ef95ee9 100644 --- a/server/controller/resource.go +++ b/server/controller/resource.go @@ -15,13 +15,13 @@ package controller import ( - "github.com/fatedier/frp/pkg/nathole" - plugin "github.com/fatedier/frp/pkg/plugin/server" - "github.com/fatedier/frp/pkg/util/tcpmux" - "github.com/fatedier/frp/pkg/util/vhost" - "github.com/fatedier/frp/server/group" - "github.com/fatedier/frp/server/ports" - "github.com/fatedier/frp/server/visitor" + "kanhole/pkg/nathole" + plugin "kanhole/pkg/plugin/server" + "kanhole/pkg/util/tcpmux" + "kanhole/pkg/util/vhost" + "kanhole/server/group" + "kanhole/server/ports" + "kanhole/server/visitor" ) // All resource managers and controllers diff --git a/server/group/http.go b/server/group/http.go index 21bbfd29..5c9478fa 100644 --- a/server/group/http.go +++ b/server/group/http.go @@ -6,7 +6,7 @@ import ( "sync" "sync/atomic" - "github.com/fatedier/frp/pkg/util/vhost" + "kanhole/pkg/util/vhost" ) // HTTPGroupController manages HTTP groups that use round-robin diff --git a/server/group/https.go b/server/group/https.go index 1ab97578..8af3d959 100644 --- a/server/group/https.go +++ b/server/group/https.go @@ -18,7 +18,7 @@ import ( "context" "net" - "github.com/fatedier/frp/pkg/util/vhost" + "kanhole/pkg/util/vhost" ) type HTTPSGroupController struct { diff --git a/server/group/tcp.go b/server/group/tcp.go index d6bfbcff..92d0bc60 100644 --- a/server/group/tcp.go +++ b/server/group/tcp.go @@ -18,7 +18,7 @@ import ( "net" "strconv" - "github.com/fatedier/frp/server/ports" + "kanhole/server/ports" ) // TCPGroupCtl manages all TCPGroups. diff --git a/server/group/tcpmux.go b/server/group/tcpmux.go index e17a152a..b159a110 100644 --- a/server/group/tcpmux.go +++ b/server/group/tcpmux.go @@ -19,9 +19,9 @@ import ( "fmt" "net" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/util/tcpmux" - "github.com/fatedier/frp/pkg/util/vhost" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/util/tcpmux" + "kanhole/pkg/util/vhost" ) // TCPMuxGroupCtl manages all TCPMuxGroups. diff --git a/server/http/controller.go b/server/http/controller.go index 65f6c00f..bbaa1b8b 100644 --- a/server/http/controller.go +++ b/server/http/controller.go @@ -22,15 +22,15 @@ import ( "strings" "time" - "github.com/fatedier/frp/pkg/config/types" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/metrics/mem" - httppkg "github.com/fatedier/frp/pkg/util/http" - "github.com/fatedier/frp/pkg/util/log" - "github.com/fatedier/frp/pkg/util/version" - "github.com/fatedier/frp/server/http/model" - "github.com/fatedier/frp/server/proxy" - "github.com/fatedier/frp/server/registry" + "kanhole/pkg/config/types" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/metrics/mem" + httppkg "kanhole/pkg/util/http" + "kanhole/pkg/util/log" + "kanhole/pkg/util/version" + "kanhole/server/http/model" + "kanhole/server/proxy" + "kanhole/server/registry" ) type Controller struct { diff --git a/server/http/controller_test.go b/server/http/controller_test.go index 44509371..6a169cd3 100644 --- a/server/http/controller_test.go +++ b/server/http/controller_test.go @@ -19,9 +19,9 @@ import ( "testing" "time" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/proto/wire" - "github.com/fatedier/frp/server/registry" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/proto/wire" + "kanhole/server/registry" ) func TestGetConfFromConfigurerKeepsPluginFields(t *testing.T) { diff --git a/server/http/model/types.go b/server/http/model/types.go index 010c5079..b51d052a 100644 --- a/server/http/model/types.go +++ b/server/http/model/types.go @@ -15,7 +15,7 @@ package model import ( - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) type ServerInfoResp struct { diff --git a/server/ports/ports.go b/server/ports/ports.go index 653715ea..7bf0d6ca 100644 --- a/server/ports/ports.go +++ b/server/ports/ports.go @@ -9,7 +9,7 @@ import ( "k8s.io/utils/clock" - "github.com/fatedier/frp/pkg/config/types" + "kanhole/pkg/config/types" ) const ( diff --git a/server/ports/ports_test.go b/server/ports/ports_test.go index cd560b25..5a3bad4c 100644 --- a/server/ports/ports_test.go +++ b/server/ports/ports_test.go @@ -8,7 +8,7 @@ import ( "github.com/stretchr/testify/require" clocktesting "k8s.io/utils/clock/testing" - "github.com/fatedier/frp/pkg/config/types" + "kanhole/pkg/config/types" ) func TestManagerUsesClockForPortTimestamps(t *testing.T) { diff --git a/server/proxy/http.go b/server/proxy/http.go index 05afc2e9..cac22af8 100644 --- a/server/proxy/http.go +++ b/server/proxy/http.go @@ -22,12 +22,12 @@ import ( libio "github.com/fatedier/golib/io" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/util/limit" - netpkg "github.com/fatedier/frp/pkg/util/net" - "github.com/fatedier/frp/pkg/util/util" - "github.com/fatedier/frp/pkg/util/vhost" - "github.com/fatedier/frp/server/metrics" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/util/limit" + netpkg "kanhole/pkg/util/net" + "kanhole/pkg/util/util" + "kanhole/pkg/util/vhost" + "kanhole/server/metrics" ) func init() { diff --git a/server/proxy/https.go b/server/proxy/https.go index e2efc736..8be0f0ce 100644 --- a/server/proxy/https.go +++ b/server/proxy/https.go @@ -19,9 +19,9 @@ import ( "reflect" "strings" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/util/util" - "github.com/fatedier/frp/pkg/util/vhost" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/util/util" + "kanhole/pkg/util/vhost" ) func init() { diff --git a/server/proxy/proxy.go b/server/proxy/proxy.go index 7945b91b..0aaf66b5 100644 --- a/server/proxy/proxy.go +++ b/server/proxy/proxy.go @@ -27,15 +27,15 @@ import ( libio "github.com/fatedier/golib/io" "golang.org/x/time/rate" - "github.com/fatedier/frp/pkg/config/types" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/msg" - plugin "github.com/fatedier/frp/pkg/plugin/server" - "github.com/fatedier/frp/pkg/util/limit" - netpkg "github.com/fatedier/frp/pkg/util/net" - "github.com/fatedier/frp/pkg/util/xlog" - "github.com/fatedier/frp/server/controller" - "github.com/fatedier/frp/server/metrics" + "kanhole/pkg/config/types" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/msg" + plugin "kanhole/pkg/plugin/server" + "kanhole/pkg/util/limit" + netpkg "kanhole/pkg/util/net" + "kanhole/pkg/util/xlog" + "kanhole/server/controller" + "kanhole/server/metrics" ) var proxyFactoryRegistry = map[reflect.Type]func(*BaseProxy) Proxy{} diff --git a/server/proxy/proxy_test.go b/server/proxy/proxy_test.go index 381c743e..9a4e4a2b 100644 --- a/server/proxy/proxy_test.go +++ b/server/proxy/proxy_test.go @@ -21,9 +21,9 @@ import ( "github.com/stretchr/testify/require" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/msg" - "github.com/fatedier/frp/pkg/proto/wire" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/msg" + "kanhole/pkg/proto/wire" ) func TestWorkConnStartWritesStartWorkConn(t *testing.T) { diff --git a/server/proxy/stcp.go b/server/proxy/stcp.go index f8c17a46..be5b3e0c 100644 --- a/server/proxy/stcp.go +++ b/server/proxy/stcp.go @@ -17,7 +17,7 @@ package proxy import ( "reflect" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) func init() { diff --git a/server/proxy/sudp.go b/server/proxy/sudp.go index d409fed6..8fb93ba1 100644 --- a/server/proxy/sudp.go +++ b/server/proxy/sudp.go @@ -17,7 +17,7 @@ package proxy import ( "reflect" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) func init() { diff --git a/server/proxy/tcp.go b/server/proxy/tcp.go index c305e779..cf1fba2f 100644 --- a/server/proxy/tcp.go +++ b/server/proxy/tcp.go @@ -20,7 +20,7 @@ import ( "reflect" "strconv" - v1 "github.com/fatedier/frp/pkg/config/v1" + v1 "kanhole/pkg/config/v1" ) func init() { diff --git a/server/proxy/tcpmux.go b/server/proxy/tcpmux.go index 0c421c8e..39799527 100644 --- a/server/proxy/tcpmux.go +++ b/server/proxy/tcpmux.go @@ -20,9 +20,9 @@ import ( "reflect" "strings" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/util/util" - "github.com/fatedier/frp/pkg/util/vhost" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/util/util" + "kanhole/pkg/util/vhost" ) func init() { diff --git a/server/proxy/udp.go b/server/proxy/udp.go index 609d9c42..0f2cfb50 100644 --- a/server/proxy/udp.go +++ b/server/proxy/udp.go @@ -26,12 +26,12 @@ import ( "github.com/fatedier/golib/errors" libio "github.com/fatedier/golib/io" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/msg" - "github.com/fatedier/frp/pkg/proto/udp" - "github.com/fatedier/frp/pkg/util/limit" - netpkg "github.com/fatedier/frp/pkg/util/net" - "github.com/fatedier/frp/server/metrics" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/msg" + "kanhole/pkg/proto/udp" + "kanhole/pkg/util/limit" + netpkg "kanhole/pkg/util/net" + "kanhole/server/metrics" ) func init() { diff --git a/server/proxy/xtcp.go b/server/proxy/xtcp.go index a6488d42..ae14c358 100644 --- a/server/proxy/xtcp.go +++ b/server/proxy/xtcp.go @@ -20,8 +20,8 @@ import ( "reflect" "sync" - v1 "github.com/fatedier/frp/pkg/config/v1" - "github.com/fatedier/frp/pkg/msg" + v1 "kanhole/pkg/config/v1" + "kanhole/pkg/msg" ) func init() { diff --git a/server/proxy/xtcp_test.go b/server/proxy/xtcp_test.go index b2e6c1ad..85f7e40f 100644 --- a/server/proxy/xtcp_test.go +++ b/server/proxy/xtcp_test.go @@ -23,8 +23,8 @@ import ( "github.com/stretchr/testify/require" - "github.com/fatedier/frp/pkg/msg" - "github.com/fatedier/frp/pkg/proto/wire" + "kanhole/pkg/msg" + "kanhole/pkg/proto/wire" ) func TestWriteNatHoleSidUsesWireV2MessageFrame(t *testing.T) { diff --git a/server/registry/registry_test.go b/server/registry/registry_test.go index 0ff083b8..f0444e69 100644 --- a/server/registry/registry_test.go +++ b/server/registry/registry_test.go @@ -20,7 +20,7 @@ import ( clocktesting "k8s.io/utils/clock/testing" - "github.com/fatedier/frp/pkg/proto/wire" + "kanhole/pkg/proto/wire" ) func TestClientRegistryRegisterStoresWireProtocol(t *testing.T) { diff --git a/server/service.go b/server/service.go index bd847d2c..f23c9959 100644 --- a/server/service.go +++ b/server/service.go @@ -32,31 +32,31 @@ import ( quic "github.com/quic-go/quic-go" "github.com/samber/lo" - "github.com/fatedier/frp/pkg/auth" - v1 "github.com/fatedier/frp/pkg/config/v1" - modelmetrics "github.com/fatedier/frp/pkg/metrics" - "github.com/fatedier/frp/pkg/msg" - "github.com/fatedier/frp/pkg/nathole" - plugin "github.com/fatedier/frp/pkg/plugin/server" - "github.com/fatedier/frp/pkg/proto/wire" - "github.com/fatedier/frp/pkg/ssh" - "github.com/fatedier/frp/pkg/transport" - httppkg "github.com/fatedier/frp/pkg/util/http" - "github.com/fatedier/frp/pkg/util/log" - netpkg "github.com/fatedier/frp/pkg/util/net" - "github.com/fatedier/frp/pkg/util/tcpmux" - "github.com/fatedier/frp/pkg/util/util" - "github.com/fatedier/frp/pkg/util/version" - "github.com/fatedier/frp/pkg/util/vhost" - "github.com/fatedier/frp/pkg/util/xlog" - "github.com/fatedier/frp/server/admin" - "github.com/fatedier/frp/server/controller" - "github.com/fatedier/frp/server/group" - "github.com/fatedier/frp/server/metrics" - "github.com/fatedier/frp/server/ports" - "github.com/fatedier/frp/server/proxy" - "github.com/fatedier/frp/server/registry" - "github.com/fatedier/frp/server/visitor" + "kanhole/pkg/auth" + v1 "kanhole/pkg/config/v1" + modelmetrics "kanhole/pkg/metrics" + "kanhole/pkg/msg" + "kanhole/pkg/nathole" + plugin "kanhole/pkg/plugin/server" + "kanhole/pkg/proto/wire" + "kanhole/pkg/ssh" + "kanhole/pkg/transport" + httppkg "kanhole/pkg/util/http" + "kanhole/pkg/util/log" + netpkg "kanhole/pkg/util/net" + "kanhole/pkg/util/tcpmux" + "kanhole/pkg/util/util" + "kanhole/pkg/util/version" + "kanhole/pkg/util/vhost" + "kanhole/pkg/util/xlog" + "kanhole/server/admin" + "kanhole/server/controller" + "kanhole/server/group" + "kanhole/server/metrics" + "kanhole/server/ports" + "kanhole/server/proxy" + "kanhole/server/registry" + "kanhole/server/visitor" ) const ( diff --git a/server/visitor/visitor.go b/server/visitor/visitor.go index 57194d98..061a1449 100644 --- a/server/visitor/visitor.go +++ b/server/visitor/visitor.go @@ -23,8 +23,8 @@ import ( libio "github.com/fatedier/golib/io" - netpkg "github.com/fatedier/frp/pkg/util/net" - "github.com/fatedier/frp/pkg/util/util" + netpkg "kanhole/pkg/util/net" + "kanhole/pkg/util/util" ) type listenerBundle struct { diff --git a/test/e2e/compatibility/compatibility_test.go b/test/e2e/compatibility/compatibility_test.go index b6225890..0acf6c18 100644 --- a/test/e2e/compatibility/compatibility_test.go +++ b/test/e2e/compatibility/compatibility_test.go @@ -13,11 +13,11 @@ import ( "github.com/onsi/ginkgo/v2" "github.com/onsi/gomega" - "github.com/fatedier/frp/pkg/util/log" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/pkg/port" - "github.com/fatedier/frp/test/e2e/pkg/process" + "kanhole/pkg/util/log" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/pkg/port" + "kanhole/test/e2e/pkg/process" ) type compatTestContext struct { diff --git a/test/e2e/e2e.go b/test/e2e/e2e.go index ee00e103..804231f4 100644 --- a/test/e2e/e2e.go +++ b/test/e2e/e2e.go @@ -6,8 +6,8 @@ import ( "github.com/onsi/ginkgo/v2" "github.com/onsi/gomega" - "github.com/fatedier/frp/pkg/util/log" - "github.com/fatedier/frp/test/e2e/framework" + "kanhole/pkg/util/log" + "kanhole/test/e2e/framework" ) var _ = ginkgo.SynchronizedBeforeSuite(func() []byte { diff --git a/test/e2e/e2e_test.go b/test/e2e/e2e_test.go index e32f89f0..e3e2a77e 100644 --- a/test/e2e/e2e_test.go +++ b/test/e2e/e2e_test.go @@ -8,15 +8,15 @@ import ( _ "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/pkg/util/log" + "kanhole/pkg/util/log" // test source - "github.com/fatedier/frp/test/e2e/framework" - _ "github.com/fatedier/frp/test/e2e/legacy/basic" - _ "github.com/fatedier/frp/test/e2e/legacy/features" - _ "github.com/fatedier/frp/test/e2e/legacy/plugin" - _ "github.com/fatedier/frp/test/e2e/v1/basic" - _ "github.com/fatedier/frp/test/e2e/v1/features" - _ "github.com/fatedier/frp/test/e2e/v1/plugin" + "kanhole/test/e2e/framework" + _ "kanhole/test/e2e/legacy/basic" + _ "kanhole/test/e2e/legacy/features" + _ "kanhole/test/e2e/legacy/plugin" + _ "kanhole/test/e2e/v1/basic" + _ "kanhole/test/e2e/v1/features" + _ "kanhole/test/e2e/v1/plugin" ) // handleFlags sets up all flags and parses the command line. diff --git a/test/e2e/examples.go b/test/e2e/examples.go index 9f0bc335..f22d6bb5 100644 --- a/test/e2e/examples.go +++ b/test/e2e/examples.go @@ -5,8 +5,8 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" ) var _ = ginkgo.Describe("[Feature: Example]", func() { diff --git a/test/e2e/framework/client.go b/test/e2e/framework/client.go index c13cee10..0da16da3 100644 --- a/test/e2e/framework/client.go +++ b/test/e2e/framework/client.go @@ -1,7 +1,7 @@ package framework import ( - clientsdk "github.com/fatedier/frp/pkg/sdk/client" + clientsdk "kanhole/pkg/sdk/client" ) func (f *Framework) APIClientForFrpc(port int) *clientsdk.Client { diff --git a/test/e2e/framework/consts/consts.go b/test/e2e/framework/consts/consts.go index 4c7c2f13..d2f94362 100644 --- a/test/e2e/framework/consts/consts.go +++ b/test/e2e/framework/consts/consts.go @@ -4,7 +4,7 @@ import ( "fmt" "time" - "github.com/fatedier/frp/test/e2e/pkg/port" + "kanhole/test/e2e/pkg/port" ) const ( diff --git a/test/e2e/framework/framework.go b/test/e2e/framework/framework.go index 34c0eb63..680d7b3d 100644 --- a/test/e2e/framework/framework.go +++ b/test/e2e/framework/framework.go @@ -11,9 +11,9 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/test/e2e/mock/server" - "github.com/fatedier/frp/test/e2e/pkg/port" - "github.com/fatedier/frp/test/e2e/pkg/process" + "kanhole/test/e2e/mock/server" + "kanhole/test/e2e/pkg/port" + "kanhole/test/e2e/pkg/process" ) type Options struct { diff --git a/test/e2e/framework/mockservers.go b/test/e2e/framework/mockservers.go index 65d9f621..156b4692 100644 --- a/test/e2e/framework/mockservers.go +++ b/test/e2e/framework/mockservers.go @@ -5,11 +5,11 @@ import ( "net/http" "os" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/mock/server" - "github.com/fatedier/frp/test/e2e/mock/server/httpserver" - "github.com/fatedier/frp/test/e2e/mock/server/streamserver" - "github.com/fatedier/frp/test/e2e/pkg/port" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/mock/server" + "kanhole/test/e2e/mock/server/httpserver" + "kanhole/test/e2e/mock/server/streamserver" + "kanhole/test/e2e/pkg/port" ) const ( diff --git a/test/e2e/framework/process.go b/test/e2e/framework/process.go index 8d27e887..6988deea 100644 --- a/test/e2e/framework/process.go +++ b/test/e2e/framework/process.go @@ -9,10 +9,10 @@ import ( "strconv" "time" - "github.com/fatedier/frp/pkg/config" - flog "github.com/fatedier/frp/pkg/util/log" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/pkg/process" + "kanhole/pkg/config" + flog "kanhole/pkg/util/log" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/pkg/process" ) // RunProcesses starts one frps and zero or more frpc processes from templates. diff --git a/test/e2e/framework/request.go b/test/e2e/framework/request.go index a6ac565a..2eec4823 100644 --- a/test/e2e/framework/request.go +++ b/test/e2e/framework/request.go @@ -4,9 +4,9 @@ import ( "bytes" "net/http" - flog "github.com/fatedier/frp/pkg/util/log" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/pkg/request" + flog "kanhole/pkg/util/log" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/pkg/request" ) func SpecifiedHTTPBodyHandler(body []byte) http.HandlerFunc { diff --git a/test/e2e/legacy/basic/basic.go b/test/e2e/legacy/basic/basic.go index 0115c6cb..d32d9df8 100644 --- a/test/e2e/legacy/basic/basic.go +++ b/test/e2e/legacy/basic/basic.go @@ -8,13 +8,13 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/pkg/transport" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/mock/server/httpserver" - "github.com/fatedier/frp/test/e2e/mock/server/streamserver" - "github.com/fatedier/frp/test/e2e/pkg/port" - "github.com/fatedier/frp/test/e2e/pkg/request" + "kanhole/pkg/transport" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/mock/server/httpserver" + "kanhole/test/e2e/mock/server/streamserver" + "kanhole/test/e2e/pkg/port" + "kanhole/test/e2e/pkg/request" ) var _ = ginkgo.Describe("[Feature: Basic]", func() { diff --git a/test/e2e/legacy/basic/client.go b/test/e2e/legacy/basic/client.go index d9b9b6da..c5267121 100644 --- a/test/e2e/legacy/basic/client.go +++ b/test/e2e/legacy/basic/client.go @@ -9,9 +9,9 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/pkg/request" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/pkg/request" ) var _ = ginkgo.Describe("[Feature: ClientManage]", func() { diff --git a/test/e2e/legacy/basic/client_server.go b/test/e2e/legacy/basic/client_server.go index 330b9cfc..e4fdfee4 100644 --- a/test/e2e/legacy/basic/client_server.go +++ b/test/e2e/legacy/basic/client_server.go @@ -7,10 +7,10 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/pkg/cert" - "github.com/fatedier/frp/test/e2e/pkg/port" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/pkg/cert" + "kanhole/test/e2e/pkg/port" ) type generalTestConfigures struct { diff --git a/test/e2e/legacy/basic/cmd.go b/test/e2e/legacy/basic/cmd.go index 7d86233a..25bd3d60 100644 --- a/test/e2e/legacy/basic/cmd.go +++ b/test/e2e/legacy/basic/cmd.go @@ -6,8 +6,8 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/pkg/request" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/pkg/request" ) const ( diff --git a/test/e2e/legacy/basic/config.go b/test/e2e/legacy/basic/config.go index 334cc062..445bcb5b 100644 --- a/test/e2e/legacy/basic/config.go +++ b/test/e2e/legacy/basic/config.go @@ -5,9 +5,9 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/pkg/port" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/pkg/port" ) var _ = ginkgo.Describe("[Feature: Config]", func() { diff --git a/test/e2e/legacy/basic/http.go b/test/e2e/legacy/basic/http.go index f1807ecd..e9fee4a9 100644 --- a/test/e2e/legacy/basic/http.go +++ b/test/e2e/legacy/basic/http.go @@ -9,10 +9,10 @@ import ( "github.com/gorilla/websocket" "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/mock/server/httpserver" - "github.com/fatedier/frp/test/e2e/pkg/request" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/mock/server/httpserver" + "kanhole/test/e2e/pkg/request" ) var _ = ginkgo.Describe("[Feature: HTTP]", func() { diff --git a/test/e2e/legacy/basic/server.go b/test/e2e/legacy/basic/server.go index 3407a165..cabc04e7 100644 --- a/test/e2e/legacy/basic/server.go +++ b/test/e2e/legacy/basic/server.go @@ -8,10 +8,10 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/pkg/port" - "github.com/fatedier/frp/test/e2e/pkg/request" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/pkg/port" + "kanhole/test/e2e/pkg/request" ) var _ = ginkgo.Describe("[Feature: Server Manager]", func() { diff --git a/test/e2e/legacy/basic/tcpmux.go b/test/e2e/legacy/basic/tcpmux.go index 3872ea04..995472b8 100644 --- a/test/e2e/legacy/basic/tcpmux.go +++ b/test/e2e/legacy/basic/tcpmux.go @@ -8,12 +8,12 @@ import ( "github.com/onsi/ginkgo/v2" - httppkg "github.com/fatedier/frp/pkg/util/http" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/mock/server/streamserver" - "github.com/fatedier/frp/test/e2e/pkg/request" - "github.com/fatedier/frp/test/e2e/pkg/rpc" + httppkg "kanhole/pkg/util/http" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/mock/server/streamserver" + "kanhole/test/e2e/pkg/request" + "kanhole/test/e2e/pkg/rpc" ) var _ = ginkgo.Describe("[Feature: TCPMUX httpconnect]", func() { diff --git a/test/e2e/legacy/basic/xtcp.go b/test/e2e/legacy/basic/xtcp.go index 6e72f2e1..3018aea4 100644 --- a/test/e2e/legacy/basic/xtcp.go +++ b/test/e2e/legacy/basic/xtcp.go @@ -6,10 +6,10 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/pkg/port" - "github.com/fatedier/frp/test/e2e/pkg/request" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/pkg/port" + "kanhole/test/e2e/pkg/request" ) var _ = ginkgo.Describe("[Feature: XTCP]", func() { diff --git a/test/e2e/legacy/features/bandwidth_limit.go b/test/e2e/legacy/features/bandwidth_limit.go index a54866b8..e5463308 100644 --- a/test/e2e/legacy/features/bandwidth_limit.go +++ b/test/e2e/legacy/features/bandwidth_limit.go @@ -7,12 +7,12 @@ import ( "github.com/onsi/ginkgo/v2" - plugin "github.com/fatedier/frp/pkg/plugin/server" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/mock/server/streamserver" - pluginpkg "github.com/fatedier/frp/test/e2e/pkg/plugin" - "github.com/fatedier/frp/test/e2e/pkg/request" + plugin "kanhole/pkg/plugin/server" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/mock/server/streamserver" + pluginpkg "kanhole/test/e2e/pkg/plugin" + "kanhole/test/e2e/pkg/request" ) var _ = ginkgo.Describe("[Feature: Bandwidth Limit]", func() { diff --git a/test/e2e/legacy/features/chaos.go b/test/e2e/legacy/features/chaos.go index 9fccc4cb..60f16dcd 100644 --- a/test/e2e/legacy/features/chaos.go +++ b/test/e2e/legacy/features/chaos.go @@ -6,7 +6,7 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/test/e2e/framework" + "kanhole/test/e2e/framework" ) var _ = ginkgo.Describe("[Feature: Chaos]", func() { diff --git a/test/e2e/legacy/features/group.go b/test/e2e/legacy/features/group.go index 57c143c5..eb3b4baa 100644 --- a/test/e2e/legacy/features/group.go +++ b/test/e2e/legacy/features/group.go @@ -8,11 +8,11 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/mock/server/httpserver" - "github.com/fatedier/frp/test/e2e/mock/server/streamserver" - "github.com/fatedier/frp/test/e2e/pkg/request" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/mock/server/httpserver" + "kanhole/test/e2e/mock/server/streamserver" + "kanhole/test/e2e/pkg/request" ) var _ = ginkgo.Describe("[Feature: Group]", func() { diff --git a/test/e2e/legacy/features/heartbeat.go b/test/e2e/legacy/features/heartbeat.go index 3c1758f2..271a2fd1 100644 --- a/test/e2e/legacy/features/heartbeat.go +++ b/test/e2e/legacy/features/heartbeat.go @@ -6,7 +6,7 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/test/e2e/framework" + "kanhole/test/e2e/framework" ) var _ = ginkgo.Describe("[Feature: Heartbeat]", func() { diff --git a/test/e2e/legacy/features/monitor.go b/test/e2e/legacy/features/monitor.go index 0b19a85e..09cbced5 100644 --- a/test/e2e/legacy/features/monitor.go +++ b/test/e2e/legacy/features/monitor.go @@ -7,10 +7,10 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/pkg/util/log" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/pkg/request" + "kanhole/pkg/util/log" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/pkg/request" ) var _ = ginkgo.Describe("[Feature: Monitor]", func() { diff --git a/test/e2e/legacy/features/real_ip.go b/test/e2e/legacy/features/real_ip.go index dae74e56..d4f50e8e 100644 --- a/test/e2e/legacy/features/real_ip.go +++ b/test/e2e/legacy/features/real_ip.go @@ -9,13 +9,13 @@ import ( "github.com/onsi/ginkgo/v2" pp "github.com/pires/go-proxyproto" - "github.com/fatedier/frp/pkg/util/log" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/mock/server/httpserver" - "github.com/fatedier/frp/test/e2e/mock/server/streamserver" - "github.com/fatedier/frp/test/e2e/pkg/request" - "github.com/fatedier/frp/test/e2e/pkg/rpc" + "kanhole/pkg/util/log" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/mock/server/httpserver" + "kanhole/test/e2e/mock/server/streamserver" + "kanhole/test/e2e/pkg/request" + "kanhole/test/e2e/pkg/rpc" ) var _ = ginkgo.Describe("[Feature: Real IP]", func() { diff --git a/test/e2e/legacy/plugin/client.go b/test/e2e/legacy/plugin/client.go index ca294280..7ef045fe 100644 --- a/test/e2e/legacy/plugin/client.go +++ b/test/e2e/legacy/plugin/client.go @@ -8,13 +8,13 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/pkg/transport" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/mock/server/httpserver" - "github.com/fatedier/frp/test/e2e/pkg/cert" - "github.com/fatedier/frp/test/e2e/pkg/port" - "github.com/fatedier/frp/test/e2e/pkg/request" + "kanhole/pkg/transport" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/mock/server/httpserver" + "kanhole/test/e2e/pkg/cert" + "kanhole/test/e2e/pkg/port" + "kanhole/test/e2e/pkg/request" ) var _ = ginkgo.Describe("[Feature: Client-Plugins]", func() { diff --git a/test/e2e/legacy/plugin/server.go b/test/e2e/legacy/plugin/server.go index b00b1bac..fe339279 100644 --- a/test/e2e/legacy/plugin/server.go +++ b/test/e2e/legacy/plugin/server.go @@ -6,11 +6,11 @@ import ( "github.com/onsi/ginkgo/v2" - plugin "github.com/fatedier/frp/pkg/plugin/server" - "github.com/fatedier/frp/pkg/transport" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - pluginpkg "github.com/fatedier/frp/test/e2e/pkg/plugin" + plugin "kanhole/pkg/plugin/server" + "kanhole/pkg/transport" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + pluginpkg "kanhole/test/e2e/pkg/plugin" ) var _ = ginkgo.Describe("[Feature: Server-Plugins]", func() { diff --git a/test/e2e/mock/server/streamserver/server.go b/test/e2e/mock/server/streamserver/server.go index 9e237d96..2e493ad9 100644 --- a/test/e2e/mock/server/streamserver/server.go +++ b/test/e2e/mock/server/streamserver/server.go @@ -7,8 +7,8 @@ import ( "net" "strconv" - libnet "github.com/fatedier/frp/pkg/util/net" - "github.com/fatedier/frp/test/e2e/pkg/rpc" + libnet "kanhole/pkg/util/net" + "kanhole/test/e2e/pkg/rpc" ) type Type string diff --git a/test/e2e/pkg/plugin/plugin.go b/test/e2e/pkg/plugin/plugin.go index b807a060..bc69e4aa 100644 --- a/test/e2e/pkg/plugin/plugin.go +++ b/test/e2e/pkg/plugin/plugin.go @@ -6,9 +6,9 @@ import ( "io" "net/http" - plugin "github.com/fatedier/frp/pkg/plugin/server" - "github.com/fatedier/frp/pkg/util/log" - "github.com/fatedier/frp/test/e2e/mock/server/httpserver" + plugin "kanhole/pkg/plugin/server" + "kanhole/pkg/util/log" + "kanhole/test/e2e/mock/server/httpserver" ) type Handler func(req *plugin.Request) *plugin.Response diff --git a/test/e2e/pkg/request/request.go b/test/e2e/pkg/request/request.go index c3b72669..1916e72a 100644 --- a/test/e2e/pkg/request/request.go +++ b/test/e2e/pkg/request/request.go @@ -14,8 +14,8 @@ import ( libnet "github.com/fatedier/golib/net" - httppkg "github.com/fatedier/frp/pkg/util/http" - "github.com/fatedier/frp/test/e2e/pkg/rpc" + httppkg "kanhole/pkg/util/http" + "kanhole/test/e2e/pkg/rpc" ) type Request struct { diff --git a/test/e2e/v1/basic/annotations.go b/test/e2e/v1/basic/annotations.go index 78e94a16..343e6521 100644 --- a/test/e2e/v1/basic/annotations.go +++ b/test/e2e/v1/basic/annotations.go @@ -8,8 +8,8 @@ import ( "github.com/onsi/ginkgo/v2" "github.com/tidwall/gjson" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" ) var _ = ginkgo.Describe("[Feature: Annotations]", func() { diff --git a/test/e2e/v1/basic/basic.go b/test/e2e/v1/basic/basic.go index 8994ba73..0a6d5ccb 100644 --- a/test/e2e/v1/basic/basic.go +++ b/test/e2e/v1/basic/basic.go @@ -8,13 +8,13 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/pkg/transport" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/mock/server/httpserver" - "github.com/fatedier/frp/test/e2e/mock/server/streamserver" - "github.com/fatedier/frp/test/e2e/pkg/port" - "github.com/fatedier/frp/test/e2e/pkg/request" + "kanhole/pkg/transport" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/mock/server/httpserver" + "kanhole/test/e2e/mock/server/streamserver" + "kanhole/test/e2e/pkg/port" + "kanhole/test/e2e/pkg/request" ) var _ = ginkgo.Describe("[Feature: Basic]", func() { diff --git a/test/e2e/v1/basic/client.go b/test/e2e/v1/basic/client.go index ec2011ea..f2ce9fcf 100644 --- a/test/e2e/v1/basic/client.go +++ b/test/e2e/v1/basic/client.go @@ -9,9 +9,9 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/pkg/request" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/pkg/request" ) var _ = ginkgo.Describe("[Feature: ClientManage]", func() { diff --git a/test/e2e/v1/basic/client_server.go b/test/e2e/v1/basic/client_server.go index 3a2fa28d..0211950c 100644 --- a/test/e2e/v1/basic/client_server.go +++ b/test/e2e/v1/basic/client_server.go @@ -7,10 +7,10 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/pkg/cert" - "github.com/fatedier/frp/test/e2e/pkg/port" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/pkg/cert" + "kanhole/test/e2e/pkg/port" ) type generalTestConfigures struct { diff --git a/test/e2e/v1/basic/cmd.go b/test/e2e/v1/basic/cmd.go index 44aa3599..7292d9b7 100644 --- a/test/e2e/v1/basic/cmd.go +++ b/test/e2e/v1/basic/cmd.go @@ -6,8 +6,8 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/pkg/request" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/pkg/request" ) const ( diff --git a/test/e2e/v1/basic/config.go b/test/e2e/v1/basic/config.go index e290109e..88b51189 100644 --- a/test/e2e/v1/basic/config.go +++ b/test/e2e/v1/basic/config.go @@ -6,9 +6,9 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/pkg/port" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/pkg/port" ) var _ = ginkgo.Describe("[Feature: Config]", func() { diff --git a/test/e2e/v1/basic/http.go b/test/e2e/v1/basic/http.go index 1a44ba21..9c722938 100644 --- a/test/e2e/v1/basic/http.go +++ b/test/e2e/v1/basic/http.go @@ -10,10 +10,10 @@ import ( "github.com/gorilla/websocket" "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/mock/server/httpserver" - "github.com/fatedier/frp/test/e2e/pkg/request" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/mock/server/httpserver" + "kanhole/test/e2e/pkg/request" ) var _ = ginkgo.Describe("[Feature: HTTP]", func() { diff --git a/test/e2e/v1/basic/oidc.go b/test/e2e/v1/basic/oidc.go index 19539c76..f1b24ad5 100644 --- a/test/e2e/v1/basic/oidc.go +++ b/test/e2e/v1/basic/oidc.go @@ -20,10 +20,10 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/mock/server/oidcserver" - "github.com/fatedier/frp/test/e2e/pkg/port" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/mock/server/oidcserver" + "kanhole/test/e2e/pkg/port" ) var _ = ginkgo.Describe("[Feature: OIDC]", func() { diff --git a/test/e2e/v1/basic/server.go b/test/e2e/v1/basic/server.go index 04ae01b7..458e58db 100644 --- a/test/e2e/v1/basic/server.go +++ b/test/e2e/v1/basic/server.go @@ -8,10 +8,10 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/pkg/port" - "github.com/fatedier/frp/test/e2e/pkg/request" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/pkg/port" + "kanhole/test/e2e/pkg/request" ) var _ = ginkgo.Describe("[Feature: Server Manager]", func() { diff --git a/test/e2e/v1/basic/tcpmux.go b/test/e2e/v1/basic/tcpmux.go index 9b839faa..7effa34d 100644 --- a/test/e2e/v1/basic/tcpmux.go +++ b/test/e2e/v1/basic/tcpmux.go @@ -8,12 +8,12 @@ import ( "github.com/onsi/ginkgo/v2" - httppkg "github.com/fatedier/frp/pkg/util/http" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/mock/server/streamserver" - "github.com/fatedier/frp/test/e2e/pkg/request" - "github.com/fatedier/frp/test/e2e/pkg/rpc" + httppkg "kanhole/pkg/util/http" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/mock/server/streamserver" + "kanhole/test/e2e/pkg/request" + "kanhole/test/e2e/pkg/rpc" ) var _ = ginkgo.Describe("[Feature: TCPMUX httpconnect]", func() { diff --git a/test/e2e/v1/basic/token_source.go b/test/e2e/v1/basic/token_source.go index d12dd4de..dbef56b2 100644 --- a/test/e2e/v1/basic/token_source.go +++ b/test/e2e/v1/basic/token_source.go @@ -24,9 +24,9 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/pkg/port" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/pkg/port" ) var _ = ginkgo.Describe("[Feature: TokenSource]", func() { diff --git a/test/e2e/v1/basic/wire.go b/test/e2e/v1/basic/wire.go index bbae9199..89a96d04 100644 --- a/test/e2e/v1/basic/wire.go +++ b/test/e2e/v1/basic/wire.go @@ -8,9 +8,9 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/pkg/port" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/pkg/port" ) var _ = ginkgo.Describe("[Feature: WireProtocol]", func() { diff --git a/test/e2e/v1/basic/xtcp.go b/test/e2e/v1/basic/xtcp.go index 57905f0d..2d4655a4 100644 --- a/test/e2e/v1/basic/xtcp.go +++ b/test/e2e/v1/basic/xtcp.go @@ -6,10 +6,10 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/pkg/port" - "github.com/fatedier/frp/test/e2e/pkg/request" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/pkg/port" + "kanhole/test/e2e/pkg/request" ) var _ = ginkgo.Describe("[Feature: XTCP]", func() { diff --git a/test/e2e/v1/features/bandwidth_limit.go b/test/e2e/v1/features/bandwidth_limit.go index 11503adb..1121c584 100644 --- a/test/e2e/v1/features/bandwidth_limit.go +++ b/test/e2e/v1/features/bandwidth_limit.go @@ -7,12 +7,12 @@ import ( "github.com/onsi/ginkgo/v2" - plugin "github.com/fatedier/frp/pkg/plugin/server" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/mock/server/streamserver" - pluginpkg "github.com/fatedier/frp/test/e2e/pkg/plugin" - "github.com/fatedier/frp/test/e2e/pkg/request" + plugin "kanhole/pkg/plugin/server" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/mock/server/streamserver" + pluginpkg "kanhole/test/e2e/pkg/plugin" + "kanhole/test/e2e/pkg/request" ) var _ = ginkgo.Describe("[Feature: Bandwidth Limit]", func() { diff --git a/test/e2e/v1/features/chaos.go b/test/e2e/v1/features/chaos.go index 8c515251..1badb53c 100644 --- a/test/e2e/v1/features/chaos.go +++ b/test/e2e/v1/features/chaos.go @@ -6,7 +6,7 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/test/e2e/framework" + "kanhole/test/e2e/framework" ) var _ = ginkgo.Describe("[Feature: Chaos]", func() { diff --git a/test/e2e/v1/features/group.go b/test/e2e/v1/features/group.go index 85b938a9..5a47322e 100644 --- a/test/e2e/v1/features/group.go +++ b/test/e2e/v1/features/group.go @@ -9,12 +9,12 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/pkg/transport" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/mock/server/httpserver" - "github.com/fatedier/frp/test/e2e/mock/server/streamserver" - "github.com/fatedier/frp/test/e2e/pkg/request" + "kanhole/pkg/transport" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/mock/server/httpserver" + "kanhole/test/e2e/mock/server/streamserver" + "kanhole/test/e2e/pkg/request" ) var _ = ginkgo.Describe("[Feature: Group]", func() { diff --git a/test/e2e/v1/features/heartbeat.go b/test/e2e/v1/features/heartbeat.go index 08a1b5d9..3ac07154 100644 --- a/test/e2e/v1/features/heartbeat.go +++ b/test/e2e/v1/features/heartbeat.go @@ -6,7 +6,7 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/test/e2e/framework" + "kanhole/test/e2e/framework" ) var _ = ginkgo.Describe("[Feature: Heartbeat]", func() { diff --git a/test/e2e/v1/features/monitor.go b/test/e2e/v1/features/monitor.go index f70dce16..7f894399 100644 --- a/test/e2e/v1/features/monitor.go +++ b/test/e2e/v1/features/monitor.go @@ -7,10 +7,10 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/pkg/util/log" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/pkg/request" + "kanhole/pkg/util/log" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/pkg/request" ) var _ = ginkgo.Describe("[Feature: Monitor]", func() { diff --git a/test/e2e/v1/features/real_ip.go b/test/e2e/v1/features/real_ip.go index 6bebfc2b..a83cbd51 100644 --- a/test/e2e/v1/features/real_ip.go +++ b/test/e2e/v1/features/real_ip.go @@ -10,14 +10,14 @@ import ( "github.com/onsi/ginkgo/v2" pp "github.com/pires/go-proxyproto" - "github.com/fatedier/frp/pkg/transport" - "github.com/fatedier/frp/pkg/util/log" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/mock/server/httpserver" - "github.com/fatedier/frp/test/e2e/mock/server/streamserver" - "github.com/fatedier/frp/test/e2e/pkg/request" - "github.com/fatedier/frp/test/e2e/pkg/rpc" + "kanhole/pkg/transport" + "kanhole/pkg/util/log" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/mock/server/httpserver" + "kanhole/test/e2e/mock/server/streamserver" + "kanhole/test/e2e/pkg/request" + "kanhole/test/e2e/pkg/rpc" ) var _ = ginkgo.Describe("[Feature: Real IP]", func() { diff --git a/test/e2e/v1/features/ssh_tunnel.go b/test/e2e/v1/features/ssh_tunnel.go index c120eab0..5dca252c 100644 --- a/test/e2e/v1/features/ssh_tunnel.go +++ b/test/e2e/v1/features/ssh_tunnel.go @@ -9,13 +9,13 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/pkg/transport" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/mock/server/httpserver" - "github.com/fatedier/frp/test/e2e/mock/server/streamserver" - "github.com/fatedier/frp/test/e2e/pkg/request" - "github.com/fatedier/frp/test/e2e/pkg/ssh" + "kanhole/pkg/transport" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/mock/server/httpserver" + "kanhole/test/e2e/mock/server/streamserver" + "kanhole/test/e2e/pkg/request" + "kanhole/test/e2e/pkg/ssh" ) var _ = ginkgo.Describe("[Feature: SSH Tunnel]", func() { diff --git a/test/e2e/v1/features/store.go b/test/e2e/v1/features/store.go index 76a9b05a..430f87e5 100644 --- a/test/e2e/v1/features/store.go +++ b/test/e2e/v1/features/store.go @@ -8,9 +8,9 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/pkg/request" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/pkg/request" ) var _ = ginkgo.Describe("[Feature: Store]", func() { diff --git a/test/e2e/v1/plugin/client.go b/test/e2e/v1/plugin/client.go index 1ea25a6e..482bbaf6 100644 --- a/test/e2e/v1/plugin/client.go +++ b/test/e2e/v1/plugin/client.go @@ -9,13 +9,13 @@ import ( "github.com/onsi/ginkgo/v2" - "github.com/fatedier/frp/pkg/transport" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - "github.com/fatedier/frp/test/e2e/mock/server/httpserver" - "github.com/fatedier/frp/test/e2e/pkg/cert" - "github.com/fatedier/frp/test/e2e/pkg/port" - "github.com/fatedier/frp/test/e2e/pkg/request" + "kanhole/pkg/transport" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + "kanhole/test/e2e/mock/server/httpserver" + "kanhole/test/e2e/pkg/cert" + "kanhole/test/e2e/pkg/port" + "kanhole/test/e2e/pkg/request" ) var _ = ginkgo.Describe("[Feature: Client-Plugins]", func() { diff --git a/test/e2e/v1/plugin/server.go b/test/e2e/v1/plugin/server.go index fd684ef5..db2d6c25 100644 --- a/test/e2e/v1/plugin/server.go +++ b/test/e2e/v1/plugin/server.go @@ -6,11 +6,11 @@ import ( "github.com/onsi/ginkgo/v2" - plugin "github.com/fatedier/frp/pkg/plugin/server" - "github.com/fatedier/frp/pkg/transport" - "github.com/fatedier/frp/test/e2e/framework" - "github.com/fatedier/frp/test/e2e/framework/consts" - pluginpkg "github.com/fatedier/frp/test/e2e/pkg/plugin" + plugin "kanhole/pkg/plugin/server" + "kanhole/pkg/transport" + "kanhole/test/e2e/framework" + "kanhole/test/e2e/framework/consts" + pluginpkg "kanhole/test/e2e/pkg/plugin" ) var _ = ginkgo.Describe("[Feature: Server-Plugins]", func() { diff --git a/web/frpc/embed.go b/web/frpc/embed.go index 77b4863e..cce58ede 100644 --- a/web/frpc/embed.go +++ b/web/frpc/embed.go @@ -5,7 +5,7 @@ package frpc import ( "embed" - "github.com/fatedier/frp/assets" + "kanhole/assets" ) //go:embed dist diff --git a/web/frps/embed.go b/web/frps/embed.go index a1264d7c..3d469970 100644 --- a/web/frps/embed.go +++ b/web/frps/embed.go @@ -5,7 +5,7 @@ package frps import ( "embed" - "github.com/fatedier/frp/assets" + "kanhole/assets" ) //go:embed dist