[Tue Jun 06 14:53:09 2006] [error] [client x.x.x.x] [Tue Jun 6 14:53:09 2006] bulkmailers-request.pl: Use of uninitialized value in concatenation (.) or string at /usr/lib/cgi-bin/bulkmailers-request.pl line 56., referer: http://tangerine/cgi-bin/bulkmailers-request.pl [Tue Jun 06 14:53:09 2006] [error] [client x.x.x.x] [Tue Jun 6 14:53:09 2006] bulkmailers-request.pl: readline() on unopened filehandle at /usr/lib/cgi-bin/bulkmailers-request.pl line 57., referer: http://tangerine/cgi-bin/bulkmailers-request.pl #### $filename=~m/^.*(\\|\/)(.*)/; # strip the remote path and keep the filename my ($newfilename) = $1; open(LOCAL, ">/var/www/html/upload/".$newfilename); #### sub process_form { my ($from_address) = $query->param('from'); my ($reply_to_address) = $query->param('reply_to'); my ($subject) = $query->param('subject'); my ($message) = $query->param('message'); my ($description) = $query->param('description'); my ($msg_month) = $query->param('msg_month'); my ($msg_day) = $query->param('msg_day'); my ($msg_year) = $query->param('msg_year'); my ($from_address2) = 'rjm@uchicago.edu'; my ($to_address) = 'rjm@uchicago.edu'; my ($mail_host) = 'smtp.uchicago.edu'; if ( validate_form ( $from_address, $reply_to_address, $subject, $message, $description, $msg_month, $msg_day, $msg_year ) ) { my ($filename) = $query->param('email_list'); $filename=~m/^.*(\\|\/)(.*)/; # strip the remote path and keep the filename my ($newfilename) = $1; open(LOCAL, ">/var/www/html/upload/".$newfilename); while(<$filename>) { print LOCAL $_; } my ($mm) = new File::MMagic; # use internal magic file my ($res) = $mm->checktype_contents("/var/www/html/upload/".$filename); # Adjust subject and body message my ($message_body) = "Request submission\rFrom: ".$from_address."\rReply_to: ".$reply_to_address."\rSubject: ".$subject."\rMessage:\r\r".$message."\r\rRecipients: ".$description."\r\rDate message is to be sent: ".$msg_month."/".$msg_day."/".$msg_year; # Create the multipart container my ($msg) = MIME::Lite->new ( From => $from_address2, To => $to_address, Subject => $subject, Type =>'multipart/mixed' ) or die "Error creating multipart container: $!\n"; # Add the text message part $msg->attach ( Type => 'TEXT', Data => $message_body ) or die "Error adding the text message part: $!\n"; # Add the file $msg->attach ( Type => $res, Path => '/var/www/html/upload', Filename => $filename, Disposition => 'attachment' ) or die "Error adding $filename: $!\n"; # Send the Message MIME::Lite->send('smtp', $mail_host, Timeout=>60); $msg->send; print $query->header; print "Thank you!
Confirmation of your submission will be emailed to you."; } }