aspose file tools
The moose likes Security and the fly likes Regular expression to find French and German charaters (White List for Input Validation) Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Engineering » Security
Reply Bookmark "Regular expression to find French and German charaters (White List for Input Validation)" Watch "Regular expression to find French and German charaters (White List for Input Validation)" New topic
Author

Regular expression to find French and German charaters (White List for Input Validation)

Shankar Tanikella
Ranch Hand

Joined: Jan 30, 2011
Posts: 329

Hi all,
Firstly sorry, if the forum location is wrong. Since the scenario is related to security I just put my concern here.

Scenario: We are creating a filter to parse the request and eliminate the vulnerable characters for our application which supports languages en, fr, de. To achieve that we are creating a list of characters that can be allowed and we could do it successfully for English using a regular expression as below.

However, to achieve the same for French and German characters in form of regular expression, we couldn't get a way out. Google search didn't help much.
Any suggestions or links are highly appreciated.

Thanks in advance


Have Fun with Java
little,little.. little by little makes a lot..
Shankar Tanikella
Ranch Hand

Joined: Jan 30, 2011
Posts: 329

Closing it late
For those who are looking for it, If I remember, we used \p{L} to consider these characters and it worked fine.
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: Regular expression to find French and German charaters (White List for Input Validation)
 
Similar Threads
Regular expression to check for specific special characters (any repitition) and 0 to 9 numbers
need a regular expression
Regular Expression
Comparing 2 Strings with 1?
special character check in text box