359 reputation
14
bio website etalabs.net
location
age
visits member for 3 years, 9 months
seen Dec 21 at 7:48

Dec
16
comment Is there any algorithm pattern to protect any content in the web to ensure I am the first one who created it?
@congusbongus: That's an irrelevant detail since having P and the ciphertext gives you the plaintext, with which you can construct a new S', P', and new ciphertext that decrypts (with P') to the same plaintext.
Dec
16
comment Is there any algorithm pattern to protect any content in the web to ensure I am the first one who created it?
@congusbongus: Like I said, the attacker can easily publish the same plaintext with a different P, and it's impossible for an observer to determine who is the original author of the plaintext and who is the attacker who copied it without trusting a third-party timestamp. The cryptography here is purely security theater.
Dec
16
comment Is there any algorithm pattern to protect any content in the web to ensure I am the first one who created it?
@congusbongus: Doing that is not necessary to mount an attack, because as the attacker you can change P.
Dec
15
comment Is there any algorithm pattern to protect any content in the web to ensure I am the first one who created it?
@Paul: But then the encryption is irrelevant. It's equivalent to just posting your plaintext content and relying on the date.
Dec
15
comment Is there any algorithm pattern to protect any content in the web to ensure I am the first one who created it?
How does this help? Anyone who can decrypt cipher can just republish the same way with their own secret key and you have no way of proving which party published first and which copied from the other without trusting some third-party record of publication time.
Sep
27
comment Is there a good reason to make pure functions non-public?
Foo Create(){ return new Foo(); } can never be pure since it can throw an exception if the allocation fails.
Aug
30
comment What specifically does expressive power refer to?
It should be noted that limiting a program to at most 100 million variables in a given scope imposes some limit on expressiveness. It might make it impossible to implement Firefox, for instance. ;-)
Aug
29
comment Are C static libraries frowned upon?
This is true (speeding up development), but it's really frustrating that it makes it into production. The canonical example is Firefox. The amount of engineering effort (in the form of hideous hacks) that have gone into speeding up dynamic linking symbol resolution so that Firefox loads in reasonable time is utterly crazy. Much better performance could have been attained with much less engineering cost if they were just willing to static-link all of their in-project code (while still dynamic linking system libraries and plugins, if desired).
Aug
15
comment Why can't we use IP address instead of cookies in identifying the client in servlets?
@dirkk: Please don't accuse me of being wrong about something you have no idea about. As Bob suspected, I was talking about wifi. I have access to 8+ cafes and other business access points, plus (lower-quality) city-provided wifi access points along the street, and my phone regularly jumps between them while walking.
Aug
14
comment Why can't we use IP address instead of cookies in identifying the client in servlets?
Using an IP address at all to identify a client is a huge bug. My IP address probably changes several times a minutes while walking down the street accessing a site from my phone.
Aug
7
comment Why do we have postfix increment?
@Snowman: That's not a function call. It's the C comma operator, which is a sequence point, parenthesized to control precedence. The result is the same as x++ in most cases (one exception: x is an unsigned type with rank lower than int and the initial value of x is the max value of that type).
Aug
7
comment Why do we have postfix increment?
@Snowman: Which one? I see no such issues in my answer.
Aug
7
answered Is it bad practice to resolve null arguments to default static variables?
Jun
19
comment Why do most programming languages not nest block comments?
@ThePopMachine: I'm sure of what I stated, that regular has a defined formal meaning, not the meaning you're using, and that the "regular" in "regular expression" was chosen for this meaning. Being non-recursive is one result of its definition.
May
11
comment Is it okay to not completely understand code functionality?
I question the principle of abstraction you're citing, on the basis that, for a large portion of real-world code, the full interface contract is considerably larger than the implementation. In other words it often requires the mental ability to handle more complexity to deal with methods as black boxes than it would require to just look inside. This is not an argument against abstraction but an argument that complexity is something fundamental that can't be abstracted away, and that all software necessarily does collapse (in quality) under complexity.
Mar
29
awarded  Yearling
Feb
19
comment Why is it so difficult to fix buffer overflows?
What pmg said. The only reasons fixing buggy code is hard are (1) you're not familiar with the code to begin with, and (2) the person who wrote it is probably not competent, and therefore the code is really bad and hard to fix. :-)
Oct
26
comment Should I teach my students alloca?
C does not have constructors.
Oct
26
comment Should I teach my students alloca?
If it's a few KB and you're confident you have a few KB, you can just use T foo[5000]; or whatever.
Oct
25
comment Should I teach my students alloca?
The only "responsible" use of alloc is 100% equivalent to fixed-size automatic arrays, and less portable.