Live data from Hacker News

ShowHN: GetURL - A CLI tool to get a public link for any file

github.com

41–50 of 53 posts

Re: ShowHN: GetURL - A CLI tool to get a public link for any file

#41

Seems like this could be done with more respect for user/data sovereignty if done with Node.js. Essentially, you'd cat the file into the script, it would spin up an HTTP server, do some port knocking or whatever NAT-traversal-fu is necessary, then spit out a link with either your raw IP, or a preconfigured dynDNS domain name. This way we aren't carelessly littering our data all over the "cloud".

Know any port knocking as a service companies? If there was a reliable way to get a udp connection between hosts that I didn't have to write myself, I'd be tempted to take this on.

> Know any port knocking as a service companies?

Are you serious?

Re: ShowHN: GetURL - A CLI tool to get a public link for any file

#42
post #35

I have no idea why I haven't installed xsel already. The help mentions a secondary clipboard. X has a secondary clipboard? Is there a way to paste that (like middle click for the primary)?

Following the old zero-one-infinity rule[1], X has an arbitrary number of clipboards; the most commonly used are PRIMARY (select+middle click), CLIPBOARD (usually C-c/C-v or edit→copy menus) and SECONDARY which, as far as I know, can only be pasted using applications that support it (e.g. xclip -o).

[1]: http://www.catb.org/jargon/html/Z/Zero-One-Infinity-Rule.htm...

Re: ShowHN: GetURL - A CLI tool to get a public link for any file

#43
post #17

Another: cat file | curl -F 'sprunge=

Does sprunge work for non-textual data?

In the same vein, you can try http://flag.io/:

  curl -T /path/to/any/file flag.io
  # or
  cat some-file | curl -T - flag.io
Basically, pipe anything you want into it. It can also syntax-highlight your text files.

Re: ShowHN: GetURL - A CLI tool to get a public link for any file

#44
post #35

I have no idea why I haven't installed xsel already. The help mentions a secondary clipboard. X has a secondary clipboard? Is there a way to paste that (like middle click for the primary)?

You can ignore the bit about Emacs if you wish. http://www.jwz.org/doc/x-cut-and-paste.html

Re: ShowHN: GetURL - A CLI tool to get a public link for any file

#45

Earlier quoted context omitted.

Tooting my own horn again, but you just asked for https://pagekite.net/ : $ pagekite.py /path/to/file.blah yourname.pagekite.me ... send people a link to https://yourname.pagekite.me/file.blah and it streams from your disk. CTRL+C and it's offline with no copies stored anywhere in the cloud. Works with entire folders too (append +indexes to generate indexes), which is good for static HTML demos. If you want a harder-…

Be proud, your domain has made BlueCoat's list of "proxy avoidance" sites and is blocked at my workplace.

Woah, I'm in the big leagues now! Blocking us actually makes perfect sense, PageKite can be used to avoid a lot of quite reasonable corp security policies.

Can you access sites on other domains which are connected via. PageKite? For example my personal site, http://bre.klaki.net/ or my kite http://bre.pagekite.me/ ?

Re: ShowHN: GetURL - A CLI tool to get a public link for any file

#46

Earlier quoted context omitted.

Be proud, your domain has made BlueCoat's list of "proxy avoidance" sites and is blocked at my workplace.

Woah, I'm in the big leagues now! Blocking us actually makes perfect sense, PageKite can be used to avoid a lot of quite reasonable corp security policies. Can you access sites on other domains which are connected via. PageKite? For example my personal site, http://bre.klaki.net/ or my kite http://bre.pagekite.me/ ?

Nothing on pagekite.me, will check the other tomorrow.

Re: ShowHN: GetURL - A CLI tool to get a public link for any file

#47
Nice work and very handy.

I hadn't come across filepicker.io before and reading through the geturl code something jumped out at me:

APIKEY = check_output(['curl', '--silent', "%(fpurl)s/getKey?email=%(email)s" % {'fpurl': FPAPIURL, 'email': email}])

From that, it looks like any random person can fill up your filepicker.io space providing they have your API key or know the email address you used to register the account with. Made sense when I read a bit more about what filepicker.io actually does (i.e. a client-side embeddable javascript file uploader) but it's something to be aware of (especially if you link your account up to an S3 backend!).

Re: ShowHN: GetURL - A CLI tool to get a public link for any file

#48

Earlier quoted context omitted.

Woah, I'm in the big leagues now! Blocking us actually makes perfect sense, PageKite can be used to avoid a lot of quite reasonable corp security policies. Can you access sites on other domains which are connected via. PageKite? For example my personal site, http://bre.klaki.net/ or my kite http://bre.pagekite.me/ ?

Nothing on pagekite.me, will check the other tomorrow.

This probably doesn't belong on this thread, but I would really appreciate e-mail: bre at pagekite dot net.

Re: ShowHN: GetURL - A CLI tool to get a public link for any file

#49
post #47

Nice work and very handy. I hadn't come across filepicker.io before and reading through the geturl code something jumped out at me: APIKEY = check_output(['curl', '--silent', "%(fpurl)s/getKey?email=%(email)s" % {'fpurl': FPAPIURL, 'email': email}]) From that, it looks like any random person can fill up your filepicker.io space providing they have your API key or know the email address you used to register the accoun…

One of the founders, just wanted to reply and say, yes, you are entirely right. We put up that endpoint for a separate purpose, didn't expect people to find it (underestimating people is clearly a bad strategy) and will be locking it down to require a password to create/find a apikey.

In general, the apikey doesn't actually provide very much security as is; by it's public by it's very nature as you have to put it client side and expose it to all your users. We've got HMAC and secret keys in the pipeline for next week :D

Post reply on HN