Connecting Tech Pros Worldwide Help | Site Map

How to make xss safe strings

 
LinkBack Thread Tools Search this Thread
  #1  
Old August 21st, 2008, 03:15 AM
Roopesh
Guest
 
Posts: n/a
Default How to make xss safe strings

Hi,

How can I make a string XSS safe? Will
simply .replace('<','&lt;').replace('>','&gt;').... do the work? Or
are there some other issues to take into account?. Is there already a
function in python which will do this for me.

Regards
Roopesh

  #2  
Old August 21st, 2008, 04:05 AM
Dan Bishop
Guest
 
Posts: n/a
Default Re: How to make xss safe strings

On Aug 20, 10:10*pm, Roopesh <roopesh....@gmail.comwrote:
Quote:
Hi,
>
How can I make a string XSS safe? Will
simply .replace('<','&lt;').replace('>','&gt;').... do the work? Or
are there some other issues to take into account?. Is there already a
function in python which will do this for me.
For HTML, use the cgi.escape function.
 

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Popular Articles

What is Bytes?

We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights. Get the best answers to your questions from over 220,662 network members.