Activity Stream
48,167 MEMBERS
6784 ONLINE
besthostingforums On YouTube Subscribe to our Newsletter besthostingforums On Twitter besthostingforums On Facebook besthostingforums On facebook groups

Page 2 of 2 FirstFirst 12
Results 11 to 18 of 18
  1.     
    #11
    ლ(ಠ益ಠლ)
    Website's:
    extremecoderz.com
    so in your XSS example, your ensuring everything is HtmlEncoded?

    Forgive me for my ignorance, but why are these not hard-implemented? Is there any given situation where you wound want these functionalities?

  2.   Sponsored Links

  3.     
    #12
    Member
    Website's:
    litewarez.net litewarez.com triniwarez.com
    Because some systems especially BBCODE, use there raw entities to convert to valid html i/e a bbcode B tag to be converted into <strong> html tag, the bbcode system will parse the submitted post then extract all allowed tags from the post, then turn all the remaining into its entities then add the converted code back to the post, this way it does not produce messed up bbcode.

    Thats the best example i can give you.
    Join Litewarez.net today and become apart of the community.
    Unique | Clean | Advanced (All with you in mind)
    Downloads | Webmasters


    Notifications,Forum,Chat,Community all at Litewarez Webmasters


  4.     
    #13
    Respected Developer
    Website's:
    wrzc.org
    It depends on what I'm coding. If it's just a small simple thing I'll do it like el_j above but if it's a fairly big script with a few pages and tables I'll use something like Litewarez. It's far less coding and work in the long run to just clean everything at the start.

    If I'm super paranoid like an admin area I do like to do stuff like eg. replace example.com?go=delete with example?go=3 and example.com?go=reply with example.com?go=4 etc.
    And then make sure it's an integer. Same thing for $_POST. Basically I try and make every transfered variable a number. It also confuses people a bit too which all helps.
    Interested to know people's thought's on this.
    Tutorial How to SEO your Warez Site a guide to help you increase your organic traffic

    Huge list of Warez Sites and free Multiposter Templates

  5.     
    #14
    Member
    Website's:
    litewarez.net litewarez.com triniwarez.com
    Mr Happy, i dont really think using integers is a great advantage apart from sanitization i.e typecasting your can lose yourself in your code if your getting into the 100+ actions, this i would keep with reply,edit,delete what i tend to do is to develop a MVC Framework and create a sort of REST system so:

    Instead of topic.php?mode=reply&id=22 i would do

    /topic/reply/22/

    this way you only have to sanitize the topic/reply values so that they only allowed to be called IF the function exists within the topic class, this gives better security then within the reply method i just intergize the 3rd param.

    This gives alot more structure and security to your code.
    Join Litewarez.net today and become apart of the community.
    Unique | Clean | Advanced (All with you in mind)
    Downloads | Webmasters


    Notifications,Forum,Chat,Community all at Litewarez Webmasters


  6.     
    #15
    ლ(ಠ益ಠლ)
    Website's:
    extremecoderz.com
    hmm

    But wouldnt having to decode be a better option than having to encode? I mean, everything is encoded whether you like it or not in the interest of security, and if you dont like it, decode it.

    Just seems far more logical to me..

  7.     
    #16
    Member
    Website's:
    litewarez.net litewarez.com triniwarez.com
    i also think the mojor reason for leaving the entities down to the end user is to allow the user to have more control over its code.

    personally i think its good that its not auto-encoded because users then learn about html entities, and characters codes, this is an important part of web-development and personally i dont expect PHP Dev team to do all my work for me!
    Join Litewarez.net today and become apart of the community.
    Unique | Clean | Advanced (All with you in mind)
    Downloads | Webmasters


    Notifications,Forum,Chat,Community all at Litewarez Webmasters


  8.     
    #17
    Member
    I agree with litewarez, in a way, PHP has made sure to provide encoding and escaping functions, so they are doing it, just not directly.

    I don't really think it's just about giving control, PHP language, like I always say, is almost becoming a noob friendly language, which is great, means anyone can learn it fast.

    If you implement the things mentioned in the article (or other methods) into functions or classes it'll definitely save you a lot of time, but first you need to make sure how to handle functions and classes, and what to add in there, this way you don't end up escaping or encoding the wrong characters, which will render the function useless.

    The most common "hacks" are SQL injection and HTML injection. Never really saw much reports about system/shell injection, but thought I'd include it anyway.

    I still say, for direct small inputs, regex is the man.

    The other good thing about not having everything encoded automatically is if you're saving that data into a database, you don't really need to encode all characters if you code a strong script.

    With direct input, it'll save you space, instead of &quot; or &amp; the decoded version will be inserted, if you consider a large database, that will save you a lot of bytes and bits "ie: &amp; vs &".

    It's much better than the early days, when using base_64 to encode data then store in database was a standard, which increased data by 30-40%.

  9.     
    #18
    Banned
    Website's:
    KWWHunction.com
    @ el_jentel1

    Thank you for posting that very detailed information, Even knowing as much as i do when it comes up PHP their is always more to learn really appreciate to have an admin around that actually devotes their knowledge to their forum

Page 2 of 2 FirstFirst 12

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. How to secure RDP??
    By Jiung in forum Technical Help Desk Support
    Replies: 6
    Last Post: 9th Aug 2012, 09:55 PM
  2. How to Secure SSH in WHM
    By Bharat in forum Technical and Security Tutorials
    Replies: 0
    Last Post: 28th Dec 2011, 02:10 PM
  3. Replies: 0
    Last Post: 20th Dec 2011, 03:37 AM
  4. How We Can Secure
    By WarezMania in forum Webmaster Discussion
    Replies: 6
    Last Post: 17th May 2010, 04:27 PM
  5. How to convert data of wordpress to data of Datalife Engine
    By chipve in forum Webmaster Discussion
    Replies: 0
    Last Post: 5th May 2010, 05:35 PM

Tags for this Thread

BE SOCIAL