From: Jay V. <jva...@sy...> - 2003-05-28 23:56:08
|
I'm trying to use the STAF HTTP service for the first time. The syntax for a reqeust is shown in the HTTP service documentation to be: REQUEST METHOD <http_method> URL <target_url> [CONTENT <content>] [HEADER <key1=value1> [...]] [FILE <output_filename>] [IGNOREERRORS] [NOSTATUS] [RETURNHEADERS] The following log output shows the request string and the result: INFO: Sending STAF LOCAL HTTP REQUEST METHOD POST URL http://155.64.27.66/Sign HEADER Content-Type=application/xml RETURNHEADERS CONTENT <?xml version="1.0" encoding="UTF-8" standalone="yes"?> <licenses> ...... (shortened to simplify this email) </licenses> ERROR: STAF HTTP POST of xml file failed, rc: 1 INFO: RESULT BUFFER: INFO: You may have no more than 0 argument(s). You specified 22 argument(s). T he first excess argument is, version=1.0. I am submitting this within a C++ method. The CONTENT I wish to POST is a multiline XML document. As a string, it includes quotation marks, newline characters, etc. My questions are: Is the error message in the result buffer from the STAF HTTP service? Is there some way I need to enclose the CONTENT argument so that it will correctly pass the whole thing to the Web Server? According to the error table (in the STAF User's Guide), the return code of 1 means "Invalid API", and suggests reporting it to the authors. Thanks, Jay VanSant Symantec Corp. |