资源简介
OpenSSh 7.1 相比 OpenSSH 7.0 的改进
=========================
此版本是个 bug 修复版本
安全更新
--------
* sshd(8): OpenSSH 7.0 contained a logic error in PermitRootLogin=
prohibit-password/without-password that could, depending on
compile-time configuration, permit password authentication to
root while preventing other forms of authentication. This problem
was reported by Mantas Mikulenas.
Bug 修复
--------
* ssh(1), sshd(8): add compatability workarounds for FuTTY
* ssh(1), sshd(8): refine compatability workarounds for WinSCP
* Fix a number of memory faults (double-free, free of uninitialised
memory, etc) in ssh(1) and ssh-keygen(1). Reported by Mateusz
Kocielski.
Checksums:
==========
- SHA1 (openssh-7.1.tar.gz) = 06c1db39f33831fe004726e013b2cf84f1889042
- SHA256 (openssh-7.1.tar.gz) = H7U1se9EoBmhkKi2i7lqpMX9QHdDTsgpu7kd5VZUGSY=
- SHA1 (openssh-7.1p1.tar.gz) = ed22af19f962262c493fcc6ed8c8826b2761d9b6
- SHA256 (openssh-7.1p1.tar.gz) = /AptLR0GPVxm3/2VJJPQzaJWytIE9oHeD4TvhbKthCg=
代码片段和文件信息
/* $OpenBSD: addrmatch.cv 1.10 2015/07/08 19:04:21 markus Exp $ */
/*
* Copyright (c) 2004-2008 Damien Miller
*
* Permission to use copy modify and distribute this software for any
* purpose with or without fee is hereby granted provided that the above
* copyright notice and this permission notice appear in all copies.
*
* THE SOFTWARE IS PROVIDED “AS IS“ AND THE AUTHOR DISCLAIMS ALL WARRANTIES
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
* ANY SPECIAL DIRECT INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
* WHATSOEVER RESULTING FROM LOSS OF USE DATA OR PROFITS WHETHER IN AN
* ACTION OF CONTRACT NEGLIGENCE OR OTHER TORTIOUS ACTION ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#include “includes.h“
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include “match.h“
#include “log.h“
struct xaddr {
sa_family_t af;
union {
struct in_addr v4;
struct in6_addr v6;
u_int8_t addr8[16];
u_int32_t addr32[4];
} xa; /* 128-bit address */
u_int32_t scope_id; /* iface scope id for v6 */
#define v4 xa.v4
#define v6 xa.v6
#define addr8 xa.addr8
#define addr32 xa.addr32
};
static int
addr_unicast_masklen(int af)
{
switch (af) {
case AF_INET:
return 32;
case AF_INET6:
return 128;
default:
return -1;
}
}
static inline int
masklen_valid(int af u_int masklen)
{
switch (af) {
case AF_INET:
return masklen <= 32 ? 0 : -1;
case AF_INET6:
return masklen <= 128 ? 0 : -1;
default:
return -1;
}
}
/*
* Convert struct sockaddr to struct xaddr
* Returns 0 on success -1 on failure.
*/
static int
addr_sa_to_xaddr(struct sockaddr *sa socklen_t slen struct xaddr *xa)
{
struct sockaddr_in *in4 = (struct sockaddr_in *)sa;
struct sockaddr_in6 *in6 = (struct sockaddr_in6 *)sa;
memset(xa ‘\0‘ sizeof(*xa));
switch (sa->sa_family) {
case AF_INET:
if (slen < (socklen_t)sizeof(*in4))
return -1;
xa->af = AF_INET;
memcpy(&xa->v4 &in4->sin_addr sizeof(xa->v4));
break;
case AF_INET6:
if (slen < (socklen_t)sizeof(*in6))
return -1;
xa->af = AF_INET6;
memcpy(&xa->v6 &in6->sin6_addr sizeof(xa->v6));
#ifdef HAVE_STRUCT_SOCKADDR_IN6_SIN6_SCOPE_ID
xa->scope_id = in6->sin6_scope_id;
#endif
break;
default:
return -1;
}
return 0;
}
/*
* Calculate a netmask of length ‘l‘ for address family ‘af‘ and
* store it in ‘n‘.
* Returns 0 on success -1 on failure.
*/
static int
addr_netmask(int af u_int l struct xaddr *n)
{
int i;
if (masklen_valid(af l) != 0 || n == NULL)
return -1;
memset(n ‘\0‘ sizeof(*n));
switch (af) {
case AF_INET:
n->af = AF_INET;
if (l == 0)
return 0;
n->v4.s_addr = htonl((0xffffffff << (32 - l)) & 0xffffffff);
return 0;
case AF_INET6:
n->af
- 上一篇:Labview万用表
- 下一篇:IAR7.8安装及破解教程
相关资源
- openssh-5.9p1.tar.gz
- centos 7.x openssh7.8p RPM包
- centos openssh 升级安装rpm包
- AIX5.3、6.1、7.1可用的openssl0.9.8和open
- 海思3516A 3516D openssl zlib openssh编译
- openssl+openssh离线安装包
- openssh8.1p1-update-el6.tar.gz
- ubuntu14.04LTS离线安装openssh所需要的介
- openssh-8.2.tar.gz
- ubuntu openssh 7.8p1 升级安装包
- Ubuntu升级openssh7.8p1快速命令集
- openssh-6.6p1-1.x86_64.rpm
- openssh for windows--setupssh-7.9p1-1
- CentOS7 1804 OpenSSH8.3p1打包RPM、安装升级
- ubuntu 16.04 离线安装openssh
- OpenSSH for Windows
- window-OpenSSH-64位
- openssh升级包
- CentOSRedHat7版本升级openssh8.1P1.rar
- CentOS7 openssh8.2p1 openssl 1.1.1d升级.txt
- Hi3559A交叉编译openssh
- centos7 openssh7.7p rpm包
- openssh-8.0整合包.zip
- openssh的离线安装包.rar
- openssh-8.0p1 rpm安装包 适用redhat6.9
- OpenSSH_7.9p1
- openssh-8.0p1-1.el7.x86_64.rpm包含所有的r
- Ubuntu16.04 离线安装openssh所需的安装包
- pam-devel-0.99.6.2-6.el5_4.1.x86_64.rpm
- Redhat5.7 6.4升级openSSH7.3sp1、7.7sp1版本
评论
共有 条评论