From patchwork Sat Apr 11 11:45:29 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Adolf Belka X-Patchwork-Id: 9688 Return-Path: Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519) (Client CN "mail01.haj.ipfire.org", Issuer "R12" (not verified)) by web04.haj.ipfire.org (Postfix) with ESMTPS id 4ftBgp6J3Nz3wsm for ; Sat, 11 Apr 2026 11:45:42 +0000 (UTC) Received: from mail02.haj.ipfire.org (mail02.haj.ipfire.org [IPv6:2001:678:b28::201]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519) (Client CN "mail02.haj.ipfire.org", Issuer "E7" (not verified)) by mail01.ipfire.org (Postfix) with ESMTPS id 4ftBgn2SgMz7BZ for ; Sat, 11 Apr 2026 11:45:41 +0000 (UTC) Received: from mail02.haj.ipfire.org (localhost [IPv6:::1]) by mail02.haj.ipfire.org (Postfix) with ESMTP id 4ftBgl23kFz34BB for ; Sat, 11 Apr 2026 11:45:39 +0000 (UTC) X-Original-To: development@lists.ipfire.org Received: from mail01.ipfire.org (mail01.haj.ipfire.org [IPv6:2001:678:b28::25]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519) (Client CN "mail01.haj.ipfire.org", Issuer "R12" (not verified)) by mail02.haj.ipfire.org (Postfix) with ESMTPS id 4ftBgh4zwGz30X7 for ; Sat, 11 Apr 2026 11:45:36 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mail01.ipfire.org (Postfix) with ESMTPSA id 4ftBgh3SNyz76v; Sat, 11 Apr 2026 11:45:36 +0000 (UTC) DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003ed25519; t=1775907936; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=m03a/Dw7Q0wwW0DgHtBKd+4BG+EXN2zqh4nOUF0/lk4=; b=JdzLPyi2IWQv1/bNTPsUBtUDwDP6dRW3JHm4KRYgSHupJ25MfMavmnCHd2DHx01CmzaUKA 6Afa15IpKWVlkjCw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003rsa; t=1775907936; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=m03a/Dw7Q0wwW0DgHtBKd+4BG+EXN2zqh4nOUF0/lk4=; b=pnHe2HwICvezY8bAvm2zXxX/uLzHXtnDC5GevjhizuovUC5vr70di7nvkF9VCqXu0OS1L2 gsr3Wk6MimKg/vHZPloWWtl5M0FFXCTFoJSZ08gt4rmOCNIyoZvmc9rXmSIhfDDFLoUWre 1zWmSyUiTB0T90RwN3Ioi0ReC6d0qvOPkq/vPsVgDGBehWjuXvtoYlzfdkzr4BxcN/4+7V DFusP1TWseSE827N5U9Q8MZXzdmCru8z8X/pBfhfoEmxufUmTbPj9SGUZB2b7ccm/BIBlD uOjJ/ENC0bptG7pBvNsKKZ/wStBxYQMBMFEJNEHJM8sZQ42SC6yFIl2+ssvm9g== From: Adolf Belka To: development@lists.ipfire.org Cc: Adolf Belka Subject: [PATCH 4/7] ovpnmain.cgi: Display only IP for Real Address in Connection Statistics Page Date: Sat, 11 Apr 2026 13:45:29 +0200 Message-ID: <20260411114532.43348-4-adolf.belka@ipfire.org> In-Reply-To: <20260411114532.43348-1-adolf.belka@ipfire.org> References: <20260411114532.43348-1-adolf.belka@ipfire.org> Precedence: list List-Id: List-Subscribe: , List-Unsubscribe: , List-Post: List-Help: Sender: Mail-Followup-To: MIME-Version: 1.0 - In the Connection Statistics page under Real Address it was showing the IP:Port instead of just the IP. - The IP was being split out in $address but this variable was not then used to display the Real Address. - This patch fixes that so that only the IP is shown for the Real Address. Signed-off-by: Adolf Belka --- html/cgi-bin/ovpnmain.cgi | 1 + 1 file changed, 1 insertion(+) diff --git a/html/cgi-bin/ovpnmain.cgi b/html/cgi-bin/ovpnmain.cgi index b435d9e1b..b0d950cbb 100644 --- a/html/cgi-bin/ovpnmain.cgi +++ b/html/cgi-bin/ovpnmain.cgi @@ -3192,6 +3192,7 @@ END $users[$uid]{'Since'} = $match[5]; my $address = (split ':', $users[$uid]{'RealAddress'})[0]; + $users[$uid]{'RealAddress'} = $address; $users[$uid]{'Country'} = &Location::Functions::lookup_country_code($address); $uid++;