Giter VIP home page Giter VIP logo

Comments (6)

benbjohnson avatar benbjohnson commented on July 23, 2024

@tv42 What's the security issue exactly? They're all in tests and go test code already has full system access anyway. Also, the last 3 db_test.go references are only for generating string representations of DB. The example_test.go references are there because it's cleaner to show in the Examples section of godocs.

from bolt.

benbjohnson avatar benbjohnson commented on July 23, 2024

Fixed in #127.

from bolt.

tv42 avatar tv42 commented on July 23, 2024

Sorry for losing track of this ticket. The bad code is gone, replying here for the sake of historical record.

The reason for avoiding hardcoded paths to files inside /tmp is that on multi-user systems, that behavior lets other users attack you. Classic attacks target root, but this is a general user isolation crossing technique.

Some more modern less-UNIX environments have all kinds of mitigating mechanisms, but even if the attacks themselves are stopped, if a program assumes /tmp/foo is safe to mess with, what happens when you run two copies of the program? Or two different users run the program? Or someone does "touch /tmp/foo" and goes on a vacation? (Cue rant about how /tmp should not be shared across users anymore, in this day and age of bind mounts and what not.)

http://www.infosecwriters.com/texts.php?op=display&id=159
https://en.wikipedia.org/wiki/Symlink_race

from bolt.

benbjohnson avatar benbjohnson commented on July 23, 2024

Thanks for following up on the ticket. By the way, I really liked your LA gophers talk on Bolt. I thought it was a really straightforward and good intro.

from bolt.

tv42 avatar tv42 commented on July 23, 2024

Thanks! Feel free to steal my way of explaining it ;)

from bolt.

benbjohnson avatar benbjohnson commented on July 23, 2024

Definitely! I'm going to start closing up the "documentation" GitHub issues. It'll be useful for writing a Getting Started section.

from bolt.

Related Issues (20)

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.