<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<!-- Template generated by Exclaimer Mail Disclaimers on 01:18:33 Friday, 1 June 2018 -->
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<style type="text/css">P.ImprintUniqueID {
MARGIN: 0cm 0cm 0pt
}
LI.ImprintUniqueID {
MARGIN: 0cm 0cm 0pt
}
DIV.ImprintUniqueID {
MARGIN: 0cm 0cm 0pt
}
TABLE.ImprintUniqueIDTable {
MARGIN: 0cm 0cm 0pt
}
DIV.Section1 {
page: Section1
}
</style><!-- Template generated by Exclaimer Mail Disclaimers on 01:18:33 Friday, 1 June 2018 --><style type="text/css">P.ImprintUniqueID {
MARGIN: 0cm 0cm 0pt
}
LI.ImprintUniqueID {
MARGIN: 0cm 0cm 0pt
}
DIV.ImprintUniqueID {
MARGIN: 0cm 0cm 0pt
}
TABLE.ImprintUniqueIDTable {
MARGIN: 0cm 0cm 0pt
}
DIV.Section1 {
page: Section1
}
</style><!-- Template generated by Exclaimer Mail Disclaimers on 01:18:33 Friday, 1 June 2018 --><style type="text/css">P.ImprintUniqueID {
MARGIN: 0cm 0cm 0pt
}
LI.ImprintUniqueID {
MARGIN: 0cm 0cm 0pt
}
DIV.ImprintUniqueID {
MARGIN: 0cm 0cm 0pt
}
TABLE.ImprintUniqueIDTable {
MARGIN: 0cm 0cm 0pt
}
DIV.Section1 {
page: Section1
}
</style><!-- Template generated by Exclaimer Mail Disclaimers on 01:18:33 Friday, 1 June 2018 --><style type="text/css">P.ImprintUniqueID {
MARGIN: 0cm 0cm 0pt
}
LI.ImprintUniqueID {
MARGIN: 0cm 0cm 0pt
}
DIV.ImprintUniqueID {
MARGIN: 0cm 0cm 0pt
}
TABLE.ImprintUniqueIDTable {
MARGIN: 0cm 0cm 0pt
}
DIV.Section1 {
page: Section1
}
</style>
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<!--[if !mso]><style>v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style><![endif]--><style><!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0in;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:"Times New Roman",serif;}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
p
{mso-style-priority:99;
mso-margin-top-alt:auto;
margin-right:0in;
mso-margin-bottom-alt:auto;
margin-left:0in;
font-size:12.0pt;
font-family:"Times New Roman",serif;}
span.EmailStyle19
{mso-style-type:personal-reply;
font-family:"Calibri",sans-serif;
color:#1F497D;}
.MsoChpDefault
{mso-style-type:export-only;
font-family:"Calibri",sans-serif;}
@page WordSection1
{size:8.5in 11.0in;
margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="EN-US" link="blue" vlink="purple">
<p class="ImprintUniqueID"></p>
<p class="ImprintUniqueID"></p>
<p class="ImprintUniqueID"></p>
<p class="ImprintUniqueID"></p>
<div class="WordSection1">
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D">Brian,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D">Here is my really hacky python script to do this.
<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D">Thanks<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"><br>
Tommy<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><b><span style="font-size:11.0pt;font-family:"Calibri",sans-serif">From:</span></b><span style="font-size:11.0pt;font-family:"Calibri",sans-serif"> cisco-voip [mailto:cisco-voip-bounces@puck.nether.net]
<b>On Behalf Of </b>Brian Meade<br>
<b>Sent:</b> Friday, June 1, 2018 9:54 AM<br>
<b>To:</b> cisco-voip voyp list <cisco-voip@puck.nether.net><br>
<b>Subject:</b> [cisco-voip] CUCM Bulk TFTP File Upload<o:p></o:p></span></p>
<p class="MsoNormal"><o:p> </o:p></p>
<table class="MsoNormalTable" border="1" cellspacing="4" cellpadding="0" style="background:lightyellow;border:solid black 1.0pt">
<tbody>
<tr>
<td style="border:none;padding:.75pt .75pt .75pt .75pt">
<p class="MsoNormal"><strong><span style="color:#FF3333">EXTERNAL EMAIL</span></strong><o:p></o:p></p>
</td>
</tr>
</tbody>
</table>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Calibri",sans-serif;display:none"><o:p> </o:p></span></p>
<table class="MsoNormalTable" border="0" cellspacing="4" cellpadding="0">
<tbody>
<tr>
<td style="padding:.75pt .75pt .75pt .75pt">
<p class="MsoNormal"> <o:p></o:p></p>
</td>
</tr>
</tbody>
</table>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Calibri",sans-serif">Does anyone have a working script for this?<o:p></o:p></span></p>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Calibri",sans-serif"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Calibri",sans-serif">I put together a script in python to do this but hitting some issues.<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Calibri",sans-serif"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif">Right now I’ve got it to the point that it’s trying to upload a single file.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif"> <o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif">I used Fiddler to copy what I saw for a working request through a browser.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif"> <o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif">I first do a Get to the cmplatform page to get a cookie.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif"> <o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif">I then do a Post to the /cmplatform/j_security_check page to authenticate that cookie.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif"> <o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif">I then do a Get to /cmplatform/tftpFileUpload.do to get a Struts Token.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif"> <o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif">I then do a Post to /cmplatform/tftpFileUpload.do with the Struts token, filename, and directory details.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif"> <o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif">This looks to be successful as I get a "File uploaded successfully" message returned but then I can't find the file on the TFTP File Management page.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif">I tried using the curl methods I found here (
<a href="https://communities.cisco.com/docs/DOC-43506"><span style="color:#0563C1">https://communities.cisco.com/docs/DOC-43506</span></a> ) but no luck there. Not sure if this works in 11.5 without grabbing the Struts token. Without a token, I get an error
message saying something to the affect of I hit the Submit button twice.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif">Here's what it looks like when my script runs in Fiddler:<o:p></o:p></span></p>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Calibri",sans-serif"><img border="0" width="544" height="450" id="_x0000_i1025" src="cid:image001.png@01D3F9AB.08AD3810"><o:p></o:p></span></p>
</div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Calibri",sans-serif"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif">This looks almost exactly like the real example through a browser I captured minus a few headers I tried manually adding with no luck.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif">Python script attached.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Calibri",sans-serif"><o:p> </o:p></span></p>
</div>
</div>
</div>
<p></p>
<span style="FONT-SIZE: xx-small; FONT-FAMILY: Verdana; FONT-WEIGHT: bolder; COLOR: #808080"><br>
Tommy Schlotterer | Systems Engineer - Collaboration<br>
Presidio (NASDAQ: PSDO) | <a href="http://presidio.com" title="" target="" style="">
presidio.com</a><br>
20 N Saint Clair 3rd Floor, Toledo, OH 43604<br>
D: 419.214.1415 | C: 419.706.0259 | <a href="mailto:tschlotterer@presidio.com" title="Click to send email to Schlotterer, Tommy" target="" style="">
tschlotterer@presidio.com</a><br>
<br>
</span>
<p class="ImprintUniqueID"></p>
<p></p>
<span style="FONT-SIZE: xx-small; FONT-FAMILY: Verdana; FONT-WEIGHT: bolder; COLOR: #808080"><br>
<br>
<a href="http://www.presidio.com"><img id="IMG1" border="0" alt="Future. Built." src="https://www2.presidio.com/signatures/Presidio_Blue_FutureBuilt_200px.png" width="223" height="49"></a><br>
<br>
</span>
<p class="ImprintUniqueID"></p>
<p></p>
<span style="FONT-FAMILY: Verdana; COLOR: #808080; FONT-SIZE: xx-small; FONT-WEIGHT: bolder"><br>
Follow us:<br>
<br>
<a href="http://www.twitter.com/presidio"><img id="IMG1" border="0" alt="Follow Presidio on Twitter" src="http://twitter-badges.s3.amazonaws.com/t_small-a.png" width="22" height="22"></a><br>
<br>
</span>
<p class="ImprintUniqueID"></p>
<p></p>
<span style="FONT-FAMILY: Verdana; COLOR: #808080; FONT-SIZE: xx-small; FONT-WEIGHT: bolder"><br>
<br>
</span>
<p class="ImprintUniqueID"></p>
<br>
<P class=MsoNormal>
<P class=MsoNormal><span><em><span style="FONT-SIZE: 11px">This message w/attachments (message) is intended solely for the use of the intended recipient(s) and may contain information that is privileged, confidential or proprietary. If you are not an intended recipient, please notify the sender, and then please delete and destroy all copies and attachments<span style="COLOR: #1f497d">. </span>Please be advised that any review or dissemination of, or the taking of any action in reliance on, the information contained in or attached to this message is prohibited.</span></em></span><span style="FONT-SIZE: 10.5pt"><?xml:namespace prefix = "o" /><o:p></o:p></span></P>
<P></P></body>
</html>