Skip to content

Support for Archlinux #6

@XenGi

Description

@XenGi

I tried porting this to archlinux with not much success. I skipped the weird setup script because it assumes that the otseca files live in someones home dir or similar which is not how you should install software.
I put together this PKGBUILD to install it which seems to work for now but a proper install method would be nice in the future. Maybe try a Makefile or something. It's really ieasy to do and people know how to use those.

# Maintainer: Ricardo (XenGi) Band <[email protected]>
pkgname=otseca
pkgver=1.0.5
pkgrel=1
pkgdesc="Open source security auditing tool to search and dump system configuration"
arch=('i686' 'x86_64')
url="https://github.com/trimstray/otseca"
license=('GPL')
source=("https://github.com/trimstray/otseca/archive/v${pkgver}.tar.gz")
sha256sums=('c04818c531bc8181f5e6603f237d1f6ca7a909c149f73ed7f9a54f94ce065df6')

package() {
  cd "${srcdir}/${pkgname}-${pkgver}"
  # ./setup.sh install -- not doing that weird thing of an install script

  install -Dm0755 bin/otseca ${pkgdir}/usr/share/otseca/bin/otseca
  install -d ${pkgdir}/usr/bin
  ln -sf /usr/share/otseca/bin/otseca ${pkgdir}/usr/bin/otseca

  install -d ${pkgdir}/usr/share/otseca
  cp -r doc ${pkgdir}/usr/share/otseca/
  gzip ${pkgdir}/usr/share/otseca/doc/man8/otseca.8
  install -d ${pkgdir}/usr/share/man/man8
  ln -sf /usr/share/otseca/doc/man8/otseca.8.gz ${pkgdir}/usr/share/man/man8/otseca.8.gz

  install -Dm0644 -t ${pkgdir}/etc/otseca/ etc/*
  ln -sf /etc/otseca ${pkgdir}/usr/share/otseca/etc

  install -Dm0644 -t ${pkgdir}/usr/share/otseca/lib lib/*
  install -Dm0644 -t ${pkgdir}/usr/share/otseca/src src/*
  cp -r templates ${pkgdir}/usr/share/otseca/templates
  install -Dm0644 README.md ${pkgdir}/usr/share/otseca/README.md

  install -d ${pkgdir}/var/log/otseca
  ln -sf /var/log/otseca ${pkgdir}/usr/share/otseca/log

  install -d ${pkgdir}/usr/share/otseca/data/output
}

Anyway after installing otseca and running it I get the following output:

$ sudo otseca --show-errors
      ┌─────────────────────────────────────────────────────────────┐
      │                                                             │
      │           Φ otseca v1.0.5 security audit script             │
      │                                                             │
      │        Project: https://github.com/trimstray/otseca         │
      │                                                             │
      │               Debian GNU/Linux, CentOS Linux                │
      │                                                             │
      └─────────────────────────────────────────────────────────────┘

      
   °°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°

  -- [ Init environment ] --

     • load otseca.conf
     • set dump directory: dump.1552473482
     • set log file: dump.log

   °°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°°

  -- [ Dump system information ] --

     × task: SYSTEM
     ¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨
      • exec: uname -a  					 [ DONE ] 
      • exec: uptime    					 [ DONE ] 
      • exec: lsb_release -a    				 [ DONE ] 
      • exec: cat /proc/cpuinfo 				 [ DONE ] 
      • exec: ps -auxenf					 [ DONE ] 
      • grep: "^\s*linux" in /boot/grub/grub.*  		 [ TRUE ] 
         stderr:
sed: can't read /usr/share/otseca/bin/../data/output/dump.1552473482/err.log: No such file or directory

I'm not sure what the problem is. The directory /usr/share/otseca/bin/../data/output/dump.1552473482 has no err.log file but instead some dump.log.1552473482-system-* files.

This doesn't seem to be a archlinux specific problem. SO maybe I found a generic bug here?

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions