From owner-freebsd-questions@freebsd.org Sat Apr 28 02:40:20 2018 Return-Path: Delivered-To: freebsd-questions@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CB7D5FBA624; Sat, 28 Apr 2018 02:40:20 +0000 (UTC) (envelope-from grarpamp@gmail.com) Received: from mail-it0-x244.google.com (mail-it0-x244.google.com [IPv6:2607:f8b0:4001:c0b::244]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 59C60801D1; Sat, 28 Apr 2018 02:40:20 +0000 (UTC) (envelope-from grarpamp@gmail.com) Received: by mail-it0-x244.google.com with SMTP id f6-v6so4181801ita.2; Fri, 27 Apr 2018 19:40:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to:cc; bh=le5T0bXDDAZZsxTeYCw5GH+GVdvtfj8A8elO+5HagWw=; b=n4wZeTzyM5/e70Md3D27ftwNXXt9jHTiAUBZAWYVtfquaAAIgiuFAH4Nix53UKydpY u/rHOCyhxH5S06DgWzv3dek8X9xCk5+ckpmkqy+qnPrevKwOIHkZ+riw3hqUTrnCYPq2 8p8jfqjFanFW7ngVGIHbDpOJ4rtFWV2bN+j3su9YZXXT/dNRx88XEOYhW79EiGEa3Yw5 8GMvdkEcR2b/8eIgmnpZGtuzrdplwhR7iS1rDNaMt3gTQabpNVsk6q7kGYsooleIZ+3n AGT/fjAu7rVloYIGHCORfYSrkcuhfJiccBpGwY0IE5ekYC7aY6pyrhVPFKDh32Q1p5K3 KtHA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to:cc; bh=le5T0bXDDAZZsxTeYCw5GH+GVdvtfj8A8elO+5HagWw=; b=p/pDF9CviblF8rKF1RHwBWfaZexcbt2PHDVlmZSczRAcuCQOM7I3+1CL/ew94BLSu6 y/rQi8TTlGOHmwOHaPSdihyXrvtCT9PzzTK1FYCr95KJiVQDFZ1zzdDlb/v04BWRQNz2 41vJbYFw0Uhl72coeARH8uVx3/S1T/0ld8JUzmndwfluNobVL29fa+kJSrByZv7lc8eI O4F66vv7ny0lJp5cLzpE9KwRqKJHt1/2wuxAooFPaKOepbTYtBhmiYUuMb5cg8CbKoAw o/A2PVZPlYUSU1OozpgjeRL49bdwwiekrCHMHn+JBKsEWqdJIPrFMsC/mm92WLLmzefx CPkA== X-Gm-Message-State: ALQs6tDN4ja0mpW2mSHhTYVVSleiTdwZAIHNX4xaHAB3ryyt1GYFKWwz hB3uKAEI0x2cT1+a4D/kSuUVX7gffWinFyVPRnJbZg== X-Google-Smtp-Source: AB8JxZqmVeBWmtXqZG/5ZHUcb/y8ueP4fUcnyhLRlLpIO1nNlDSrYBPeji6IaC6K3F0Fe6Y9kjwt2/lGG9oFGWuupvQ= X-Received: by 2002:a24:2c52:: with SMTP id i79-v6mr4611525iti.101.1524883219326; Fri, 27 Apr 2018 19:40:19 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a02:8d6a:0:0:0:0:0 with HTTP; Fri, 27 Apr 2018 19:39:38 -0700 (PDT) From: grarpamp Date: Fri, 27 Apr 2018 22:39:38 -0400 Message-ID: Subject: Exploit Lecture: Writing FreeBSD Malware To: freebsd-security@freebsd.org Cc: freebsd-questions@freebsd.org, freebsd-hackers@freebsd.org Content-Type: text/plain; charset="UTF-8" X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 28 Apr 2018 02:40:21 -0000 https://www.youtube.com/watch?v=bT_k06Xg-BE Without exploit mitigations and with an insecure-by-default design, writing malware for FreeBSD is a fun task, taking us back to 1999-era Linux exploit authorship. Several members of FreeBSD's development team have claimed that Capsicum, a capabilities/sandboxing framework, prevents exploitation of applications. Our in-depth analysis of the topics below will show that in order to be effective, applying Capsicum to existing complex codebases lends itself to wrapper-style sandboxing. Wrapper-style sandbox is a technique whereby privileged operations get wrapped and passed to a segregated process, which performs the operation on behalf of the capsicumized process. With a new libhijack payload, we will demonstrate that wrapper-style sandboxing requires ASLR and CFI for effectiveness. FreeBSD supports neither ASLR nor CFI. Tying into the wrapper-style Capsicum defeat, we'll talk about advances being made with libhijack, a tool announced at Thotcon 0x4. The payload developed in the Capsicum discussion will be used with libhijack, thus making it easy to extend. We will also learn the Mandatory Access Control (MAC) framework in FreeBSD. The MAC framework places hooks into several key places in the kernel. We'll learn how to abuse the MAC framework for writing efficient rootkits. Attendees of this presentation should walk away with the knowledge to skillfully and artfully write offensive code targeting both the FreeBSD userland and the kernel. https://twitter.com/lattera/status/989602709950029824 Shawn Webb is a cofounder of HardenedBSD, a hardened downstream distribution of FreeBSD. With over a decade in infosec, he dabbles in both the offensive and defensive aspects of the industry. On the advisory board for Emerald Onion, Shawn believes in a more free and open Internet. His whole house is wired for Tor. Getting on the Tor network is only a network jack away! https://www.youtube.com/user/CarolinaConVideos/videos CarolinaCon was started in 2005 and has been held every year since. With each passing year the conference continues to grow and attract more attendees and speakers. As has always been the case, CarolinaCon is put together and run by an all-volunteer staff. CarolinaCon is proudly brought to you by "The CarolinaCon Group". The CarolinaCon Group is a non-profit organization registered in the state of NC, dedicated to educating the local and global communities about technology, information/network/computer security, and information rights. The CarolinaCon Group is also closely associated with various 2600 chapters across NC, SC, TN, VA, LA, DC, GA, PA and NY. Many of the volunteers who help develop and deliver CarolinaCon come from those chapters.