HNHacker News
TopNewBestAskShowJobs

tshadwell

798 karma · joined April 17, 2012

Infosec @Twitch twitter.com/zemnmez

I can be contacted at my gmail: thomas.shadwell

submissionscomments
tshadwell··on Why Go Is Not Good
I'm not suggesting these are the best patterns, or even 'good' patterns. I am simply drawing a parallel between them and pythonic iterators. When it comes to errors from generator patterns, I've gone between your suggestion and chan<-struct{T;error} when channel based generator patterns are appropriate.
tshadwell··on Tesla Model S JSON API
It's good to know that cars can now be remotely controlled via CSRF attacks.
tshadwell··on Why Go Is Not Good
I meant something like this:

http://play.golang.org/p/eqnDLVMHGA (pseudocode)

tshadwell··on Why Go Is Not Good
For fear of disagree downvotes: I would say that many of the qualms brought up in this article are problems that are encountered fighting the language.

The problem of 'summing any kind of list' is not a problem that is solved in Go via the proposed kind of parametric polymorphism. Instead, one might define a type, `type Adder Interface{Add(Adder)Adder}`, and then a function to add anything you want is fairly trivial, `func Sum(a ...Adder) Adder`, put anything you want in it, then assert the type of what comes out.

When it comes to iteration, there is the generator pattern, in which a channel is returned, and then the thread 'drinks' the channel until it is dry, for example `func (m myType) Walk() chan->myType` can be iterated over via `range v := mt.Walk(){ [...] }`. Non-channel based patterns also exist, tokenisers usually have a Next() which can be used to step into the next token, etc.

The Nil pointer is not unsafe as far as I know, from the FAQ: http://golang.org/doc/faq#no_pointer_arithmetic

The writer seems to believe that functions on nil pointers crash the program, this is not the case. It's a common pattern in lazy construction to check if the receiving pointer is nil before continuing.

Go is not flawless by any means, but it warrants a specific style of simplistic but powerful programming that I personally enjoy.

tshadwell··on In search of the perfect URL validation regex
I've put the test cases into a refiddle: http://refiddle.com/refiddles/53a736c175622d2770a70400
tshadwell··on Generalized Secure Hash Algorithm
The scrypt paper includes comparisons to bcrypt: https://www.tarsnap.com/scrypt/scrypt.pdf decide for yourself.
tshadwell··on Try to close this tab
It only works if you mouse into the window, which I don't typically do when skimming websites.
tshadwell··on OWASP Developer Guide
Nope. There is a presentation on cookie tossing, but scant else.
tshadwell··on Show HN: Fast and Extensible Parser for Markdown in PHP
:¬)
tshadwell··on OWASP Developer Guide
The Open Web App Security Project has a pretty good (but alas not very up-to-date) catalogue of common web application exploits.
tshadwell··on Show HN: Fast and Extensible Parser for Markdown in PHP
I agree, but I did not mean to make any sweeping statement in that regard, but in the case of a standardised markup like markdown, there are already suites of field-tested C libraries that provide much better speed than this library would; for markdown content, this provides a better experience for your users.
tshadwell··on Show HN: Fast and Extensible Parser for Markdown in PHP
I don't understand what you mean. Could you also explain the negativity around this comment? I didn't think it was a badly voiced opinion, and karma is not meant to be used to show how much you agree or disagree with someone.
tshadwell··on Deep Learning From The Bottom Up
Ah, I see. Thanks.
tshadwell··on Deep Learning From The Bottom Up
I'm pretty familiar with neural networks, and skimming that article it appears to describe something that is a neural network. Is 'Deep Learning' new terminology for 'Neural Network', or does it describe a subset of ways of using them?
tshadwell··on Show HN: Fast and Extensible Parser for Markdown in PHP
Perhaps I am looking at this wrong, but I don't see why you would use a Markdown parser written in PHP if you're looking for speed. Case in point the parsedown system is fast because it has heavy use of regular expressions, which parse faster and run faster than the host language-- it already relies on a language other than PHP to essentially emulate parts of a well-written lexer.

As debaserab2 says[1], if you are looking for speed, consider PHP extensions.

In my opinion, writing a system like this is a misappropriation of PHP, which evolved from and works best as a hybrid templating/scripting language. It becomes a powerful development platform when its extensive library of C functions is used to do most heavy lifting.

[1] https://news.ycombinator.com/item?id=7784219

tshadwell··on Famo.us open to everyone
Is anyone else encountering large lagtime problems with scrolling? Also, the scroll-bar is non-functional. https://dl.dropboxusercontent.com/u/41231461/455436902/fff.w...
tshadwell··on To sleep, perchance to control your dreams
Essentially: electrical stimulation of the brain can cause some to wake up, and some to enter a state between awake and asleep; sounds fairly intuitive.

I have had personal experience of lucid dreams, when I was very young I would stare at my bedroom wall until I fell asleep, the concentration must have kept me awake to some degree.

tshadwell··on Skype group video calling becomes free
But will they update Skype for Linux to have group video at all?
tshadwell··on Why all the fuzz about MS Paint – Just use Paint Dot NET
GIMP is not for creating Vector graphics, though you can have vector elements through bezier curves. Inkscape, however is created for this exact purpose.
tshadwell··on Why all the fuzz about MS Paint – Just use Paint Dot NET
What "fuzz" is this referring to? I have for a long time preferred GIMP to paint.net for its portability and versatility, but neither of these compete with MSPaint in any way-- they fill a completely different role.
tshadwell··on Gravity waves from Big Bang detected
https://en.wikipedia.org/wiki/Uncertainty#Measurements

"When the uncertainty represents the standard error of the measurement, then about 68.2% of the time, the true value of the measured quantity falls within the stated uncertainty range. For example, it is likely that for 31.8% of the atomic mass values given on the list of elements by atomic mass, the true value lies outside of the stated range. If the width of the interval is doubled, then probably only 4.6% of the true values lie outside the doubled interval, and if the width is tripled, probably only 0.3% lie outside. These values follow from the properties of the normal distribution, and they apply only if the measurement process produces normally distributed errors. In that case, the quoted standard errors are easily converted to 68.3% ("one sigma"), 95.4% ("two sigma"), or 99.7% ("three sigma") confidence intervals."

tshadwell··on Iconic – An Icon System Designed for the Modern Web
Icomoon is great, I just wish it provided Compass markup so I could have the cross-browser support Compass provides.
tshadwell··on Iconic – An Icon System Designed for the Modern Web
Use an icon font generated by icomoon or the like. That does not require Javascript, HTML and CSS prerequisites, is only as heavy as the used constituent SVG elements and is well-supported.
tshadwell··on Iconic – An Icon System Designed for the Modern Web
I feel I am perhaps being too pessimistic, but I fear this trend toward this heavier, unused-feature filled web-- a mosaic of libraries that make web development or design better in X and Y way that really doesn't affect the end user that much, but largely increases the cost and speed of viewing a webpage, especially in places and countries without the high internet speeds the developers inevitably have.

How many icons will a website need before an abstraction like this is necessary to manage them?

If every icon has each element labelled with large prefixed classes (".iconic-camera-slr-lens-release"), this is going to be a lot of extra footprint for websites that have enough icons to make this useful.

Perhaps I am alone in thinking that colourful icons are somewhat noisy, and thus will be used only in designs where icons are prominent elements, and as such infrequently; with that frequency, they could even be individually coded for.

tshadwell··on Steam's VAC reads all the domains you visited
I can't see any evidence that the hash is sent to any server. I think it is more likely the hash is used to look up the recent websites in a hash table or via a bloom filter.
tshadwell··on How does Facebook disable Developer Tools?
Because it is possible to get around with just code: http://escape.alf.nu/20

(which I have done, under another username)

tshadwell··on Every line of code is always documented
Is this Javascript? Why is there no semicolon?
tshadwell··on Cookie Bomb or Let's Break the Internet
Surely if you were able to do this, you would use it for cookie tossing rather than this simple mischief?
tshadwell··on Show HN: email - Send emails easily in Go
Interesting choice of NewEmail() over the more idiomatic email.New().
tshadwell··on Show HN: Use any text as a domain name
I think this could be accomplished without creating a new system of domain names by using visually similar non-ascii characters in an IDN[1].

"food in chicago.com" becomes "food⋅in⋅chicago.com" becomes "xn--foodinchicago-lj4hc.com"

[1] https://en.wikipedia.org/wiki/Internationalized_domain_name

← PreviousPage 4 of 6Next →