Welcome to the Java Programming Forums


The professional, friendly Java community. 21,500 members and growing!


The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


>> REGISTER NOW TO START POSTING


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 12 of 12

Thread: Generating per person URL

  1. #1
    Member
    Join Date
    Mar 2011
    Posts
    84
    My Mood
    Daring
    Thanks
    17
    Thanked 1 Time in 1 Post

    Question Generating per person URL

    Hi

    Is it possible that when we send a link to something(say some online task) in mail, then that will work only if it is clicked from same mailbox whom it was sent?

    let me elaborate it:
    suppose person A hosts google.com/someApp

    and now A invites B and expects to do something using EMAIL system. so he compose a mail consisting URL ---> google.com/someApp/B
    but B forwards that mail to someone else, say C and via any means.
    Now C is doing the actual work, and A sees that B is doing it.

    So My requirement is that can we make URL(in mail) working only if it is clicked only, not even typed into address bar??

    as far as I can think, I need to find out if the current window ( browser tab's address bar details when the link was clicked.

    So here by I invite you; please add something...
    feel free to ask as required.

    Thanking you in advance


  2. #2
    Forum VIP
    Join Date
    Jul 2010
    Posts
    1,676
    Thanks
    25
    Thanked 329 Times in 305 Posts

    Default Re: Generating per person URL

    I could be wrong, but I don't think so. The best way I could imagine doing that is sending the email info as metadata to the url, but the email host would control what information gets sent when a url is clicked, not you.
    NOTE TO NEW PEOPLE LOOKING FOR HELP ON FORUM:

    When asking for help, please follow these guidelines to receive better and more prompt help:
    1. Put your code in Java Tags. To do this, put [highlight=java] before your code and [/highlight] after your code.
    2. Give full details of errors and provide us with as much information about the situation as possible.
    3. Give us an example of what the output should look like when done correctly.

    Join the Airline Management Simulation Game to manage your own airline against other users in a virtual recreation of the United States Airline Industry. For more details, visit: http://airlinegame.orgfree.com/

  3. #3
    Senior Member
    Join Date
    Jul 2013
    Location
    Europe
    Posts
    666
    Thanks
    0
    Thanked 121 Times in 105 Posts

    Default Re: Generating per person URL

    If B would have a unique IP-adress that could not change then you could simply verify whether its actual B or not, but not many workstations have a unique IP adress.
    Additionally it could maybe be done with cookies but that isnt too safe since there are ways to break the system. Maybe even with a downloadable program that needs to be running and to verify the computer specs of B, but this has problems of its own.

    In the end, even if it was possible to do it safely, it would not be easy, not be cheap and not be comfortable to anybody using it.

  4. #4
    Crazy Cat Lady KevinWorkman's Avatar
    Join Date
    Oct 2010
    Location
    Washington, DC
    Posts
    5,424
    My Mood
    Hungover
    Thanks
    144
    Thanked 636 Times in 540 Posts

    Default Re: Generating per person URL

    This sounds like a horrible idea. It sounds like you're trying to do some security-through-obscurity type of restriction, which never works.

    What is your actual end goal that you think this is a solution for?
    Useful links: How to Ask Questions the Smart Way | Use Code Tags | Java Tutorials
    Static Void Games - Play indie games, learn from game tutorials and source code, upload your own games!

  5. The Following User Says Thank You to KevinWorkman For This Useful Post:

    ChristopherLowe (September 12th, 2014)

  6. #5
    Member
    Join Date
    Mar 2011
    Posts
    84
    My Mood
    Daring
    Thanks
    17
    Thanked 1 Time in 1 Post

    Default Re: Generating per person URL

    Quote Originally Posted by KevinWorkman View Post
    This sounds like a horrible idea. It sounds like you're trying to do some security-through-obscurity type of restriction, which never works.

    What is your actual end goal that you think this is a solution for?
    I'm Glad you asked. my client usually give assignments online and he send access links to specific pupils only ( one which require it ) via emails, last time he caught his students cheating him, like assignment was for A but he convinced B to do it for him. B did that.

    I have to avoid this from happening again in future! As link was sent to A then that link must only work iff it is clicked from A's mailbox.

    Any Ideas how we can achieve this?? I'm open to Ideas...... we may end up developing something new ...

    --- Update ---


    If B would have a unique IP-adress that could not change then you could simply verify whether its actual B or not, but not many workstations have a unique IP adress.
    Additionally it could maybe be done with cookies but that isnt too safe since there are ways to break the system. Maybe even with a downloadable program that needs to be running and to verify the computer specs of B, but this has problems of its own.

    In the end, even if it was possible to do it safely, it would not be easy, not be cheap and not be comfortable to anybody using it.
    as far as I know we can access emails from anywhere. like A can open mailbox from B's home, possible right so IP based tracking doesn't seems working here. Sorry to dis-agree.

    I liked end of your post. Well when anything is hard to get, fun starts there only.... right!

  7. #6
    Senior Member
    Join Date
    Jul 2013
    Location
    Europe
    Posts
    666
    Thanks
    0
    Thanked 121 Times in 105 Posts

    Default Re: Generating per person URL

    This is impossible. If you are dealing with students you have no way of making this happen. You can not control their computers, you can not monitor their houses. These little buggers will always find a way to cheat.
    I liked end of your post. Well when anything is hard to get, fun starts there only.... right!
    It usually means you are doing something wrong. Doing the right thing is easy. Finding out what the right thing actually is is the hard part.

  8. #7
    Member
    Join Date
    Mar 2011
    Posts
    84
    My Mood
    Daring
    Thanks
    17
    Thanked 1 Time in 1 Post

    Default Re: Generating per person URL

    This is impossible. If you are dealing with students you have no way of making this happen. You can not control their computers, you can not monitor their houses. These little buggers will always find a way to cheat.
    Then Its time to teach them; we been through that stage of life.


    Well lets get back to topic. Is there any way to achieve this???

    Can we stop mail forwarding???
    Actually I don't know much about SMTP (protocol) or mailing system. May be there is a header present in SMTP which may stop the recipient from forwarding received mail. What you guys say???

    Guys, lets discuss different ways????
    Last edited by arvindbis; September 11th, 2014 at 09:14 AM.

  9. #8
    Administrator copeg's Avatar
    Join Date
    Oct 2009
    Location
    US
    Posts
    5,320
    Thanks
    181
    Thanked 833 Times in 772 Posts
    Blog Entries
    5

    Default Re: Generating per person URL

    Can we stop mail forwarding???
    No. Once an email is sent, it is out of your hands (unless - in some scenarios - all recipients/senders are using the same software, like MS Outlook which allows exceptions like email recall).

    An alternative way to look at the problem is to enforce identity matching between the client and server (which you do not mention is implemented). Say, for instance, by forcing clients to login with private credentials (username/pass). It won't stop someone from sharing their credentials (or cheating for that matter), but I'd think user's would be more hesitant to share login information (and based upon your description above IMO would be essential anyway)

  10. The Following User Says Thank You to copeg For This Useful Post:

    arvindbis (September 12th, 2014)

  11. #9
    Grand Poobah
    Join Date
    Mar 2011
    Posts
    1,545
    My Mood
    Grumpy
    Thanks
    0
    Thanked 167 Times in 158 Posts

    Default Re: Generating per person URL

    Even if this was possible what would stop A logging on and then handing computer over to B to do homework for them? As Cornix said, students will always think of ways to cheat. What gets me is that sometimes the effort they go to in order to cheat is greater than if they just did the work themselves.
    Improving the world one idiot at a time!

  12. #10
    Member
    Join Date
    Mar 2011
    Posts
    84
    My Mood
    Daring
    Thanks
    17
    Thanked 1 Time in 1 Post

    Default Re: Generating per person URL

    @copeg
    It won't stop someone from sharing their credentials (or cheating for that matter)
    I agree here, we can't stop them.

    by forcing clients to login with private credentials (username/pass).
    Yes, this approach is already implemented.

    All I'm trying can we make it abstract??
    by abstract I mean no need to provide username/password and we are still able to track who did what.

    What gets me is that sometimes the effort they go to in order to cheat is greater than if they just did the work themselves
    You just reminded my college days.

  13. #11
    Crazy Cat Lady KevinWorkman's Avatar
    Join Date
    Oct 2010
    Location
    Washington, DC
    Posts
    5,424
    My Mood
    Hungover
    Thanks
    144
    Thanked 636 Times in 540 Posts

    Default Re: Generating per person URL

    I'm not sure if anybody mentioned this approach, but another way is to send each email address a unique link.

    When somebody visits that unique link, then you know that they got it from the email address you sent the link to.

    However, that wouldn't stop somebody from sending out that link and letting people visit it.
    Useful links: How to Ask Questions the Smart Way | Use Code Tags | Java Tutorials
    Static Void Games - Play indie games, learn from game tutorials and source code, upload your own games!

  14. #12
    Member
    Join Date
    Mar 2011
    Posts
    84
    My Mood
    Daring
    Thanks
    17
    Thanked 1 Time in 1 Post

    Default Re: Generating per person URL

    Quote Originally Posted by KevinWorkman View Post
    However, that wouldn't stop somebody from sending out that link and letting people visit it.
    that is what happened and I'm trying to uproot this and Yes I'm sending unique links per email.

    I will keep trying new ways, and update here if I'm able to do it. meanwhile your comments or suggestion is appreciated.

Similar Threads

  1. [SOLVED] How do I sort a TreeSet<Person> by Person's age?
    By bihlas in forum Java Theory & Questions
    Replies: 2
    Last Post: August 2nd, 2014, 04:00 AM
  2. First Person Camera
    By Aaron in forum What's Wrong With My Code?
    Replies: 1
    Last Post: November 13th, 2010, 01:54 PM