{"id":817,"date":"2013-01-14T17:49:06","date_gmt":"2013-01-14T21:49:06","guid":{"rendered":"http:\/\/blog.uvm.edu\/ctl-projects\/?p=307"},"modified":"2013-01-14T17:49:06","modified_gmt":"2013-01-14T21:49:06","slug":"silk-servers-and-perl","status":"publish","type":"post","link":"https:\/\/blog.uvm.edu\/waw\/2013\/01\/14\/silk-servers-and-perl\/","title":{"rendered":"Silk Servers and perl"},"content":{"rendered":"<p><strong>Jim McGarry<\/strong>, Exam Proctoring center, sent me this question:<\/p>\n<blockquote><p>\u00a0This html has been working for years apparently up to the end of Fall 2012 semester; it calls a program to send email &amp; to create a flat file in the directory it resides in that I download to create forms &amp; update a database.<\/p>\n<p>&nbsp;<\/p>\n<p><a href=\"http:\/\/blog.uvm.edu\/ctl-projects\/files\/2013\/01\/eadbcefi1.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignleft size-full wp-image-309\" src=\"http:\/\/blog.uvm.edu\/ctl-projects\/files\/2013\/01\/eadbcefi1.png\" alt=\"\" width=\"762\" height=\"60\" \/><\/a><\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>Now when I try to execute it I get<\/p>\n<p><a href=\"http:\/\/blog.uvm.edu\/ctl-projects\/files\/2013\/01\/jhijdjfh.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignleft size-full wp-image-311\" src=\"http:\/\/blog.uvm.edu\/ctl-projects\/files\/2013\/01\/jhijdjfh.png\" alt=\"\" width=\"899\" height=\"190\" \/><\/a><\/p><\/blockquote>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p><strong>Scott Dellinger<\/strong>, Systems Architecture &amp; Administration, Enterprise Technology Services, made note<\/p>\n<blockquote><p><em>The old server at cgi.uvm.edu was retired at the end of 2012.\u00a0 This was announced in November and December to the it-announce and it-discuss mailing lists used to disseminate such information, though it does not appear you currently subscribe to either.\u00a0 (You might wish to do so, in order to ensure you see IT service announcements.)\u00a0 We also directly contacted script owners whose scripts we could determine were being actively used, though most of the remaining contents on this server were only being spammed anymore and so this was difficult to identify.\u00a0 I\u2019m sorry you were not aware of the change. It looks like your script is a derivative of FormMail.\u00a0 We have a copy of FormMail running on a supported server, available on scripts.uvm.edu (see http:\/\/www.uvm.edu\/it\/utilities\/formmail.html for details).\u00a0 If this will work for you, then moving to use that would probably be your easiest option.\u00a0 If not, then we have a new CGI hosting service that could be an option, though it works a little differently.\u00a0 Just let us know and we\u2019ll be glad to help.<\/em><\/p><\/blockquote>\n<p>Turns out ,Jim already has a &#8220;silk&#8221; server at<\/p>\n<p>http:\/\/epc.w3.uvm.edu<\/p>\n<p>created last October. See <a href=\"http:\/\/blog.uvm.edu\/ctl-projects\/2012\/10\/10\/i-m-oscar\/\">here<\/a> and <a href=\"http:\/\/blog.uvm.edu\/ctl-projects\/2012\/10\/17\/oscar-client-happy\/\">here<\/a>.<\/p>\n<p>the Bformmail2.pl script he was using had some additional features not found in formmail.pl He had a copy of this on backup drive, loaded it on his server. Nothing happened.<\/p>\n<p>&nbsp;<\/p>\n<p>Apparently, form POST variables are not appearing in perl %ENV hash. I was able to prove this with this here <a href=\"http:\/\/waw.w3.uvm.edu\/test_cgi.pl\">link<\/a> and this perl<\/p>\n<blockquote><p>#!\/usr\/bin\/perl<br \/>\nuse Data::Dumper;<br \/>\nuse CGI;<br \/>\nprint &#8220;Content-type: text\/htmlnn&#8221;;<br \/>\n$query=CGI-&gt;new;<br \/>\nprint &#8220;<\/p>\n<pre>\";\nprint Dumper $query;<\/pre>\n<\/blockquote>\n<p>But no, say Ben:<\/p>\n<blockquote><p>Use $fcgi, as if it was an automagically created instance of CGI (because it is):<\/p>\n<pre>#!\/usr\/bin\/perl\nuse Data::Dumper;\nprint \"Content-type: text\/htmlnn\";\nprint \"<\/pre>\n<pre>\";<\/pre>\n<p>The fcgi stuff on the server is setting up CGI, and is persistent across requests.\u00a0 The requested perl script is executed per-request from a persistent fcgid handler<\/p><\/blockquote>\n<p>Oh, the fun we have.<\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Jim McGarry, Exam Proctoring center, sent me this question: \u00a0This html has been working for years apparently up to the end of Fall 2012 semester; it calls a program to send email &amp; to create a flat file in the &hellip; <a href=\"https:\/\/blog.uvm.edu\/waw\/2013\/01\/14\/silk-servers-and-perl\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":7,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[41826],"tags":[42758],"class_list":["post-817","post","type-post","status-publish","format-standard","hentry","category-wes","tag-boffins"],"_links":{"self":[{"href":"https:\/\/blog.uvm.edu\/waw\/wp-json\/wp\/v2\/posts\/817","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.uvm.edu\/waw\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.uvm.edu\/waw\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.uvm.edu\/waw\/wp-json\/wp\/v2\/users\/7"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.uvm.edu\/waw\/wp-json\/wp\/v2\/comments?post=817"}],"version-history":[{"count":0,"href":"https:\/\/blog.uvm.edu\/waw\/wp-json\/wp\/v2\/posts\/817\/revisions"}],"wp:attachment":[{"href":"https:\/\/blog.uvm.edu\/waw\/wp-json\/wp\/v2\/media?parent=817"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.uvm.edu\/waw\/wp-json\/wp\/v2\/categories?post=817"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.uvm.edu\/waw\/wp-json\/wp\/v2\/tags?post=817"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}