mirror of
https://github.com/novatiq/packages.git
synced 2026-04-29 06:58:39 +01:00
95fa96bda2
Currently, we called `/usr/libexec/login.sh` as login command, but unfortunately the auth
is disabled by default in it[1], and this is really serious as it could be a free "backdoor"
for any spoiler who has conntectd to the router via LAN or wireless.
In my option, it shouldn't be exposed to anyone without auth, so I set the default login
command to `/bin/login`. And for those who really want that, they can do it themselves.
1. `login.sh` adjusts whether use authentication or not from system config named ttylogin,
which is set to disabled by default. See package/base-files/files/bin/config_generate#L243.
Signed-off-by: Tianling Shen <cnsztl@project-openwrt.eu.org>
Backported from f45bb2981d
51 lines
1.3 KiB
Makefile
51 lines
1.3 KiB
Makefile
#
|
|
# Copyright (C) 2016 Shuanglei Tao <tsl0922@gmail.com>
|
|
#
|
|
# This is free software, licensed under the GNU General Public License v2.
|
|
# See /LICENSE for more information.
|
|
#
|
|
|
|
include $(TOPDIR)/rules.mk
|
|
|
|
PKG_NAME:=ttyd
|
|
PKG_VERSION:=1.5.2
|
|
PKG_RELEASE:=2
|
|
|
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
|
PKG_SOURCE_URL:=https://codeload.github.com/tsl0922/ttyd/tar.gz/$(PKG_VERSION)?
|
|
PKG_HASH:=b5b62ec2ce08add0173e6d1dfdd879e55f02f9490043e89f389981a62e87d376
|
|
|
|
PKG_LICENSE:=MIT
|
|
PKG_LICENSE_FILES:=LICENSE
|
|
PKG_MAINTAINER:=Shuanglei Tao <tsl0922@gmail.com>
|
|
|
|
PKG_BUILD_DEPENDS:=vim/host
|
|
CMAKE_INSTALL:=1
|
|
|
|
include $(INCLUDE_DIR)/package.mk
|
|
include $(INCLUDE_DIR)/cmake.mk
|
|
|
|
define Package/ttyd
|
|
SECTION:=utils
|
|
CATEGORY:=Utilities
|
|
TITLE:=Command-line tool for sharing terminal over the web
|
|
DEPENDS:=+libopenssl +libjson-c +libpthread +libwebsockets-full
|
|
URL:=https://github.com/tsl0922/ttyd
|
|
SUBMENU:=Terminal
|
|
endef
|
|
|
|
define Package/ttyd/description
|
|
ttyd is a command-line tool for sharing terminal over the web.
|
|
endef
|
|
|
|
define Package/ttyd/install
|
|
$(INSTALL_DIR) $(1)/usr/bin
|
|
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/ttyd $(1)/usr/bin/
|
|
$(INSTALL_DIR) $(1)/etc/config/
|
|
$(INSTALL_CONF) ./files/ttyd.config $(1)/etc/config/ttyd
|
|
$(INSTALL_DIR) $(1)/etc/init.d/
|
|
$(INSTALL_BIN) ./files/ttyd.init $(1)/etc/init.d/ttyd
|
|
endef
|
|
|
|
$(eval $(call BuildPackage,ttyd))
|