<alexherbo28>
I want to implement a websocket to execute shell commands
<alexherbo28>
can a website, through javascript, connect to my localhost to execute commands?
<alexherbo28>
as javascript is client side, if it has `new WebSocket(…)` to localhost to do nasty things, it's me who execute this code to do the nasty things?
<alexherbo28>
or there is a cross domain security
<alexherbo28>
I'm not sure
<alexherbo28>
how to add auth (username, password) ?
livcd has quit [Quit: leaving]
livcd has joined #crystal-lang
foxxx0 has quit [Ping timeout: 245 seconds]
alexherbo28 has quit [Ping timeout: 268 seconds]
alexherbo28 has joined #crystal-lang
FromGitter has quit [Remote host closed the connection]
<repo>
so for example if you'd support the `ls` command then have an explicit handling for this that will execute `ls` using Process.run(`ls`, arguments)
<alexherbo2>
websocket looks cool for send/receiving messages
<alexherbo2>
but I'm afraid of the security risk
<repo>
important that you don't use backticks
<repo>
or Process.run("foo bar baz")
<alexherbo2>
what do you suggest?
<repo>
as this will run it in a shell and open the door for users to send somehting like "foo; rm -rf --no-preserve-root /"
<FromGitter>
<Blacksmoke16> from the URI you pass `HTTP::WebSocket.new`?
<FromGitter>
<Ph055a> Hello, I am trying to use https://github.com/mamantoha/crest to make a simple GET requests so I can start playing around with crystal more but I'm stuck, it keeps returning a memory address instead of JSON. So what dumb simple thing am I missing here??? ⏎ ⏎ ```curl -L "http://httpbin.org/get?lang=en" ``` ⏎ ⏎ Thank you for any help, new at this crystal thing [https
<FromGitter>
<lbarasti> Congrats on the 0.32 release 🎉 ⏎ On a different note... What do you call a Crystal programmer? `Crystaller`?
<FromGitter>
<bcardiff> @Blacksmoke16 thanks
<FromGitter>
<dscottboggs_gitlab> > What do you call a Crystal programmer? ⏎ ⏎ A programmer. One who happens to write Crystal. I never got this, like I write Crystal and Python and BASH and C and maybe combine all of the above and others and, while crystal is my favorite I never got the whole *rustacean*/*gopher* thing
<FromGitter>
<dscottboggs_gitlab> sorry idk that came off kinda agressive I didn't mean it that way
<FromGitter>
<lbarasti> no no, I get what you mean @dscottboggs_gitlab
<FromGitter>
<lbarasti> I kind of like the idea of having being a `Rubyist`, though
<FromGitter>
<lbarasti> it's just something that stays with you, no matter what you end up doing next or day to day
<FromGitter>
<dscottboggs_gitlab> idk. I might feel that way if I felt I'd find the "perfect" language but I don't feel like I have, or that perhaps that's not attainable
<FromGitter>
<lbarasti> hey, maybe I'm just too sentimental 😅
<FromGitter>
<dscottboggs_gitlab> hah! maybe I'm just too picky!