GithubHelp home page GithubHelp logo

gocapability's People

Contributors

akihirosuda avatar avagin avatar fvoznika avatar justincormack avatar k1low avatar lk4d4 avatar picohz avatar rhatdan avatar syndtr avatar vishvananda avatar vmarmol avatar wking avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

gocapability's Issues

please tag formal releases

Please consider assigning version numbers and tagging releases. Tags/releases
are useful for downstream package maintainers (in Debian and other distributions) to export source tarballs, automatically track new releases and to declare dependencies between packages. Read more in the Debian Upstream Guide.

Versioning provides additional benefits to encourage vendoring of a particular (e.g. latest stable) release contrary to random unreleased snapshots.

Thank you.

See also

Getting the capability data value to write to write to tar header

Is there a way to access the data of security.capability?

I want to add capabilities to files in a tar archive. This library would do exactly what I need, except that it seems like there is no way to get the actual data. I only found setVfsCap which directly sets it on a file. It would be great if there would be something like VFSCap() []byte which would return a byte array which I can directly write into a PAXRecords from the golang tar library.

Cannot set ambient by gocapability?

Hello, I wrote a test program, as following:
package main

import (
"fmt"
"github.com/syndtr/gocapability/capability"
)

func main() {
processCaps, err := capability.NewPid(0)
if err != nil {
fmt.Println("failed to create pid")
}
processCaps.Set(capability.BOUNDING,capability.CAP_CHOWN)
processCaps.Set(capability.EFFECTIVE,capability.CAP_CHOWN)
processCaps.Set(capability.PERMITTED,capability.CAP_CHOWN)
processCaps.Set(capability.INHERITABLE,capability.CAP_CHOWN)
processCaps.Set(capability.AMBIENT,capability.CAP_CHOWN)
if err := processCaps.Apply(capability.CAPS | capability.BOUNDS | capability.AMBIENT); err != nil {
fmt.Println("failed to apply")
}

processCaps2, err := capability.NewPid(0)
if err != nil {
    fmt.Println("failed to create pid")
}   
set := processCaps2.Get(capability.AMBIENT, capability.CAP_CHOWN)
if !set {
    fmt.Println("failed to set")
}   

}

And the result is
$ sudo go run test.go
failed to set

Is there a bug with library or used it in a wrong way?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.