[Snort-users] Re: MS SQL 2000 database setup for snort with snortdb-extra (osql syntax issues?)

Tony Ly anthony_ly at ...11721...
Tue Apr 27 09:45:32 EDT 2004


Hi John, 

It is the way MSSQL handles single quote.  Modify your data as below (add 
another single quote as an escape character) and try again: 

INSERT INTO services(port, protocol, name, description) VALUES('188', 
'6','mumps', 'Plus Five''s MUMPS')
INSERT INTO services(port, protocol, name, description) VALUES('188', 
'17','mumps', 'Plus Five''s MUMPS')
INSERT INTO services(port, protocol, name, description) VALUES('513', 
'17','who', 'maintains data bases showing who''s')
INSERT INTO services(port, protocol, name, description) VALUES('1392', 
'6','iclpv-pm', 'Print Manager')
INSERT INTO services(port, protocol, name, description) VALUES('1392', 
'17','iclpv-pm', 'Print Manager')
INSERT INTO services(port, protocol, name, description) VALUES('3264', 
'6','ccmail', 'cc:mail/lotus')
INSERT INTO services(port, protocol, name, description) VALUES('3264', 
'17','ccmail', 'cc:mail/lotus') 

Good luck... 

 

McCash, John writes: 

> Guys,
> 	I've been digging into the snortdb-extra code, and it appears that the following lines are the ones actually causing the problem. The comments don't scan properly either, but I can just remove them. 
> 
> INSERT INTO services(port, protocol, name, description) VALUES('188', '6', 'mumps', 'Plus Five\'s MUMPS');
> INSERT INTO services(port, protocol, name, description) VALUES('188', '17', 'mumps', 'Plus Five\'s MUMPS');
> INSERT INTO services(port, protocol, name, description) VALUES('513', '17', 'who', 'maintains data bases showing who\'s');
> INSERT INTO services(port, protocol, name, description) VALUES('1392', '6', 'iclpv-pm', 'Print Manager');
> INSERT INTO services(port, protocol, name, description) VALUES('1392', '17', 'iclpv-pm', 'Print Manager');
> INSERT INTO services(port, protocol, name, description) VALUES('3264', '6', 'ccmail', 'cc:mail/lotus');
> INSERT INTO services(port, protocol, name, description) VALUES('3264', '17', 'ccmail', 'cc:mail/lotus'); 
> 
> The issues seem to be with the escaped apostrophe, the colon, and the use of the word 'Manager'. Does anyone know the proper way to structure these lines for mssql?
> 		John
> ------------------------------------------------------------------------------------------------
> This message is for the designated recipient only and may
> contain privileged, proprietary, or otherwise private information.  
> If you have received it in error, please notify the sender
> immediately and delete the original.  Any unauthorized use of
> this email is prohibited.
> ------------------------------------------------------------------------------------------------
> [mf2] 
> 
> 
> -------------------------------------------------------
> This SF.net email is sponsored by: The Robotic Monkeys at ThinkGeek
> For a limited time only, get FREE Ground shipping on all orders of $35
> or more. Hurry up and shop folks, this offer expires April 30th!
> http://www.thinkgeek.com/freeshipping/?cpg297
> _______________________________________________
> Snort-users mailing list
> Snort-users at lists.sourceforge.net
> Go to this URL to change user options or unsubscribe:
> https://lists.sourceforge.net/lists/listinfo/snort-users
> Snort-users list archive:
> http://www.geocrawler.com/redir-sf.php3?listsnort-users
 


Tony Ly 

This email may contain confidential and privileged information for the sole
use of the intended recipient. Any review or distribution by others is
strictly prohibited. If you are not the intended recipient, please contact
the sender and delete all copies of this email message. 





More information about the Snort-users mailing list