FreeBSD Bugzilla – Attachment 56462 Details for
Bug 85240
Ampersand problem in security/pwman
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
file.diff
file.diff (text/plain), 1.40 KB, created by
Maurice Castro
on 2005-08-23 05:50:29 UTC
(
hide
)
Description:
file.diff
Filename:
MIME Type:
Creator:
Maurice Castro
Created:
2005-08-23 05:50:29 UTC
Size:
1.40 KB
patch
obsolete
>--- src/pwlist.c.old 2005-03-09 16:07:07.000000000 +0000 >+++ src/pwlist.c 2005-03-09 16:06:37.000000000 +0000 >@@ -272,13 +272,32 @@ > write_password_node(xmlNodePtr root, Pw* pw) > { > xmlNodePtr node; >+ xmlChar *escaped; >+ >+ // Take the inbound strings. Treat as an xmlChar, and escape >+ // Need to free the result of escape every time > > node = xmlNewChild(root, NULL, (xmlChar*)"PwItem", NULL); >- xmlNewChild(node, NULL, (xmlChar*)"name", (xmlChar*)pw->name); >- xmlNewChild(node, NULL, (xmlChar*)"host", (xmlChar*)pw->host); >- xmlNewChild(node, NULL, (xmlChar*)"user", (xmlChar*)pw->user); >- xmlNewChild(node, NULL, (xmlChar*)"passwd", (xmlChar*)pw->passwd); >- xmlNewChild(node, NULL, (xmlChar*)"launch", (xmlChar*)pw->launch); >+ >+ escaped = xmlEncodeSpecialChars(root, (xmlChar*)pw->name); >+ xmlNewChild(node, NULL, (xmlChar*)"name", escaped); >+ xmlFree(escaped); >+ >+ escaped = xmlEncodeSpecialChars(root, (xmlChar*)pw->host); >+ xmlNewChild(node, NULL, (xmlChar*)"host", escaped); >+ xmlFree(escaped); >+ >+ escaped = xmlEncodeSpecialChars(root, (xmlChar*)pw->user); >+ xmlNewChild(node, NULL, (xmlChar*)"user", escaped); >+ xmlFree(escaped); >+ >+ escaped = xmlEncodeSpecialChars(root, (xmlChar*)pw->passwd); >+ xmlNewChild(node, NULL, (xmlChar*)"passwd", escaped); >+ xmlFree(escaped); >+ >+ escaped = xmlEncodeSpecialChars(root, (xmlChar*)pw->launch); >+ xmlNewChild(node, NULL, (xmlChar*)"launch", escaped); >+ xmlFree(escaped); > } > > int
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 85240
: 56462