include $(TOPDIR)/rules.mk
PKG_NAME:=obfs4proxy
-PKG_VERSION:=0.0.7
+PKG_VERSION:=0.0.9
PKG_RELEASE:=1
-PKG_SOURCE_PROTO:=git
-PKG_SOURCE_URL:=https://git.torproject.org/pluggable-transports/obfs4.git
-PKG_SOURCE_VERSION:=8256fac93c2cf79742725e3aaced5bbe3380fd32
-PKG_SOURCE_DATE:=20161115
-PKG_MIRROR_HASH:=9c504337f7a2b46310083224cf0998fc7645f8af5d50657cf74358d39916eddc
+PKG_SOURCE:=obfs4-$(PKG_NAME)-$(PKG_VERSION).tar.bz2
+PKG_SOURCE_URL:=https://gitlab.com/yawning/obfs4/-/archive/$(PKG_NAME)-$(PKG_VERSION)/
+PKG_HASH:=ab2608014fae15b4e0dad2f8128e81f912ab27277539004b759180c1fb5007dd
+PKG_BUILD_DIR:=$(BUILD_DIR)/obfs4-$(PKG_NAME)-$(PKG_VERSION)
PKG_LICENSE:=BSD-2-Clause
PKG_LICENSE_FILES:=LICENSE
PKG_BUILD_PARALLEL:=1
PKG_USE_MIPS16:=0
-GO_PKG:=git.torproject.org/pluggable-transports/obfs4.git
+GO_PKG:=gitlab.com/yawning/obfs4.git
include $(INCLUDE_DIR)/package.mk
include ../../lang/golang/golang-package.mk
define Package/obfs4proxy/Default
TITLE:=A Tor pluggable transport proxy, implementing obfs4
- URL:=https://gitweb.torproject.org/pluggable-transports/obfs4.git/
+ URL:=https://gitlab.com/yawning/obfs4
DEPENDS:=$(GO_ARCH_DEPENDS)
endef
CATEGORY:=Network
endef
-define Package/golang-torproject-pluggable-transports-obfs4-dev
+define Package/golang-gitlab-yawning-obfs4-dev
$(call Package/obfs4proxy/Default)
$(call GoPackage/GoSubMenu)
TITLE+= (source files)
program.
endef
-define Package/golang-torproject-pluggable-transports-obfs4-dev/description
+define Package/golang-gitlab-yawning-obfs4-dev/description
$(call Package/obfs4proxy/Default/description)
This package provides the source files for the client/bridge program.
$(eval $(call GoBinPackage,obfs4proxy))
$(eval $(call BuildPackage,obfs4proxy))
-
-$(eval $(call GoSrcPackage,golang-torproject-pluggable-transports-obfs4-dev))
-$(eval $(call BuildPackage,golang-torproject-pluggable-transports-obfs4-dev))
+$(eval $(call GoSrcPackage,golang-gitlab-yawning-obfs4-dev))
+$(eval $(call BuildPackage,golang-gitlab-yawning-obfs4-dev))
+++ /dev/null
-From af4824cb0b2c36a0eba4bc1590eb0737302e992e Mon Sep 17 00:00:00 2001
-From: Yawning Angel <yawning@schwanenlied.me>
-Date: Wed, 10 Jan 2018 15:11:44 +0000
-Subject: Bug 24793: Send the correct authorization HTTP header for basic auth.
-
-Apparently I didn't test the "connect via HTTP(s)" proxy with
-authentication at all when I added that functionality, so it has been
-broken for years.
-
-This should fix it now.
----
- obfs4proxy/proxy_http.go | 5 ++++-
- 1 file changed, 4 insertions(+), 1 deletion(-)
-
-diff --git a/obfs4proxy/proxy_http.go b/obfs4proxy/proxy_http.go
-index 6f11790..a5c2100 100644
---- a/obfs4proxy/proxy_http.go
-+++ b/obfs4proxy/proxy_http.go
-@@ -29,6 +29,7 @@ package main
-
- import (
- "bufio"
-+ "encoding/base64"
- "fmt"
- "net"
- "net/http"
-@@ -90,7 +91,9 @@ func (s *httpProxy) Dial(network, addr string) (net.Conn, error) {
- }
- req.Close = false
- if s.haveAuth {
-- req.SetBasicAuth(s.username, s.password)
-+ // SetBasicAuth doesn't quite do what is appropriate, because
-+ // the correct header is `Proxy-Authorization`.
-+ req.Header.Set("Proxy-Authorization", base64.StdEncoding.EncodeToString([]byte(s.username + ":" + s.password)))
- }
- req.Header.Set("User-Agent", "")
-
---
-cgit v1.1
-