[Lift] setting user-agent header with Databinder

2009-09-08 Thread jack
[String, Any]) = java.util.Arrays asList ( values.toSeq map { case (k, v) = new BasicNameValuePair(k, v.toString) } toArray : _* ) /** @return %-encoded string for use in URLs */ def % (s: String) = java.net.URLEncoder.encode(s, UTF_8) /** @return %-decoded string e.g. from query string

[Lift] Re: setting user-agent header with Databinder

2009-09-08 Thread David Pollak
. from query string or form body */ def -% (s: String) = java.net.URLDecoder.decode(s, UTF_8) /** @return formatted and %-encoded query string, e.g. name=valuename2=value2 */ def q_str (values: Map[String, Any]) = URLEncodedUtils.format(map2ee (values), UTF_8) /** @return formatted query

[Lift] Re: setting user-agent header with Databinder

2009-09-08 Thread Timothy Perrett
) = java.net.URLEncoder.encode(s, UTF_8) /** @return %-decoded string e.g. from query string or form body */ def -% (s: String) = java.net.URLDecoder.decode(s, UTF_8) /** @return formatted and %-encoded query string, e.g. name=valuename2=value2 */ def q_str (values: Map[String, Any

[Lift] Re: setting user-agent header with Databinder

2009-09-08 Thread Jack Widman
) = java.net.URLEncoder.encode(s, UTF_8) /** @return %-decoded string e.g. from query string or form body */ def -% (s: String) = java.net.URLDecoder.decode(s, UTF_8) /** @return formatted and %-encoded query string, e.g. name=valuename2=value2 */ def q_str (values: Map[String, Any

[Lift] Re: setting user-agent header with Databinder

2009-09-08 Thread Jack Widman
BasicNameValuePair(k, v.toString) } toArray : _* ) /** @return %-encoded string for use in URLs */ def % (s: String) = java.net.URLEncoder.encode(s, UTF_8) /** @return %-decoded string e.g. from query string or form body */ def -% (s: String) = java.net.URLDecoder.decode(s, UTF_8) /** @return

[Lift] Re: security

2009-06-13 Thread David Pollak
(unless the developer explicitly builds their own query string, which requires that the developer sign and date the code and is a place where one can grep for the construct during a code review.) Strings back out to XML or XHTML will be escaped properly, unless the developer uses Unparsed

[Lift] Re: security

2009-06-16 Thread James Matlik
with this recommendation within the bounds of a Lift app. Strings in Java survive having \00 characters. They are impurvious to buffer overflow attacks. Strings are escaped before being used as part of queries by the JDBC and/or JPA systems (unless the developer explicitly builds their own query string