Hacker Newsnew | past | comments | ask | show | jobs | submit | T-R's commentslogin

I work with the SEC data, and have a work contact e-mail explicitly for this. I similarly caught Claude happily sending my personal e-mail (likely just the e-mail associated with the Claude account), without prompt or warning, only because I happened to catch it in the curl requests. Definitely a security concern that Claude generally has this behavior, even if in this specific instance it was more of a mild annoyance.


Better sandboxing is possible and would help this.


Agreed. I was just a bit surprised that the account information/PII seemed to not have explicit gating, given so much work has gone into gating commands and curl requests.

It seems outside of user expectations for Claude Code, at least; I could see it arguably being what some users expect for the Claude app, if some people are using it to fill out forms or something (ill advised as that seems to me).


Please don't mix personal and work. Using a personal LLM account on work computer etc. It leads to many problems.


A startup forum is a strange place to assume someone works at a corporation with work computers and AI account budgets.

Realistically, there are concepts like threat models to help decide whether or not a TODO list app needs a SCIF, or a few curl requests need their own sandboxed Claude Max account.


Even if you have to use personal laptops for work, why wouldn't you create separate users for work and personal lives?

It's insane to me that programmers out of all people seem utterly incapable of accepting the most minor of inconvenience for the most modest modicum of privacy and security. There are other people in this post complaining that Claude should have asked the user before sending network requests. Well guess what, it does if you don't fucking run `--dangerously-skip-permissions`, but you do because how else you are gonna slop your way to rewrite every swath of existing insecure software to fix the bullshits this industry impounded upon itself unconscientiously for the past 30 years by allowing a non-deterministic babeller RCE its way onto your fucking personal-work machine.


> why wouldn't you create separate users for work and personal lives?

Because it's a pain in the ass and only advantageous in very specific work life scenarios that a lot of people don't fall under.

Why would you assume one size fits all, so to speak?


I've tried the multi-user approach, and it is annoying when you install something in $HOME/bin rather than /usr/local/bin so that you have to go back and re-install globally or install again to local. You really have to remind yourself that it isn't just a different project. As with most things in life, practice/repetition makes it easier. You just need to decide if it is worth it


Some corporations do not provide claude access so you use your own account.


In the real engineering world, it's seen as unethical (for both practitioners and firms) to have practitioners using their privately owned tools for the firm's work.


Doesn’t it vary heavily?

Auto mechanics usually are required to bring their own tools to the shop. Historically civil engineers working on paper often brought their own favorite mechanical pencils, calculators, and slide rules.

Back when paper manuals were more common, it was pretty common to see software developers have their own dog-eared O’Reilly books in their cubicles, and those were probably the closest predecessor to something like Claude.


There's nothing about software dev that's anything near like the real engineering world even if the label "software engineering" is used.

Until software dev is regulated by professional boards and the government, it will continue to do the same damage to society that pre-regulation engineering did during the industrial revolution.

So talking about corollaries to real engineering is stupid because without those regulatory and professional liability components, people aren't just going to magically coalesce around best practices and ethics. This is a libertarian trope

Unfortunately thanks to silicon valley, the libertarian viewpoint here has far too much sway


I am constantly reminded of the heavy industrial sites near the US Great Lakes in the early 20th century, and elsewhere. The raw toxic output into the local rivers and air were "worth it" -- to investors and subsequently to their carefully chosen engineers. Did engineering standards alone improve this?


Ok. In the fake engineering world, it's not.


i would still create that account with my work-email tho


so you need 2 subscriptions because Anthropic must send your email to everyone?


I suspect based on their stance they would do this regardless of whether Anthropic does this or not.


> Even if you have to use personal laptops for work, why wouldn't you create separate users for work and personal lives?

I mean, where it makes sense, clearly I do, since my opening comment was that it failed to use the work credentials specified, and instead fetched the ones from the account.

I agree on the general security concerns; there are people running agents in an unconstrained, unattended loop - it's negligent; you can hardly be surprised when it decides to hack HuggingFace. Not in their defense, but in everyone else's - as with any person or tool, you build a mental model of the likelihood of failure, and weigh that against the estimated cosequence, and make decisions based on that. And maybe post on HN when it surprises you.

For some people that estimation bewilderingly means unfettered access to root and their e-mail and bank account. For me, working out of my own pocket to help a friend's early stage startup get traction, the risk of asking it about a few trusted government APIs and drafting functions that I manually review doesn't quite justify personally paying for additional expenive Claude accounts.


It is well known that the readers of this forum are not limited to start ups. There are plenty of people that work for well established companies. Also, it is never a bad idea to remind people to keep personal/work data separate by never using employer provided equipment for personal use of any sort. See, I just did it again.

Also, just because this is a "start up forum" does not mean all of the readers are founders running a start up. Many are just people working at a start up. Sounds like yet another example of someone so scoped in, that the assumption is that everyone is the same losing site that there are lots of readers that at the end of the day are just worker bees even if they are more technically minded


My point is precisely that the parent commenter assumed things about my situation - something outside the original audience of the forum - to justify making a condescending comment. It is uncalled for to assume that someone here is a junior engineer who needs to be lectured on basic security policy, rather than someone doing their best to balance tradeoffs given their situation.


[flagged]


Most human personal assistants are equally vulnerable to this prompt injection.


Yeah, anyone who has had to manage developers in a big company will be able to tell you that it is a constant struggle between giving them freedom to work independently and get things done vs. limiting their access to prevent potential bad stuff from happening. In practice, the more bad stuff happens (and the more consultants you allow in), the more hurdles are introduced. Eventually even trivial tasks become a corporate nightmare of approvals. You can't have the conveniences of both work philosophies at the same time. Even the smartest AI agents won't change that fact. It simply limits their work speed to the speed of the approval process.


Humans are vulnerable to scams, cons, phishing and social engineering. This is a vulnerability whose root cause we not know how to fix. We can only alleviate its effects by re-engineering the environment around those vulnerable humans.

LLMs are just as gullible, we just tend to call their vulnerabilities "prompt injection", even though it's basically the same class of attack under the hood. Unlike humans, though, LLMs are a lot less diverse (you and I are using the same Opus 5.5, but we have different brains). This makes attacks on LLMs much more predictable and easier to pull off, just as a phishing campaign that targets one specific person is easier than an attack that scales to millions of diverse victims.

In the age of agents, phishing will continue to be the biggest attack vector of all, it's just the victims that will change.


Well, there's definitively a pareto frontier of freedom and avoiding bad stuff. And many companies ain't on it.

(In practice, I found Google to be better at having (internal) security controls that are reliably but also don't get in the way than eg banks I worked at.)


the difference being, that if you build those kind of approval processes up with AI agents, the system will function a bit faster. you could have a web reading agent. a web writing agent. a coding agent. a credentials agent. etc. and have everyone make these formal requests.

it will catch quite some prompt injections, as the prompt injection has to promptinject a secondary system in order to be successful.


> the more bad stuff happens (and the more consultants you allow in)

In your parenthetical, you just said the same thing using different words


They actually aren't. There is ambiguity on what the proper email to use is.


I have, never in my career, had any of my coworkers deanonymize my browsing or leak my email address everywhere on the internet. Your copy-pasted, thought-terminating argument doesn't work here.


Have you had any of your coworkers update Adobe Flash Player, enter their Okta credentials to "claim their $150 Christmas Walmart voucher" in the company-mandated phishing test, or install "Zoom" to join a job interview or sales call from their work laptop?

The attack is different, the result is the same.


I can't believe I have to say this, but they are not the same. Your coworker isn't deanonymizing other people's browsing by sending their email address to every site they visit without their consent.

Your example is a completely different ragebait that just serves to muddy the waters by making the easier claim that people too, are gullible. Well, even that's misleading because not all people stoop so low for a fake $150. You can hold such people accountable and contain the damage, but LLMs will make the same mistake over and over again and people will still line up on HN to say how that has always been the norm with people. The grift in the software industry is reaching new lows every day.


It wasn't even that long ago since a human error led to billions of crypto being stolen


And what am I to make of this totally unrelated story?


This would be more like your HR department giving your info to the government no ?


No. This is an attack that any website can unleash. Or perhaps even ads, which is a popular vector for malware.


Most human personal assistants don't have access to vast swathes of private data that they collected without permission, unless your house is the site of multiple watergates


Wait, are you saying Claude isn't conscious on the internet, sir?


You're dehumanizing Claude, sir. That's against Anthropic's updated ToS!


Say more, or say less.


Please look up the research area "alignment."


You can align until the Sun goes out,

the base technology sees all context as equal to user instruction if the context has enough weight.


A lot of material for younger readers uses similar spacing to Korean, like the Pokemon games. It works well enough when you know the vocabulary being used is limited, but even there it gets frustrating.

When you're reading, you're trying to identify a substring and map it back to the unit of meaning, which is effectively the kanji. That works seamlessly with Hangul, because it mostly blocks (as syllables) the same way as kanji, and, as you mentioned, the extra vowels and silent consonants provide more disambiguation. With kana, the length you have to scan to read, and then guess at (using only context to disambiguate), a root word, is a lot more arbitrary.

Mechanically kana is just less compressed, less aligned, and makes it harder to visually identify/scan for units of meaning. Obviously Korean shows that you can make different tradeoffs, but for Japanese losing the kanji would probably necessitate reworking Kana as well - and unless the pronunciation changed, it would probably need to be in a way that represents the pitch accent, which is a modifier on the whole syllable, rather than just a few extra consonants or vowels.


Spoken Japanese uses pitch accent to distinguish homophones


In some cases, but note that (a) this is only true for a tiny handful of homophones, and (b) the distinguishing accent varies by region.

E.g. "hashi" famously can mean bridge/edge/chopsticks depending on accent, but which accent has which meaning is different in Tokyo vs Osaka.


So shouldn't the better solution be a few more pronounciation markers beyond two strokes, a circle and tiny letters instead of thousands of chinese characters?


But who is this solution for? Unless you change the pronunciation of the language, it would be adding markers around whole syllables to disambiguate - syllables that represent the kanji they came from (many of which already have phoentic components) - but those syllables would still be less dense and visually identifiable than kanji is for someone who already speaks the language.

It's similar to initialisms or emoji in English; it's of course frustrating for people who don't know them, and there are reasonable complaints about some of the extremes, but speakers/writers use them because they find them useful when communicating with an audience that's also assumed to know them.


To add something a little more practical than "it's fun" or "it's philisophical" -

For someone packaging things with Nix, it's tempting to think of derivations as just a builder - you write your scripts, accept your inputs, and your result ends up in the store.

The article suggests, taking advantage of lazy evaluation, that you can put a whole state machine in Nix (i.e., lift the DSL for describing states into the Nix language). If you had a team of developers that need various customizations of something, they could describe it in Nix, and benefit from the caching of intermediate steps. If someone's just changing something at the end of the long string of customizations, they only need to build their changes.

A more concrete, if very niche, example - Back in the days when we were all training our own deep learning models, my company had assembled a list of facts for every product we could find on the internet. Our data scientists wanted to be able to test datasets with different aggregates of the lists - we needed to both build the training set, and compute it at runtime for new products. There was some compositionality to the aggregates - one run might use the mean, another would subtract the mean from every element, etc. It was time consuming and annoying to manage. One of our developers made a DSL in Haskell to describe the set of aggregates desired for a given dataset, and needed to build caching for each column. The technique the article suggests could have done this out of the box (at build time, even) - build a function and a vector for each aggregate, throw them in the nix store, and then wrap them up as a training set and a server.


> inner expressions must be indented more

Not to support the parent comment, which I disagree with, but If you use multi-line let-bindings, those require that you indent not just more than the previous line, but as much as the first token after the let keyword on the previous line. It’s a very strange rule, all the more surprising because it’s inconsistent even with the rest of the language. It is totally avoidable if you, like I think most experienced haskellers do, just prefer ‘where’, but people more familiar with procedural code usually lean into using ‘let’ everywhere because it feels more familiar.

I think the strange indentation used to be required in more places - I vaguely remember running into it a lot more when I started with Haskell 20 years ago, but that was also just when I was new to the language. These days I just keep ‘let’ to a bare minimum, so it doesn’t bother me. One thing that made Elm frustrating was that it disallowed ‘where’ clauses, forcing you to deal with this weird edge case all the time.


So you want to line the equals signs up or similar?

  let
     f = 9
    fo = 10
   foo = 123
  in f+fo+foo
vs.

  let
    f = 9
    fo = 10
    foo = 123
  in f+fo+foo


No, the issue is if the first binding is on the same line as the `let`, you are required to write, e.g.:

    someValue = let f = 9
                    fo = 10
                    foo = 123
      in f+fo+foo
rather than:

    someValue = let f = 9
      fo = 10
      foo = 123
      in f+fo+foo
I think it used to be the case that it had to be indented past the `=` or the `let` even if it was't on the same line. Note also that `in` has to be indented past `someValue`, but doesn't need to be indented as far `let`.

This is fine:

    someValue = let
      f = 9
      fo = 10
      foo = 123
      in f+fo+foo
So, it is possible to land on sane indentation, but the parser is much pickier than, e.g., Python's off-sides rule, so it takes some trial and error for new users to find it, and it can be frustrating if you're just temporarily modifying an expression to quickly try something out.

I honestly think it would be less surprising if the parser just disallowed writing the first binding on the same line as the `let` entirely, treating it only as a block, but some people (bewilderingly) do seem to prefer to write their code with the excessive indentation (I'd imagine with editor support, rather than manually maintaining the spacing).


I feel like you are describing that the parser is too lenient rather than too picky. It could just require you to always put `let` and `in` on their own lines, in which case the indentation makes sense, I think. It's only when trying to keep more stuff on the same line that the details of Haskell's indentation rules come into play.


In Haskell, you can do, if you prefer,

    someValue = let {f = 9;
      fo = 10;
      foo = 123 }
      in f+fo+foo
it will just look a little out of place.

Edited to add that this is also OK:

    someValue = let 
      f = 9
      fo = 10
      foo = 123
      in f+fo+foo


I'm a huge fan of it - I was never able to get one while they were officially available, I only managed to rent one from Blockbuster a few times. I eventually picked one up on eBay in the early 2000's for $60, before they became collectors items.

The appeal is definitely somewhere between intrinsic and from the rarity - there's not just been no official way to play these games for the last 30 years, they've barely even gotten a passing mention, and even emualators have been few and far between. It was sad that Teleroboxer, Wario Land, and Mario Clash were basically lost to time.

The games definitely weren't up to to NES/SNES quality, but they were at least up to par with the average portable game at the time, which I think is what they were meant to be compared against. I see the Virtual Boy games as Game Boy games that suffered from the mechanics of the platform the platform they were released on. In that light, I think they compare pretty favorably to similar lesser-known games of the time; most WonderSwan games I've played, hell even a lot of Game Gear and Game Boy games, had much more serious gameplay issues, even though they were on hardware that was arguably less... challenging.


> The games definitely weren't up to to NES/SNES quality, but they were at least up to par with the average portable game at the time, which I think is what they were meant to be compared against.

Which I think is the problem: The system wasn't really portable. When 3D was the rage, it was really a 2D system. I used the system at home when I was in the mood for "big" games.

Seems like it would have made more sense to make a 3D headset for the N64 as a high-end accessory.


The article seems to assume readers are already familiar with the context, or maybe that they'll stop to read the original paper. For those who aren't familiar, Selective Applicative Functors were presented as part of the development of the Haxl library at Facebook (after they hired a series of prominent Haskellers like author of "Real World Haskell", Bryan O'Sullivan, and GHC Co-Developer Simon Marlow). Haxl is a batching framework for Haskell (to, e.g., solve the "N+1 database query problem"), which later inspired the various DataLoader libraries in other language ecosystems.

In Haskell, there's a lot of desire to be able to write effectful code as you normally would, but with different types to do things like restrict the available actions (algebraic effects) or do optimizations like batching. The approaches generally used for this (Free Monads) do this by producing a data structure kind of like an AST; Haskell's "do" notation transforms the sequential code into Monadic "bind" calls for your AST's type (like turning .then() into .flatMap() calls, if you're from Javascript), and then the AST can be manipulated before being interpreted/executed. This works, but it's fundamentally limited by the fact that the "bind" operation takes a callback to decide what to do next - a callback is arbitrary code - your "bind" implementation can't look into it to see what it might do, so there's no room to "look ahead" to do runtime optimization.

Another approach is to slide back to something less powerful than Moands, Applicative Functors, where the structure of the computation is known in advance, but the whole point of using Monads is that they can decide what to do next based on the runtime results of the previous operation - that they accept a callback - so by switching to Applicatives, by definition you're giving up the ability to make runtime choices like deciding not to run a query if the last one got no results.

Selective Functors were introduced as a middle ground - solidifying the possible decisions ahead of time, while still allowing decisions based on runtime information - for example, choosing from a set of pre-defined SQL queries, rather than just running a function that generates an arbitrary one.


Abstract Algebra, looked at through the lens of Programming, is kind of "the study of good library interface design", because it describes different ways things can be "composable", like composing functions `A -> B` and `B -> C`, or operators like `A <> A -> A`, or nestable containers `C<C<T>> -> C<T>`, with laws clearly specifying how to ensure they don't break/break expectations for users, optimizers, etc. Ways where your output is in some sense the same as your input, so you can break down problems, and don't need to use different functions for each step.

Category Theory's approach of "don't do any introspection on the elements of the set" led it to focus on some structures that turned out to be particularly common and useful (functors, natural transformations, lenses, monads, etc.). Learning these is like learning about a new interface/protocol/API you can use/implement - it lets you write less code, use out-of-the-box tools, makes your code more general, and people can know how to use it without reading as much documentation.

Focusing on these also suggests a generally useful way to approach problems/structuring your code - rather than immediately introspecting your input and picking away at it, instead think about the structual patterns of the computation, and how you could model parts of it as transformations between different data structures/instances of well-known patterns.

As a down-to-earth example, if you need to schedule a bunch of work with some dependencies, rather than diving into hacking out a while-loop with a stack, instead model it as a DAG, decide on an order to traverse it (transform to a list), and define an `execute` function (fold/reduce). This means just importing a graph library (or just programming to an interface that the graph library implements) instead of spending your day debugging. People generally associate FP with recursion, but the preferred approach is to factor out the control flow entirely; CT suggests doing that by breaking it down into transformations between data structures/representations. It's hugely powerful, though you can also imagine that someone who's never seen a DAG might now be confused why you're importing a graph library in your code for running async jobs.


I definitely agree for traversals, but Lenses need some sort of primitive support - even in Haskell they're mostly generated with TemplateHaskell, and the language developers have spent a long time trying to make the `record.field` accessor syntax overloadable enough to work with lenses[1][2]. Hopefully someday we'll be free from having to memorize all the lens operators.

Optics are famously abstract in implementation, but I don't think people have trouble applying them - people seem to like JQuery/CSS selectors, and insist on `object.field` syntax; it's kind of wild that no mainstream language has a first-class way to pass around the description of a location in an arbitrary data structure.

[1] https://ghc-proposals.readthedocs.io/en/latest/proposals/002...

[2] https://ghc-proposals.readthedocs.io/en/latest/proposals/015...



Optics let you concisely describe the location, but defer the dereferencing, so you could definitely approximate optics, not by passing around pointers you compute with `offsetof`, but passing around functions that use `offsetof` to return memory locations to reference (read/write to). You could certainly write a composition operator for `*(*T) => List<*R>`... Some people have done something like it[1][2]:

    Account acc = getAccount();
    QVERIFY(acc.person.address.house == 20);

    auto houseLens = personL() to addressL() to houseL();
    std::function<int(int)> modifier = [](int old) { return old + 6; };
    
    Account newAcc2 = over(houseLens, newAcc1, modifier);
These also use templating to get something that still feels maybe a little less ergonomic than it could be, though.

[1] https://github.com/graninas/cpp_lenses [2] https://github.com/jonsterling/Lens.hpp


> should I implement the Monad, Applicative or Functor type class?

I struggled with this when I first learned Haskell. The answer is "yes, if you can". If you have a type, and you can think of a sane way to implement `pure`, `fmap`, and `bind` that doesn't break the algebraic laws, then there's really no drawback. Same for any typeclass. It gives users access to utility functions that you might not really have to document (because they follow a standard interface) and you might not even have to maintain (when you can just use `deriving`).

Doing so will let you/users write cleaner code by allowing use of familiar tools like `do` notation, or functions from libraries that say they'll work for any Monad. It saves you from coming up with new names for those functions, and saves users from having to learn them; if I see something's a Monad, I know I can just use `do` notation; if I see something's a Monoid, I know I can get an empty one with `mempty` and use `fold` with it. As long as it's not a really strange Monad, and it doesn't break any laws, it probably just works the way it looks like it does.

If you can define `bind` et. al., but it breaks the laws, it means the abstraction is leaky - things might not work as expected, or they might work subtly differently when someone refactors the code. Probably don't do that.

If you don't implement a typeclass that you could have, it just means you might have written some code where you could've used something out of the box. Same as going through old code and realizing "this giant for-loop could've just been a few function calls if I used underscore/functools or generators".

That said, it's not too common to stumble on a whole new Monad. The Tweet type probably isn't a Monad - what does it mean for a Tweet to be parameterized on another type like `Int`, as in `Tweet<Int>`? What would it mean to `flatMap`(`bind`) a function like `Int -> Tweet<String>` on it? A Tweet is probably just a Tweet. On the other hand, it's a little easier to imagine what a `JSON<Int>` might be, and what applying a function like `Int -> JSON<String>` to it might reasonably do. Or what applying an `Int -> Graph<String>` to a `Graph<Int>` might do.

Most Monads in practice are combinations of well known ones. Usually you'll be writing some procedural code in IO, or working with a parser, and realize "I'm writing a lot of code checking for errors", "I'm tired of explicitly passing this same argument", or "I need some temporary mutable storage", or some other Effect - so you wrap up the Monad you're using with a Monad Transformer like `ExceptT`, `ReaderT`, or `StateT` in a `newtype`, derive a bunch of typeclasses, and then just delete a bunch of messy code.


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: