Slashdot Mirror


New NSA-Funded Code Rolls All Programming Languages Into One

An anonymous reader writes "What's your favorite programming language? Is it CSS? Is it JavaScript? Is it PHP, HTML5, or something else? Why choose? A new programming language developed by researchers at Carnegie Mellon University is all of those and more — one of the world's first "polyglot" programming languages. Sound cool? It is, except its development is partially funded by the National Security Agency, so let's look at it with a skeptical eye. It's called Wyvern — named after a mythical dragon-like thing that only has two legs instead of four — and it's supposed to help programmers design apps and websites without having to rely on a whole bunch of different stylesheets and different amalgamations spread across different files.

24 of 306 comments (clear)

  1. Wyvern = Wyrm by Anonymous Coward · · Score: 3, Interesting

    Why? What's the worst that could happen? What's the best?

    Why is the NSA interested in something like that directly? What is the potential for abuse?

    Is it to make code analysis that much more centralized and (supposedly) simple?

    Why didn't this come up with itself before now?

    1. Re:Wyvern = Wyrm by ObsessiveMathsFreak · · Score: 4, Interesting

      The standard NSA tatctic for introducing security holes into a system is to obfuscate things so that holes are hard to spot and find. SELinux is probably such a system, and this polglot language -- which effectviely makes debugging impossible -- is likely another.

      --
      May the Maths Be with you!
    2. Re:Wyvern = Wyrm by Bite+The+Pillow · · Score: 5, Insightful

      Why?

      To write applications in one language, instead of HTML, CSS, JavaScript, SQL, and something else. Not including multiple levels of configuration files (website and web server at least).

      What's the worst that could happen?

      The NSA could insert backdoors which, unless they were incomprehensible crypto, would be easily found by both white and black hat investigators. Also, Carnegie Mellon University, which has a pile of research announcements every year, has its entire research department under suspicion of colluding with an oppressive government agency and spends decades regaining international status as someone you can do anything other than make the punchline of a joke.

      CMU losing status is, to CMU, absolutely an intolerable option. I'm not saying it won't just because of the potential impact, but you asked what is the worst that could happen. Backdoors, and a respected university bursts into flames and is disregarded for decades internationally. That's bad.

      What's the best?

      Fewer bugs.

      Why is the NSA interested in something like that directly?

      Because despite recent bad press, they are interested in security. If we can write stuff with fewer bugs, we are more secure. Maybe there are still plenty of bugs in the hardware/OS that they know about, but fewer bugs in the application level, which means the foreigners don't know about them because they don't exist.

      What is the potential for abuse?

      Pretty small. White hats will vet the libraries, black hats will try to penetrate it, and it's no more or less secure than anything else a human has written. But people can make mistakes in fewer languages. And they aren't replacing languages, from the sound of it.

      Is it to make code analysis that much more centralized and (supposedly) simple?

      I suppose you could read the article.

      Why didn't this come up with itself before now?

      Why didn't the airplane come up before it did? Are you insinuating something? Do you know something we don't know? Did someone mod you up for any particular reason, or just because you spewed thoughtless rhetorical questions?

    3. Re:Wyvern = Wyrm by Anonymous Coward · · Score: 5, Insightful

      backdoors [...] would be easily found by both white and black hat investigators.

      That's about the same as stating it is as simple to find a needle in a haystack as to put one in.

      We already have issues finding normal bugs. We have seen flaws in kernels and encryption libraries that might have well been a typo, yet were in for years.

  2. Lack of basic research by Taco+Cowboy · · Score: 5, Insightful

    I arrived at America pretty late - at the 60's - but at least at that time America had several institutions doing all kinds of wonderful basic research

    Bell Labs
    Xerox's famous lab at Palo Alto
    The Skunkworks

    And at that time Darpa funded a lot of basic research as well

    Today, all gone

    Even Darpa's funding are not aiming at basic research - such as what TFA has outlined - what they are doing at Carnegie Mellon is actually an applied research ... taking what has been known and add another layer onto it

    What's happening in America nowadays is very worrying

    --
    Muchas Gracias, Señor Edward Snowden !
    1. Re:Lack of basic research by 50000BTU_barbecue · · Score: 4, Insightful

      Of course, a lot of research was done by the private labs of corporations back then, like IBM, RCA, etc.. Engineering was a respected profession, you needed real talent to become an engineer or programmer and you could earn a good living that way in the West.

      Then one day some bright psychopath realized it would be cheaper if universities did the research with government money instead.

      Then you get the research done, your future employees come already in debt, and then they work for peanuts paying back their student loans.

      So companies used to pay YOU to do research, now YOU pay to go to university and the companies get to keep the IP!

      And social engineering and manipulation means that people will WILLINGLY do so!

      Brilliant!

      --
      Mostly random stuff.
  3. Shit summary by Anonymous Coward · · Score: 5, Insightful

    CSS and HTML5 are not programming languages. You don't "choose" html5 over, say, php.
    (And don't fucking say HTML5 + CSS3 is turing complete)

    1. Re:Shit summary by Bing+Tsher+E · · Score: 5, Insightful

      I didn't see any programming languages in the list on the summary. Just a bunch of web shit.

    2. Re:Shit summary by binarylarry · · Score: 4, Funny

      Yeah and can you imagine the horrific shit sandwich that would be a combination of CSS, HTML5, PHP and JavaScript?

      666 Mark of the Techno Beast. It's like some shit Ghostbusters 2099 would be tasked with stopping.

      --
      Mod me down, my New Earth Global Warmingist friends!
  4. CSS? by Anonymous Coward · · Score: 5, Funny

    "What's your favorite programming language? Is it CSS?"

    Why yes, I just love writing VoIP systems in CSS.

    1. Re:CSS? by doublebackslash · · Score: 4, Insightful

      I'd like to point out that you can't represent irrational numbers accurately without a new system. Let alone trancendental numbers.

      Also some numbering systems are more convenient. Binary, for example. Not different numerals, but used differently.

      I know, not exactly your point, but don't dismiss languages other than C, Basic, and Pascal.

      --
      md5sum /boot/vmlinuz
      d41d8cd98f00b204e9800998ecf8427e /boot/vmlinuz
  5. Compiler virus by penguinoid · · Score: 4, Interesting

    Wasn't there some discussion on how effective a special, compiler-embedded virus would be? This seems like a good candidate for that.

    --
    Don't waste your vote! Vote for whoever you want, unless you live in a swing state it won't matter anyways
  6. You have n programming languages... by Anonymous Coward · · Score: 5, Funny

    You have n programming languages. You think "That's to many, let's invent a programming language that combines all of them!", and then do so. You now have n+1 programming languages...

  7. Ridiculous Summary, Interesting Papers by Anonymous Coward · · Score: 3, Informative

    As you'd expect from CMU, the papers themselves are pretty interesting. Just read the abstracts instead of trying to guess from the summary or vice article, which are both way off the mark.

    http://www.cs.cmu.edu/~aldrich/papers/ecoop14-tsls.pdf
    http://www.cs.cmu.edu/~aldrich/papers/maspeghi13.pdf

  8. why- just why? by sumdumass · · Score: 3, Insightful

    Why in the hell would you need to look at something with a skeptical eye just because money came from a certain source? Is the reputation of carnegie mellon suspect or something? And if so, shouldn't that in and of itself be the reason of suspect?

    The submiter is a shallow person suffering from guilt by association which is never a valid premise. I mean i know skin heads who donate to planned patrenthood specifically because they have all their abortion clinics in areas with high minority populations and keep the minority populations in check. Does that mean we have to look at them wiyh a skeptical eye too? Of course not- or at least npt because a source of their funding has issues most of us find repulsive.

    The merrits of this will rest on its own. There is absolutely no reason to put the integrity of the development into question simply because the NSA gave funding.

    1. Re:why- just why? by Spinalcold · · Score: 4, Insightful

      You should always look at the funding path. It tells you a lot about the quality of research. In the past 60 years funding towards 'think tanks' has gone into making bad science to combat good science research, all in an effort to move political goals. I'm not saying this particular research is bad, however it is good to know some of the funding came from the NSA.

  9. No, it doesn't "roll all languages into one" by Animats · · Score: 5, Informative

    No, it doesn't "roll all languages into one". It just allows embedding of the text of another language, such as HTML, into a Wyvern program. Variables can be substituted. Like this:

    let webpage : HTML = <html><body><h1>Results for {keyword}</h1
    <ul id="results">{to_list_items(query(db,
    SELECT title, snippet FROM products WHERE {keyword} in title))}
    </ul></body></html>

    (except that the last 3 lines above should be indented, because this language uses Python-style block notation.)

    Of course, everybody does that now, but the way they do it, especially in PHP, tends to lead to problems such as SQL injection attacks. The idea here is that Wyvern has modules for the inserted text which understand what kinds of quoting or escaping are required for the embedded language text.

    I just glanced at the paper, but that seems to be the big new feature.

  10. CSS? JavaScript? PHP? HTML5? by tommeke100 · · Score: 5, Insightful

    To write better Apps and Websites?
    Are these what the kids call programming languages these days?
    It doesn't sound very serious.

  11. Which behaviour? by NotInHere · · Score: 4, Interesting

    This program is valid C and, when saved as "test2.java", valid java code. Compilation with the C compiler results in a program that doesn't behave the same way if it were compiled with java:

    //\
    /*
    #include "stdio.h"
    /**///\
    public class test2 {

    //\
    public static
    void main //\
    (String[]a)//\
    /*
    (int argc, char *argv[])//*/
    {
      //\
      System.out.printf("hi, I'm java\n");/*
      printf("hi, I'm C\n");//*/
    }

    //\
    }

  12. LLVM's logo is a wyvern by Henriok · · Score: 3, Insightful

    May I point out that the LLVM logo is a wyvern? http://llvm.org/Logo.html

    --

    - Henrik

    - when the Shadows descend -
  13. if it did, that would eliminate my bugs by raymorris · · Score: 3, Insightful

    It doesn't do what the summary says.

    If it did, that would take care of half of my bugs. Within a 30-minute period, I might well work in PHP, Perl, ActionScript, JavaScript, and some other language. A large portion of my errors are things like using empty() in JavaScript. Especially, ActionScript is almost the same as JavaScript, and a lot of Perl is also valid PHP, so when switching between these it's easy to absent-mindedly tap out a line in the wrong language.

    Once upon a time, I used vim syntax highlighting, which doesn't typically catch using the right syntax, but the wrong function name, but does make missed braces and such obvious. Maybe I should right a vim plugin for "wrong language, dummy." It would look for echo (phph vs print (Perl), etc.

  14. Re:Programming language? by Capsaicin · · Score: 5, Insightful

    I really like PHP. It is however not a bloody programming language, it's a scripting language.

    I really hate PHP, but what I hate even more is being confronted with this mysterious distinction between "scripting" and "programming" languages.

    A language might be strongly or weakly, dynamically or statically typed. A particular implementation might employ a compiler, a virtual machine or interpreter. These are meaningful distinctions. But what (with the possible exception of a hardware specific control language) does it even mean for a language (as distinct from its implementation) to be a "scripting" language?

    Would PHP cease to be a scripting language if an object code compiler were available for it? Is 'C' a "scripting language" just because it's interpreted? And what about a language which has never actually been implemented, what in the language specification determines unequivocally if that language is 'scripting' or a a 'programming' language?

    --
    Better to be despised for too anxious apprehensions, than ruined by too confident a security. --Edmund Burke
  15. Its really too bad... by Karmashock · · Score: 5, Insightful

    The NSA's reputation has been annihilated. There are good people that work for such organizations. People that could and do benefit our society on a regular basis. Their institution was simply coopted by irresponsible people that sadly destroyed everything. Its a shame.

    --
    I've decided to stop wasting my time responding to AC trolls/sockpuppets... so if you want a response from me... login.
  16. FTFY by QilessQi · · Score: 4, Funny

    "Web applications today are written as a poorly-coordinated mishmash of artifacts written in different languages, file formats, and technologies.

    "...and here's another one!"