GithubHelp home page GithubHelp logo

eleweek / histsync Goto Github PK

View Code? Open in Web Editor NEW
33.0 33.0 13.0 100 KB

Cloud Bash History app using python and flask

Home Page: http://histsync.io/

License: MIT License

Python 37.24% Mako 0.77% HTML 25.50% CSS 1.35% JavaScript 16.59% Shell 18.54%

histsync's People

Contributors

echocage avatar eleweek avatar elimohl avatar evverx avatar gitter-badger avatar justanr avatar patallen avatar phillipsz avatar raoulvdberge avatar ravenvz avatar rsiemens 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

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

histsync's Issues

Add cmd.exe support

I'm not sure if you can edit te history of a cmd.exe session, but that would be a cool feature.

Full API

The current api is very basic, web UI uses _command urls(e.g. _publish_command/)

Split configuration into Development/Production and, maybe Standalone

Right now, to start playing around with local version of the app, quite a few
changes have to be made. For example, here are steps I had to do:

  • It does not make much sense for me to use PostgreSQL on local machine,
    so I had to alter requirements.txt to not include psycopg2 adapter;
  • I had to change App config to use sqlite db;
  • A had to use a hack to bypass GitHub authorization.

Steps like these are tedious to do by hand and should be handled by configuration files.
I think, that separation of configuration would help new contributors to get started more quickly.

This issue intersects with #10, as it would probably require separate configuration anyway.
If this proposal is accepted, I could work on it. Please let me know if it makes sense.

Internal server error 500.

Some server configuration seems to be off.

$ cat ~/.histsync/log

2015-06-24 20:09:40,279 - 15405 - root - ERROR - HTTP Error 500: INTERNAL SERVER ERROR
Traceback (most recent call last):
  File "/Users/nudies/.histsync/histsync-client", line 36, in upload_command
    urllib2.urlopen(req)
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 154, in urlopen
    return opener.open(url, data, timeout)
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 437, in open
    response = meth(req, response)
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 550, in http_response
    'http', request, response, code, msg, hdrs)
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 475, in error
    return self._call_chain(*args)
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 409, in _call_chain
    result = func(*args)
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 558, in http_error_default
    raise HTTPError(req.get_full_url(), code, msg, hdrs, fp)
HTTPError: HTTP Error 500: INTERNAL SERVER ERROR

Posting the same payload to the server in the browser returns the same error.

http://www.histsync.io/api/v0/user/nudies/commands?api_key=<api-key>&command=cut%20-f%20%3Ccol%20%23%3E%20%3Ctabfile.txt%3E%20%7C%20sort%20%7C%20uniq%20-dc

{
status: 500,
message: "Internal Server Error"
}

Easy stand-alone deploy

Some people care a lot about their privacy. It is necessary to provide a nice way to deploy the app for them(e.g. no github dependency, "deploy to heroku" button, etc, etc)

Fix Starring and Unstarring

First I came here to leave an issue about maybe allowing commands to be upvoted which I thought would be cool, and then I realized that Starring other peoples commands acts in the same way as an upvote would.

So the issue is twofold, one is that when you star something a message pops over and says you starred it, but the counter doesn't increment without refreshing the page. And the second part of the issue is that unstar does not work entirely.

I will probably submit a pull request to fix this sometime tomorrow if you don't mind. Otherwise it's probably not difficult to fix yourself.

Issue when making something public

When making this command public:

java -jar Passambler-DEV-jar-with-dependencies.jar -r="writeln('Hello World')"

It cuts it off in the publish dialog like this:

java -jar Passambler-DEV-jar-with-dependencies.jar -r=

This happens because the element is specified like this:

value="' + $(that).data('command-text') + '"

This makes the value this:

value="java -jar Passambler-DEV-jar-with-dependencies.jar -r="writeln('Hello World')""

...which cuts of the ".

This makes XSS injection possible!

Use this instead:

value="' + $(that).data('command-text').replace(/"/g, "&quot;") + '"

Cool index page

E.g. show big buttons to app core functionality, show recent commands etc

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.