From patchwork Tue Sep 11 01:52:23 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Peter_M=C3=BCller?= X-Patchwork-Id: 1923 Return-Path: Received: from mail01.ipfire.org (mail01.ipfire.org [IPv6:2001:470:7183:25::1]) by web02.i.ipfire.org (Postfix) with ESMTP id 2FAC761A11 for ; Mon, 10 Sep 2018 17:57:29 +0200 (CEST) Received: from mail01.i.ipfire.org (localhost [IPv6:::1]) by mail01.ipfire.org (Postfix) with ESMTP id E02E310A14AD; Mon, 10 Sep 2018 16:57:28 +0100 (BST) Received: from mx-nbg.link38.eu (mx-nbg.link38.eu [IPv6:2a03:4000:6:432c:1f9e:48:ac3:199]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mx-nbg.link38.eu", Issuer "Let's Encrypt Authority X3" (verified OK)) by mail01.ipfire.org (Postfix) with ESMTPS id A5B1310A149C for ; Mon, 10 Sep 2018 16:53:03 +0100 (BST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=link38.eu; s=201803; t=1536594743; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=0XcUsEwK19fuPVbX1FfvEHPRDmUaue/Qcdkw4iJVvCw=; b=wmoCQY7SQLfTZRAdPC1S0puIn6Xbp0lMHGvEuxQRrH4c2kaRC0d3SZ88udabnpb6mWfEtb xOfsm0dAwQkRoii46CPUeUta7ooytrm+WikIgPFXakRJ/KlsTrubFFkeXxQ6skw/AsETAb O+lfbPzZZHHw28HCMSYzKg0ih5eB1g2EmrJ5M8WwUBILPHK6QS74RmuHlrAohChRCBeUfQ H47cl+GAiuUuk7TwHPFptBAO6+dFZmX5P038V9kC+Tjb7eao56Bh8Zratp4PhJ0pMgzG7L x2YZRXt2lzQLckd1wFfj3iS2ngqMQ7CzaJKhScl0sBAw3Wsrs3DaLtgDl4B6cA== From: =?utf-8?q?Peter_M=C3=BCller?= To: development@lists.ipfire.org Subject: [PATCH v4 2/2] use custom SSH server configuration in LFS file Date: Mon, 10 Sep 2018 17:52:23 +0200 Message-Id: <20180910155223.2828-2-peter.mueller@link38.eu> In-Reply-To: <20180910155223.2828-1-peter.mueller@link38.eu> References: <20180910155223.2828-1-peter.mueller@link38.eu> MIME-Version: 1.0 Authentication-Results: mail01.ipfire.org; dkim=pass header.d=link38.eu; dmarc=pass (policy=none) header.from=link38.eu; spf=pass smtp.mailfrom=peter.mueller@link38.eu X-Spamd-Result: default: False [-11.54 / 11.00]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[link38.eu]; FROM_HAS_DN(0.00)[]; R_SPF_ALLOW(-0.20)[+ip6:2a03:4000:6:432c:1f9e:48:ac3:199]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; DKIM_TRACE(0.00)[link38.eu:+]; DMARC_POLICY_ALLOW(-0.25)[link38.eu,none]; MID_CONTAINS_FROM(1.00)[]; RCVD_IN_DNSWL_MED(-2.00)[9.9.1.0.3.c.a.0.8.4.0.0.e.9.f.1.c.2.3.4.6.0.0.0.0.0.0.4.3.0.a.2.list.dnswl.org : 127.0.6.2]; NEURAL_HAM(-3.00)[-0.999,0]; MX_GOOD(-0.01)[cached: mx-nbg.link38.eu]; RCVD_COUNT_ZERO(0.00)[0]; FROM_EQ_ENVFROM(0.00)[]; IP_SCORE(-3.78)[ip: (-9.90), ipnet: 2a03:4000::/32(-4.95), asn: 197540(-3.96), country: DE(-0.09)]; ASN(0.00)[asn:197540, ipnet:2a03:4000::/32, country:DE]; RCVD_TLS_ALL(0.00)[]; BAYES_HAM(-3.00)[100.00%] X-Spam-Status: No, score=-11.54 X-Rspamd-Server: mail01.i.ipfire.org X-BeenThere: development@lists.ipfire.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: IPFire development talk List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: development-bounces@lists.ipfire.org Sender: "Development" Include OpenSSH server configuration file during build. Signed-off-by: Peter Müller --- lfs/openssh | 21 ++++----------------- 1 file changed, 4 insertions(+), 17 deletions(-) diff --git a/lfs/openssh b/lfs/openssh index a88b2d126..d60ec7ce5 100644 --- a/lfs/openssh +++ b/lfs/openssh @@ -82,23 +82,10 @@ $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects)) cd $(DIR_APP) && make $(MAKETUNING) cd $(DIR_APP) && make install - sed -i -e 's/^#\?Port .*$$/Port 22/' \ - -e 's/^#\?Protocol .*$$/Protocol 2/' \ - -e 's/^#\?LoginGraceTime .*$$/LoginGraceTime 30s/' \ - -e 's/^#\?PubkeyAuthentication .*$$/PubkeyAuthentication yes/' \ - -e 's/^#\?PasswordAuthentication .*$$/PasswordAuthentication no/' \ - -e 's/^#\?MaxStartups .*$$/MaxStartups 5/' \ - -e 's/^#\?IgnoreUserKnownHosts .*$$/IgnoreUserKnownHosts yes/' \ - -e 's/^#\?UsePAM .*$$//' \ - -e 's/^#\?X11Forwarding .*$$/X11Forwarding no/' \ - -e 's/^#\?SyslogFacility AUTH .*$$/SyslogFacility AUTH/' \ - -e 's/^#\?LogLevel INFO .*$$/LogLevel INFO/' \ - -e 's/^#\?AllowTcpForwarding .*$$/AllowTcpForwarding no/' \ - -e 's/^#\?PermitRootLogin .*$$/PermitRootLogin yes/' \ - -e 's|^#\?HostKey /etc/ssh/ssh_host_dsa_key$$||' \ - -e 's|^#\?HostKey /etc/ssh/ssh_host_ecdsa_key$$||' \ - -e 's|^#\?HostKey /etc/ssh/ssh_host_ed25519_key$$||' \ - -e 's|^#\?HostKey /etc/ssh/ssh_host_rsa_key$$|HostKey /etc/ssh/ssh_host_ecdsa_key\nHostKey /etc/ssh/ssh_host_ed25519_key\nHostKey /etc/ssh/ssh_host_rsa_key|' \ + + # install custom OpenSSH server configuration + install -v -m 644 $(DIR_SRC)/config/ssh/sshd_config \ /etc/ssh/sshd_config + @rm -rf $(DIR_APP) @$(POSTBUILD)