22 Jun, 2019

1 commit

  • Pull still more SPDX updates from Greg KH:
    "Another round of SPDX updates for 5.2-rc6

    Here is what I am guessing is going to be the last "big" SPDX update
    for 5.2. It contains all of the remaining GPLv2 and GPLv2+ updates
    that were "easy" to determine by pattern matching. The ones after this
    are going to be a bit more difficult and the people on the spdx list
    will be discussing them on a case-by-case basis now.

    Another 5000+ files are fixed up, so our overall totals are:
    Files checked: 64545
    Files with SPDX: 45529

    Compared to the 5.1 kernel which was:
    Files checked: 63848
    Files with SPDX: 22576

    This is a huge improvement.

    Also, we deleted another 20000 lines of boilerplate license crud,
    always nice to see in a diffstat"

    * tag 'spdx-5.2-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/spdx: (65 commits)
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 507
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 506
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 505
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 504
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 503
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 502
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 501
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 499
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 498
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 497
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 496
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 495
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 491
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 490
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 489
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 488
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 487
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 486
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 485
    ...

    Linus Torvalds
     

19 Jun, 2019

4 commits

  • Based on 2 normalized pattern(s):

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public license version 2 as
    published by the free software foundation

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public license version 2 as
    published by the free software foundation #

    extracted by the scancode license scanner the SPDX license identifier

    GPL-2.0-only

    has been chosen to replace the boilerplate/reference in 4122 file(s).

    Signed-off-by: Thomas Gleixner
    Reviewed-by: Enrico Weigelt
    Reviewed-by: Kate Stewart
    Reviewed-by: Allison Randal
    Cc: linux-spdx@vger.kernel.org
    Link: https://lkml.kernel.org/r/20190604081206.933168790@linutronix.de
    Signed-off-by: Greg Kroah-Hartman

    Thomas Gleixner
     
  • Each function that manipulates the aa_ext struct should reset it's "pos"
    member on failure. This ensures that, on failure, no changes are made to
    the state of the aa_ext struct.

    There are paths were elements are optional and the error path is
    used to indicate the optional element is not present. This means
    instead of just aborting on error the unpack stream can become
    unsynchronized on optional elements, if using one of the affected
    functions.

    Cc: stable@vger.kernel.org
    Fixes: 736ec752d95e ("AppArmor: policy routines for loading and unpacking policy")
    Signed-off-by: Mike Salvatore
    Signed-off-by: John Johansen

    Mike Salvatore
     
  • A packed AppArmor policy contains null-terminated tag strings that are read
    by unpack_nameX(). However, unpack_nameX() uses string functions on them
    without ensuring that they are actually null-terminated, potentially
    leading to out-of-bounds accesses.

    Make sure that the tag string is null-terminated before passing it to
    strcmp().

    Cc: stable@vger.kernel.org
    Fixes: 736ec752d95e ("AppArmor: policy routines for loading and unpacking policy")
    Signed-off-by: Jann Horn
    Signed-off-by: John Johansen

    Jann Horn
     
  • While commit 11c236b89d7c2 ("apparmor: add a default null dfa") ensure
    every profile has a policy.dfa it does not resize the policy.start[]
    to have entries for every possible start value. Which means
    PROFILE_MEDIATES is not safe to use on untrusted input. Unforunately
    commit b9590ad4c4f2 ("apparmor: remove POLICY_MEDIATES_SAFE") did not
    take into account the start value usage.

    The input string in profile_query_cb() is user controlled and is not
    properly checked to be within the limited start[] entries, even worse
    it can't be as userspace policy is allowed to make us of entries types
    the kernel does not know about. This mean usespace can currently cause
    the kernel to access memory up to 240 entries beyond the start array
    bounds.

    Cc: stable@vger.kernel.org
    Fixes: b9590ad4c4f2 ("apparmor: remove POLICY_MEDIATES_SAFE")
    Signed-off-by: John Johansen

    John Johansen
     

15 Jun, 2019

1 commit

  • The 5.1 mount system rework changed the smackfsdef mount option to
    smackfsdefault. This fixes the regression by making smackfsdef treated
    the same way as smackfsdefault.

    Also fix the smack_param_specs[] to have "smack" prefixes on all the
    names. This isn't visible to a user unless they either:

    (a) Try to mount a filesystem that's converted to the internal mount API
    and that implements the ->parse_monolithic() context operation - and
    only then if they call security_fs_context_parse_param() rather than
    security_sb_eat_lsm_opts().

    There are no examples of this upstream yet, but nfs will probably want
    to do this for nfs2 or nfs3.

    (b) Use fsconfig() to configure the filesystem - in which case
    security_fs_context_parse_param() will be called.

    This issue is that smack_sb_eat_lsm_opts() checks for the "smack" prefix
    on the options, but smack_fs_context_parse_param() does not.

    Fixes: c3300aaf95fb ("smack: get rid of match_token()")
    Fixes: 2febd254adc4 ("smack: Implement filesystem context security hooks")
    Cc: stable@vger.kernel.org
    Reported-by: Jose Bollo
    Signed-off-by: Casey Schaufler
    Signed-off-by: David Howells
    Tested-by: Casey Schaufler
    Signed-off-by: Linus Torvalds

    Casey Schaufler
     

13 Jun, 2019

2 commits


12 Jun, 2019

2 commits

  • In selinux_add_mnt_opt(), 'val' is allocated by kmemdup_nul(). It returns
    NULL when fails. So 'val' should be checked. And 'mnt_opts' should be
    freed when error.

    Signed-off-by: Gen Zhang
    Fixes: 757cbe597fe8 ("LSM: new method: ->sb_add_mnt_opt()")
    Cc:
    [PM: fixed some indenting problems]
    Signed-off-by: Paul Moore

    Gen Zhang
     
  • These strings may come from untrusted sources (e.g. file xattrs) so they
    need to be properly escaped.

    Reproducer:
    # setenforce 0
    # touch /tmp/test
    # setfattr -n security.selinux -v 'kuřecí řízek' /tmp/test
    # runcon system_u:system_r:sshd_t:s0 cat /tmp/test
    (look at the generated AVCs)

    Actual result:
    type=AVC [...] trawcon=kuřecí řízek

    Expected result:
    type=AVC [...] trawcon=6B75C5996563C3AD20C599C3AD7A656B

    Fixes: fede148324c3 ("selinux: log invalid contexts in AVCs")
    Cc: stable@vger.kernel.org # v5.1+
    Signed-off-by: Ondrej Mosnacek
    Acked-by: Richard Guy Briggs
    Signed-off-by: Paul Moore

    Ondrej Mosnacek
     

05 Jun, 2019

4 commits

  • Based on 1 normalized pattern(s):

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public license as published by
    the free software foundation version 2 of the license

    extracted by the scancode license scanner the SPDX license identifier

    GPL-2.0-only

    has been chosen to replace the boilerplate/reference in 315 file(s).

    Signed-off-by: Thomas Gleixner
    Reviewed-by: Allison Randal
    Reviewed-by: Armijn Hemel
    Cc: linux-spdx@vger.kernel.org
    Link: https://lkml.kernel.org/r/20190531190115.503150771@linutronix.de
    Signed-off-by: Greg Kroah-Hartman

    Thomas Gleixner
     
  • Based on 1 normalized pattern(s):

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public license as published by
    the free software foundation version 2

    extracted by the scancode license scanner the SPDX license identifier

    GPL-2.0-only

    has been chosen to replace the boilerplate/reference in 135 file(s).

    Signed-off-by: Thomas Gleixner
    Reviewed-by: Allison Randal
    Cc: linux-spdx@vger.kernel.org
    Link: https://lkml.kernel.org/r/20190531081036.435762997@linutronix.de
    Signed-off-by: Greg Kroah-Hartman

    Thomas Gleixner
     
  • Based on 1 normalized pattern(s):

    this program is free software you can redistribute it and or modify
    it under the terms of version 2 of the gnu general public license as
    published by the free software foundation this program is
    distributed in the hope that it will be useful but without any
    warranty without even the implied warranty of merchantability or
    fitness for a particular purpose see the gnu general public license
    for more details

    extracted by the scancode license scanner the SPDX license identifier

    GPL-2.0-only

    has been chosen to replace the boilerplate/reference in 64 file(s).

    Signed-off-by: Thomas Gleixner
    Reviewed-by: Alexios Zavras
    Reviewed-by: Allison Randal
    Cc: linux-spdx@vger.kernel.org
    Link: https://lkml.kernel.org/r/20190529141901.894819585@linutronix.de
    Signed-off-by: Greg Kroah-Hartman

    Thomas Gleixner
     
  • Based on 1 normalized pattern(s):

    this software is licensed under the terms of the gnu general public
    license version 2 as published by the free software foundation and
    may be copied distributed and modified under those terms this
    program is distributed in the hope that it will be useful but
    without any warranty without even the implied warranty of
    merchantability or fitness for a particular purpose see the gnu
    general public license for more details

    extracted by the scancode license scanner the SPDX license identifier

    GPL-2.0-only

    has been chosen to replace the boilerplate/reference in 285 file(s).

    Signed-off-by: Thomas Gleixner
    Reviewed-by: Alexios Zavras
    Reviewed-by: Allison Randal
    Cc: linux-spdx@vger.kernel.org
    Link: https://lkml.kernel.org/r/20190529141900.642774971@linutronix.de
    Signed-off-by: Greg Kroah-Hartman

    Thomas Gleixner
     

01 Jun, 2019

1 commit

  • …l/git/zohar/linux-integrity

    Pull integrity subsystem fixes from Mimi Zohar:
    "Four bug fixes, none 5.2-specific, all marked for stable.

    The first two are related to the architecture specific IMA policy
    support. The other two patches, one is related to EVM signatures,
    based on additional hash algorithms, and the other is related to
    displaying the IMA policy"

    * 'next-fixes-for-5.2-rc' of git://git.kernel.org/pub/scm/linux/kernel/git/zohar/linux-integrity:
    ima: show rules with IMA_INMASK correctly
    evm: check hash algorithm passed to init_desc()
    ima: fix wrong signed policy requirement when not appraising
    x86/ima: Check EFI_RUNTIME_SERVICES before using

    Linus Torvalds
     

31 May, 2019

1 commit

  • Based on 1 normalized pattern(s):

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public license as published by
    the free software foundation either version 2 of the license or at
    your option any later version

    extracted by the scancode license scanner the SPDX license identifier

    GPL-2.0-or-later

    has been chosen to replace the boilerplate/reference in 3029 file(s).

    Signed-off-by: Thomas Gleixner
    Reviewed-by: Allison Randal
    Cc: linux-spdx@vger.kernel.org
    Link: https://lkml.kernel.org/r/20190527070032.746973796@linutronix.de
    Signed-off-by: Greg Kroah-Hartman

    Thomas Gleixner
     

30 May, 2019

2 commits

  • Show the '^' character when a policy rule has flag IMA_INMASK.

    Fixes: 80eae209d63ac ("IMA: allow reading back the current IMA policy")
    Signed-off-by: Roberto Sassu
    Cc: stable@vger.kernel.org
    Signed-off-by: Mimi Zohar

    Roberto Sassu
     
  • This patch prevents memory access beyond the evm_tfm array by checking the
    validity of the index (hash algorithm) passed to init_desc(). The hash
    algorithm can be arbitrarily set if the security.ima xattr type is not
    EVM_XATTR_HMAC.

    Fixes: 5feeb61183dde ("evm: Allow non-SHA1 digital signatures")
    Signed-off-by: Roberto Sassu
    Cc: stable@vger.kernel.org
    Signed-off-by: Mimi Zohar

    Roberto Sassu
     

25 May, 2019

1 commit

  • Pule more SPDX updates from Greg KH:
    "Here is another set of reviewed patches that adds SPDX tags to
    different kernel files, based on a set of rules that are being used to
    parse the comments to try to determine that the license of the file is
    "GPL-2.0-or-later".

    Only the "obvious" versions of these matches are included here, a
    number of "non-obvious" variants of text have been found but those
    have been postponed for later review and analysis.

    These patches have been out for review on the linux-spdx@vger mailing
    list, and while they were created by automatic tools, they were
    hand-verified by a bunch of different people, all whom names are on
    the patches are reviewers"

    * tag 'spdx-5.2-rc2-2' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core: (85 commits)
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 125
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 123
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 122
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 121
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 120
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 119
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 118
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 116
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 114
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 113
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 112
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 111
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 110
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 106
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 105
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 104
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 103
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 102
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 101
    treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 98
    ...

    Linus Torvalds
     

24 May, 2019

1 commit

  • Based on 1 normalized pattern(s):

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public licence as published by
    the free software foundation either version 2 of the licence or at
    your option any later version

    extracted by the scancode license scanner the SPDX license identifier

    GPL-2.0-or-later

    has been chosen to replace the boilerplate/reference in 114 file(s).

    Signed-off-by: Thomas Gleixner
    Reviewed-by: Allison Randal
    Reviewed-by: Kate Stewart
    Cc: linux-spdx@vger.kernel.org
    Link: https://lkml.kernel.org/r/20190520170857.552531963@linutronix.de
    Signed-off-by: Greg Kroah-Hartman

    Thomas Gleixner
     

22 May, 2019

1 commit


21 May, 2019

3 commits

  • Based on 2 normalized pattern(s):

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public license as published by
    the free software foundation either version 2 of the license or at
    your option any later version this program is distributed in the
    hope that it will be useful but without any warranty without even
    the implied warranty of merchantability or fitness for a particular
    purpose see the gnu general public license for more details you
    should have received a copy of the gnu general public license along
    with this program if not see http www gnu org licenses

    this program is free software you can redistribute it and or modify
    it under the terms of the gnu general public license as published by
    the free software foundation either version 2 of the license or at
    your option any later version this program is distributed in the
    hope that it will be useful but without any warranty without even
    the implied warranty of merchantability or fitness for a particular
    purpose see the gnu general public license for more details [based]
    [from] [clk] [highbank] [c] you should have received a copy of the
    gnu general public license along with this program if not see http
    www gnu org licenses

    extracted by the scancode license scanner the SPDX license identifier

    GPL-2.0-or-later

    has been chosen to replace the boilerplate/reference in 355 file(s).

    Signed-off-by: Thomas Gleixner
    Reviewed-by: Kate Stewart
    Reviewed-by: Jilayne Lovejoy
    Reviewed-by: Steve Winslow
    Reviewed-by: Allison Randal
    Cc: linux-spdx@vger.kernel.org
    Link: https://lkml.kernel.org/r/20190519154041.837383322@linutronix.de
    Signed-off-by: Greg Kroah-Hartman

    Thomas Gleixner
     
  • Add SPDX license identifiers to all Make/Kconfig files which:

    - Have no license information of any form

    These files fall under the project license, GPL v2 only. The resulting SPDX
    license identifier is:

    GPL-2.0-only

    Signed-off-by: Thomas Gleixner
    Signed-off-by: Greg Kroah-Hartman

    Thomas Gleixner
     
  • calling connect(AF_UNSPEC) on an already connected TCP socket is an
    established way to disconnect() such socket. After commit 68741a8adab9
    ("selinux: Fix ltp test connect-syscall failure") it no longer works
    and, in the above scenario connect() fails with EAFNOSUPPORT.

    Fix the above explicitly early checking for AF_UNSPEC family, and
    returning success in that case.

    Reported-by: Tom Deseyn
    Cc: stable@vger.kernel.org
    Fixes: 68741a8adab9 ("selinux: Fix ltp test connect-syscall failure")
    Suggested-by: Paul Moore
    Signed-off-by: Paolo Abeni
    Signed-off-by: Paul Moore

    Paolo Abeni
     

20 May, 2019

1 commit


14 May, 2019

1 commit

  • Pull networking fixes from David Miller:
    "Fixes all over:

    1) Netdev refcnt leak in nf_flow_table, from Taehee Yoo.

    2) Fix RCU usage in nf_tables, from Florian Westphal.

    3) Fix DSA build when NET_DSA_TAG_BRCM_PREPEND is not set, from Yue
    Haibing.

    4) Add missing page read/write ops to realtek driver, from Heiner
    Kallweit.

    5) Endianness fix in qrtr code, from Nicholas Mc Guire.

    6) Fix various bugs in DSA_SKB_* macros, from Vladimir Oltean.

    7) Several BPF documentation cures, from Quentin Monnet.

    8) Fix undefined behavior in narrow load handling of BPF verifier,
    from Krzesimir Nowak.

    9) DMA ops crash in SGI Seeq driver due to not set netdev parent
    device pointer, from Thomas Bogendoerfer.

    10) Flow dissector has to disable preemption when invoking BPF
    program, from Eric Dumazet"

    * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (48 commits)
    net: ethernet: stmmac: dwmac-sun8i: enable support of unicast filtering
    net: ethernet: ti: netcp_ethss: fix build
    flow_dissector: disable preemption around BPF calls
    bonding: fix arp_validate toggling in active-backup mode
    net: meson: fixup g12a glue ephy id
    net: phy: realtek: Replace phy functions with non-locked version in rtl8211e_config_init()
    net: seeq: fix crash caused by not set dev.parent
    of_net: Fix missing of_find_device_by_node ref count drop
    net: mvpp2: cls: Add missing NETIF_F_NTUPLE flag
    bpf: fix undefined behavior in narrow load handling
    libbpf: detect supported kernel BTF features and sanitize BTF
    selftests: bpf: Add files generated after build to .gitignore
    tools: bpf: synchronise BPF UAPI header with tools
    bpf: fix minor issues in documentation for BPF helpers.
    bpf: fix recurring typo in documentation for BPF helpers
    bpf: fix script for generating man page on BPF helpers
    bpf: add various test cases for backward jumps
    net: dccp : proto: remove Unneeded variable "err"
    net: dsa: Remove the now unused DSA_SKB_CB_COPY() macro
    net: dsa: Remove dangerous DSA_SKB_CLONE() macro
    ...

    Linus Torvalds
     

11 May, 2019

5 commits

  • Commit cff0e6c3ec3e6230 ("tomoyo: Add a kernel config option for fuzzing
    testing.") enabled the learning mode, but syzkaller is detecting any
    "WARNING:" string as a crash. Thus, disable TOMOYO's quota warning if
    built for fuzzing testing.

    Signed-off-by: Tetsuo Handa
    Cc: Dmitry Vyukov
    Signed-off-by: James Morris

    Tetsuo Handa
     
  • Commit 5625f2e3266319fd ("TOMOYO: Change pathname for non-rename()able
    filesystems.") intended to be applied to filesystems where the content is
    not controllable from the userspace (e.g. proc, sysfs, securityfs), based
    on an assumption that such filesystems do not support rename() operation.

    But it turned out that read-only filesystems also do not support rename()
    operation despite the content is controllable from the userspace, and that
    commit is annoying TOMOYO users who want to use e.g. squashfs as the root
    filesystem due to use of local name which does not start with '/'.

    Therefore, based on an assumption that filesystems which require the
    device argument upon mount() request is an indication that the content
    is controllable from the userspace, do not use local name if a filesystem
    does not support rename() operation but requires the device argument upon
    mount() request.

    Signed-off-by: Tetsuo Handa
    Signed-off-by: James Morris

    Tetsuo Handa
     
  • KMSAN will complain if valid address length passed to bind()/connect()/
    sendmsg() is shorter than sizeof("struct sockaddr"->sa_family) bytes.

    Signed-off-by: Tetsuo Handa
    Signed-off-by: James Morris

    Tetsuo Handa
     
  • syzbot is reporting kernel panic triggered by memory allocation fault
    injection before loading TOMOYO's policy [1]. To make the fuzzing tests
    useful, we need to assign a profile other than "disabled" (no-op) mode.
    Therefore, let's allow syzbot to load TOMOYO's built-in policy for
    "learning" mode using a kernel config option. This option must not be
    enabled for kernels built for production system, for this option also
    disables domain/program checks when modifying policy configuration via
    /sys/kernel/security/tomoyo/ interface.

    [1] https://syzkaller.appspot.com/bug?extid=29569ed06425fcf67a95

    Reported-by: syzbot
    Reported-by: syzbot
    Reported-by: syzbot
    Signed-off-by: Tetsuo Handa
    Signed-off-by: James Morris

    Tetsuo Handa
     
  • This reverts commit c7e0d6cca86581092cbbf2cd868b3601495554cf.

    It was agreed a slightly different fix via the selinux tree.

    v1 -> v2:
    - use the correct reverted commit hash

    Signed-off-by: Paolo Abeni
    Signed-off-by: David S. Miller

    Paolo Abeni
     

10 May, 2019

2 commits

  • Pull networking fixes from David Miller:
    "Several bug fixes, many are quick merge-window regression cures:

    - When NLM_F_EXCL is not set, allow same fib rule insertion. From
    Hangbin Liu.

    - Several cures in sja1105 DSA driver (while loop exit condition fix,
    return of negative u8, etc.) from Vladimir Oltean.

    - Handle tx/rx delays in realtek PHY driver properly, from Serge
    Semin.

    - Double free in cls_matchall, from Pieter Jansen van Vuuren.

    - Disable SIOCSHWTSTAMP in macvlan/vlan containers, from Hangbin Liu.

    - Endainness fixes in aqc111, from Oliver Neukum.

    - Handle errors in packet_init properly, from Haibing Yue.

    - Various W=1 warning fixes in kTLS, from Jakub Kicinski"

    * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (34 commits)
    nfp: add missing kdoc
    net/tls: handle errors from padding_length()
    net/tls: remove set but not used variables
    docs/btf: fix the missing section marks
    nfp: bpf: fix static check error through tightening shift amount adjustment
    selftests: bpf: initialize bpf_object pointers where needed
    packet: Fix error path in packet_init
    net/tcp: use deferred jump label for TCP acked data hook
    net: aquantia: fix undefined devm_hwmon_device_register_with_info reference
    aqc111: fix double endianness swap on BE
    aqc111: fix writing to the phy on BE
    aqc111: fix endianness issue in aqc111_change_mtu
    vlan: disable SIOCSHWTSTAMP in container
    macvlan: disable SIOCSHWTSTAMP in container
    tipc: fix hanging clients using poll with EPOLLOUT flag
    tuntap: synchronize through tfiles array instead of tun->numqueues
    tuntap: fix dividing by zero in ebpf queue selection
    dwmac4_prog_mtl_tx_algorithms() missing write operation
    ptp_qoriq: fix NULL access if ptp dt node missing
    net/sched: avoid double free on matchall reoffload
    ...

    Linus Torvalds
     
  • Pull smack updates from James Morris:
    "Bug fixes for IPv6 handling and other issues and two memory use
    improvements."

    * 'next-smack' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security:
    Smack: Fix kbuild reported build error
    smack: Check address length before reading address family
    Smack: Fix IPv6 handling of 0 secmark
    Smack: Create smack_rule cache to optimize memory usage
    smack: removal of global rule list

    Linus Torvalds
     

09 May, 2019

1 commit

  • calling connect(AF_UNSPEC) on an already connected TCP socket is an
    established way to disconnect() such socket. After commit 68741a8adab9
    ("selinux: Fix ltp test connect-syscall failure") it no longer works
    and, in the above scenario connect() fails with EAFNOSUPPORT.

    Fix the above falling back to the generic/old code when the address family
    is not AF_INET{4,6}, but leave the SCTP code path untouched, as it has
    specific constraints.

    Fixes: 68741a8adab9 ("selinux: Fix ltp test connect-syscall failure")
    Reported-by: Tom Deseyn
    Signed-off-by: Paolo Abeni
    Reviewed-by: Marcelo Ricardo Leitner
    Signed-off-by: David S. Miller

    Paolo Abeni
     

08 May, 2019

5 commits

  • Pull mount ABI updates from Al Viro:
    "The syscalls themselves, finally.

    That's not all there is to that stuff, but switching individual
    filesystems to new methods is fortunately independent from everything
    else, so e.g. NFS series can go through NFS tree, etc.

    As those conversions get done, we'll be finally able to get rid of a
    bunch of duplication in fs/super.c introduced in the beginning of the
    entire thing. I expect that to be finished in the next window..."

    * 'work.mount-syscalls' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs:
    vfs: Add a sample program for the new mount API
    vfs: syscall: Add fspick() to select a superblock for reconfiguration
    vfs: syscall: Add fsmount() to create a mount for a superblock
    vfs: syscall: Add fsconfig() for configuring and managing a context
    vfs: Implement logging through fs_context
    vfs: syscall: Add fsopen() to prepare for superblock creation
    Make anon_inodes unconditional
    teach move_mount(2) to work with OPEN_TREE_CLONE
    vfs: syscall: Add move_mount(2) to move mounts around
    vfs: syscall: Add open_tree(2) to reference or clone a mount

    Linus Torvalds
     
  • Pull audit updates from Paul Moore:
    "We've got a reasonably broad set of audit patches for the v5.2 merge
    window, the highlights are below:

    - The biggest change, and the source of all the arch/* changes, is
    the patchset from Dmitry to help enable some of the work he is
    doing around PTRACE_GET_SYSCALL_INFO.

    To be honest, including this in the audit tree is a bit of a
    stretch, but it does help move audit a little further along towards
    proper syscall auditing for all arches, and everyone else seemed to
    agree that audit was a "good" spot for this to land (or maybe they
    just didn't want to merge it? dunno.).

    - We can now audit time/NTP adjustments.

    - We continue the work to connect associated audit records into a
    single event"

    * tag 'audit-pr-20190507' of git://git.kernel.org/pub/scm/linux/kernel/git/pcmoore/audit: (21 commits)
    audit: fix a memory leak bug
    ntp: Audit NTP parameters adjustment
    timekeeping: Audit clock adjustments
    audit: purge unnecessary list_empty calls
    audit: link integrity evm_write_xattrs record to syscall event
    syscall_get_arch: add "struct task_struct *" argument
    unicore32: define syscall_get_arch()
    Move EM_UNICORE to uapi/linux/elf-em.h
    nios2: define syscall_get_arch()
    nds32: define syscall_get_arch()
    Move EM_NDS32 to uapi/linux/elf-em.h
    m68k: define syscall_get_arch()
    hexagon: define syscall_get_arch()
    Move EM_HEXAGON to uapi/linux/elf-em.h
    h8300: define syscall_get_arch()
    c6x: define syscall_get_arch()
    arc: define syscall_get_arch()
    Move EM_ARCOMPACT and EM_ARCV2 to uapi/linux/elf-em.h
    audit: Make audit_log_cap and audit_copy_inode static
    audit: connect LOGIN record to its syscall record
    ...

    Linus Torvalds
     
  • Pull selinux updates from Paul Moore:
    "We've got a few SELinux patches for the v5.2 merge window, the
    highlights are below:

    - Add LSM hooks, and the SELinux implementation, for proper labeling
    of kernfs. While we are only including the SELinux implementation
    here, the rest of the LSM folks have given the hooks a thumbs-up.

    - Update the SELinux mdp (Make Dummy Policy) script to actually work
    on a modern system.

    - Disallow userspace to change the LSM credentials via
    /proc/self/attr when the task's credentials are already overridden.

    The change was made in procfs because all the LSM folks agreed this
    was the Right Thing To Do and duplicating it across each LSM was
    going to be annoying"

    * tag 'selinux-pr-20190507' of git://git.kernel.org/pub/scm/linux/kernel/git/pcmoore/selinux:
    proc: prevent changes to overridden credentials
    selinux: Check address length before reading address family
    kernfs: fix xattr name handling in LSM helpers
    MAINTAINERS: update SELinux file patterns
    selinux: avoid uninitialized variable warning
    selinux: remove useless assignments
    LSM: lsm_hooks.h - fix missing colon in docstring
    selinux: Make selinux_kernfs_init_security static
    kernfs: initialize security of newly created nodes
    selinux: implement the kernfs_init_security hook
    LSM: add new hook for kernfs node initialization
    kernfs: use simple_xattrs for security attributes
    selinux: try security xattr after genfs for kernfs filesystems
    kernfs: do not alloc iattrs in kernfs_xattr_get
    kernfs: clean up struct kernfs_iattrs
    scripts/selinux: fix build
    selinux: use kernel linux/socket.h for genheaders and mdp
    scripts/selinux: modernize mdp

    Linus Torvalds
     
  • Pull compiler-based variable initialization updates from Kees Cook:
    "This is effectively part of my gcc-plugins tree, but as this adds some
    Clang support, it felt weird to still call it "gcc-plugins". :)

    This consolidates Kconfig for the existing stack variable
    initialization (via structleak and stackleak gcc plugins) and adds
    Alexander Potapenko's support for Clang's new similar functionality.

    Summary:

    - Consolidate memory initialization Kconfigs (Kees)

    - Implement support for Clang's stack variable auto-init (Alexander)"

    * tag 'meminit-v5.2-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/kees/linux:
    security: Implement Clang's stack initialization
    security: Move stackleak config to Kconfig.hardening
    security: Create "kernel hardening" config area

    Linus Torvalds
     
  • Pull vfs inode freeing updates from Al Viro:
    "Introduction of separate method for RCU-delayed part of
    ->destroy_inode() (if any).

    Pretty much as posted, except that destroy_inode() stashes
    ->free_inode into the victim (anon-unioned with ->i_fops) before
    scheduling i_callback() and the last two patches (sockfs conversion
    and folding struct socket_wq into struct socket) are excluded - that
    pair should go through netdev once davem reopens his tree"

    * 'work.icache' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: (58 commits)
    orangefs: make use of ->free_inode()
    shmem: make use of ->free_inode()
    hugetlb: make use of ->free_inode()
    overlayfs: make use of ->free_inode()
    jfs: switch to ->free_inode()
    fuse: switch to ->free_inode()
    ext4: make use of ->free_inode()
    ecryptfs: make use of ->free_inode()
    ceph: use ->free_inode()
    btrfs: use ->free_inode()
    afs: switch to use of ->free_inode()
    dax: make use of ->free_inode()
    ntfs: switch to ->free_inode()
    securityfs: switch to ->free_inode()
    apparmor: switch to ->free_inode()
    rpcpipe: switch to ->free_inode()
    bpf: switch to ->free_inode()
    mqueue: switch to ->free_inode()
    ufs: switch to ->free_inode()
    coda: switch to ->free_inode()
    ...

    Linus Torvalds
     

07 May, 2019

1 commit

  • Pull security subsystem updates from James Morris:
    "Just a few bugfixes and documentation updates"

    * 'next-general' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security:
    seccomp: fix up grammar in comment
    Revert "security: inode: fix a missing check for securityfs_create_file"
    Yama: mark function as static
    security: inode: fix a missing check for securityfs_create_file
    keys: safe concurrent user->{session,uid}_keyring access
    security: don't use RCU accessors for cred->session_keyring
    Yama: mark local symbols as static
    LSM: lsm_hooks.h: fix documentation format
    LSM: fix documentation for the shm_* hooks
    LSM: fix documentation for the sem_* hooks
    LSM: fix documentation for the msg_queue_* hooks
    LSM: fix documentation for the audit_* hooks
    LSM: fix documentation for the path_chmod hook
    LSM: fix documentation for the socket_getpeersec_dgram hook
    LSM: fix documentation for the task_setscheduler hook
    LSM: fix documentation for the socket_post_create hook
    LSM: fix documentation for the syslog hook
    LSM: fix documentation for sb_copy_data hook

    Linus Torvalds