Beta
×

Welcome to the Slashdot Beta site -- learn more here. Use the link in the footer or click here to return to the Classic version of Slashdot.

Thank you!

Before you choose to head back to the Classic look of the site, we'd appreciate it if you share your thoughts on the Beta; your feedback is what drives our ongoing development.

Beta is different and we value you taking the time to try it out. Please take a look at the changes we've made in Beta and  learn more about it. Thanks for reading, and for making the site better!

Gaming Foursquare With 9 Lines of Perl

Soulskill posted more than 4 years ago | from the i-can-name-that-bar-in-8-lines dept.

Security 84

caffeinemessiah writes "With the recent launch of Facebook Places, the rise to prominence of Foursquare and GoWalla, and articles in the New York Times about the increasing popularity of 'checking in' to locations using GPS-enabled mobile phones, a number of businesses are wondering how to reward frequent patrons. But exactly how susceptible are these 'location based services' to being abused? A researcher at the University of Illinois at Chicago shows how easily Foursquare can be gamed in 9 Perl statements, and invites readers to submit more succinct versions of the code to game the system." An anonymous reader contributes a link to a similar article about spoofing Facebook Places to create an alibi.

cancel ×

84 comments

Sorry! There are no comments related to the filter you selected.

SPHREAKING (5, Interesting)

Anonymous Coward | more than 4 years ago | (#33324668)

I am happy that this is taking off. It's the only way we can fight back against data hoarders.

I propose SOCIAL PHREAKING: We need a P2P client that pretends to be a user of a social network: twitter, facebook, linked in, whatever. The software will login periodically (each client does it at a different rate, in fact, they negotiate.)

The idea is, the various fake accounts form relationships with one another. Every now and then they create a new account and share passwords where they login and 'appear to login' to be from a different location. The growth should be such that it is not suspicious and not an abuse of service. It would make more sense for every node to have only 1 or 2 accounts at most, to simulate families with accounts per family member.

  • You can use a chat bot to generate the junk that goes into twitter feeds and people's walls. A markov would be a good one.
  • You can spider nouns, hobbies from Wikipedia and randomly generate names and demographics. Of course they would have to be corrobative with the user's real location.
  • You can use pictures from the various leaked archives to upload pictures.
  • You can randomly spider groups and join them and so on.

With enough privacy advocates on the phreaknet should be able to generate enough traffic and data to distort the demographics at least slightly. We could make poison the data hoarders to make them think that everyone loves a certain brand of ice cream and then it would become more popular.

We can restore the tip of knowledge and power to ourselves.

Re:SPHREAKING (0)

Anonymous Coward | more than 4 years ago | (#33325436)

Until the people hoarding the data take a look at the programs being used, figure out a pattern (not necessarily one that's immediately obvious, but is there) that gives away its use, and rescan all their existing data to filter that out.

Voila, now the fake data is gone and they're left with the "good" data. Not so great if you were relying on the data pollution for a false sense of security.

I'm a fan of "information pollution" to screw with the data of greedy f****s who want to collect it for their own use, regardless of how it affects our privacy. But let's not kid ourselves that we're as smart as that- your plan might work, but only if it's for polluting data that is likely to be used (and useful) in the near future and not after that.

IMHO, the danger is greater if one is using a browser plugin that auto-generates false requests and is specifically relying upon those false requests to drown out their "true" browsing history. If such data would still be dangerous or useful against you in a few years time, then you have to consider the possibility that those one is trying to evade (e.g. a repressive government) will have taken into account that plugin's behaviour and/or improved their data mining techniques in a few years time. Again, in such a case the false sense of security would be worse than no security.

Re:SPHREAKING (3, Funny)

Requiem18th (742389) | more than 4 years ago | (#33325850)

I'd like to subscribe to your mailing list.

Re:SPHREAKING (1)

SirRedTooth (1785808) | more than 4 years ago | (#33327062)

Then the people who abuse the demographics see a amazing opportunity, they are the only ones who can differentiate the distorted and real data. So they can use their unique knowledge to put themselves ahead of the game. Assuming there is only one group of people distorting the data in a certain region. Anyway, who cares if some company knows i like mint ice cream. Or that I like to go jogging from 4pm - 7pm. As long as they dont bug my bathroom and take pictures of me in the shower I really don't care. Actually it would be quite nice to have products that suit me a bit more than ones on the market already. Whats the big deal? I already disclose a huge amount of information about myself to colleges, friends and partners so why should I go all ape shit when somebody tries to find out whether people in my village like tea or coffe.

Re:SPHREAKING (0)

Anonymous Coward | more than 4 years ago | (#33328118)

"We could make poison the data hoarders to make them think that everyone loves a certain brand of ice cream and then it would become more popular."

I suggest using Kava ice cream for this idea.

Re:SPHREAKING (1)

Starayo (989319) | more than 4 years ago | (#33328800)

They make kava ice cream? As in, from the roots of the kava plant?

Huh. How about that.

Re:SPHREAKING (2, Interesting)

Geoff-with-a-G (762688) | more than 4 years ago | (#33331252)

A very interesting idea, but I think spam shows us that whoever actually developed and implemented such systems would most likely use them to intentionally skew the data towards something they could profit from, rather than adding noise to degrade the data.

How much of your spam is not related to making money off you?

I imagine this massive and convincing network of fake people would suddenly discover that they all love Axe body spray...

Re:SPHREAKING (1)

fulldecent (598482) | more than 4 years ago | (#33353422)

Spammers already do this, searched twitter lately?

Luckily (1)

RaymondKurzweil (1506023) | more than 4 years ago | (#33324684)

Foursquare isn't useful for anything important.

Re:Luckily (4, Informative)

naz404 (1282810) | more than 4 years ago | (#33324824)

Sure it is! It is a revolutionary app indispensable for burglars everywhere!

Re:Luckily (1)

TheJokeExplainer (1760894) | more than 4 years ago | (#33324860)

and hitmen!

Re:Luckily (1)

forkazoo (138186) | more than 4 years ago | (#33327660)

and guys who want to take out a hit on the burglars!

It all sort of balances out.

Re:Luckily (1)

WNight (23683) | more than 4 years ago | (#33330302)

Or stealing from hit-men. They'd have the cool toys...

Re:Luckily (1)

mweather (1089505) | more than 4 years ago | (#33328608)

Like they need an app to know that a house with no cars in the driveway in the middle of the day on a weekday is empty.

Re:Luckily (1)

foniksonik (573572) | more than 4 years ago | (#33329096)

See the key point is not that you are away, it's how far away and for how long.

Re:Luckily (1)

mweather (1089505) | more than 4 years ago | (#33360362)

How far doesn't matter, only how long. And for virtually everyone, that is 9AM to 5PM or some approximation thereof. Thieves know you're going to be away for hours, and it only takes them minutes. You could be out getting milk and they'd have enough time to hit you before you got back.

Re:Luckily (1)

WrongSizeGlass (838941) | more than 4 years ago | (#33325070)

Foursquare isn't useful for anything important.

Clearly it functions well as the target of Perl scripts and being the butt of /. jokes. Hmm, I see you point.

Re:Luckily (0)

Anonymous Coward | more than 4 years ago | (#33334032)

There are businesses that offer discounts to the Foursquare mayor of that location, so this might be a good way to save 50 cents on your coffee each morning.

Julian Assange... (4, Funny)

Jazz-Masta (240659) | more than 4 years ago | (#33324694)

How long before Julian Assange is proven (through his Facebook account) to have been at a McDonald's in Seattle when the alleged assault took place?

Warrant has been cancelled (1)

wjh31 (1372867) | more than 4 years ago | (#33324834)

apparently, this has already been cancelled http://www.bbc.co.uk/news/world-europe-11049316 [bbc.co.uk]

Re:Warrant has been cancelled (1)

WrongSizeGlass (838941) | more than 4 years ago | (#33325090)

I guess we all need to wait for someone in Sweden's Prosecution Authority office to leak the truth about this ;-)

Re:Warrant has been cancelled (0)

Anonymous Coward | more than 4 years ago | (#33325250)

Too late - I already made up my mind that he did it.

Re:Warrant has been cancelled (0)

Anonymous Coward | more than 4 years ago | (#33325260)

I wonder if the prosecutor's office will be as dilligent in issuing warrants for the two women and investigating for possible charges.

Re:Julian Assange... (1)

MachDelta (704883) | more than 4 years ago | (#33324882)

A better question is, how long will it take before some random (relative) nobody is prosecuted for a crime based on their facebook 'location' ?

aa (0, Offtopic)

herryones (1882778) | more than 4 years ago | (#33325282)

How long before Julian Assange is proven (through his Facebook account) to have been at a McDonald's in Seattle when the alleged assault took place?

smoking toothpaste [x10.mx] bread allergy symptoms [pcriot.com] chronic migraine headache [x10.mx] relaxation balls [x10.mx] ron rash author [x10.mx] effects of smoking smoking [x10.mx] stress incontinence medication [x10.mx] quit smoking quotes [x10.mx] effects of smoking on the body [x10.mx] allergy jobs [pcriot.com] ex quit smoking [x10.mx] herpes rash [x10.mx] flu shot egg allergy [pcriot.com] candida rash on face [x10.mx] migraine prescription [x10.mx] teen depression symptoms [x10.mx] feminine rash [x10.mx] auriculotherapy smoking [x10.mx] allergy vaccine [pcriot.com] navel rash [x10.mx] allergic rash [x10.mx] eczema and milk allergy [pcriot.com] dental relaxation [x10.mx] smoking complications [x10.mx] pork allergy symptoms [pcriot.com] unusual psychological disorders [x10.mx] performance anxiety disorder [x10.mx] smoking vaccine [x10.mx] rash around navel [x10.mx] nickel rash [x10.mx] primary hiv rash [x10.mx] smoking doctors [x10.mx] mould allergy symptoms [pcriot.com] best stop smoking products [x10.mx] ways to say no to smoking [x10.mx] itchy rash on hands [x10.mx] allergy club [pcriot.com] canine skin rash [x10.mx] cat skin rash [x10.mx] rash after virus [x10.mx] bike rash [x10.mx] seafood allergy symptoms [pcriot.com] stop smoking article [x10.mx] infantigo rash [x10.mx] allergy moms [pcriot.com] dangers of stress [x10.mx] solutions to stop smoking [x10.mx] shingles rash treatment [x10.mx] stress articles [x10.mx] vitamin d allergy [pcriot.com] rosacea redness [pcriot.com] no smoking stickers [x10.mx] stevens johnson rash [x10.mx] mold allergy diet [pcriot.com] rash flare up [x10.mx] itching Century [pcriot.com] rash on forehead [x10.mx] lace like rash [x10.mx] major depressive disorder symptoms [x10.mx] stop smoking posters [x10.mx] psychological disorders depression [x10.mx] herbal migraine relief [x10.mx] anxiety disorder that amounts [x10.mx] stop smoking devices [x10.mx] pets for allergy sufferers [pcriot.com] mmr egg allergy [pcriot.com] effexor migraine [x10.mx] homeopathic remedies for stress [x10.mx] nhs stop smoking helpline [x10.mx] new stop smoking pill [x10.mx] ingrown hair rash [x10.mx] acupuncture quit smoking [x10.mx] meningitis rash photos [x10.mx] hives and fever [pcriot.com] signs of heat rash [x10.mx] foot rash [x10.mx] causes of rashes [pcriot.com] particular rash [x10.mx] mrsa rash [x10.mx] migraine ice [x10.mx] pustule rash [x10.mx] post traumatic stress disorder treatment [x10.mx] can stress cause back pain [x10.mx] hiv chest rash [x10.mx] baby rash torso [x10.mx] postpartum depression symptoms [x10.mx] rash under skin [x10.mx] quit smoking jokes [x10.mx] signs of anaphylaxis [pcriot.com] symptoms of stress and depression [x10.mx] atlanta help quit smoking [x10.mx] deodorant allergy [pcriot.com] cause of social anxiety disorder [x10.mx] insect bite allergy [pcriot.com] cashew allergy [pcriot.com] avoid smoking [x10.mx] allergy swelling [pcriot.com] intermountain allergy clinic [pcriot.com] smoking hypnotist [x10.mx] rash that does not itch [x10.mx] penicillin allergy rash [x10.mx] causes of heat rash [x10.mx] dusky devastators of the depression [x10.mx] itchy feet [pcriot.com] quit smoking, stop smoking [x10.mx] fungal infection rash [x10.mx] smoking questions [x10.mx] stop smoking sutton coldfield [x10.mx] symptoms of deep depression [x10.mx] seasonal anxiety disorder [x10.mx] symptoms of severe depression [x10.mx] homeopathic stop smoking [x10.mx] side effects of smoking [x10.mx] road rash windows xp [x10.mx] calming oils [x10.mx] lip swelling allergy [pcriot.com] dog rash treatment [x10.mx] stop smoking london [x10.mx] erythematous skin rash [x10.mx] rash around mouth [x10.mx] stress aches [x10.mx] relaxation activities for teens [x10.mx] mens rash vests [x10.mx] side effects of stress [x10.mx] national non smoking day [x10.mx] scalp rash [x10.mx] road rash computer game [x10.mx] migraine statistics [x10.mx] acute depression symptoms [x10.mx] balmex diaper rash cream [x10.mx] stress relief drug [x10.mx] quit smoking chat rooms [x10.mx] swollen tongue allergy [pcriot.com] relaxation stress relief [x10.mx] city of london migraine clinic [x10.mx] treatment for fear of public speaking [x10.mx] infatigo rash [x10.mx] drug eruption rash [x10.mx] allergy associates [pcriot.com] signs and symptoms of anxiety [x10.mx] itchy bites [pcriot.com] itch between the legs [pcriot.com] stop smoking video [x10.mx] smoking cessation pill [x10.mx] stress test machine [x10.mx] heparin allergy [pcriot.com] introduction to stress management [x10.mx] lupus rash pictures [x10.mx] yellow country teeth [x10.mx] diffuse maculopapular rash [x10.mx] stress management interventions [x10.mx] food allergy facts [pcriot.com] abdominal migraine treatment [x10.mx] pataday allergy [pcriot.com] dangers of passive smoking [x10.mx] stop smoking commercials [x10.mx] symptoms of anxiety and panic [x10.mx] antibiotic skin rash [x10.mx] easy stop smoking [x10.mx] vertebrobasilar migraine [x10.mx] common migraine [x10.mx] advil migraine [x10.mx] rash on penius [x10.mx] allergy diagnostics [pcriot.com] cluster migraine treatment [x10.mx] atama rash guard [x10.mx] rash under eye [x10.mx] lycra rash guard [x10.mx] biofeedback migraine [x10.mx] quit smoking coupons [x10.mx] rash around groin [x10.mx] motivation to stop smoking [x10.mx] itchy genital organs of women [pcriot.com] yeast food allergy [pcriot.com] cow milk allergy [pcriot.com] painless rash [x10.mx] scabies rash photo [x10.mx] 7 day in quit smoking [x10.mx] health effects of smoking cigarettes [x10.mx] hayfever season [pcriot.com] skin rash stress [x10.mx] celiac rash [x10.mx] stress at work symptoms [x10.mx] diabetes rash [x10.mx] aromatherapy relaxation [x10.mx] rash guard for woman [x10.mx] early hiv rash [x10.mx] naturally yellow teeth [x10.mx] black lungs from smoking [x10.mx] fentanyl allergy [pcriot.com] imitrex migraine medicine [x10.mx] cessation fl smoking [x10.mx] 25 ways to quit smoking [x10.mx] social anxiety disorder symptoms [x10.mx] sudden rash on face [x10.mx] smoking and anxiety attacks [x10.mx] homeopathic remedy for hives [pcriot.com] prevent shaving rash [x10.mx] nhs smoking helpline [x10.mx] negative effects of bulimia [x10.mx] relaxation and stress reduction [x10.mx] cure for hives [pcriot.com] red scaly rash [x10.mx] relaxation visualization techniques [x10.mx] headache treatment center [x10.mx] sun allergy rash [pcriot.com] allergy mucus [pcriot.com] raised rash on face [x10.mx] migraine effects [x10.mx] exercise anaphylaxis [pcriot.com] steps to stop smoking [x10.mx] quit smoking pregnancy [x10.mx] allergy elimination clinic [pcriot.com] commit smoking [x10.mx] itching in the urethra [pcriot.com] migraine spray [x10.mx] basilar migraine symptoms [x10.mx] common mental health problems [x10.mx] medications used to treat depression [x10.mx] anti smoking pill [x10.mx] poll shows stress [x10.mx] smoking habits [x10.mx] itching in the canal [pcriot.com] cigarette smoking facts [x10.mx] fungus rash [x10.mx] red dye allergy [pcriot.com] laser acupuncture to quit smoking [x10.mx] toddler rash amoxil [x10.mx] primary hiv infection rash [x10.mx] rash around nose [x10.mx] smoking causes pollution [x10.mx] anxiety disorders in teenren [x10.mx] commit stop smoking [x10.mx] severe headache treatment [x10.mx] digestive advantage irritable bowel syndrome [x10.mx] menopause rash [x10.mx] meaning of bulimia [x10.mx] epoxy allergy [pcriot.com] peanut allergy symptoms [pcriot.com] rash around hairline [x10.mx] what is stress [x10.mx] bed bug rash pictures [x10.mx] pimple like skin rash [x10.mx] pityriasis rash [x10.mx] chronic fatigue specialist [x10.mx] wellpatch migraine [x10.mx] quit smoking inhaler [x10.mx] stress fracture symptoms [x10.mx] allergy medicine pregnant [pcriot.com] smoking weight gain [x10.mx] reasons to stop smoking [x10.mx] spreading itchy rash [x10.mx] airborne peanut allergy [pcriot.com] stop smoking hypnotherapist [x10.mx] herbal stress relief [x10.mx] irritable bowel remedies [x10.mx] stress relief heat treatment [x10.mx] smoking cessation prescription [x10.mx] relaxation breathing techniques [x10.mx] quit smoking magnets [x10.mx] clam allergy [pcriot.com] follicular rash [x10.mx] drug rash pictures [x10.mx] hayfever sore throat [pcriot.com] flour allergy [pcriot.com] cigar smoking and cancer [x10.mx] chronic fatigue disability [x10.mx] vertiginous migraine [x10.mx] stop smoking now [x10.mx] calming remedies [x10.mx] smoking is expensive [x10.mx] carolina asthma and allergy center [pcriot.com] prescription migraine medicine [x10.mx] fear of becoming fat [x10.mx] effects of stopping smoking [x10.mx] national quit smoking day [x10.mx] causes of anxiety disorders [x10.mx] signs of hayfever [pcriot.com] no smoking orkestra [x10.mx] fall allergy season [pcriot.com] red rash on thighs [x10.mx] nocturnal migraine [x10.mx] hives and diarrhea [pcriot.com] anti smoking aids [x10.mx] stress related acne [x10.mx] migraine eye pain [x10.mx] tramadol rash [x10.mx] triptan migraine [x10.mx]

Of course it's easy (1)

TheLink (130905) | more than 4 years ago | (#33324714)

Not like there's going to be lots of fancy safeguards to try to prevent you from faking the GPS coordinates - which can come from a device in your control.

I think it was obvious to many from the start that it could be gamed, but most of those same people aren't interested in gaming it.

Re:Of course it's easy (1)

Atryn (528846) | more than 4 years ago | (#33331532)

"Not like there's going to be lots of fancy safeguards to try to prevent you from faking the GPS coordinates - which can come from a device in your control."

Or, for that matter, to prevent others from faking your GPS coordinates? If you opt out of providing your real location, where is your data to prove you WEREN'T at the scene of the crime when someone presents "data" that says you WERE there? Interesting conundrum...

Re:Of course it's easy (1)

jeremymiles (725644) | more than 4 years ago | (#33334492)

The bit where you enter their password might make it a little bit tricky.

Re:Of course it's easy (1)

Atryn (528846) | more than 4 years ago | (#33335330)

The bit where you enter their password might make it a little bit tricky.

I submit Exhibit A [blogspot.com] , showing that Foursquare and Gowalla (at least... who knows how many other apps) send usernames and passwords in plaintext.

Fake mayors (0)

Anonymous Coward | more than 4 years ago | (#33324738)

The other hilarious hack is fakemayor.com - all it does is fakes the screenshot so you can get the free beer or whatever. Expect more of this stuff as these checkin apps proliferate and the mayorship becomes more valuable.

9 lines of perl? What does that even mean? (0)

Anonymous Coward | more than 4 years ago | (#33324754)

Honestly, this is like saying that a poem is "two sentences" - totally meaningless. Now, if he had said 9 lines of pseudocode ...

no need for srand; (4, Informative)

Danny Rathjens (8471) | more than 4 years ago | (#33324764)

"If srand() is not called explicitly, it is called implicitly at the first use of the "rand" operator." -- perldoc -f rand

So there is a wasted line right there. This whole thing is quite silly, though. perlgolf can be a lot more challenging and fun than making a simple http post. :)

Re:no need for srand; (1)

MacGyver2210 (1053110) | more than 4 years ago | (#33325718)

This is not true of the Microsoft-based rand() function though. If you don't seed before you call rand() it will ALWAYS return 42 as the first random number(gee, I wonder if that's a joke), and the subsequent sequence of numbers are also always the same. I always call it to be sure, because what's a few clock cycles to make certain you're truly randomizing?

Re:no need for srand; (2, Informative)

pyrrhonist (701154) | more than 4 years ago | (#33325862)

Perl itself calls srand() if it hasn't been called (regardless of what platform it's running on). You don't need to do it explicitly.

Re:no need for srand; (1)

slaingod (1076625) | more than 4 years ago | (#33327384)

I thought the same thing, until I ran across a situation in ruby's Passenger, where they were initializing the srand with time or something similar, but of course all the servers were restarted at the same time. This then caused my UUID's to collide in another library because we had removed a 'superflous' srand in our code that was masking the problem.

Just saying you don't always know what the code that isn't yours is doing, so it is probably a good idea to assume it isn't done and do it explicitly.

Re:no need for srand; (1)

chromatic (9471) | more than 4 years ago | (#33328220)

Just saying you don't always know what the code that isn't yours is doing....

In this case, read Perl's documentation for rand().

Re:no need for srand; (1)

slaingod (1076625) | more than 4 years ago | (#33329290)

Yes, in this specific case of 9 lines of code that aren't doing anything with many outside libraries, etc., it may be possible to read the documentation, and assuming the documentation is correct, rely on the default behavior. That is very rarely the case however.

However when I have come across a particular problem that is resolved by being thorough, and ensuring things are initialized, my tendency is to remember that and keep doing it in the future, which is the case for srand/rand.

Just sharing my story.

stres-s.x10.mx (-1, Troll)

herryones (1882778) | more than 4 years ago | (#33324812)

how reduce stress [x10.mx] stress relief techniques [x10.mx] stress relief pills [x10.mx] aromatherapy stress relief [x10.mx] stress relief annealing [x10.mx] stress headache relief [x10.mx] stress relief remedies [x10.mx] stress relief pillow [x10.mx] homeopathic stress relief [x10.mx] stress relief clinic [x10.mx] massage therapy for stress relief [x10.mx] stress relief massage miami [x10.mx] stress relief west palm beach [x10.mx] stress relief reflexology [x10.mx] stress relief center miami [x10.mx] critical stress management [x10.mx] massage therapy stress relief [x10.mx] music therapy stress relief [x10.mx] art therapy stress relief [x10.mx] body stress release therapy [x10.mx] stress management ppt [x10.mx] stress management [x10.mx] stress management presentation [x10.mx] stress definition [x10.mx] stress management quotes [x10.mx] stress quotes [x10.mx] stress symptoms [x10.mx] definition of stress [x10.mx] stress management powerpoint [x10.mx] stress management strategies [x10.mx] stress management definition [x10.mx] stress management techniques [x10.mx] stress management tips [x10.mx] stress management interventions [x10.mx] time management [x10.mx] time stress management [x10.mx] what is stress [x10.mx] work stress [x10.mx] work stress management [x10.mx] workplace stress [x10.mx] workplace stress management [x10.mx] stress testing risk management [x10.mx] hse stress management standards [x10.mx] stress management computer flash video [x10.mx] introduction to stress management [x10.mx] international stress management [x10.mx] stress management standards [x10.mx] hse stress management [x10.mx] stress management for students [x10.mx] stress management for parents [x10.mx] stress management model [x10.mx] office stress management techniques [x10.mx] stress management workbook [x10.mx] stress management services [x10.mx] effective stress management [x10.mx] project on stress management [x10.mx] stress management lessons [x10.mx] ways to get rid of stress [x10.mx] stress fracture symptoms [x10.mx] proof stress [x10.mx] what is cortisol [x10.mx] stress at work [x10.mx] peterson stress concentration [x10.mx] infp stress [x10.mx] infp under stress [x10.mx] coulomb stress [x10.mx] von mises stress wiki [x10.mx] derogatis stress profile [x10.mx] whitney stress block [x10.mx] immobilization stress [x10.mx] stress mibi [x10.mx] talus stress fracture [x10.mx] folk and stress hip hop [x10.mx] organized konfusion stress [x10.mx] petersons stress concentration factors [x10.mx] adenosine stress [x10.mx] critical stress debriefing [x10.mx] hot spot stress [x10.mx] summed stress score [x10.mx] stress builds character [x10.mx] non reactive non stress test [x10.mx] video memory stress test [x10.mx] health managing principle strategy stress well [x10.mx] nuclear stress test risks [x10.mx] stress sestamibi [x10.mx] stress exchange tooley street [x10.mx] adenosine sestamibi stress test [x10.mx] adenosine stress test protocol [x10.mx] stress in teenagers [x10.mx] causes of job stress [x10.mx] can stress cause back pain [x10.mx] can stress cause night sweats [x10.mx] causes of teenage stress [x10.mx] can stress cause chest pain [x10.mx] does stress cause high blood pressure [x10.mx] can stress cause constipation [x10.mx] can stress cause hives [x10.mx] can stress cause dizziness [x10.mx] can stress cause high blood pressure [x10.mx] side effects of stress [x10.mx] effects of stress on teens [x10.mx] stress management organization [x10.mx] stress management for workers [x10.mx] stress management institute [x10.mx] stress management worksheets [x10.mx] samhsa anger management [x10.mx] anger management ottawa [x10.mx] stress management clinic [x10.mx] stress management websites [x10.mx] homeopathic stress reliever [x10.mx] can stress cause shingles [x10.mx] stress related itching [x10.mx] essential oils for stress [x10.mx] stress mints [x10.mx] poll shows stress [x10.mx] skin rash stress [x10.mx] natural stress therapy [x10.mx] herbal stress relievers [x10.mx] can stress cause a rash [x10.mx] stress chair [x10.mx] lower back stress fracture [x10.mx] lumbar stress fracture [x10.mx] stress relief medicine [x10.mx] stress test equipment [x10.mx] stress test machine [x10.mx] stress fracture spine [x10.mx] stress test blood pressure [x10.mx] herbal stress [x10.mx] acupuncture stress relief [x10.mx] tmj stress [x10.mx] homeopathy stress [x10.mx] traumatic stress clinic [x10.mx] stress master leather executive massage chair [x10.mx] stress management training birmingham [x10.mx] austin stress clinic [x10.mx] homeopathic remedies for stress [x10.mx] stress management training dublin [x10.mx] stress fracture leg [x10.mx] stress induced rash [x10.mx] stress master massage chair [x10.mx] stress relief therapy [x10.mx]

Re:stres-s.x10.mx (1)

WrongSizeGlass (838941) | more than 4 years ago | (#33325122)

Wow ... reading all that was really stressful ... too bad there isn't a source for stress relief that is easily accessible. sigh

9 lines of Perl? (1)

colinrichardday (768814) | more than 4 years ago | (#33324856)

How long before someone gets it down to five lines?

Re:9 lines of Perl? (1)

mr_mischief (456295) | more than 4 years ago | (#33324908)

Ummm... already done [slashdot.org] . Do I get a cookie?

Re:9 lines of Perl? (1)

colinrichardday (768814) | more than 4 years ago | (#33325426)

Do I get a cookie?

No.

Easy golf: round one (5, Interesting)

mr_mischief (456295) | more than 4 years ago | (#33324892)


#!/usr/bin/perl -W
use IO::Socket;
srand;
sleep(rand()*600);
my $sock = IO::Socket::INET->new(PeerAddr=>'api.foursquare.com', PeerPort=>80,
        Proto =>'tcp', Type=>SOCK_STREAM) or die;
$ARGV[1] += rand() * 0.0001 - 0.00005;
$ARGV[2] += rand() * 0.0001 - 0.00005;
my $str = "vid=$ARGV[0]&private=0&geolat=$ARGV[1]&geolong=$ARGV[2]";
print $sock "POST /v1/checkin HTTP/1.1\r\nHost: api.foursquare.com\r\nUser-Agent:" ." Mozilla/5.0 (iPhone; U; CPU like Mac OS X; en) AppleWebKit/420+ " ."(KHTML, like Gecko) Version/3.0 Mobile/1C10 Safari/419.3\r\nContent" ."-Type: application/x-www-form-urlencoded\r\nAuthorization: Basic " ."XXXXXX\r\nContent-length: ",
length($str)+2, "\r\n\r\n$str\r\n";
$_=;

The author didn't really even try, so it'll be easy to shorten it. Shortening it a lot is left as further exercise. I'll just get rid of some low-hanging fruit. I'm sure Perlmonks [perlmonks.org] will pick up the challenge if they haven't already.

  1. The random number generator is automatically seeded, so get rid of that line.
  2. The results from the socket are assigned to a variable, but that variable is not printed or otherwise used. There's a whole line. It might be friendly to read the data waiting, but it's not necessary to the task.
  3. Rather than assigning to the command-line arguments, the assignment to $str could have included the random perturbations, so there's two more lines.


#!/usr/bin/perl -W
use IO::Socket;
sleep(rand()*600);
my $sock = IO::Socket::INET->new(PeerAddr=>'api.foursquare.com', PeerPort=>80,
        Proto =>'tcp', Type=>SOCK_STREAM) or die;
my $str = "vid=$ARGV[0]&private=0&geolat=" . ($ARGV[1] += rand() * 0.0001 - 0.00005)
        . "&geolong=" . ($ARGV[2] += rand() * 0.0001 - 0.00005);
print $sock "POST /v1/checkin HTTP/1.1\r\nHost: api.foursquare.com\r\nUser-Agent:"
        . " Mozilla/5.0 (iPhone; U; CPU like Mac OS X; en) AppleWebKit/420+ " ."(KHTML, like Gecko) Version/3.0 Mobile/1C10 Safari/419.3\r\nContent" ."-Type: application/x-www-form-urlencoded\r\nAuthorization: Basic " ."XXXXXX\r\nContent-length: ",
length($str)+2, "\r\n\r\n$str\r\n";

Five logical lines. Actual display lines may of course be different depending upon several factors like attempting to break long lines for viewing and the vagaries of the textual mangling on Slashdot.

Re:Easy golf: round one (3, Funny)

ducomputergeek (595742) | more than 4 years ago | (#33327636)

So now you can tell Foursquare to go away as I've replaced you with a small perl script?

to make it portable use \015\012 instead of \r\n (2, Informative)

Anonymous Coward | more than 4 years ago | (#33327642)

cause \r\n isn't \015\012 on every platform

Re:to make it portable use \015\012 instead of \r\ (1)

ais523 (1172701) | more than 4 years ago | (#33332508)

The only even remotely common one where it isn't is Mac OS Classic (i.e. pre-OSX), nowadays. (Although Windows will convert \n into \r\n on output to a textmode file, this will happen whether it's written as \015\012 or \r\n.) So you don't really gain anything by doing this. (A better method is to set the "binary mode" flag on the filehandle, e.g. by using "binmode" in Perl, in order to turn off platform-specific newline translation; this will avoid the \n to \r\n translation on Windows and not hurt on other common platforms. It wouldn't surprise me if this was the default for network sockets anyway, though.)

Re:Easy golf: round one (1)

kwoff (516741) | more than 4 years ago | (#33327998)

If "use IO::Socket" counts as one line, just make a module "Foursquare::Mayor" whose import does what you did. Voila, one line! (Or, since we ignored the shebang line (which merely invokes megabytes of interpreter), why not make an executable which....)

What is foursquare? - The missing description. (3, Informative)

gnalle (125916) | more than 4 years ago | (#33324928)

Foursquare is a mobile application that makes cities easier to use and more interesting to explore. It is a friend-finder, a social city guide and a game that challenges users to experience new things, and rewards them for doing so. Foursquare lets users "check in" to a place when they're there, tell friends where they are and track the history of where they've been and who they've been there with. For more information on how foursquare works, see our searchable FAQ. http://foursquare.com/about [foursquare.com]

Re:What is foursquare? - The missing description. (0)

Anonymous Coward | more than 4 years ago | (#33325198)

So many words, just to say "shitty".

Re:What is foursquare? - The missing description. (1)

xeoron (639412) | more than 4 years ago | (#33325388)

Do you work for them?

Re:What is foursquare? - The missing description. (1)

gnalle (125916) | more than 4 years ago | (#33330038)

I don't work for Foursquare. I just thought that the slashdot summary was inadequate, so I decided to provide the missing information..

Re:What is foursquare? - The missing description. (4, Funny)

mr_mischief (456295) | more than 4 years ago | (#33325578)

There's this other application on mobile phones that lets people selectively contact those they want at a particular moment and communicate arbitrary information including that and a bunch more via simultaneous two-way voice.

Re:What is foursquare? - The missing description. (0)

Anonymous Coward | more than 4 years ago | (#33327136)

Right, because one-on-one communication works just as efficiently as one-to-many communication for all possible social situations.

Re:What is foursquare? - The missing description. (1)

mr_mischief (456295) | more than 4 years ago | (#33331926)

Well, for one thing, there's this feature called group calling. For another, there is probably a many-to-many over IP voice chat application for your phone if you look hard enough.

And finally... WOOSH!

Re:What is foursquare? - The missing description. (0)

Anonymous Coward | more than 4 years ago | (#33331718)

There's this other application on mobile phones that lets people selectively contact those they want at a particular moment and communicate arbitrary information including that and a bunch more via simultaneous two-way voice.

What's the name of this app? I searched on the appstore, but I couldn't find anything that fit the description.

Re:What is foursquare? - The missing description. (0)

Anonymous Coward | more than 4 years ago | (#33329542)

What does it mean to "make cities easier to use"? I don't see how Foursquare does that. I have found the general Internet makes learning about your city far easier, but I've not under stood how 4SQ is special in that regard.

This is why... (1)

Bazman (4849) | more than 4 years ago | (#33325012)

...we can't have nice things.

  Yeah, foursquare is a cute little idea, but if people don't play nicely it'll suck. And with current GPS and locational technologies, it'll always be open to abuse.

Also, I reckon this is how Agent Smith managed to appear a zillion times in the same location.

Re:This is why... (1)

interval1066 (668936) | more than 4 years ago | (#33325100)

Well, it just follows that, like just about anything on the web, anyone relying on Foursquare as an absolute reflection of reality is being foolish. I think that as a simple social tool among friends its fine, but for government spook work obviously this ain't your playground. Of course, the news is rife with stories about criminals who don't seem to believe they can be caught by anything they do on-line [economist.com] .

Re:This is why... (1)

SanityInAnarchy (655584) | more than 4 years ago | (#33332576)

Unfortunately, aside from being "cute" for a beer or something, it could conceivably be used as evidence to show that you were in a certain place at a certain time. Exploits like these have to become pretty common before we can be reasonably sure a court will throw out the "evidence" that I checked in at the scene of the crime...

Faking geolocation in Firefox (3, Informative)

BerkeleyDude (827776) | more than 4 years ago | (#33325214)

Firefox allows you to fake your geolocation: http://pugio.net/2009/07/fake-your-geolocation-in-firef.html [pugio.net]

Re:Faking geolocation in Firefox (1, Informative)

Anonymous Coward | more than 4 years ago | (#33326748)

Apparently I was the first person on Facebook to check in at the NSA headquarters.

Re:Faking geolocation in Firefox (1, Funny)

Anonymous Coward | more than 4 years ago | (#33326778)

We're sorry, you have spelled Firefox correctly in your Slashdot post. Here at Slashdot, you are supposed to pretend to be all about "teh open sourcez" but spell the names of the all popular F/OSS apps like a retard. Some accepted misspellings are: FireFox, Fire-Fox, Fire Fox, Foxfire, FireFOX, and Mozilla. If you choose the last option, please remember to be consistent and refer to all Adobe Acrobat apps as simply "Adobe."

Thanks!
The Management

Great idea. (1, Insightful)

Anonymous Coward | more than 4 years ago | (#33325216)

> NOTE: To get this script to work, you must replace XXXXXX with the Base64
> encoded version of "email/phone:password", so base64("john@doe.com:mypassword").
> Here's Google's top ranked site for online Base64 encoding.

Yeah, what should go wrong by running your email/password-combo through a server-side Base64 encoder.

Re:Great idea. (1)

mr_mischief (456295) | more than 4 years ago | (#33325600)

The same thing that could go wrong by sending it in Base64 in the first place? It's an encoding, not encryption. Oh, and there are already Perl modules to do Base64 encoding, but I guess importing another module and calling it for something you can calculate once would have just ballooned his line count a whole two lines.

Re:Great idea. (0)

Anonymous Coward | more than 4 years ago | (#33328986)

whoosh

So wait... (4, Insightful)

coryking (104614) | more than 4 years ago | (#33325266)

Did any body else catch that the Foursquare API has you sending your username and password in the clear?

Please tell me you can do all this on port 443 and that your phone is using SSL.

That said, I love it!

Re:So wait... (3, Informative)

francium de neobie (590783) | more than 4 years ago | (#33326996)

Well, unfortunately, that plain text thing isn't limited to the hack. I intercepted the traffic coming from their iPhone app and it sends your passwords in plain text too [blogspot.com] .

Re:So wait... (1)

Atryn (528846) | more than 4 years ago | (#33331572)

Holy cow... I wonder how many mobile apps in general are this inept at security? I'm betting - a lot. Thanks for the link, I've shared it already...

Web 1.0 defeats Web 2.0! (1)

WWWWolf (2428) | more than 4 years ago | (#33325616)

It has been shown many times and it has been shown again: Web 1.0, with all of the glorious unreadable Perl stuff, neatly and cleanly defeats all this Ruby on Rails, gradients-and-rounded-corners, Twitter-compatible, "beta" Web 2.0 nonsense!

...or maybe Web 2.0 people should stop designing RESTful asynchronous JavaScript-compatible social-media APIs that are too easily abused. It's not that hard!

(This was supposed to be a humorous post, but it's not really working today, is it?)

Re:Web 1.0 defeats Web 2.0! (1)

SanityInAnarchy (655584) | more than 4 years ago | (#33332598)

It has been shown many times and it has been shown again: Web 1.0, with all of the glorious unreadable Perl stuff, neatly and cleanly defeats all this Ruby on Rails, gradients-and-rounded-corners, Twitter-compatible, "beta" Web 2.0 nonsense!

I can write that script much quicker and cleaner in Ruby. In nine lines, I might even be able to tweet the results, just to annoy you...

...or maybe Web 2.0 people should stop designing RESTful asynchronous JavaScript-compatible social-media APIs that are too easily abused. It's not that hard!

Agreed. It's actually quite easy to create a RESTFUL AJAX-compatible social-media API which isn't so easily abused.

(This was supposed to be a humorous post, but it's not really working today, is it?)

Nope.

You fai7 1t!? (-1, Troll)

Anonymous Coward | more than 4 years ago | (#33325790)

Use ruby instead of perl (0)

Anonymous Coward | more than 4 years ago | (#33326058)

Ruby first round:


#!/usr/bin/env ruby
require 'net/http'
sleep(rand(600))
l=["user@host:password"].pack('m')
def z i;ARGV[i].to_f+rand*0.0001-0.00005;ends="vid=#{ARGV[0]}&private=0&geolat=#{z 1}&geolong=#{z 2}"puts Net::HTTP.new('api.foursquare.com').post('/v1/checkin',s,'Host'=>'api.foursquare.com', 'User-Agent'=>'Mozilla/5.0 (iPhone; U; CPU like Mac OS X; en) AppleWebKit/420+ (KHTML, like Gecko) Version/3.0 Mobile/1C10 Safari/419.3','Content-Type'=>'application/x-www-form-urlencoded','Authentication'=>'Basic '+l,'Content-length'=>"#{s.size+2}")

I'm certain Ruby golfers could shorten this significantly too.The "Content-length" and "Host" headers may be redundant--I'm not sure if Net::HTTP adds them automagically or not.

Re:Use ruby instead of perl (0)

Anonymous Coward | more than 4 years ago | (#33326158)

Let me fix a bug for you. Change one line to this:

l=["user@host:password"].pack('m').strip

Without the .strip there's an extra newline "\n" character at the end.

9 lines of perl? (1, Informative)

Anonymous Coward | more than 4 years ago | (#33326496)

You can do that with 1 line of shell + wget/curl

spoofing the phone's internal GPS (1)

Isaac-Lew (623) | more than 4 years ago | (#33326626)

Wouldn't a better hack be to spoof the location reported by your phone? After all, if the feds subpoena your cell phone records & get your actual location, wouldn't that destroy your foursquare/facebook alibi (as well as making you look more suspicious)?

Re:spoofing the phone's internal GPS (0)

Anonymous Coward | more than 4 years ago | (#33326792)

Wouldn't a better hack be to spoof the location reported by your phone?

Wouldn't that be defeated by a little trigonometry and the base stations that you phone connects to?

Hire a "hacker" (1)

n_djinn (1883738) | more than 4 years ago | (#33326924)

To route burglaries. I no longer need to sit outside in my El Camino watching people and trying to guess when they will be gone. no all I need is a entry level programmer to parse all the "places" info in my target area. No longer will our street crew need to be on the street surveilling.

Foursquare iPhone app sends password in plain text (1)

francium de neobie (590783) | more than 4 years ago | (#33326968)

I did a simple Wireshark session with Foursquare's iPhone app and found they're sending my username and password in plain text over HTTP - they don't encrypt anything at all and they do it every time you open the Foursquare app.

You can see the Wireshark screenshot at my : blog post [blogspot.com] .

I'm removing the Foursquare app from my iPhone now. It's way too dangerous.

$ARGV[0] (1)

pgn674 (995941) | more than 4 years ago | (#33328250)

Is it just me, or was $ARGV[0] never initialized? I wonder what 'vid' stands for?

Re:$ARGV[0] (1)

Smallpond (221300) | more than 4 years ago | (#33329012)

"Must accept a venue ID and base GPS coordinates as command line input."

$ARGV[0] is the venue ID

Re:$ARGV[0] (0)

Anonymous Coward | more than 4 years ago | (#33331050)

So how do you go about feeding these arguments into the script to actually check in with a venue ID, lat and long?

Gaming places (1)

GregNorc (801858) | more than 4 years ago | (#33328384)

You don't need a proxy or perl to game facebook places... you can do it by changing one line in your about:config and hard code "geo.wifi.uri"

I wrote up a full tutorial [blogspot.com] on my blog for those who are interested.

how do you make this work? (0)

Anonymous Coward | more than 4 years ago | (#33331144)

So how do you go about feeding these arguments into the script to actually check in with a venue ID, lat and long?
How do you enter in ARGV0? do you have to run this from a web page? or can you do this from command line.
how does the script find your geolat and geolong?

Check for New Comments
Slashdot Login

Need an Account?

Forgot your password?