refpolicy | SELinux Reference Policy v2 | Authorization library

 by   SELinuxProject Python Version: RELEASE_2_20221101 License: GPL-2.0

kandi X-RAY | refpolicy Summary

kandi X-RAY | refpolicy Summary

refpolicy is a Python library typically used in Security, Authorization applications. refpolicy has no bugs, it has no vulnerabilities, it has a Strong Copyleft License and it has low support. However refpolicy build file is not available. You can download it from GitHub.

install-src Install the policy sources into /etc/selinux/NAME/src/policy, where NAME is defined in the Makefile. If not defined, the TYPE, as defined in the Makefile, is used. The default NAME is refpolicy. A pre-existing source policy will be moved to /etc/selinux/NAME/src/policy.bak. conf Regenerate policy.xml, and update/create modules.conf and booleans.conf. This should be done after adding or removing modules, or after running the bare target. If the configuration files exist, their settings will be preserved. This must be ran on policy sources that are checked out from the CVS repository before they can be used. clean Delete all temporary files, compiled policies, and file_contexts. Configuration files are left intact. bare Do the clean make target and also delete configuration files, web page documentation, and policy.xml. html Regenerate policy.xml and create web page documentation in the doc/html directory.
Support
    Quality
      Security
        License
          Reuse

            kandi-support Support

              refpolicy has a low active ecosystem.
              It has 250 star(s) with 114 fork(s). There are 18 watchers for this library.
              OutlinedDot
              It had no major release in the last 12 months.
              There are 3 open issues and 76 have been closed. On average issues are closed in 45 days. There are 5 open pull requests and 0 closed requests.
              It has a neutral sentiment in the developer community.
              The latest version of refpolicy is RELEASE_2_20221101

            kandi-Quality Quality

              refpolicy has 0 bugs and 0 code smells.

            kandi-Security Security

              refpolicy has no vulnerabilities reported, and its dependent libraries have no vulnerabilities reported.
              refpolicy code analysis shows 0 unresolved vulnerabilities.
              There are 0 security hotspots that need review.

            kandi-License License

              refpolicy is licensed under the GPL-2.0 License. This license is Strong Copyleft.
              Strong Copyleft licenses enforce sharing, and you can use them when creating open source projects.

            kandi-Reuse Reuse

              refpolicy releases are available to install and integrate.
              refpolicy has no build file. You will be need to create the build yourself to build the component from source.
              It has 2502 lines of code, 104 functions and 31 files.
              It has high code complexity. Code complexity directly impacts maintainability of the code.

            Top functions reviewed by kandi - BETA

            kandi has reviewed refpolicy and discovered the below as its top functions. This is intended to give you an instant insight into refpolicy implemented functionality, and help decide if they suit your requirements.
            • Generate the documentation
            • Formats a node description
            • Print an error message
            • Executes the given data and returns the result
            • Get access vectors from a file
            • Get permissions for a given object
            • Return the module XML
            • Get the tunable XML from a file
            • Write the output to the file
            • Generate a module configuration file
            • Generate booleans configuration file
            • Generate class permissions
            • Read security classes from a file
            • Parse a corenet file
            • Reads a conf file
            • Creates a template node for the given parser
            • Print Netfilter configuration
            • Print out netfilter configuration
            • Read a policy XML document
            • Print usage information
            • Adds a node
            • Execute the expression
            • Add a node
            • Parse a template string
            • Returns the SELinux type
            • Execute the script
            Get all kandi verified functions for this library.

            refpolicy Key Features

            No Key Features are available at this moment for refpolicy.

            refpolicy Examples and Code Snippets

            No Code Snippets are available at this moment for refpolicy.

            Community Discussions

            QUESTION

            How to update modules.conf for SELINUX in BUILDROOT?
            Asked 2020-Aug-18 at 02:32

            looking to disable some SELinux modules (set to off) and create others in modules.conf. I don't see an obvious way of updating modules.conf as I tried adding my changes as a modules.conf patch but it failed given that the modules.conf file gets built and is not just downloaded by BR so it is not available for patching like other things under the refpolicy directory:

            Build window output:

            refpolicy 2.20190609 PatchingApplying 0001-refpolicy-update-modules-conf.patch using patch: can't find file to patch at input line 3

            I did see in the log that there is a support/sedoctool.py that autogenerates the policy/modules.conf file so that the file is NOT patchable like most other things in the ref policy.

            The relevant section of the buildroot/output/build/refpolicy-2.20190609/Makefile:

            ...

            ANSWER

            Answered 2020-Aug-18 at 02:32

            Turns out that the sedoctool.py script is reading the doc/policy.xml. Looking at sedoctool.py:

            Source https://stackoverflow.com/questions/63450612

            Community Discussions, Code Snippets contain sources that include Stack Exchange Network

            Vulnerabilities

            No vulnerabilities reported

            Install refpolicy

            You can download it from GitHub.
            You can use refpolicy like any standard Python library. You will need to make sure that you have a development environment consisting of a Python distribution including header files, a compiler, pip, and git installed. Make sure that your pip, setuptools, and wheel are up to date. When using pip it is generally recommended to install packages in a virtual environment to avoid changes to the system.

            Support

            For any new features, suggestions and bugs create an issue on GitHub. If you have any questions check and ask questions on community page Stack Overflow .
            Find more information at:

            Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items

            Find more libraries
            CLONE
          • HTTPS

            https://github.com/SELinuxProject/refpolicy.git

          • CLI

            gh repo clone SELinuxProject/refpolicy

          • sshUrl

            git@github.com:SELinuxProject/refpolicy.git

          • Stay Updated

            Subscribe to our newsletter for trending solutions and developer bootcamps

            Agree to Sign up and Terms & Conditions

            Share this Page

            share link

            Explore Related Topics

            Consider Popular Authorization Libraries

            casbin

            by casbin

            RxPermissions

            by tbruyelle

            opa

            by open-policy-agent

            cancan

            by ryanb

            Try Top Libraries by SELinuxProject

            selinux

            by SELinuxProjectC

            selinux-notebook

            by SELinuxProjectPython

            setools

            by SELinuxProjectPython

            selinux-kernel

            by SELinuxProjectC

            cil

            by SELinuxProjectC