text
stringlengths
454
608k
url
stringlengths
17
896
dump
stringclasses
91 values
source
stringclasses
1 value
word_count
int64
101
114k
flesch_reading_ease
float64
50
104
Try a syscall trace for what the is trying to be opened. On Sep 18, 2016 2:57 PM, <wopl...@gmail.com> wrote: Advertising > hello! Thanks for replying. i' m not sure what you mean. I created a file > index.html in a dir web, inside my user /usr/glenda (so, > /usr/glenda/web/index.html). > I think i need a small configuration example for /sys/lib/httpd.rewrite > and namespace.httpd and a small explanation on how and what directories to > use to make the raspberry pi host a smal site. Maybe someone that has done > the same, or similar? > > Thanks for the help! > João Reis. > > > Try changing the object index.html into a file. > > /Bootes > > > > On Sat, Sep 17, 2016 at 6:40 PM, <wopl...@gmail.com> wrote: > > > >> Hello! I just re-installed plan9 in a raspberry pi, and this time > >> around, i´m trying to play with the httpd web server, for creating a > >> small site. > >> > >> I created /usr/web/index.html and tried to run ip/httpd/httpd which > >> produces the following error page (via browser, and for the intended > >> ip): > >> > >> " > >> Object not found > >> > >> The object /usr/glenda/web/index.html does not exist on this server. > >> errstr: '/usr/web/usr' does not exist > >> uri host: > >> header host: 192.168.1.100 > >> actual host: who cares > >> " > >> I also created /usr/glenda/web/index.html but the results are the > >> same. I know that the /sys/lib/httpd.rewrite and namespace.httpd are > >> important files for configuring but i´m not sure how. I didn´t, i´m > >> afraid, get less cofused by reading httpd man page, but i´m sure it is > >> my fault :). > >> > >> My objective is the to run the web server for a index.html basic file > >> on a directory, somewhere in plan9. Does anyone have any ideas where > >> the problem might lie? > >> > >> > >> Thanks! > >> > >> João Reis > >> > >> > >> > > >
https://www.mail-archive.com/9fans@9fans.net/msg35823.html
CC-MAIN-2016-40
refinedweb
312
70.9
Question: I created instance of base class in derived class and tried to access protected members. I can directly access protected members in a derived class without instantiating the base class. Base class: package com.core; public class MyCollection { protected Integer intg; } A derived class in the same package - package com.core; public class MyCollection3 extends MyCollection { public void test(){ MyCollection mc = new MyCollection(); mc.intg=1; // Works } } A derived class in a different package - package secondary; import com.core.MyCollection; public class MyCollection2 extends MyCollection{ public void test(){ MyCollection mc = new MyCollection(); mc.intg = 1; //!!! compile time error - change visibility of "intg" to protected } } How it is possible to access a protected member of a base class in a derived class using instance of base class when derived class is also in same package but not when derived class is in different package? If I mark protected member as "static" then I am able to access protected member of base class using instance of base class in a derived class which resides in a different package. Solution:1 You're right that you can't do this. The reason why you can't access the field, is that you're not in the same package as the class, nor are you accessing an inherited member of the same class. The last point is the critical one - if you'd written MyCollection2 mc = new MyCollection2(); mc.intg = 1; then this would work, as you're changing a protected member of your own class (which is present in that class through inheritance). However, in your case you're trying to change a protected member of a different class in a different package. Thus it should come as no surprise that you're denied access. Solution:2 The Java tutorial says: The protected modifier specifies that the member can only be accessed within its own package (as with package-private) and, in addition, by a subclass of its class in another package. And in your case, you are accessing the variable in another object. By coincidence it has a class that's the same as the current one, but the visibility checks wouldn't check that. So, the second time you are denied access, because you are in a different package, and the first time you are given access because you are in the same package (and not because it's a subclass) Solution:3 If a class member is protected then there are 2 cases: - If subclass is in same package - If subclass is in different package I. Same package : - Can access through inheritance - Can access by creating an instance of parent class II. Different package : - Can only access through inheritance See the table below for all use cases: Solution:4 In short, it's not really possible. It seems like you should reconsider your design. However, there's a work around, if you're sure that's what you want to do. You can add a protected method to MyCollection which takes an instance and sets the value of intg on your behalf: package com.core; public class MyCollection { protected Integer intg; protected void setIntg(MyCollection collection, Integer newIntg) { collection.intg = newIntg; } } Now your subclasses can access this method: package secondary; import com.core.MyCollection; public class MyCollection2 extends MyCollection{ public void test(){ MyCollection mc = new MyCollection(); setIntg(mc, 1); } } But please note that this is a very strange way of doing it. I'd suggest again that your design needs to be rethought before you go down this route. Solution:5 According to the member accessibility rule of Java you cannot access protected member of a class without extending it. You can try the following. package secondary; import com.core.MyCollection; public class MyCollection2 extends MyCollection{ public void test(){ intg = 1; } } Instead of creating the new instance try to assign the value. It will work. Solution:6 You cant access a protected variable in a derived class (which is in different package) if accessed using a new object of class MyCollection. you can just write intg = 1; directly without making ( new MyCollection ) like this: package secondary; import com.core.MyCollection; public class MyCollection2 extends MyCollection{ public void test(){ intg = 1; } } Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com EmoticonEmoticon
http://www.toontricks.com/2019/05/tutorial-java-protected-members.html
CC-MAIN-2019-22
refinedweb
721
52.39
Feature #13763open Trigger "unused variable warning" for unused variables in parameter lists Description Consider the following program nowa.rb: def foo(a) end %w(x).each {|y|} foo(1) z=5 If I syntax-check it with ruby -cw nowa.rb I get the following warning: nowa.rb:5: warning: assigned but unused variable - z Ruby complains about z, but does not complain about a and y, even though these are also variables which receive a value which never is used. I suggest to issue a warning in these cases too. Tested with: ruby 2.3.3p222 (2016-11-21 revision 56859) [x86_64-cygwin] Updated by Hanmac (Hans Mackowiak) almost 5 years ago i am against this, becauese such functions could be used as hookups too for other functions to overwrite them. like: def xyz do_something(temp) end def do_something(x) end then something else can overwrite do_something with something else and hook to the parameters ruby does something with functions like method_defined Updated by shevegen (Robert A. Heiler) almost 5 years ago I am indifferent, so neither pro or con. I can see both points, more warnings or "hints" and less warnings. There may be a practical reason to not change towards this as it may lead to many more warnings all of a sudden? I don't know, just mentioning it - I can be wrong here of course. I think we can all agree that most "forgotten" local variables will not have a big negative impact - like in the above example, the world will not end if variable "z" is not used. I think there was some other suggestion, by Jeremy Evans (or someone else), who pointed out something in regards to ruby issuing warnings. Since I do not remember it, I can not quote it but I think that one suggestion was to control or "fine tune" warnings, which I think should be possible. Perhaps ruby 3.x will have a warning-system that allows people more to customize it. A bit like rubocop, no? The default style guide of rubocop is not very useful to me, but you can customize the styles, and you can even let rubocop autocorrect code, which I think as an idea, is awesome. What I think should be possible, though, is for ruby hackers to have some more control over warnings issued in general, ideally even in a custom manner - like the above could perhaps be specified by Ronald Fischer and stored in some file, like irbrc, or some config parameter for your local ruby variant. And/or also as command-line switch like ... I don't know ... --use-excessive-warnings or --use-lots-of-nagging-warning-messages or something like that. :D Thing is that while hanmac's example is perfectly fine, we can also give counter-examples of code or accidental code or forgotten/partially refactored code where the situation by Ronald Fischer would be valid. Last but not least, and I shall finish this - while I think in general that it would be nice for ruby to have a better, more flexible and sophisticated warning system, I am not sure if there is a huge use case or need for the above scenario detailed by Ronald Fischer. Then again, with flexibility, it would not matter since you could easily create your own warning-triggering codes (one could even say this for errors, and then allow people to have ruby continue to work just fine, even when errors happen ... but this is perhaps too much flexibility even for ruby. I just envision some crazy schemes, all without having to use "rescue" clauses ... like embedding lisp code right into ruby and crazy stuff like this). Updated by marcandre (Marc-Andre Lafortune) over 4 years ago Hanmac (Hans Mackowiak) wrote: i am against this, becauese such functions could be used as hookups too for other functions to overwrite them. This is particularly true for named parameters, which can not be renamed with a leading underscore. FWIW, rubocop can detect those already, for any version of Ruby, and is customizable by the user. I feel that it's probably best to handle such cases at a higher level than MRI itself. Also available in: Atom PDF
https://bugs.ruby-lang.org/issues/13763
CC-MAIN-2022-21
refinedweb
704
60.55
has changed the release date of Java SE 9 from March 2017 to July 2017. Let us start this post now. Table of Contents. Java SE 8: “_” Changes In Java SE 8 release, using Underscore alone as an identifier is not recommended and it gives a WARNING message. To test it, write a simple Java program in any IDEs like Eclipse and run it. Example:- public class Java8UnderscoreTest { public static void main(String[] args) { int _ = 10; System.out.println("Value of underscore (_) = " + _); } } Output:- Value of underscore (_) = 10 It works fine without any issues. However, we can see the following warning messages in IDEs. Multiple jshell> int _ = 10 | Error: | as of release 9, '_' is a keyword, and may not be used as an identifier | int _ = 10 | ^ | Error: | reached end of file while parsing | int _ = 10 That’s it all about “Java SE 9: Underscore Changes”. We will discuss some more Java SE 9 New Features in my coming posts. Please drop me a comment if you like my post or have any issues/suggestions/type errors. Thank you for reading my tutorials. Happy Java SE 9 Learning! Very nice post…Short and simple…Necessary information provided without any BLA BLA… underscore is taken as keyword from java 9 onwards, why? I have written simple java program which will list down all files in your code base where underscore has been used as an identifier:
https://www.journaldev.com/13563/javase9-underscore-changes
CC-MAIN-2021-04
refinedweb
242
64.2
Those answers come off as somewhat insular or holier-than-thou. More than a few people I know factored the Python community's lack of nerdraging into their decision to learn it over Ruby. Not that you intended that, but some people might take it as such. I'd change a few answers. Forgive me if the answers are wrong, I'm a journeyman, not a master of Python. Here are my answers to the first four: A1. There are many reasons to make a language case-sensitive, not the least of which being that many (possibly even most) other languages are also case-sensitive. Case-sensitivity also encourages a sensible and consistent naming style. A2. Since Python's internals are standardizing on Unicode, strings are, by default, Unicode. The 'u' tag no longer has a purpose, and with the break in compatibility from 2.x to 3.0, now is the ideal time to remove it from the language. A3. There are many things that make languages faster or slower. It is often the case that the more flexibility a language gives you, the harder it is to optimize. C++ is fast because it is extremely explicit and much of its logic can be optimized and transformed into machine code at compile-time. Python, on the other hand, is much more dynamic, and allows the programmer a great deal of functionality at run-time. With respect to the lack of lambdas, this isn't entirely true. There are lambdas that aren't quite as useful as full functions, but Python also supports nested function definitions, and functions are first class. Anywhere a lambda can be used, a function can be used, and you can define these within a local scope. If most of this flew over your head, then take our word for it that Python is how it is to make it easier to quickly write solid code. It should also be noted that Python makes it easy to write C or C++ extensions, bypassing the overhead when speed is needed more than flexibility. A4. --- see A3 Andy Toulouse On Thu, Jun 19, 2008 at 1:54 PM, Charles Merriam <charles.merriam at gmail.com> wrote: > Hello Shandy, > > While there isn't a link, here are the frequent questions I see: > > Q1. Why is Python case-sensitive? That is, why is > 'bob_is_your_uncle" different from "Bob_is_your_uncle" and > "BobIsYourUncle"? > A1. Because Guido said so, it would be too much of a break with older > languages, and it encourages a consistent style. > > Q2. Why is Python moving to 3.0? Why is the 'u' tag breaking? Why > change? > A2. Languages evolve or die. The 'u' tag disappears because purists > like to write. > > Q3. Why isn't Python the same speed as C++, have lambdas like Lisp, > strong typing like Java, etc? > A3. Because it is Python. > > Q4. Why isn't Python faster? > A4. It's fast enough for almost everything, and links easily to C/C++ > code. It is aimed at quickly writing solid code. > > Q5. Why is Pep-8 hard to read? Why isn't rgruet's quick reference > guide part of the Python documentation? Why don't Python docs link to > sample code and a wiki? Why aren't usual "gotcha's" pointed out in > the Python documentation. > A5. Because you haven't rewritten the Python documentation. > > Q6. Why is Python so complicated and concise? > A7. Many common problems can be written concisely, so as to save > space. Python works on some consistent rules under the hood, like > linear execution within a namespace, which provides an understanding > of the concise syntax. > > Have fun! > > Charles Merriam > _______________________________________________ > Baypiggies mailing list > Baypiggies at python.org > To change your subscription options or unsubscribe: > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <>
https://mail.python.org/pipermail/baypiggies/2008-June/003507.html
CC-MAIN-2016-30
refinedweb
629
75.2
Java Defining, Instantiating, and Starting Threads Introduction One of the most appealing features in Java is the support for easy thread programming. Java provides built-in support for multithreaded programming. A multithreaded program contains two or more parts that can run concurrently. Each part of such a program is called a thread, and each thread defines a separate path of execution. Thus we can say that multithreading is a specialized form of multitasking. The formal definition of a thread is, A thread is a basic processing unit to which an operating system allocates processor time, and more than one thread can be executing code inside a process. A thread is sometimes called a lightweight process or an execution context Imagine an online ticket reservation application with a lot of complex capabilities. One of its functions is "search for train/flight tickets from source and destination" another is "check for prices and availability," and a third time-consuming operation is "ticket booking for multiple clients at a time". In a single-threaded runtime environment, these actions execute one after another. The next action can happen only when the previous one is finished. If a ticket booking takes 10 mins, then other users have to wait for their search operation or book operation. This kind of application will result into waste of time and clients. To avoid this kind of problems java provides multithreading features where multiple operations can take place simultaneously and faster response can be achieved for better user experience. Multithreading enables you to write very efficient programs that make maximum use of the CPU, because idle time can be kept to a minimum. Defining a Thread In the most general sense, you create a thread by instantiating an object of type Thread. Java defines two ways in which this can be accomplished: - You can implement the Runnable interface. - You can extend the Thread class implements a single method called run( ), which is declared like this: public void run( ) Inside run( ), you will define the code that constitutes the new thread. It is important to understand that run( ) can call other methods, use other classes, and declare variables, just like the main thread can. The only difference is that run( ) establishes the entry point for another, concurrent thread of execution within your program. This thread will end when run( ) returns. class MyRunnableThread implements Runnable { public void run() { System.out.println("Important job running in MyRunnableThread"); } } Extending java.lang.Thread The simplest way to define code to run in a separate thread is to - Extend the java.lang.Thread class. - Override the run() method. It looks like this: classMyThread extends Thread { public void run() { System.out.println("Important job running in MyThread"); } } The limitation with this approach (besides being a poor design choice in most cases) is that if you extend Thread, you can't extend anything else. And it's not as if you really need that inherited Thread class behavior because in order to use a thread you'll need to instantiate one anyway. Instantiating a Thread Remember, every thread of execution begins as an instance of class Thread. Regardless of whether your run() method is in a Thread subclass or a Runnable implementation class, you still need a Thread object to do the work. If you have approach two (extending Thread class): Instantiation would be simple MyThread thread = new MyThread(); If you implement Runnable, instantiation is only slightly less simple. To instantiate your Runnable class: MyRunnableThreadmyRunnable = new MyRunnableThread (); Thread thread = new Thread(myRunnable); // Pass your Runnable to the Thread Giving the same target to multiple threads means that several threads of execution will be running the very same job (and that the same job will be done multiple times). Thread Class Constructors - Thread() : Default constructor – To create thread with default name and priority - Thread(Runnable target) This constructor will createa thread from the runnable object. - Thread(Runnable target, String name) This constructor will create thread from runnable object with name as passed in the second argument - Thread(String name) This constructor will create a thread with the name as per argument passed. So now we've made a Thread instance, and it knows which run() method to call. But nothing is happening yet. At this point, all we've got is a plain old Java object of type Thread. It is not yet a thread of execution. To get an actual thread—a new call stack—we still have to start the thread. Starting a Thread You've created a Thread object and it knows its target (either the passed-inRunnable or itself if you extended class Thread). Now it's time to get the whole thread thing happening—to launch a new call stack. It's so simple it hardly deserves its own subheading: t.start(); Prior to calling start() on a Thread instance, the thread is said to be in the new state. There are various thread states which we will cover in next tutorial. When we call t.start() method following things happens: - A new thread of execution starts (with a new call stack). - The thread moves from the new state to the runnable state. - When the thread gets a chance to execute, its target run() method will run. The following example demonstrates what we've covered so far—defining, instantiating, and starting a thread: In below Java program we are not implementing thread communication or synchronization, because of that output may depend on operating system’s scheduling mechanism and JDK version. We are creating two threads t1 and t2 of MyRunnable class object. Starting both threads, each thread is printing thread name in the loop. Java Code ( MyRunnable.java ) package mythreading; public class MyRunnable implements Runnable{ @Override public void run() { for(int x =1; x < 10; x++) { System.out.println("MyRunnable running for Thread Name: " + Thread.currentThread().getName()); } } } Java Code ( TestMyRunnable.java ) package mythreading; public class TestMyRunnable { public static void main (String [] args) { MyRunnable myrunnable = new MyRunnable(); //Passing myrunnable object to Thread class constructor Thread t1 = new Thread(myrunnable); t1.setName("Amit-1 Thread"); //Starting Thread t1 t1.start(); Thread t2 = new Thread(myrunnable); t2.setName("Amit-2 Thread"); t2.start(); } } Output: Summary: - Threads can be created by extending Thread and overriding the public void run() method - Thread objects can also be created by calling the Thread constructor that takes a Runnable argument. The Runnable object is said to be the target of the thread. - You can call start() on a Thread object only once. If start() is called more than once on a Thread object, it will throw a Runtime Exception. - Each thread has its own call stack which is storing state of thread execution - When a Thread object is created, it does not become a thread of execution until its start() method is invoked. When a Thread object exists but hasn't been started, it is in the new state and is not considered alive. Java Code Editor: Previous: Java Utility Class Next: Java Thread States and
https://www.w3resource.com/java-tutorial/java-defining-instantiating-and-starting-threads.php
CC-MAIN-2020-45
refinedweb
1,165
62.58
Introduction: Raspberry Pi RFID Triggered Email I've never worked with an RFID reader before so had no idea how this was going to go. As usual though, someone else had done it and so the individual elements were easy enough - getting it all to work together was a bit of a struggle but it's been a great learning experience for me! This project is can become a part of someone else's work. What I've done is gotten an RFID reader to scan an RFID card, then trigger the Pi camera to take an image and finally email that image. It could form part of a wider access set up to open a lock or something. I haven't gone that far as I've no real need to - I just wanted to figure out how to do something with the few bits I had on hand at the time! Step 1: Here's the Bits You'll Need for the Project.... Parallax RFID reader - I'm sure there is code out there for others. Or indeed the code below might work for a different one. I can't tell you that as this is the first time I've tried anything with them! I understand these are available with and without an FTDI chip. This one has it's own on board and from working with other things that require an FTDI cable, it's always seemed simpler to me to buy the components that have the FTDI chip on board. RFID card - which comes with the reader. Raspberry Pi - I have no doubt that this will work with pretty much any RPi - mine is an RPi 2 model B. SD Card with Raspbian installed. Raspberry Pi camera module. Usb mini cable - for the RFID reader. Step 2: Preparation... If you've used the RPi camera module before you've most likely enabled it. If not, Open a terminal and type: sudo raspi-config and move down to "Enable Camera". When prompted, select "YES" to enable the camera module. This will take you back to the raspi-config menu at which you can use the TAB key to go to "FINISH". The RPi will ask if you want to reboot now - select NO. This is because we need to connect everything up now before restarting and so we need to shut down instead. To shutdown type the following into the terminal: sudo shutdown -h now Once shutdown you can connect the RFID scanner by USB to the Raspberry Pi. Also connect the RPi camera module. Now you can boot the Pi up again. For the RPi to communicate with the RFID reader you'll need to install a few bits. Open up the terminal on your RPi & at the $ prompt: sudo pip install pyserial Then "Enter" - if you get asked to confirm, just select "Y". You'll also need to install this: sudo apt-get install sqlite3 Once both of these are installed you're ready to create your python files to handle the jobs. Step 3: The Code for Sending Email With Attachment... I like to create a specific folder to separate projects. To create a folder type into the terminal: mkdir yourfoldername Then to move to that folder and create your python files: cd yourfoldername Note: You'll be creating 2 different python files. They kind of depend on each other to some extent so there's not much point in running one untill they are both created. Let's first create the 2 files and then go over what they're doing. You're in the folder you created you can create the files: sudo nano rf-img-mail.py Now copy and paste the following code into terminal (I've highlighted bits you need to or can change): #! = "YOURUSERNAME" # you'll need your own gmail username in here PASSWORD = "YOURPASSWORD" #you'll need your gmail password here') #this is for communicating through gmail. I've no idea about other mail handlers! server.ehlo_or_helo_if_needed() server.starttls() server.ehlo_or_helo_if_needed() server.login(USERNAME,PASSWORD) server.sendmail(USERNAME, to, msg.as_string()) server.quit() sendMail( ["YOUR.EMAIL@gmail.com"], #change to match the receiver's email address "RFID Access Notification", #Your subject line which can suit your project "Someome has accessed your RFID lock, picture attached", #The body text of the email ["/home/pi/rf-parallax/rfid.jpg"] ) #the location of the image that will be taken - you'll need to change this to suit the directory name you've created. Once you've copied and edited the necessary bits above, press CTRL + X and answer Y then ENTER a couple of times to save the file. CREDIT where it's due: This is code from where it's triggered instead by a doorbell. Step 4: Creating the RFID Reading Trigger File... This file will be the one we actually run. It will listen for a card to be presented to the RFID reader then trigger the camera. Once the image is taken it will then call the previous python file to send the image as an attachment to your email. In terminal: sudo nano rf-read.py And copy in the following contents: #! /usr/bin/python import serial import time import sqlite3 import os # = "" print("Present RFID tag")() # take an image on presentation of rfid tag print("Taking RFID image - remain still while camera led is on") os.system("raspistill -w 640 -h 480 -o rfid.jpg") #this is a REALLY handy feature in Python. No matter what you want to run you can place commands between the quotes in the same way you can run things from the command line. So for taking a picture like here, you can add in all the options available to raspistill. tagid = tagid.strip() timestamp = time.time() cursor.execute("INSERT INTO tagreads VALUES (?,?);", (timestamp, tagid)) db.commit() print("Time:%s, Tag:%s" % (timestamp,tagid)) # The actual mail send is completed in a seperate python script located within the same folder os.system("python rf-img-mail.py") #Again, using that time.sleep(.5) port.open() print("Present RFID tag") lastid = tagid except KeyboardInterrupt: port.close() db.commit() db.close() print ("Program interrupted") Again once you've copied and edited the necessary bits above, press CTRL + X and answer Y then ENTER a couple of times to save the file. CREDIT where's its due: I got the vast majority of this code from here - Step 5: Running It All Together.... Here's your moment of truth - and if you've gotten your email details correct then I'd expect this should work for you straight away. Any time you want to run this, just open a terminal and navigate to the location of the 2 python files. cd thatdirectoryyoucreatedatthestart python rf-read.py One image is an example of how it should all react on starting and when presenting the RFID card. It won't look the same as yours as I'm using my Ubuntu laptop to ssh to the RPi. I've also got a different filename - which is pretty much irrelevant! The other image is the email that the recipient will get. Enjoy! Be the First to Share Recommendations 2 Discussions 8 months ago hi bro, do you have demo? Question 1 year ago on Step 3 Hi Tony. I have happened upon your rpi RFID to email with an attached image and would love to see it work for me but I am having issues. Can I ask should I be using a particular ver of python as when I run the file it reports many, many syntax errors and needs indents to work. I love the idea and imagine the hours you have put in. Cheers. Phil
https://www.instructables.com/Raspberry-Pi-RFID-Triggered-Email/
CC-MAIN-2020-50
refinedweb
1,293
72.46
The HBase Handler allows you to populate HBase tables from existing Oracle GoldenGate supported sources. Topics: HBase is an open source Big Data application that emulates much of the functionality of a relational database management system (RDBMS). Hadoop is specifically designed to store large amounts of unstructured data. Conversely, data stored in databases and being replicated through Oracle GoldenGate is highly structured. HBase provides a method of maintaining the important structure of data, while taking advantage of the horizontal scaling that is offered by the Hadoop Distributed File System (HDFS). The HBase Handler takes operations from the source trail file and creates corresponding tables in HBase, and then loads change capture data into those tables. HBase Table Names Table names created in an HBase map to the corresponding table name of the operation from the source trail file. It is case-sensitive. HBase Table Namespace For two part table names (schema name and table name), the schema name maps to the HBase table namespace. For a three part table name like Catalog.Schema.MyTable, the create HBase namespace would be Catalog_Schema. HBase table namespaces are case sensitive. A NULL schema name is supported and maps to the default HBase namespace. HBase Row Key HBase has a similar concept of the database primary keys called the HBase row key. The HBase row key is the unique identifier for a table row. HBase only supports a single row key per row and it cannot be empty or NULL. The HBase Handler maps the primary key value into the HBase row key value. If the source table has multiple primary keys, then the primary key values are concatenated, separated by a pipe delimiter ( |).You can configure the HBase row key delimiter. The source table must have at least one primary key column. Replication of a table without a primary key causes the HBase Handler to abend. HBase Column Family HBase has the concept of a column family. A column family is a grouping mechanism for column data. Only a single column family is supported. Every HBase column must belong to a single column family. The HBase Handler provides a single column family per table that defaults to cf. The column family name is configurable by you. However, once a table is created with a specific column family name, reconfiguration of the column family name in the HBase example without first modify or dropping the table results in an abend of the Oracle GoldenGate Replicat processes. Instructions for configuring the HBase Handler components and running the handler are described in this section. HBase must be up and running either collocated with the HBase Handler process or on a machine that is network connectable from the machine hosting the HBase Handler process. The underlying HDFS single instance or clustered instance serving as the repository for HBase data must be up and running. Topics: You must include two things in the gg.classpath configuration variable in order for the HBase Handler to connect to HBase and stream data. The first is the hbase-site.xml file and the second are the HBase client jars. The HBase client jars must match the version of HBase to which the HBase Handler is connecting. The HBase client jars are not shipped with the Oracle GoldenGate for Big Data product. HBase Handler Client Dependencies includes the listing of required HBase client jars by version. The default location of the hbase-site.xml file is HBase_Home /conf. The default location of the HBase client JARs is HBase_Home /lib/*. If the HBase Handler is running on Windows, follow the Windows classpathing syntax. The gg.classpath must be configured exactly as described. Pathing to the hbase-site.xml should simply contain the path with no wild card appended. The inclusion of the * wildcard in the path to the hbase-site.xml file will cause it not to be accessible. Conversely, pathing to the dependency jars should include the * wild card character in order to include all of the jar files in that directory in the associated classpath. Do not use *.jar. An example of a correctly configured gg.classpath variable is the following: gg.classpath=/var/lib/hbase/lib/*:/var/lib/hbase/conf The following are the configurable values for the HBase Handler. These properties are located in the Java Adapter properties file (not in the Replicat properties file). Table 5-1 HBase Handler Configuration Properties Footnote 1 For more Java information, see Java Internalization Support at. The following is a sample configuration for the HBase Handler from the Java Adapter properties file: gg.handlerlist=hbase gg.handler.hbase.type=hbase gg.handler.hbase.mode=tx gg.handler.hbase.hBaseColumnFamilyName=cf gg.handler.hbase.includeTokens=true At each transaction commit, the HBase Handler performs a flush call to flush any buffered data to the HBase region server. This must be done to maintain write durability. Flushing to the HBase region server is an expensive call and performance can be greatly improved by using the Replicat GROUPTRANSOPS parameter to group multiple smaller transactions in the source trail file into a larger single transaction applied to HBase. You can use Replicat base-batching by adding the configuration syntax in the Replicat configuration file. Operations from multiple transactions are grouped together into a larger transaction, and it is only at the end of the grouped transaction that transaction commit is executed. HBase connectivity can be secured using Kerberos authentication. Follow the associated documentation for the HBase release to secure the HBase cluster. The HBase Handler can connect to Kerberos secured cluster. The HBase hbase-site.xml should be in handlers classpath with the hbase.security.authentication property set to kerberos and hbase.security.authorization property set to true. Additionally, you must set the following properties in the HBase Handler Java configuration file: gg.handler.{name}.authType=kerberos gg.handler.{name}.keberosPrincipalName={legal Kerberos principal name} gg.handler.{name}.kerberosKeytabFile={path to a keytab file that contains the password for the Kerberos principal so that the Oracle GoldenGate HDFS handler can programmatically perform the Kerberos kinit operations to obtain a Kerberos ticket}. Oracle GoldenGate 12.2 includes metadata in trail and can handle metadata change events at runtime. The HBase Handler can handle metadata change events at runtime as well. One of the most common scenarios is the addition of a new column. The result in HBase will be that the new column and its associated data will begin being streamed to HBase after the metadata change event. It is important to understand that in order to enable metadata change events the entire Replication chain must be upgraded to Oracle GoldenGate 12.2. The 12.2 HBase Handler can work with trail files produced by Oracle GoldenGate 12.1 and greater. However, these trail files do not include metadata in trail and therefore metadata change events cannot be handled at runtime. HBase has been experiencing changes to the client interface in the last few releases. HBase 1.0.0 introduced a new recommended client interface and the 12.2 HBase Handler has moved to the new interface to keep abreast of the most current changes. However, this does create a backward compatibility issue. The HBase Handler is not compatible with HBase versions older than 1.0.0. If an Oracle GoldenGate integration is required with 0.99.x or older version of HBase, this can be accomplished using the 12.1.2.1.x HBase Handler. Contact Oracle Support to obtain a ZIP file of the 12.1.2.1.x HBase Handler. Common errors on the initial setup of the HBase Handler are classpath issues. The typical indicator is occurrences of the ClassNotFoundException in the Java log4j log file. The HBase client JARS do not ship with the Oracle GoldenGate for Big Data product. You must resolve the required HBase client JARS. HBase Handler Client Dependencies includes the listing of HBase client JARS for each supported version. Either the hbase-site.xml or one or more of the required client JARS are not included in the classpath. For instructions on configuring the classpath of the HBase Handler, see Classpath Configuration. Troubleshooting of the HBase Handler begins with the contents for the Java log4j file. Follow the directions in the Java Logging Configuration to configure the runtime to correctly generate the Java log4j log file. Topics: Issues with the Java classpath are one of the most common problems. An indication of a. You can make sure that all of the required dependency jars are resolved by enabling DEBUG level logging, and then search the log file for messages like the following: 2015-09-29 13:04:26 DEBUG ConfigClassPath:74 - ...adding to classpath: url="file:/ggwork/hbase/hbase-1.0.1.1/lib/hbase-server-1.0.1.1.jar" The contents of the HDFS hbase-site.xml file (including default settings) are output to the Java log4j log file when the logging level is set to DEBUG or TRACE. It shows the connection properties to HBase. Search for the following in the Java log4j log file. 2015-09-29 13:04:27 DEBUG HBaseWriter:449 - Begin - HBase configuration object contents for connection troubleshooting. Key: [hbase.auth.token.max.lifetime] Value: [604800000]. A common error is for the hbase-site.xml file to be either not included in the classpath or a pathing error to the hbase-site.xml. In this case the HBase Handler will not be able to establish a connection to HBase and the Oracle GoldenGate process will abend. The following error will be reported in the Java log4j log. 2015-09-29 12:49:29 ERROR HBaseHandler:207 - Failed to initialize the HBase handler. org.apache.hadoop.hbase.ZooKeeperConnectionException: Can't connect to ZooKeeper Verify that the classpath correctly includes the hbase-site.xml file and that HBase is running. The Java log4j log file contains information on the configuration state of the HBase Handler. This information is output at the INFO log level. Sample output is as follows: 2015-09-29 12:45:53 INFO HBaseHandler:194 - **** Begin HBase Handler - Configuration Summary **** Mode of operation is set to tx. HBase data will be encoded using the native system encoding. In the event of a primary key update, the HBase Handler will ABEND. HBase column data will use the column family name [cf]. The HBase Handler will not include tokens in the HBase data. The HBase Handler has been configured to use [=] as the delimiter between keys and values. The HBase Handler has been configured to use [,] as the delimiter between key values pairs. The HBase Handler has been configured to output [NULL] for null values. Hbase Handler Authentication type has been configured to use [none] If you are using the HBase Handler gg.handler.name.setHBaseOperationTimestamp configuration property, the source database may get out of sync with data in the HBase Handler tables. This is caused by the deletion of a row followed by the immediate reinsertion of the row. HBase creates a tombstone marker for the delete that is identified by a specific timestamp. This tombstone marker marks any row records in HBase with the same row key as deleted that have a timestamp before or the same as the tombstone marker. This can occur when the deleted row is immediately reinserted. The insert operation can inadvertently have the same timestamp as the delete operation so the delete operation causes the subsequent insert operation to incorrectly appear as deleted. To work around this issue, you need to set the gg.handler.name.setHbaseOperationTimestamp= to true, which does two things: Sets the timestamp for row operations in the HBase Handler. Detection of a delete-insert operation that ensures that the insert operation has a timestamp that is after the insert. The default for gg.handler.name.setHbaseOperationTimestamp is false, which means that the HBase server supplies the timestamp for a row. This can cause the out of sync problem. Setting the row operation timestamp in the HBase Handler can have these consequences: Since the timestamp is set on the client side, this could create problems if multiple applications are feeding data to the same HBase table. If delete and reinsert is a common pattern in your use case, then the HBase Handler has to increment the timestamp 1 millisecond each time this scenario is encountered. Processing cannot be allowed to get too far into the future so the HBase Handler only allows the timestamp to increment 100 milliseconds into the future before it attempts to wait the process so that the client side HBase operation timestamp and real time are back in sync. When a delete-insert is used instead of an update in the source database so this sync scenario would be quite common. Processing speeds may be affected by not allowing the HBase timestamp to go over 100 milliseconds into the future if this scenario is common. The Cloudera CDH has moved to HBase 1.0.0 in the CDH 5.4.0 version. To keep reverse compatibility with HBase 0.98.x and before, the HBase client in the CDH broke the binary compatibility with Apache HBase 1.0.0. This created a compatibility problem for the HBase Handler when connecting to Cloudera CDH HBase for CDH versions 5.4 - 5.11. You may have been advised to solve this problem by using the old 0.98 HBase interface and setting the following configuration parameter: gg.handler.name.hBase98Compatible=true This compatibility problem is solved using Java Refection. If you are using the HBase Handler to connect to CDH 5.4x, then you should changed the HBase Handler configuration property to the following: gg.handler.name.hBase98Compatible=false Optionally, you can omit the property entirely because the default value is false.
http://docs.oracle.com/goldengate/bd123110/gg-bd/GADBD/using-hbase-handler.htm
CC-MAIN-2017-43
refinedweb
2,292
57.57
Practical .NET You don't have to give up on creating dynamic queries just because you're using Entity Framework. Entity SQL and ObjectQuery will let you generate queries at runtime and still let you update your data through Entity Framework. There was a time, before LINQ and Entity Framework, when developers concatenated SQL statements together and passed them to ADO.NET to be executed. This was a more flexible system than LINQ with EF because it let you generate a query at runtime from the user's input. LINQ and EF do take that flexibility away (and give, in return, object-oriented data access, compile-time syntax checking, automatically generated updates and IntelliSense support). But LINQ isn't the only way to leverage Entity Framework: You can also use Entity SQL (eSQL), which will let you generate queries at runtime while still giving you object-oriented data access through your EF model and automatic updates through the EF SaveChanges method. You do have to give up compile-time checking of your queries, though. In an earlier column, I looked at using plain old SQL with EF -- an excellent solution if you want to customize the objects you retrieve and don't need to do updates. However, if you're willing to learn eSQL you can get that updating capability back. The good news is that eSQL looks very much like plain old SQL. Creating a Query To issue an eSQL query you need to access your database through the ObjectContext object. The issue here is, if you're using a current version of Entity Framework, then you're almost certainly accessing your database through the DbContext object. Your first step, therefore, is to retrieve the ObjectContext that's inside your DbContext object. Here's the code to do that in Visual Basic (AdventureWorksLTEntities is my DbContextObject): Dim db As New AdventureWorksLTEntities Dim oc As ObjectContext oc = CType(db, IObjectContextAdapter).ObjectContext The equivalent C# code looks like this: AdventureWorksLTEntities db = new AdventureWorksLTEntities(); ObjectContext oc; oc = ((IObjectContextAdapter) db).ObjectContext If you're having compile-time errors with this code make sure you have an Imports or using statement for the System.Data.Entity.Core.Objects namespace (and remove any Imports or using statements for System.Data.Objects). The next step is to create an ObjectQuery object tied to an entity in your EF model (in my sample code, I work with Customer entities from the AdventureWorks database). When you create the ObjectQuery, you must pass it the string containing your eSQL statement, the ObjectContext you've retrieved from the DbContext object and, optionally, a merge option (see "Merge Options" at the end of this article for a discussion of the merge options). Creating the ObjectQuery is, by the way, the only time you'll need to use the ObjectContext. In this example, I'm using the OverwriteChanges option to create an ObjectQuery: Dim sCusts As ObjectQuery(Of Customer) Dim sql As String sql = "Select Value cust " & " From AdventureWorksLTEntities.Customers AS cust " & " Where cust.LastName = 'Gee'" sCusts = New ObjectQuery(Of Customer)(sql, oc, MergeOption.OverwriteChanges) Using the ObjectQuery Results With the ObjectQuery created, you're ready to retrieve your entities. The first step is to open a connection to the database using the original DbContext object. Once you've opened the connection, you can process the results in your ObjectQuery as if they came from a LINQ statement. If you make changes to those entities, you can call the SaveChanges method on your DbContext object to send the changes back to your database. This code, for example, corrects the customers' last name and then saves the resulting changes: db.Database.Connection.Open() For Each c As Customer In sCusts c.LastName = "Bee" db.SaveChanges() There are four MergeOptions you can use with an ObjectQuery. The NoTracking option is different from the rest: It causes EF to ignore any changes you make to the retrieved entities (that is, when you call SaveChanges, any changes you've made to the entities retrieved with the ObjectQuery will not be sent to the database). The other three MergeOptions control how the entity objects you retrieve with eSQL will affect any entities you've already retrieved: The default setting is AppendOnly, but I prefer PreserveChanges: I get the latest values from the database, but I don't lose any changes I've made elsewhere in my code. You can use an ObjectQuery almost everywhere you would use the results of a LINQ query. This example applies a LINQ statement to the ObjectQuery's results and uses the output to set the DataSource property on a grid: gView.DataSource = From c In sCusts Where c.FirstName = "Ben" Select c Obviously, eSQL looks very much like plain old SQL with Select, From and Where clauses. The From clause is slightly different than what you would find in SQL because, instead of referencing tables in your database, the clause references the EF model with its collections. The Select clause looks different because it contains that Value keyword (I'm using that to convert the default return type of an eSQL statement, a DbDataRecord, into a Customer object to use in my code). But other than those two differences, if you know SQL then you know this eSQL statement. There's more flexibility in eSQL than I've suggested here: I'm not obliged to return a whole Entity, for example, and I can use eSQL against any collection, not just EF (I'll look at some of that flexibility in a later column). However, when you need to dynamically construct updateable queries at runtime -- and are willing to learn a slightly different query language -- then eSQL could be your
https://visualstudiomagazine.com/articles/2015/03/01/dynamic-queries.aspx
CC-MAIN-2020-29
refinedweb
949
50.36
2020 Setting up React Navigation in a new git repo Skyler Dowdy ・9 min read Prerequisites System Requirements: - Computer Running Linux Debian / Ubuntu (Preferred), Windows 7 or Later, MacOS X or Later Programs Requirements: Node.js along with NPM/NPX and Chocolatey - More information can be found at A Text Editor VS Code or Atom Preferred - I am going to be using VS Code and utilizing the Shortcuts for VS code - You Can use anything from Acme to Zile (I have no Idea what either of these text editors are) If using VSCode these are the plugins I will be using you can also find them for Atom as well a. ES7 React/Redux/GraphQL/React-Native snippets b. Prettier - Code Formatter c. Turbo Console Log d. I use FiraCode font with ligatures enabled (that is how the => sign connects itself) Terminal Access (GitBash if you are using Windows) a. When installing be sure to select the correct text editor DO NOT SELECT VIM UNLESS YOU KNOW WHAT YOU ARE DOING! Basic Knowledge of HTML, CSS, and JavaScript Github Account connected either Https or SSL MY RANT: Linux Debian or Ubuntu with the Budgie or Mate desktop is what I reccommend that all programmers use. Unless, you are developing strictly for Apple products. Why? Speed, Performance, OpenSource, lack of bloatware... I could go on forever. It is however a personal preference and it does take some learning but, once you are used to it you will never want to use Windows Again... I have a PC with Windows on it and I rarely even turn it on because the only thing I cannot do on my Linux machine that I can on my Windows is play certain games... If you plan on developing for Apple products (swift) then a Mac is 100% the way to go. WINDOWS IS NEVER THE WAY TO GO Step 1 Creating a Git Repo, Creating the React Application, and Pushing to the Repo. This step just walks through the basics of creating a react application. If this does not work for you please make sure that you have checked all of the Create a new Git Repository ** NO README ** Open a Terminal (GitBash if you are using windows) Create the React App a. npx create-react-app <react-tutorial-app> Change to the newly created directory a. cd <react-tutorial-app> Paste in the commands from github Change to a new branch a. git checkout -b <Tutorial1-Create-React-App-Nav> Install React Router a. npm i react-router react-router-dom Start your React App a. npm start You should now see your React App running in your browser. If not open it and navigate to "localhost:3000" Navigate to your terminal and stop the application a. ctrl + c Step 2 Creating a folder structure and adding some base files. All good applications need organization. If your app is not organized when it gets larger it makes it very hard to find things so, we are going to go ahead and setup the file structure now. If we setup our file structure while the application is small it makes it easier to tweak if we need to as the application grows. There is no right or wrong way to organize your files and you can do it any way that you please. Once you find a way that you like you can write a BASH script that will do all of the work for you. The things you need for this tutorial are jsx files named Header Navbar Footer AppRouter Home and About you can create them any way you would like to. This is how I do it: Assuming you are coming from Step 1 and are in the root directory of your newly created app e.g. /home// Change into the "src" directory a. cd src Create your folders a. mkdir -p configs components/pages components/forms pages/user pages/admin sources/images sources/raw_images styles/components styles/pages styles/forms The -p tells it to create the parent directory if it does not exist I use components/for things like my Header, Footer, NavBar, forms, etc I use pages to hold the main pages either user or admin I use sources/images to hold all the images displayed on the site I use sources/raw_images to hold all of the photoshop or gimp files I use styles to hold all of the styling Create your files a. cd configs b. touch AppRouter.jsx c. cd ../components/pages d. touch Header.jsx Footer.jsx e. cd [.]()./ f. touch NavBar.jsx g. cd ../pages/user h. touch Home.jsx About.jsx i. cd ../../styles/pages j. touch MainPage.css k. cd ../components l. touch NavBar.css m. cd ../../../ Add the changes to git a. git add . Commit the changes a. git commit b. enter a commit message c. ctrl +x d. y e. enter Set the upstream and push the changes a. git push -u origin Tutorial1-Create-React-App-Nav Step 3 Setting up the files In this step we are just going through and creating empty arrow functions for all of our newly created files. Once you get a structure setup that you like you can also automate this with a script as well. This is where those VS code extensions will come in handy! Assuming you are coming from Step 2 and are in the root directory of your newly created app e.g. /home// Open your text editor of choice I am using VS Code (one of the few good things to come from Microsoft) a. code . Open each one of the newly created files in your text editor a. |rafce| (Creates a react arrow function default exported) - It should produce something in each one of your files that looks like example 1 at the bottom of the file - If |rafce| did not work: - Check that you have ES7 React/Redux/GraphQL/React-Native snippets installed in vs code and restart VS Code - Check that you named the file with the .jsx extension - Check that the Language Mode is "JavaScript React" in the bottom right hand corner of VS Code. - You can also copy the example 1 code click on "FileNameHere" and press ctrl + dtwice. It will highlight both instances and you can just rename it to the name of the file. Open a terminal in VS Code Start the React Server Again a. npm start Step 4 Setting up React-Router In this step we are setting up the routing for the application. A few things to note: *BrowserRouter must be wrapped at the highest possible level in the application but, this is not the only place that you can wrap BrowserRouter. You can also do it in your App.js file if you prefer *You do not have to use "Switch." *What is Switch? It is the same thing as a Switch statement in JS with reference to what place the path is in. For example if I were to Route Path to "/" and "about" without an exact or switch it would render both pages; first the home then the about right under it. You do not have to use "exact" when using Switch but, it is safer to do so in most use cases. Open index.js and import BrowserRouter from react-router-dom I rename it using "as" a. |imd| (import destructured) b. import { BrowserRouter as BR } from 'react-router-dom' Put a "<BR>" tag before "<App />" Put a "</BR>" tag after "<App />" Your index.js file should now look like example 2 Open your AppRouter file and Import Switch and Route from react-router-dom a. imd b. import { Switch as S, Route as R } from 'react-router-dom'; Import your Home and About pages a. import Home from '../pages/user/Home.jsx; b. import About from '../pages/user/About.jsx; Replace the "<Div>" tags with "<S>" a. Select the first div tag and press ctrl +dtwice then type S Add an exact route to the Home page and a non-exact route to the About page a. <R exact path='/' component={Home} /> b. <R path='/about/' component={About} /> Step 5 Setting up Navigation When setting up Navigation in a react app you want to use NavLink or Link instead of anchor tags. Since React applications are "Single Page Applications" meaning that it is run out of a single index.html file, you do not want to use anchor tags becuase this will cause the app to reload everytime someone clikcs a link therefore the app would lose any state that it is holding on to. The only time you want to use anchor tags when developing a react application are to link to an external site or email address. *NavLink is just an anchor tag that will have an active class when clicked. - Usually used in nav bars *Link is just an anchor tag it will not have an active class attached to it. - Usually Used on pages Open your Home and About pages and add in an <h1>that says ___ Page Works a. <h1>___ Page Works Open your NavBar file and import NavLink from react-router-dom a. imd b. import { NavLink as NL } from 'react-router-dom'; Create NavLinks to your Home and About Pages a. <NL exactHome</NL> b. <NL to='/about'>About</NL> Your NavBar File Should look like example 4 In your Header.jsx file import NavBar and render it between thetags a. import NavBar from '../NavBar';b. <div> <NavBar /> </div> Your Header file should look like example 5 Add a footer if you would like you can see mine in example 6 Open your App.js file and import Header, AppRouter, and Footer a. import Header from './components/pages/Header.jsx'; b. import Footer from './components/pages/Footer.jsx'; c. import AppRouter from './configs/AppRouter.jsx'; Between your app div render the above pages a. <div className='App'> <Header /> <AppRouter /> <Footer /> </div> Your App.js file should look like example 7 In your browser you should now see: a. NavLinks for Home and About b. ___ Page Works by pressing c. Your Footer. Step 6 Tying it all together Examples Example 1 - React Arrow Function import React from "react"; const YourFileNameHere = () => { return ( <div> </div> ); }; export default YourFileNameHere; Example 2 - Index.js After BrowserRouter Import import React from 'react'; import ReactDOM from 'react-dom'; import './index.css'; import App from './App'; import * as serviceWorker from './serviceWorker'; import { BrowserRouter as BR } from 'react-router-dom' ReactDOM.render( <BR> <App /> </BR> , document.getElementById('root')); // If you want your app to work offline and load faster, you can change // unregister() to register() below. Note this comes with some pitfalls. //* Learn more about service workers: https:*bit.ly/CRA-PWA serviceWorker.unregister(); Example 3 - AppRouter.jsx import React from "react"; import { Route as R, Switch as S } from "react-router-dom"; import Home from "../pages/user/Home.jsx"; import About from "../pages/user/About.jsx"; const AppRouter = () => { return ( <S> <R exact path="/" component={Home} /> <R path="/about" component={About} /> </S> ); }; export default AppRouter; Example 4 - NavBar.jsx import React from "react"; import { NavLink as NL } from "react-router-dom"; const NavBar = () => { return ( <div> <NL exactHome</NL> <NL to="/about">About</NL> </div> ); }; Example 5 - Header.jsx import React from "react"; import NavBar from "../NavBar.jsx"; const Header = () => { return ( <div> <NavBar /> </div> ); }; export default Header; Example 6 - Footer.jsx import React from "react"; const Footer = () => { return ( <div> <p>©2020 SkylerWebDev</p> </div> ); }; export default Footer; Example 7 - App.js import React from "react"; import "./App.css"; import AppRouter from "./configs/AppRouter.jsx"; import Header from "./components/pages/Header.jsx"; import Footer from "./components/pages/Footer.jsx"; const App = () =>{ return ( <div className="App"> <Header /> <AppRouter /> <Footer /> </div> ); } export default App; Know Not Only Your Weaknesses, But Strengths as Well Most people want to develop self-awareness. Whether we are managers, entrepreneurs, or aspiring software engineers, the more knowledge we have of our strength and weaknesses, the easier life becomes.
https://dev.to/skylerwebdev/2020-setting-up-react-navigation-with-git-1ac8
CC-MAIN-2020-16
refinedweb
2,007
72.16
Contents - Abstract - PEP Deferral - Background - Proposal - Key Benefits - __init_class__ hook in the class body. The new mechanism is also much easier to understand and use than implementing a custom metaclass, and thus should provide a gentler introduction to the full power Python's metaclass machinery. PEP Deferral Deferred until 3.5 at the earliest. The last review raised a few interesting points that I (Nick) need to consider further before proposing it for inclusion, and that's not going to happen in the 3.4 timeframe. class initialisation hook, modelled directly on the existing instance initialisation hook, but with the signature constrained to match that of an ordinary class decorator. Specifically, it is proposed that class definitions be able to provide a class initialisation hook as follows: class Example: def __init_class__(cls): # This is invoked after the class is created, but before any # explicit decorators are called # The usual super() mechanisms are used to correctly support # multiple inheritance. The class decorator style signature helps # ensure that invoking the parent class is as simple as possible. If present on the created object, this new hook will be called by the class creation machinery after the __class__ reference has been initialised. For types.new_class(), it will be called as the last step before returning the created class object. __init_class__ is implicitly converted to a class method when the class is created (prior to the hook being invoked). If a metaclass wishes to block class initialisation for some reason, it must arrange for cls.__init_class__ to trigger AttributeError. Note, that when __init_class__ __init_class__ class initialisation __init_class__ __init_class__, __init_class__ instead. For more advanced use cases, introduction of an explicit metaclass (possibly made available as a required base class) will still be necessary in order to support Python 3. __init_class__ from type.__init__ Calling the new hook automatically from type.__init__, would achieve most of the goals of this PEP. However, using that approach would mean that __init_class__ implementations would be unable to call any methods that relied on the __class__ reference (or used the zero-argument form of super()), and could not make use of those features themselves. Requiring an explict decorator on __init_class__ Originally, this PEP required the explicit use of @classmethod on the __init_class__ __init_class__ has been posted to the issue tracker [4]. It does not yet include the new namespace parameter for type.__prepare__. TODO - address the 5 points in
http://legacy.python.org/dev/peps/pep-0422/
CC-MAIN-2014-15
refinedweb
399
53.61
Question: Splint gives me the following warning: encrypt.c:4:8: Function exported but not used outside encrypt: flip A declaration is exported, but not used outside this module. Declaration can use static qualifier. (Use -exportlocal to inhibit warning) encrypt.c:10:1: Definition of flip Since I called splint only on this file how does it know that? #include <stdio.h> #include <stdlib.h> int flip( int a) { int b; b = a; b ^= 0x000C; return b; } int blah(int argc, char *argv[]) { FILE *fp = NULL, *fpOut=NULL; int ch; ch = 20; flip(20); return (ERROR_SUCCESS); } I even got rid of main so that it could not figure out that the file is complete in any way. I am totally stumped! Solution:1 You might find that if you included a header that declared flip() - as you should, of course - then splint would not complain. You should also declare blah() in the header as well. I'm not wholly convinced that this is the explanation because blah() is not used at all (though it uses flip()) and you don't mention splint complaining about that. However, it is a good practice to make every function (in C) static until you can demonstrate that it is needed outside its source file, and then you ensure that there is a header that declares the function, and that header is used in the file that defines the function and in every file that uses the function. In C++, the 'every function should be static' advice becomes 'every function should be defined in the anonymous namespace'. Solution:2 Since I called splint only on this file how does it know that? You have answered your question. You've fed in one file to lint, so lint knows there is only file to be taken care of (apart from the standard header includes, of course). Solution:3 int flip() is not declared as static, so it can be potentially used externally. Since you invoked splint with only one source file, it correctly says that your function, if not used externally, must be declared static Solution:4 It can only report on what it sees. Ignore the warning or follow the instructions to inhibit it if you know better than what it says. Don't assume that a tool like this necessarily knows your program better than you do. If it really is not intended to be used outside of the file, you can declare it static and it should correct the problem, but it will be inaccessible from other files. Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com EmoticonEmoticon
http://www.toontricks.com/2018/05/tutorial-how-does-splint-know-my.html
CC-MAIN-2018-47
refinedweb
445
68.91
--- a/doc/old/menus.txt +++ b/doc/plugins.txt @@ -1,107 +1,216 @@ -JEDIT MENU CONFIGURATION +JEDIT PLUGINS (plugins.txt, last modified 1 Oct 1998) + +Contents +-------- +1. Introduction +2. Installing Plugins +3. Using Plugins +4. Developing Plugins +5. Creating a Simple Plugin 1. Introduction --------------- -jEdit stores it's menus in property files (see props.txt). This has a number of -advantages to compiling them into the program: -- They're easier to modify. -- One can make JARs that add support for other languages. -- One can make JARs that add support for other key bindings, eg Emacs. - -2. Menubar Definition +jEdit has a powerful plugin architecture. Plugins can be used to add almost +any feature to jEdit. They are easy to write and even easier to install. + +2. Installing Plugins --------------------- -When a module wants to load a property-based menubar, it calls the -jEdit.loadMenubar(View view, String name) method. The method does the -following: -- It loads the property `name'. This is assumed to be a while space separated - list of menu names. -- It creates an empty menubar. -- It calls loadMenu() for each of the menus specified and adds them to the - menubar. -- It returns the menubar. - -3. Menu Definition ------------------- -The loadMenu(View view, String name) method is usually called by loadMenubar(), -but it can be called manually to load popup menus, etc. It does the following: -- It loads the property `name'. This is assumed to be a while space separated - list of menu item names. -- It creates an empty menu whose label is the value of the property - `name'.label. -- It adds a separator to the menu if a menu item is '-', otherwise it calls - loadMenuItem(). It then adds the separator/menu/menu item to the menu. -- It returns the menu. - -4. Menu Item Definition ------------------------ -The loadMenuItem(View view, String name) method is usually called by -loadMenu(), but it can be called manually for on-the-fly menu creation, etc. If -`name' starts with '%', it loads the menu whose name is `name', *NOT* including -the '%'. Otherwise, it creates a menu item whose label is the value of the -property `name'.label and whose shortcut is the value of the property -`name'.shortcut. Shortcuts are parsed as follows: -- An 'A' character adds ALT to the shortcut's modifier mask. -- An 'C' character adds CONTROL to the shortcut's modifier mask. -- An 'M' character adds META to the shortcut's modifier mask. This is probably - the right alt key. -- An 'S' character adds SHIFT to the shortcut's modifier mask. -- The last character that is not an uppercase A, C, M or S is the key. - -5. Commands ------------ -When a menu item is selected, the command with the menu item's name (NOT the -label) is executed. For more information on commands, see commands.txt. - -6. Dynamic Menus +Plugins are distributed as JAR files. They have a .jar extension. + +Plugins can be installed in one of two directories - the system plugin +directory and the user plugin directory. Plugins in the system directory +can be used by all users on the system. Plugins in a user's plugin directory +can only be used by that user. + +On Unix, the system plugin directory (assuming that you didn't change any +installation variables) is /opt/slava/share/jedit-1.00/jars. Each user has +a plugin directory in $HOME/.jedit-jars. + +On Windows 95 and 98, the system plugin directory is +C:\Program Files\jEdit\jars. The user plugin directory is +$JAVAHOME\.jedit-jars. + +On Windows NT, the system plugin directory is the same as that on +Windows 95/98, but each user has a plugin directory in $HOME\.jedit-jars. + +Additional directories can be added to the search path with the -plugindir= +command line option, see starting.txt for details. + +3. Using Plugins ---------------- -jEdit automatically generates some menus that you can insert in your menubar. -jEdit currently supports the following dynamic menus: -- `plugins': a list of installed plugins -- `buffers': a list of opened buffers -- `open_recent': a list of recently opened files -- `goto_marker': a list of markers, with each menuitem bound to goto_marker -- `clear_marker': a list of markers, with each menuitem bound to clear_marker +Once a plugin is installed, jEdit will say so during startup. + + Loading plugin /opt/slava/share/jedit-1.00/jars/HelloWorld.jar + Loading plugin /opt/slava/share/jedit-1.00/jars/ToLowercase.jar + Loading plugin /opt/slava/share/jedit-1.00/jars/ToUppercase.jar + +If a newly installed plugin doesn't appear to be loaded, check that it's in +the correct directory and that it's a JAR file. Also, a message such as this +indicates that the plugin is probably corrupted: + + Loading plugin /opt/slava/share/jedit-1.00/jars/WordCount.jar + java.util.zip.ZipException: not a ZIP file (END header not found) + at java.util.zip.ZipFile.findEND(ZipFile.java) + at java.util.zip.ZipFile.readCEN(ZipFile.java) + at java.util.zip.ZipFile.<init>(ZipFile.java) + at CommandMgr.loadJar(CommandMgr.java:63) + at CommandMgr.loadPlugins(CommandMgr.java:52) + at jEdit.main(jEdit.java:95) + +If all goes well during startup, the plugins should also appear in the +`Plugins' menu. If a plugin doesn't appear in the plugins menu but a +`Loading...' is printed, check that the plugin is valid and compatible with +the current version of jEdit. + +4. Developing Plugins +--------------------- +Plugins are stored in JAR files. The JAR file can contain two types of +entries - properties and classes. Other types of entries are ignored. + +Property entries have a .props extension and should be in standard Java +property file format. Any property files in a plugin are loaded by the +jEdit property manager automatically. + +Class entries have a .class extension. They are standard Java classes. The +jEdit command manager loads any classes in a plugin automatically. Also, +classes which implement the `Command' interface and have a name prefixed with +`Cmd_' are added to the plugins menu. To find out how to give the plugin's +menu item a shortcut and label, see menus.txt. + +The Command interface defines the following methods: + +- public Object init(Hashtable args); + This method is called when the plugin is loaded. `args' is a Hashtable + which may be used to pass parameters in the future. At the moment, it's + always empty. The return value is also unused - it should be null. -Note: A dynamic menu can only be included once in each menubar. - -7. Example Menubar Definition ------------------------------ -This is a simple menu bar definition. So if you didn't understand the above -description, this will help. If you want a more complex one, take a look at the -jEdit properties file. -### -app_mbar=file edit window help -file=new open close - save save_as - exit -file.label=File -new.label=New -new.shortcut=An ### Alt-N -open.label=Open -open.shortcut=Ao -close.label=Close -close.shortcut=Aw -save.label=Save -save.shortcut=As -save_as.label=Save As... -save_as.shortcut=ASs ### Alt-Shift-S -exit.label=Exit -exit.shortcut=Aq -edit=undo redo - cut copy paste clear select_all -edit.label=Edit -undo.label=Undo -undo.shortcut=Cz ### Control-z -redo.label=Redo -redo.shortcut=CSz ### Control-Shift-z -cut.label=Cut -cut.shortcut=Cx -copy.label=Copy -copy.shortcut=Cc -paste.label=Paste -paste.shortcut=Cv -clear.label=Clear -clear.shortcut=CSx -select_all.label=Select All -select_all.shortcut=Ca -### +- public Object exec(Hashtable args) + This method is called when the plugin is selected from the menu. `args' + is a Hashtable used to pass parameters. At the moment, the only parameter + applicable to plugins is stored at the `Command.VIEW' key. It's the view + that was active when the plugin was invoked. As with init(), the return + value is unused. For forward compatibility, it should be null. + +- Also, all commands must have a public constructor which accepts no + arguments. + +5. Creating a Simple Plugin +--------------------------- +The previous section probably doesn't make any sense at all. That's okay :). +This section contains step by step instructions for creating a simple +plugin. Hopefully, you'll be able to get the hang of this after reading this +section. + +You will need a java compiler and the jar tool to do this example. + +Step 1 - Create the source file + +Create a file, Cmd_SimplePlugin.java, with the following in it: + +// Simple jEdit plugin +import java.util.Hashtable; + +public class Cmd_SimplePlugin implements Command +{ + public Object init(Hashtable args) + { + /** this method is called when the plugin is loaded */ + System.out.println("Hello from SimplePlugin.init()!"); + /** the return value is ignored at the moment, so return null */ + return null; + } + + public Object exec(Hashtable args) + { + /** this method is called when the plugin is invoked */ + /** args contains one key - VIEW, which is the current view */ + System.out.println("Hello from SimplePlugin.exec()!"); + /** replace the selection in the current view with `hello!!!' */ + View view = (View)args.get(VIEW); + view.getTextArea().replaceSelection("hello!!!"); + } + + public SimplePlugin() + { + /** Constructor, required for command to work */ + } +} + +// End of Cmd_SimplePlugin.java + +Step 2 - Compile the source file + +Use the javac compiler to compile the source file. On Unix, do: + + javac -classpath $CLASSPATH:/opt/slava/share/jedit-1.00/jedit.jar \ + Cmd_SimplePlugin.java + +On Windows 95 98 and NT, do: + + javac -classpath "%CLASSPATH%;C:\Program Files\jEdit\jedit.jar" \ + Cmd_SimplePlugin.java + +The `-classpath' option tells javac where to look for jEdit's classes. +An error such as this during compilation means that the classpath is wrong: + + Cmd_SimplePlugin.java:4: Interface Command of class SimplePlugin + not found. + public class Cmd_SimplePlugin implements Command + ^ + 1 error + +If all goes well, go onto the next step. + +Step 3 - Create the properties file + +Create a file, SimplePlugin.props, with the following in it: + +# SimplePlugin.props: properties for simple plugin +# The menu item label that will appear in the Plugins menu +SimplePlugin.label=Simple Plugin +# The menu item's shortcut (Control-Shift-H) +# It is discouraged to give your plugins shortcuts, because +# collisions are very likely +SimplePlugin.shortcut=CS-h +# End of SimplePlugin.props + +Step 4 - Create the JAR file + +Use the jar tool to create the JAR file: + + jar cf0 SimplePlugin.jar Cmd_SimplePlugin.class SimplePlugin.props + +There should now be a file called SimplePlugin.jar. It is the finished +plugin. Note that the first parameter is c-f-zero, not c-f-capital-o. + +Step 4 - Install the test plugin + +Install the plugin in your personal plugins directory. On Unix: + + mkdir $HOME/.jedit-jars + cp SimplePlugin.jar $HOME/.jedit-jars + +On Windows 95 or 98: + + md %JAVAHOME%\.jedit-jars + copy SimplePlugin.jar %JAVAHOME%\.jedit-jars + +On Windows NT: + + md %HOME%\.jedit-jars + copy SimplePlugin.jar %HOME%\.jedit-jars + +Step 5 - Test it! + +Fire up jEdit. A message such as this should be printed: + + Loading plugin /home/slava/.jedit-jars/SimplePlugin.jar + Hello from SimplePlugin.init()! + +The plugin should also appear in the Plugins menu. Test it. It should output +`Hello from SimplePlugin.exec()!' and replace the current selection with +`hello!!!'. -- Slava Pestov <slava_pestov@geocities.com> + --- a/doc/old/plugins.txt +++ b/plugins/ToUpper/Cmd_ToUpper.java @@ -1,23 +1,45 @@ -JEDIT PLUGIN INTERFACE VERSION 1 +/* + * Cmd_ToUpper.java - Simple plugin + * Copyright (C) 1998 Slava Pest. Using Plugins ----------------- -jEdit is extensible using plugins. A plugin is a JAR file with class and/or -property files. Plugins are searched for in the plugin path. The default path -is: -- The system plugin directory, (/opt/slava/share/jedit/1.00 on Unix, - \Program Files\jEdit\share on Windows 95/NT). -- The user plugin directory (~/.jedit-jars on Unix, some JVM-dependent - directory on Windows 95/NT). -Directories can be added to the plugin path with the -plugindir= parameter. +import com.sun.java.swing.JTextArea; +import java.util.Hashtable; -2. Developing Plugins ---------------------- -To be useful, the JAR files must contain at least one .class or .props file. -The .props files are in standard Java property format. See props.txt for more -info. Each .class file is loaded into the runtime, and if it implements the -Command interface, a new instance of it is created and added to the command -list. See commands.txt for details. +public class Cmd_ToUpper implements Command +{ + public Object init(Hashtable args) + { + return null; + } --- Slava Pestov -<slava_pestov@geocities.com> + public Object exec(Hashtable args) + { + View view = (View)args.get(VIEW); + if(view != null) + { + JTextArea textArea = view.getTextArea(); + String selection = textArea.getSelectedText(); + if(selection != null) + textArea.replaceSelection(selection + .toUpperCase()); + else + view.getToolkit().beep(); + } + return null; + } +}
http://sourceforge.net/p/jedit/jEdit.bak/ci/c35e8ca99f550b68e013bbe2457cd41afe8a6291/
CC-MAIN-2014-41
refinedweb
2,041
52.56
THE SQL Server Blog Spot on the Web What happens to the cube after the processing is complete but before cube is ready for the querying ? There are actually quite a few steps that should be taken in order to prepare the cube, like create calculated members and named sets, apply security, factor in actions and KPIs etc. In this article we will provide an overview of the most important steps and discuss issues directly following from how these steps are done and how the ordering of these steps is important. Cube initialization sequence At the very high level the following events happen before cube becomes available for querying: System determined default members are applied This is kind of bootstrapping process. We really need to set up an execution context before we can go ahead with following steps. Many of the following steps require evaluation of various MDX expressions, and MDX expression always relies on the current coordinates. These coordinates need to be initially set to something. You may ask why not to use directly default members from DDL. The answer is that these could be by themselves MDX expressions, which need to be executed in some context, so we get Catch 22. How does the system determines the "system determined" default members ? Strictly speaking, this could be arbitrary, therefore no application should ever rely on the exact details. But currently the algorithm is following MDX expressions for user specified default members in DDL are evaluated From the previous paragraph, it is obvious, that normally the user will always want to overwrite the [almost random] system selection of default members on non-aggregatable attributes. And perhaps the default measure as well (although this one is not as random). Default members can be MDX expressions, and they are evaluated in the context of the system determined default members established at the previous step. But things are not as simple as they look. Let’s consider a simple example. Have you tried to define default member in measures one of the dimensions (dimension attributes really) to be a calculated member ? If you do it by using Analysis Services 2005 UI from BI Studio – you will get an error similar to this one: DefaultMeasure: Member object ‘Profit’ not found when parsing [Measures].[Profit] What is going on ? Is it a bug ? It very well might be perceived as a bug, especially given a fact that in Analysis Services 2000 UI Analysis Manager such operation worked fine. But actually, amazingly enough, from the engine perspective, this is not a bug – it is By Design behavior. And, of course, it is possible to set default members to be calculated members – it’s just that the UI for it is not obvious. I agree that for the user, trying to change default member through the property called "Default Member" is the most natural thing to do, and it appears as a bug when it doesn’t always work, but there is an explanation. What happens here is the order of applying default members vs. executing MDX Script. The default members specified by the user in UI get translated into attribute property DefaultMember or cube property DefaultMeasure in DDL, and they are applied before MDX Script is executed. Since all calculated members are created inside MDX Script, if default member refers to calculated member – the error is raised, because there are no calculated members yet. This isn’t the only scenario when such an ordering is not desired. In my book, "Fast Track to MDX", there is chapter about default members, and the example we give there is to set the default member of the Time dimension at the latest day for which there is a data in the fact table and it works with any cube in which this dimension is used, even if different fact tables have different latest date recorded. This is achieved by the following MDX expression for AS2000: Tail(Filter(Time.Day.MEMBERS, NOT IsEmpty(Measures.DefaultMember)),1).Item(0).Item(0) By the way, in AS2005 this expression could be simplified to Tail(NonEmpty(Time.Day.MEMBERS),1).Item(0) However, this won’t work in AS2005 for the same reason – since default members are evaluated before MDX Script was executed – it means that the CALCULATE statement wasn’t executed yet, therefore most of the cells in the cube are still empty, therefore Filter (or NonEmpty) function will return empty set, and default member cannot be NULL. On the other hand evaluating and applying DDL default members after MDX Script execution has its drawbacks. For example, the named sets and SCOPE subcubes need a context to be evaluated in, and the default members need to be factored in it. So there is really no "right" decision whether or not to apply DDL default members before or after MDX Script – either way, there will be scenarios when it will be wrong. And sometimes it is desirable to set default members in the middle of MDX Script, such that calculations before affect it (like CALCULATE) and calculations after are affected by it (named sets). Or even for different attributes default members should be set at different points of the MDX Script. It is, of course, possible to do – from the engine point of view pretty much the same way as it was done in AS2000. In AS2000 setting default members in the UI of Analysis Manager simply generated new ALTER CUBE command in the cube commands collection. Same can be done in AS2005, only that instead of collection of commands we have more convenient MDX Script itself. So what user needs to do is to insert into MDX Script at the right place (say, at the end of MDX Script) the appropriate ALTER CUBE statement, like the following example ALTER CUBE CURRENTCUBE UPDATE DIMENSION Measures, DEFAULT_MEMBER=[Measures].[Profit] One nice touch about ALTER CUBE statement, is that it operates on the hierarchy, therefore it allows setting default member on multiple attributes in one statement. (Of course, if all levels in the hierarchy have their underlying attributes defined relationships between each other – this is a moot point, because changing default member on one such attribute will anyway affect the others). The disadvantage of using ALTER CUBE statement in the MDX Script is that it needs to be added to the MDX Script of every cube where the default member needs to be set. However, it also can be argued, that in this case anyway default member depends on the MDX Script (either by being a calculated member or derives from the calculations) and therefore probably should be tailored separately to each cube anyway. As we have explained above, the MDX expressions for attribute default members in DDL should be such that they can be evaluated without cube context. For example, if Year is non aggregatable attribute, and we want to set default year to be the last year from the dimension, then the following expressions are fine: Tail(Time.Year.Year.MEMBERS,1).Item(0) Time.Year.Year.MEMBERS.Item(Time.Year.Year.MEMBERS.Count-1) Or if we want to tie it to the current year, then StrToMember("[Time].[Year].[Year].["+DatePart("YYYY",Now())+"]") GetDefaultYear() All these expressions don’t need to get anything from the cube, so they are fine. User specified default members are applied Default members evaluated in the previous step are applied to the context. It is important to separate these two steps, although it seems natural to combine them together. However, default members are evaluated in isolation one from another. Therefore, until all the expressions are evaluated, they are not applied. MDX expressions for dimension security are evaluated. Dimension security is applied before the MDX Script is executed. Therefore all the static expressions inside MDX Script (such as named sets and calculation SCOPE subcubes) will be resolved in the context of dimension security. In dimension security you can use arbitrary MDX expressions for specifying allowed and denied sets. The UI normally generates simple member enumeration sets, but using Advanced tab you can define more complex set expressions. At this point, the system already determined all the roles to which the user belongs (called active roles), and it evaluates all the MDX expressions for all AttributePermission objects at all active roles. These expressions are resolved in the context of the current user, therefore function Username resolves to that user. But not only that, also if you are using stored procedure inside MDX expressions for dimension security, and this stored procedure has ImpersonationLevel=ImpersonateCurrentUser, then it will work as well. Both of these things are the foundation for the dynamic dimension security techniques. More information about it can be found at. MDX expressions for dimension security default members are evaluated Dimension security can specify its own default members. This feature is more about personalization then about security (as we will quickly see in the next paragraph). Note, that while the MDX expressions for dimension security were evaluated at the previous step, the dimension security itself wasn’t applied yet. Therefore expressions for dimension security default members are still evaluated in the unsecured context. Dimension security is applied to all attributes Now it is time to apply dimension security to all attributes. This means that the evaluated allowed and denied sets in every attribute and every active role are applied to form virtual bitmask over the attribute members. It is bitmask in a sense that it is a data structure which tells for every attribute member whether it is secured or not. It is virtual, because the physical implementation is not necessarily a bitmap, many times it is more sophisticated data structure, however, it is guaranteed to never require more memory then single bit per attribute member. Usually it requires much less memory then that. Merging of active roles is simply a virtual OR operation between these virtual bitmaps, and it is very efficient. Merging security implied default members is different, because at the end there could be only one default member, therefore if there is a conflict between the roles in this respect, one of them overwrites the others. It is not possible to control which default member will win. Process of merging active roles has other interesting rules about how visual totals settings are merged etc. Default members are adjusted It is possible to set definitions in such a way that DDL defined default member or even dimension security defined default member ends up to be secured one. Obviously this would be a security hole, therefore after dimension security is applied, AS goes over all the default members and makes sure that they are all allowed. If previously defined default member is not allowed, it is changed using similar rules as in system determined default members. Dimension security visual totals are applied Dimension security visual totals now are applied to the current context, therefore all the calculations which will be done from that point on will be done with visual totals on the attributes defined in dimension security MDX Script is executed This is obviously most important step, where all the calculations are created etc. Since discussion about MDX Scripts can easily occupy few more blog articles, or even a book, we shall not say anything more here. KPI driven calculated measures are created KPIs are one of the most publicized features in AS2005, and they are very user appealing. Yet, their implementation is very simple and straightforward. When the user defines KPI object properties such as KPI value, KPI goal, KPI trend etc, the user can specify the MDX expressions for these. What happens behind the scenes is that AS creates hidden calculated measures for each one of these properties and assign the MDX expression specified in the property to the calculated measure. Later, when user queries KPIs, the KPI browser generates queries using MDX functions KPIValue, KPIGoal, KPITrend etc, which return these hidden calculated measures. Now, we are at the step when these hidden calculated measures are created. As you noticed, this step happens after MDX Script was executed. One interesting consequence of it is that the calculated measures created at this step will be executed after all other calculations in the MDX Script. (Or to put it in AS2000 terms, they will have higher solve order and/or pass). Is it a problem ? It could be. Let’s suppose that our MDX Script looks like following: CALCULATE; CREATE Account.Variance = (Account.Budget – Account.Actual)/Account.Actual; I.e. we want to compute percentage how far budget deviated from the actuals. Now, let’s also suppose that we have KPI called Profit, which will have the following simple expression for its value Measures.Sales – Measures.Cost There will be hidden calculated measure called Profit_Value created behind the scenes, and when the user will want to see the variance of the Profit, he will navigate to the intersection of Variance and Profit_Value calculated members – and since Profit_Value is executed after Variance, the user will get difference of ratios instead of ratio of differences ! So how this problem can be solved. Actually, it can be solved very easily if we know one additional piece of information. KPI trigger creation of hidden calculated measures only if the MDX expression for the KPI property is not a simple reference to some measure (either calculated or physical). However, if the expression is a simple reference, such as [Measures].[Sales], then no hidden calculated measure will be created, and KPIValue, KPIGoal, KPITrend etc functions will simply return that measure. Therefore, one can (perhaps even should) create all the calculations in the MDX Script (where they really belong in the first place), and resolve all the precedence rules there using power of MDX Scripts. Therefore in our example the MDX Script would be rewritten as following: CALCULATE; CREATE HIDDEN Profit = Measures.Sales – Measures.Cost; CREATE Account.Variance = (Account.Budget – Account.Actual)/Account.Actual; And define the expression for the KPI Profit value simply as [Measures].[Profit] (there is no problem with KPIs having same names as calculated members – they belong to different namespaces). Since calculated measure Profit was defined in the MDX Script before the calculation for Variance, it will also be executed before, and therefore the results will start to make sense. Actions are added Actions are really noop as far as calculations or current context are concerned. All the MDX expressions used in actions are evaluated dynamically upon invocation of MDSCHEMA_ACTIONS schema rowset. Cell security is applied Unlike dimension security, cell security is applied after the MDX Script was executed. Therefore all the static calculations (such as named sets and calculation SCOPE subcubes) were resolved without taking cell security into account. Of course, all the dynamic expressions (i.e. everything at the right hand side of the assignment operator – expressions of calculated members, custom member formulas etc) will be executed using cell security. Cell security is applied by applying virtual OR operator on top of cell security boolean expressions in all active roles. Perspective measures restrictions are applying We are close to the end now. The last piece deals with perspectives. Perspectives are really almost the same as the cube. It is mostly about hiding some objects, i.e. MDSCHEMA_DIMENSIONS, MDSCHEMA_HIERARCHIES, MDSCHEMA_MEASURES, MDSCHEMA_SETS etc return less rows. But the MDX is not affected by these changes (almost!). However, there is one important difference, and it deals with how measures (but not calculated members !!!) are hidden. When MEASURES.MEMBERS is used as axis expression, then only the measures and calculated measures included in the perspective are included in the set. But if same is used deeper inside expression for calculation, for example defining calculated member which does MEASURES.MEMBERS.COUNT, then the number which will be returned will count all the measures, including the hidden ones. Such behavior should sound familiar to the people who worked with MDX subselects and CREATE SUBCUBE. And indeed, the way perspective restrictions on measures are implemented is doing internal CREATE SUBCUBE PerspectiveName FROM (SELECT PerspectiveMeasures ON 0 FROM CubeName) This is pseudocode, because in AS2005 CREATE SUBCUBE cannot change the name of the cube on which it operates, but perspectives obviously have different name from the cube Default measure is adjusted to the perspective Perspectives, of course, can overwrite default measures, since they may exclude the cube default measure. And even if default measure for perspective is not explicitly specified, it still may change. Just like with any other subselect and CREATE SUBCUBE statement, after it is done, the default members are adjusted to fit into the space defined by the subcube. Since for perspectives the subcube restriction is on measures only, the default measure is adjusted.
http://sqlblog.com/blogs/mosha/archive/2005/12/31/default-members-mdx-scripts-security-kpis-and-perspectives.aspx
CC-MAIN-2014-52
refinedweb
2,780
50.57
Related How To Build a Neural Network to Recognize Handwritten Digits with TensorFlow Introduction connected in layers, with weights assigned to determine how the neuron responds when signals are propagated through the network. Previously, neural networks were limited in the number of neurons they were able to simulate, and therefore the complexity of learning they could achieve. But in recent years, due to advancements in hardware development, we have been able to build very deep networks, and train them on enormous datasets to achieve breakthroughs in machine intelligence. These breakthroughs have allowed machines to match and exceed the capabilities of humans at performing certain tasks. One such task is object recognition. Though machines have historically been unable to match human vision, recent advances in deep learning have made it possible to build neural networks which can recognize objects, faces, text, and even emotions. In this tutorial, you will implement a small subsection of object recognition—digit recognition. Using TensorFlow, an open-source Python library developed by the Google Brain labs for deep learning research, you will take hand-drawn images of the numbers 0-9 and build and train a neural network to recognize and predict the correct label for the digit displayed. While you won't need prior experience in practical deep learning or TensorFlow to follow along with this tutorial, we'll assume some familiarity with machine learning terms and concepts such as training and testing, features and labels, optimization, and evaluation. You can learn more about these concepts in An Introduction to Machine Learning. Prerequisites To complete this tutorial, you'll need: - A local Python 3 development environment, including pip, a tool for installing Python packages, and venv, for creating virtual environments. Step 1 — Configuring the Project Before you can develop the recognition program, you’ll need to install a few dependencies and create a workspace to hold your files. We’ll use a Python 3 virtual environment to manage our project's dependencies. Create a new directory for your project and navigate to the new directory: - mkdir tensorflow-demo - cd tensorflow-demo Execute the following commands to set up the virtual environment for this tutorial: - python3 -m venv tensorflow-demo - source tensorflow-demo/bin/activate Next, install the libraries you'll use in this tutorial. We'll use specific versions of these libraries by creating a requirements.txt file in the project directory which specifies the requirement and the version we need. Create the requirements.txt file: - touch requirements.txt Open the file in your text editor and add the following lines to specify the Image, NumPy, and TensorFlow libraries and their versions: image==1.5.20 numpy==1.14.3 tensorflow==1.4.0 Save the file and exit the editor. Then install these libraries with the following command: - pip install -r requirements.txt With the dependencies installed, we can start working on our project. Step 2 — Importing the MNIST Dataset The dataset we will be using in this tutorial is called the MNIST dataset, and it is a classic in the machine learning community. This dataset is made up of images of handwritten digits, 28x28 pixels in size. Here are some examples of the digits included in the dataset: Let's create a Python program to work with this dataset. We will use one file for all of our work in this tutorial. Create a new file called main.py: - touch main.py Now open this file in your text editor of choice and add this line of code to the file to import the TensorFlow library: import tensorflow as tf Add the following lines of code to your file to import the MNIST dataset and store the image data in the variable mnist: ... from tensorflow.examples.tutorials.mnist import input_data mnist = input_data.read_data_sets("MNIST_data/", one_hot=True) # y labels are oh-encoded When reading in the data, we are using one-hot-encoding to represent the labels (the actual digit drawn, e.g. "3") of the images. One-hot-encoding uses a vector of binary values to represent numeric or categorical values. As our labels are for the digits 0-9, the vector contains ten values, one for each possible digit. One of these values is set to 1, to represent the digit at that index of the vector, and the rest are set to 0. For example, the digit 3 is represented using the vector [0, 0, 0, 1, 0, 0, 0, 0, 0, 0]. As the value at index 3 is stored as 1, the vector therefore represents the digit 3. To represent the actual images themselves, the 28x28 pixels are flattened into a 1D vector which is 784 pixels in size. Each of the 784 pixels making up the image is stored as a value between 0 and 255. This determines the grayscale of the pixel, as our images are presented in black and white only. So a black pixel is represented by 255, and a white pixel by 0, with the various shades of gray somewhere in between. We can use the mnist variable to find out the size of the dataset we have just imported. Looking at the num_examples for each of the three subsets, we can determine that the dataset has been split into 55,000 images for training, 5000 for validation, and 10,000 for testing. Add the following lines to your file: ... n_train = mnist.train.num_examples # 55,000 n_validation = mnist.validation.num_examples # 5000 n_test = mnist.test.num_examples # 10,000 Now that we have our data imported, it’s time to think about the neural network. Step 3 — Defining the Neural Network Architecture The architecture of the neural network refers to elements such as the number of layers in the network, the number of units in each layer, and how the units are connected between layers. As neural networks are loosely inspired by the workings of the human brain, here the term unit is used to represent what we would biologically think of as a neuron. Like neurons passing signals around the brain, units take some values from previous units as input, perform a computation, and then pass on the new value as output to other units. These units are layered to form the network, starting at a minimum with one layer for inputting values, and one layer to output values. The term hidden layer is used for all of the layers in between the input and output layers, i.e. those “hidden” from the real world. Different architectures can yield dramatically different results, as the performance can be thought of as a function of the architecture among other things, such as the parameters, the data, and the duration of training. Add the following lines of code to your file to store the number of units per layer in global variables. This allows us to alter the network architecture in one place, and at the end of the tutorial you can test for yourself how different numbers of layers and units will impact the results of our model: ... n_input = 784 # input layer (28x28 pixels) n_hidden1 = 512 # 1st hidden layer n_hidden2 = 256 # 2nd hidden layer n_hidden3 = 128 # 3rd hidden layer n_output = 10 # output layer (0-9 digits) The following diagram shows a visualization of the architecture we've designed, with each layer fully connected to the surrounding layers: The term “deep neural network” relates to the number of hidden layers, with “shallow” usually meaning just one hidden layer, and “deep” referring to multiple hidden layers. Given enough training data, a shallow neural network with a sufficient number of units should theoretically be able to represent any function that a deep neural network can. But it is often more computationally efficient to use a smaller deep neural network to achieve the same task that would require a shallow network with exponentially more hidden units. Shallow neural networks also often encounter overfitting, where the network essentially memorizes the training data that it has seen, and is not able to generalize the knowledge to new data. This is why deep neural networks are more commonly used: the multiple layers between the raw input data and the output label allow the network to learn features at various levels of abstraction, making the network itself better able to generalize. Other elements of the neural network that need to be defined here are the hyperparameters. Unlike the parameters that will get updated during training, these values are set initially and remain constant throughout the process. In your file, set the following variables and values: ... learning_rate = 1e-4 n_iterations = 1000 batch_size = 128 dropout = 0.5 The learning rate represents how much the parameters will adjust at each step of the learning process. These adjustments are a key component of training: after each pass through the network we tune the weights slightly to try and reduce the loss. Larger learning rates can converge faster, but also have the potential to overshoot the optimal values as they are updated. The number of iterations refers to how many times we go through the training step, and the batch size refers to how many training examples we are using at each step. The dropout variable represents a threshold at which we eliminate some units at random. We will be using dropout in our final hidden layer to give each unit a 50% chance of being eliminated at every training step. This helps prevent overfitting. We have now defined the architecture of our neural network, and the hyperparameters that impact the learning process. The next step is to build the network as a TensorFlow graph. Step 4 — Building the TensorFlow Graph To build our network, we will set up the network as a computational graph for TensorFlow to execute. The core concept of TensorFlow is the tensor, a data structure similar to an array or list. initialized, manipulated as they are passed through the graph, and updated through the learning process. We’ll start by defining three tensors as placeholders, which are tensors that we'll feed values into later. Add the following to your file: ... X = tf.placeholder("float", [None, n_input]) Y = tf.placeholder("float", [None, n_output]) keep_prob = tf.placeholder(tf.float32) The only parameter that needs to be specified at its declaration is the size of the data we will be feeding in. For X we use a shape of [None, 784], where None represents any amount, as we will be feeding in an undefined number of 784-pixel images. The shape of Y is [None, 10] as we will be using it for an undefined number of label outputs, with 10 possible classes. The keep_prob tensor is used to control the dropout rate, and we initialize it as a placeholder rather than an immutable variable because we want to use the same tensor both for training (when dropout is set to 0.5) and testing (when dropout is set to 1.0). The parameters that the network will update in the training process are the weight and bias values, so for these we need to set an initial value rather than an empty placeholder. These values are essentially where the network does its learning, as they are used in the activation functions of the neurons, representing the strength of the connections between units. Since the values are optimized during training, we could set them to zero for now. But the initial value actually has a significant impact on the final accuracy of the model. We'll use random values from a truncated normal distribution for the weights. We want them to be close to zero, so they can adjust in either a positive or negative direction, and slightly different, so they generate different errors. This will ensure that the model learns something useful. Add these lines: ... weights = { 'w1': tf.Variable(tf.truncated_normal([n_input, n_hidden1], stddev=0.1)), 'w2': tf.Variable(tf.truncated_normal([n_hidden1, n_hidden2], stddev=0.1)), 'w3': tf.Variable(tf.truncated_normal([n_hidden2, n_hidden3], stddev=0.1)), 'out': tf.Variable(tf.truncated_normal([n_hidden3, n_output], stddev=0.1)), } For the bias, we use a small constant value to ensure that the tensors activate in the intial stages and therefore contribute to the propagation. The weights and bias tensors are stored in dictionary objects for ease of access. Add this code to your file to define the biases: ... biases = { 'b1': tf.Variable(tf.constant(0.1, shape=[n_hidden1])), 'b2': tf.Variable(tf.constant(0.1, shape=[n_hidden2])), 'b3': tf.Variable(tf.constant(0.1, shape=[n_hidden3])), 'out': tf.Variable(tf.constant(0.1, shape=[n_output])) } Next, set up the layers of the network by defining the operations that will manipulate the tensors. Add these lines to your file: ... layer_1 = tf.add(tf.matmul(X, weights['w1']), biases['b1']) layer_2 = tf.add(tf.matmul(layer_1, weights['w2']), biases['b2']) layer_3 = tf.add(tf.matmul(layer_2, weights['w3']), biases['b3']) layer_drop = tf.nn.dropout(layer_3, keep_prob) output_layer = tf.matmul(layer_3, weights['out']) + biases['out'] Each hidden layer will execute matrix multiplication on the previous layer’s outputs and the current layer’s weights, and add the bias to these values. At the last hidden layer, we will apply a dropout operation using our keep_prob value of 0.5. The final step in building the graph is to define the loss function that we want to optimize. A popular choice of loss function in TensorFlow programs is cross-entropy, also known as log-loss, which quantifies the difference between two probability distributions (the predictions and the labels). A perfect classification would result in a cross-entropy of 0, with the loss completely minimized. We also need to choose the optimization algorithm which will be used to minimize the loss function. A process named gradient descent optimization is a common method for finding the (local) minimum of a function by taking iterative steps along the gradient in a negative (descending) direction. There are several choices of gradient descent optimization algorithms already implemented in TensorFlow, and in this tutorial we will be using the Adam optimizer. This extends upon gradient descent optimization by using momentum to speed up the process through computing an exponentially weighted average of the gradients and using that in the adjustments. Add the following code to your file: ... cross_entropy = tf.reduce_mean( tf.nn.softmax_cross_entropy_with_logits( labels=Y, logits=output_layer )) train_step = tf.train.AdamOptimizer(1e-4).minimize(cross_entropy) We’ve now defined the network and built it out with TensorFlow. The next step is to feed data through the graph to train it, and then test that it has actually learnt something. Step 5 — Training and Testing The training process involves feeding the training dataset through the graph and optimizing the loss function. Every time the network iterates through a batch of more training images, it updates the parameters to reduce the loss in order to more accurately predict the digits shown. The testing process involves running our testing dataset through the trained graph, and keeping track of the number of images that are correctly predicted, so that we can calculate the accuracy. Before starting the training process, we will define our method of evaluating the accuracy so we can print it out on mini-batches of data while we train. These printed statements will allow us to check that from the first iteration to the last, loss decreases and accuracy increases; they will also allow us to track whether or not we have ran enough iterations to reach a consistent and optimal result: ... correct_pred = tf.equal(tf.argmax(output_layer, 1), tf.argmax(Y, 1)) accuracy = tf.reduce_mean(tf.cast(correct_pred, tf.float32)) In correct_pred, we use the arg_max function to compare which images are being predicted correctly by looking at the output_layer (predictions) and Y (labels), and we use the equal function to return this as a list of Booleans. We can then cast this list to floats and calculate the mean to get a total accuracy score. We are now ready to initialize a session for running the graph. In this session we will feed the network with our training examples, and once trained, we feed the same graph with new test examples to determine the accuracy of the model. Add the following lines of code to your file: ... init = tf.global_variables_initializer() sess = tf.Session() sess.run(init) The essence of the training process in deep learning is to optimize the loss function. Here we are aiming to minimize the difference between the predicted labels of the images, and the true labels of the images. The process involves four steps which are repeated for a set number of iterations: - Propagate values forward through the network - Compute the loss - Propagate values backward through the network - Update the parameters At each training step, the parameters are adjusted slightly to try and reduce the loss for the next step. As the learning progresses, we should see a reduction in loss, and eventually we can stop training and use the network as a model for testing our new data. Add this code to the file: ... # train on mini batches for i in range(n_iterations): batch_x, batch_y = mnist.train.next_batch(batch_size) sess.run(train_step, feed_dict={ X: batch_x, Y: batch_y, keep_prob: dropout }) # print loss and accuracy (per minibatch) if i % 100 == 0: minibatch_loss, minibatch_accuracy = sess.run( [cross_entropy, accuracy], feed_dict={X: batch_x, Y: batch_y, keep_prob: 1.0} ) print( "Iteration", str(i), "\t| Loss =", str(minibatch_loss), "\t| Accuracy =", str(minibatch_accuracy) ) After 100 iterations of each training step in which we feed a mini-batch of images through the network, we print out the loss and accuracy of that batch. Note that we should not be expecting a decreasing loss and increasing accuracy here, as the values are per batch, not for the entire model. We use mini-batches of images rather than feeding them through individually to speed up the training process and allow the network to see a number of different examples before updating the parameters. Once the training is complete, we can run the session on the test images. This time we are using a keep_prob dropout rate of 1.0 to ensure all units are active in the testing process. Add this code to the file: ... test_accuracy = sess.run(accuracy, feed_dict={X: mnist.test.images, Y: mnist.test.labels, keep_prob: 1.0}) print("\nAccuracy on test set:", test_accuracy) It’s now time to run our program and see how accurately our neural network can recognize these handwritten digits. Save the main.py file and execute the following command in the terminal to run the script: - python main.py You'll see an output similar to the following, although individual loss and accuracy results may vary slightly: OutputIteration 0 | Loss = 3.67079 | Accuracy = 0.140625 Iteration 100 | Loss = 0.492122 | Accuracy = 0.84375 Iteration 200 | Loss = 0.421595 | Accuracy = 0.882812 Iteration 300 | Loss = 0.307726 | Accuracy = 0.921875 Iteration 400 | Loss = 0.392948 | Accuracy = 0.882812 Iteration 500 | Loss = 0.371461 | Accuracy = 0.90625 Iteration 600 | Loss = 0.378425 | Accuracy = 0.882812 Iteration 700 | Loss = 0.338605 | Accuracy = 0.914062 Iteration 800 | Loss = 0.379697 | Accuracy = 0.875 Iteration 900 | Loss = 0.444303 | Accuracy = 0.90625 Accuracy on test set: 0.9206 To try and improve the accuracy of our model, or to learn more about the impact of tuning hyperparameters, we can test the effect of changing the learning rate, the dropout threshold, the batch size, and the number of iterations. We can also change the number of units in our hidden layers, and change the amount of hidden layers themselves, to see how different architectures increase or decrease the model accuracy. To demonstrate that the network is actually recognizing the hand-drawn images, let's test it on a single image of our own. If you are on a local machine and you would like to use your own hand-drawn number, you can use a graphics editor to create your own 28x28 pixel image of a digit. Otherwise, you can use curl to download the following sample test image to your server or computer: - curl -O Open the main.py file in your editor and add the following lines of code to the top of the file to import two libraries necessary for image manipulation. import numpy as np from PIL import Image ... Then at the end of the file, add the following line of code to load the test image of the handwritten digit: ... img = np.invert(Image.open("test_img.png").convert('L')).ravel() The open function of the Image library loads the test image as a 4D array containing the three RGB color channels and the Alpha transparency. This is not the same representation we used previously when reading in the dataset with TensorFlow, so we'll need to do some extra work to match the format. First, we use the convert function with the L parameter to reduce the 4D RGBA representation to one grayscale color channel. We store this as a numpy array and invert it using np.invert, because the current matrix represents black as 0 and white as 255, whereas we need the opposite. Finally, we call ravel to flatten the array. Now that the image data is structured correctly, we can run a session in the same way as previously, but this time only feeding in the single image for testing. Add the following code to your file to test the image and print the outputted label. ... prediction = sess.run(tf.argmax(output_layer, 1), feed_dict={X: [img]}) print ("Prediction for test image:", np.squeeze(prediction)) The np.squeeze function is called on the prediction to return the single integer from the array (i.e. to go from [2] to 2). The resulting output demonstrates that the network has recognized this image as the digit 2. OutputPrediction for test image: 2 You can try testing the network with more complex images –– digits that look like other digits, for example, or digits that have been drawn poorly or incorrectly –– to see how well it fares. Conclusion In this tutorial you successfully trained a neural network to classify the MNIST dataset with around 92% accuracy and tested it on an image of your own. Current state-of-the-art research achieves around 99% on this same problem, using more complex network architectures involving convolutional layers. These use the 2D structure of the image to better represent the contents, unlike our method which flattened all the pixels into one vector of 784 units. You can read more about this topic on the TensorFlow website, and see the research papers detailing the most accurate results on the MNIST website. Now that you know how to build and train a neural network, you can try and use this implementation on your own data, or test it on other popular datasets such as the Google StreetView House Numbers, or the CIFAR-10 dataset for more general image recognition. 22 Comments
https://www.digitalocean.com/community/tutorials/how-to-build-a-neural-network-to-recognize-handwritten-digits-with-tensorflow
CC-MAIN-2019-30
refinedweb
3,808
54.32
23,266 C I T R US S- U . Football Citrus, South Sumter preview PAGE Te do jmw ve ~ S -- - -II- e.= Copyrighted Material Syndicated Content Available from Commercial News Providers NO. .i""" Challenge: Protect nature, provide water Dealing with growth JIM HUNTER jhunter@chroniclebnline.com Chronicle The policy director for Florida Audubon told attendees at the annual Save Our Waters Forum on Wednesday that a new focus emerging in environ- mental protection in Florida is how to S develop strategies to protect the envi- ronment while providing water for the developing state. The speaker, Eric Draper, PhD., is the director of conservation for the Audubon of Florida, and he told the audience Wednesday that growth is happening and is not going to be stopped, so the challenge is to provide water and conserve it in a way that will protect the environment from being damaged. His theme was "Water for Nature, Not Just for Growth." Please see FORUM/Page 5A Sheriff reaches for standards Agency seeks accreditation AMY SHANNON ashannon@chronicleonline.com Chronicle National accreditation from the Commission on Accreditation for Law Enforcement Agencies (CALEA) could be on the horizon for the Citrus County Sheriff's Office if the agency's stan- dards make the grade. State accredited by the Commission for Florida Law Enforcement Accreditation (CFA) for seven years and recognized by CALEA for three, the sheriff's office has applied for national accreditation on two levels: law enforcement and public safety commu- nications. No stranger to organization, Sheriff Jeff Dawsy said accreditation holds the agency to a higher standard by measur- ing performance, providing a written system to aid in decision-making and Please see "F'-riFF/Page 4A Picking up the pieces after Katrina MATTHEW BECK/Chronicle Waveland, Miss., resident Susan Magee receives a hug from a friend Tuesday afternoon while taking a break from searching for a gold bracelet through the debris that used to be her home. Like thousands of Hancock, Miss., residents, Magee and her husband lost everything when Hurricane Katrina slammed into their community. Citrus County offers help to Hancock County . 'MIKE WRIGHT mwright@ chronicleonline.com Chronicle KILN, Miss. No single word can sum up what Hurricane Katrina did to the coastal communities of Hancock County, Miss. Hancock, adopted by relief agencies in Citrus County to help hurricane victims, is a mess. , Nearly half its 45,000 res- idents are homeless, Hancock County Admini- strator Tim Kellar said. The storm killed 49 people. An equal number are missing. The town of Waveland, three miles inland, is flat- tened. Half-million dollar homes that withstood Hurricane Camille in 1969 are gone, swept from their foundations. Nothing is left of Waveland City Hall but the front steps. Much more moderate homes on roads leading to the Mississippi Sound are crushed. At one house, flat- tened to the ground, some- one spray-painted on the roof, "Thanks for nothing, Katrina, you b -." Historic Bay St. Louis looks like it has been bombed. At the Masonic Temple downtown, two crushed cars were. wedged into the building's front door. Mayor Eddie Favre, who has lived in Bay St. Louis Please see PIECES/Page 11A Circuit Court Judge Patricia Thomas sorts through some of the thousands of canned food items donated to hurricane survivors Tuesday afternoon at an elementary school in Hancock, Miss. Annie's Mailbox . 5C Movies ...... . . 6C Comics ......... 6C Crossword ... . . 5C Editorial .... ... 10A Horoscope ... . . 6C Obituaries ...... .6A Stocks .......... 8A Four Sections Red-hot romancing "Last of the Red Hot Lovers," a comedy will open on Citrus stage Sept. 30./1C Real reality TV As it happened, passengers watched news ot their flight's emergency on television./12A Love fluently spoken here An Inverness couple has made spiritual inroads for county Hispanics./Saturday Property owner accuses county * Says county took property from his home before tear- ing it down./3A * Lecanto home destroyed by fire./3A * State agency wants more train- ing for motorcy- clists./3A :'-1' FORECAST: Partly 90 cloudy. Isolated ,. showers and t-storms 75 Southeast winds PAGE 2A Rf th WHAT IS NEEDED IN HANCOCK COUNTY The needs of Hancock County, N Brooms, rags, mops, scrub N Tarps tion, call Janelle Thompkins at Miss., are many and immediate. In brushes 0 Volunteers. To volunteer, call 321) 837 6457. particular: Buckets; dish soap; bleach (321) 837-6441 E On the Web: Go to * Small charcoal grills and self Heavy duty rubber gloves and A Hancock County fund is set up coastnewc.com and click on the lighting charcoal; lghtersrubber boots for direct donations to residents Hancok report. * Flashlights, batteries and there To donate send a check to N For more information, call lanterns 0 Respirator medical masks to Hancock County Disaster Relel Chronicle reporter Mike Wright at * Tents for families to live in; protect breathing dust and mold Fund, PO. Box 429, Bay St. 563 5660 or e-mail sleeping bags Insect repellent; sunscreen Louis, MS 39520; for informa- mwright@chronicleonline.com. ! WMRIT 2Aft nnn- v rkmy w-rlunrn 2 5ETRAN ETCnu ONY(L HOIL Florida LOTTERIES U- Here are the winning numbers selected Thursday in the Florda Lottery: CASH 3 8-1-5 PLAY 4 0-4-5-0 FANTASY 5 2-15-18-29-34 5-of-5 2 winners $92,393 4-of-5 380 $78 3-of-5 9,750 $8.50 Mega Money: 13 18 27- 29 Mega Ball: 12 4-of-4 MB No winner , 4-of-4 9 $1,987. 3-of-4 MB 62 $630.50 3-of-4 1,534 $76 2-of-4 MB 2,065 $39.50 2-of-4 44,077 $3 1-of-4 MB 16,281 $5 MONDAY, SEPTEMBER 19 .48 50 Cash 3:2-4-4 Play4:8-8-2- 8 Fantasy 5:4 12 17 19 25 5-of-5 6 winners $32,683.24 4-of-5 413 $76.50 3-of-5 11,213 $7.50 SUNDAY, SEPTEMBER 18 Cash 3:0-4-6 Play 4:2 1 7 9 Fantasy 913 INSIDE THE NUMBERS S To-verify the accuracy of winning lottery numbers,. players should double check the numbers pnnrtedabove with numbers officially, posted by the Florida Lottery. On the Web, go to .com; by telephone, call (850) 487-7777. $|I-op eatasm:Il n. ao 1oni Smy 7* y. *a ,,, amm a am ID4 e 0 -mA m ai ll mm I4 ft amm ON a *a mmnmo .n.mmo a f m till ,u emD ullim... Lecanto Homecoming Court 6b I i 0h 00 P mo v at w m n AtO owI Gmw af ft availablee . ....... .. ..E .... ........ ..,. * iiii .:- ....... ..... Sool a a ak ' as 4 S... .. - 9!* ,'a E~ eEEEEEEEEEE: eIII e S elin a- bo . I-of m H. 8-, Sft S eOM4 W. 0l .......a..... " " al .. a a .-.. eka. * ROCHELLE KAISER/For the Chronic Lecanto High School celebrates homecoming tonight when the Panthers football team plays Central High School. The 2005-0 Homecoming Court is, from left: Melissa Fatz, Lindsey Smith, Carli Benthusen, Tara Haddock, Stephanie Coatney and Sandr Almeida. The queen will be crowned during halftime festivities. Copyrighted h Syndicated C from Commerci Material ontent *A *- a/ *" i .*- ial News Providers 4 ".- *-: ar" Today in HISTORY----- Today is Friday, Sept. 23, the 266th day of 2005. There are 99 days left in the year. Today's Highlight 1806, the Lewis and Clark expedition returned to St. Louis from the Pacific Northwest. In 1939, Sigmund Freud, the founder of psychoanalysis, died in London. In 1952, Republican vice-presi- dential candidate Richard M. Nixon went on television to deliver what came to be known as the "Checkers" speech as he refuted allegations of improper campaign financing. In 1957, nine black students le who had entered Little Rock 6 Central High School in Arkansas a were forced to withdraw because of a white mob outside. Ten years ago: In a wide-rang- ing interview aboard Air Force One, President Clinton admitted he had tended in the past to get hung up on details, and pledged to do a better job in providing reas- suring leadership to Americans confused by tumultuous times. Five years ago: At the Sydney Olympics, Marion Jones won the women's 100-meter final in 10.75 seconds; Maurice Greene took the men's 100 in 9.87 seconds. One year ago: President Bush denied painting too rosy a picture about Iraq, and said he would con- sider sending more troops if asked; Iraq's interim leader, Ayad Allawi, standing with Bush in the White House Rose Garden, said additional troops weren't needed. Today's Birthdays: Actor Mickey Rooney is 85. Singer Julio Iglesias is 62. Rock star Bruce Springsteen is 56. Actor Jason Alexander is 46. Actor Chi McBride " is 44. Actress Elizabeth Pena is . 44. Actor Erik Todd Dellums is 41. Actress Lisa Raye is 39. Singer Ani DiFranco is 35. Recording executive Jermaine Dupri is 33. Pop singer Erik-Michael Estrada'; ("Making the Band').is 26. 'o0j Thought forToday: "The only ,, interesting answers are those which destroy the questions." - Susan Sontag, American author and critic (1933-2004). Cnims CouNTY (FL) CHRoNjcLE 2A FRiDAY. SEPTEMBER 23. 2005 a ENXERTAINMENT filo 4411MI, -.. .1. ( I 3A FRIDAY SEPTEMBER 23, 2005 Nor* a. Www 'b q- m. P qpw di 101 -Imp 0 u woQ o- u 0 O-m ow a -i s bso-mon 40 domw .t 4 m. o g a md oo Capt. James McCabe drags a hose Friday afternoon as he checks for hot spots at a -. 0 .0- = Fire officials still trying to determine cause c .* - AMY SHANNON flames from the outside first then w w o t ashannon@ entered the home, switching to an * _m N -W chronicleonline.com "'inner attack" in orderto search forthe Se-- so w Chronicle fire's seed, McLean said. - .* .- About 30 minutes later, firefighters ___ W D A mid-afternoon fire ripped through were forced to pull out as the roof began 41* the roof of a singlewide mobile home to dangerously sag. Once outside, fire- __ s g with an attachment Thursday at 80 S. fighters put out a few lingering flames am o 4 b Bauer Road in Lecanto. and tugged at the walls, searching for ,- -. B a Citrus County Fire Rescue spokesman any hidden fires. I aW* Tom McLean said it appeared as if the Charred around the windows and SI.am 3:38 p.m. fire started somewhere in the throughout the inside, the home was q a w o back of the home, possibly in a bedroom. destroyed. S-4b -W.. No one was injured. Family members, friends and co- ._ __ At the scene, firefighters fought the workers gathered at the home to con- g- -1IN M O gt m go,- 0 .a--. gggw lowl-o' i Copyrighted Material *--.g 0-f- lil0 * gI * S M f.. ,toSyndicated Content - "-.- Available from Commercial News S -' a 0- 10--1 1 4 1..401 1db- - 41 e a- Imp - __ p dom- olm m 4w fta 4Cdm ____ -0-000-. - -e - m 4b a ~mr keg - -. - Providers - p - a - -e - - - --- - - ~- - * ~- - - a. '* ~,* - Owner: County removed property before razing home Officials say guon were removed and will be returned TERRY WITT terrywitt@ chronicleonline.com Chronicle An Inverness Highlands man whose home was destroyed by the county earlier this week for code violations alleged on Thursday that county officials removed some of his posses- sions before the wrecking crew arrived. Anthony Boccaccio said video security cameras inside his home captured county offi- cials removing the possessions after they broke through the front door of his house at 5595 Arthur St "We know who took what Some of these people are going to jail," Boccaccio said. "We have video tapes. We're going to display that in court" Public Safety Director Charles Poliseno said sheriff's officer Kenny Wear was pres- ent when the front door of Boccaccio's home was forcibly Photo courtesy of Citrus County A county contractor destroys the home of Anthony Boccaccio on Tuesday in Inverness Highlands. The county said Boccaccio built the home without permits and it was unsafe for human habitation. opened on Tuesday. He said guns were taken from the home, but he said it's his understanding the guns will be given back to Boccaccio. Sheriff's office spokes- woman Gail Tierney said three rifles (one of them black pow- der), two revolvers (one of them black powder), a submachine gun and an archery bow were removed from a locked cabinet in the home and carried to the sheriff's office evidence room for safekeeping until Bocca- ccio picks them up. Poliseno said officials en-- tered the home to determine if there was anything that could injure county personnel when the home was knocked down. The code enforcement board had ordered destruction of the home. Boccaccio has been in a 10- year battle with the county over code violations. Boccaccio had been sent to jail in 1996 for indirect criminal contempt of court, according to a St. Petersburg Times story. Circuit Judge Patricia Thomas found he had continued to build his home without proper permits, even though she had ordered him to stop. The county has never varied from its contention that Boccaccio built the home with- out permits and without follow- ing blueprints or complying with the building code. Boccaccio said he obtained a 1996 permit to build the home himself, and renewed it annu- ally by having the construction work, which was completed in phases, inspected at least once a year. However, Poliseno said he knows of no rule allowing a builder to renew a permit by having the construction inspected annually. And Poliseno said he checked with Development Services Director Gary Maidhof before destroy- ing the home, and Maidhof said Boccaccio had no permits to build the home. Poliseno said he was part of the group that entered the home after first posting a warn- ing on the property that the home was unsafe and would have to be destroyed. He said they found the building was poorly constructed and unsafe. He said Boccaccio was given time to remove his personal possessions. He said Boccaccio gave two neighbors permission to remove items from the home. One neighbor was told he could have whatever he found in the garage and home, according to Poliseno. Boccaccio alleges the county failed to secure his home after entering it and said many pos- sessions went missing while the house was unsecured. He wants the county to repay him for the lost property and for loss of the home. County BRIEFS "What matters." "United Way is impor. tant to our commu- nity because :t has brought new ife and new energy to ,,Lynne Citrus Clarke County through its leadership with the CHARGE Long Term Disaster Recovery, anrd the FEMA Emergency Food and Shelter Program. Community is what matters." 0 GET INFO: For more information about United Way of Citrus County, call 527-8894 or visit the Web site at org. County, Teamsters to continue chatting Collective bargaining talks between the Board of County Commissioners and Teamster Local 79 will continue from 1 to 5 p.m. today in Room 262 of the Lecanto Government Building. The public is welcome. For spe- cial assistance, call 527-5370. CRHS class of 1970 to meet Oct. 15 Crystal River High School Class of 1970 will have an infor- mal get-together at 7 p.m. Saturday, Oct. 15, at Crackers Restaurant, outside by the water. Any questions on the reunion call Betty (Williams) Swafford at 563-2389. Homeless group to host fish fry The Hunger and Homeless ' Coalition of Citrus County with sponsor a fish fry from 10 a.m. to 3 p.m. Saturday, at the pavil- ion next to the tennis courts in Bicentennial Park, Crystal River. Cost is $6 per person. All pro- ceeds will benefit homeless families. Hemrick announces for school board Inverness resident Hank Hemrick filed paperwork Wednesday to run for next year's Citrus County School District 5 seat. Hemrick, 60, was a warden level 1 in the New York City Department of Correction and holds both a bachelor's degree in correctional administration and a master's degree in public administration. He served in the Air Force from 1966-1970 and was honorably discharged. After retiring, he worked as a supervisor in the foster care system in New York. He moved to Citrus County in 1998. Hemrick unsuccessfully ran for a Citrus County Mosquito Control seat in 2002 and Citrus County sheriff in 2004. The District 5 seat is now occupied by Linda Powers, who was elected to office in 2004 when Sandra "Sam" Himmel vacated the seat to run for superintendent of schools. School board races are non- partisan. The election will be held November 2006. From staff reports p. 0 - = -e Home destroyed in fire BRIAN LaPETER/Chronicle house fire on Bauer Road in Lecanto. se of Lecanto blaze sole the homeowners devastated by the fire. A Citrus County Sheriff's Office vic- tims' advocate responded to the scene to aid the home's family. Citrus County Fire Rescue firefight- ers from Inverness (station 101), Beverly Hills (station 121), Pine Ridge (station 23), Homosassa (station 93) and Connell Heights (tanker 31), along with the Homosassa volunteer fire auxiliary unit and the agency's air unit responded to the fire. Nature Coast EMS workers and Citrus County Sheriff's deputies also responded to the fire. -- --8 - - . . roclI 4A FRIDAY, SilEPTMBER 23, 2005 Man reports robbery at gas station At that point, one of the men punched the victim in his right cheek, knocking him to ground, Tierney said. As the victim reached back to break his fall, he dropped the cash. One of the men picked up the cash and fled northwest toward a wooded area. Sheriff's deputies respond- ed to the scene along with K-9 and aerial units. Tierney said a neighborhood canvass was conducted, but the suspects were not found. Deputies saw no visible injuries on the victim, Tierney said. A description of the men was unavailable Thursday evening; though Tierney said the victim did not provide many suspect details. She said the incident was classified as a robbery, although the suspects did not use force to take the money because the victim dropped it on his own. Anyone with information about this case should call sheriff's Detective Mike Kanter at 726-4488, ext. 224. AMY SHANNON ashannon@ chronicleonline.com Chronicle A local man sustained a blow to the face and his wallet Thursday morning outside a Texaco gas station in Holder. Citrus County Sheriff's Office spokeswoman Gail Tierney said a man stopped to smoke a cigarette just outside the station's convenience store on U.S. 41 when two men approached him. "They asked, 'Do you have any cigarettes,'" Tierney said. "And the man said, 'No, this is my last one."' The men then asked the vic- tim if he had any money. And the victim said no, even though he was holding $4 cash - money he planned to use to buy snacks for his co-workers. Florida Highway Patrol DUI arrest Alfred Hill, 63, 7396 W. Green Acres St., Homosassa, at 7:40 p.m. Wednesday on charges of driving under the influence and leaving the scene of an accident with property damage. His bond was set at $750. Citrus County Sheriff Arrests Robert Good, 51, 2580 N. Jungle Camp Road, Inverness, at 6:36 p.m. Wednesday on a charge of grand theft. His bond was set at $2,000. ON THE NET For more information about arrests made by the Citrus County Sheriffs Office, go to and click on the link to Daily Reports, then Arrest Reports. Christopher Green, 20, 8585 W. Longfellow St., Inverness, at 8:54 p.m. Wednesday on a charge of possession of a controlled sub- stance. His bond was set at $2,000. SHERIFF Continued from Page 1A reinforcing employee account- ability. "We think it's important for the constituency we serve," said Dawsy, who has served as a CFA commissioner since 2001. "We want to be compared to other professional agencies in the nation." Begun in 1980, CALEA sets 489 standards organized into 38 chapters in its law enforce- ment accreditation program, as opposed to the 274 standards set by the CFA's accreditation process. Deputy Wayne King said of the 489 CALEA standards the agency is already in compli- ance with 257 many are the same as outlined by CFA. King said 50 of the 440 law enforcement agencies in the state are CALEA accredited. Mount Dora Police Department became the first CALEA accredited law enforcement agency in 1984, he said. Only 6.5 percent of all law enforcement agencies in the United States are accredited from CALEA, Dawsy said. Lt. Doug Dodd, who overseas the agency's law enforcement accreditation as director of professional standards and special projects division, described any anticipated changes to meet national stan- dards as "more on the internal side." As an example of a CALEA standard already practiced by the sheriff's office, Dodd point- ed to the agency's vision, val- ues and mission statements - posted prominently in the training room at sheriff's head- quarters. Dodd added that the accred- itation would not raise salaries of sheriff's office personnel. However, the agency has spent $7,675 on CALEA appli- cation fees for law enforce- ment and $9,850 on application fees for public safety communi- cations, Citrus County Sheriff's Office spokeswoman Gail Tierney said. If the sheriff's office does earn CALEA accreditation, it will be expected to pay some reoccurring maintenance fees, Tierney said. With regards to the agency's communications division, CALEA's public safety commu- nications accreditation pro- gram (PSCAP) has 216 stan- dards organized into six chap- ters. This will be the first time the agency is pursuing national accreditation in public safety communications. Jody Bloomer, accreditation Bn Q QUALITY LISNDs AND SHUTTERS - SPVC VERTICALS I Includes deluxe track, valance, and installation i l726 4457 SSALE ON 2" Faux-Wood with Free Crown Valance Free Estimates! Call Today,.,, 3 -- -- -- -- _H _ ___nre / Hurricane \ ( Relief YARD SALE / -.r CAN DO '".M ANSWERING SERVICE will hold a yard sale Saturday & Sunday yda September 24 & 25 to benefit the victims of Hurricane Katrina. This will be an enormous sale. Something for everyone. Lots of new items. Everything including the kitchen sink. Please stop by and help us help Katrina's casualties. 8144 W. Grover Cleveland Blvd. Homosassa Just east of Hwy, 19 In front of Spotted Dog Realty Call 621-1000 for directions. officer for the sheriff's emer- gency operations center, said the only Florida counties cur- rently CALEA accreditation through PSCAP are Alachua and Sarasota. Capt. Joe Eckstein, who heads up Citrus County's emer- gency operations center, said national accreditation in pub- lic safety communications will inspire confidence in the entire community about the services, policies and proce- dures performed by his divi- sion. "CALEA accreditation sets high standards for our employ- ees and high expectations on the part of Citrus County's citi- zens for public safety and all its ramifications," Eckstein said in a press release. '"Adhering to national standards holds peo- ple accountable for their actions and raises the car for services expected." Currently in its self-assess- ment phase, sheriff's officials are reviewing existing policies and procedures, and develop- ing and implementing any CALEA-required policies not already in place. In May 2006, the agency's law enforcement and public safety communications components will undergo a mock on-site assessment. A final on-site assessment in public safety communications is set for November 2006 and in law enforcement is set for December 2006. The CALEA commission will then review the sheriff's office assessment. If all goes well, the agency could earn dual CALEA accreditation and CFA reac- credidation in March 2007 at official ceremonies in Greensboro, N.C. In March 2010, the award period would end and the sher- iff's office would be reassessed to determine if compliance has been maintained. GET THE WORD OUT SNonprofit organizations are invited to submit news releas- es about upcoming community events. * Write the name of the event, who sponsors it, when and where it will take place and other details. * Call 563-5660 for details. County BRIEF Citrus County Safety Expo set Local law enforcement agencies and organizations are set to host the 10th Annual Citrus County Safety Expo from 10 a.m. to 3 p.m. Saturday at the Crystal River Mall. The event is free to the public and offered to residents of all ages. Citrus County Seniors and Law Enforcement Together Council, in cooperation with the Citrus County Sheriffs Office, Crystal River Police Department and the American Association of Retired Persons, are hosting the event, which kicks off October as National Crime Prevention Month. In addition to nearly 30 informa- tion booths and tabletop displays, there will be topical presentations on stage in the mall's food court. These brief presentations and demonstrations will focus on scams, identity theft, hurricane pre- paredness, home and personal safety, Child Lures Prevention and the Sheriff's Office K-9 Unit. For more information about this event, call the Citrus County Sheriff's Office at 726-4488. WEEKLY LINEUP I 0 Nearly a dozen medical professionals contribute their expertise to columns in Health & Life./Tuesdays Read up on all things school-related in the Chronicle's Education section. /Wednesdays Plan menus for the week from the tempting recipes in the I Flair for Food section./Thursdays Get a jump on weekend entertainment with the stories in i Scene./Fridays * See what local houses of worship plan to do for the week in the Religion section./Saturdays Read about area businesses in the Business section./Sundays C I R LU .C U N rT Y CHRONICLE Florida's Best Conmmunity Meadowcrest office Where to find us: Inverness office 1624 N. Meadowcrest Blvd. 106 W. Main St., Crystal River, FL 34429 Inverness, FL 34450 Beverly Hills office: Visitor .jj Irnjaran Boulv-ran Suspects still on loose For the RECORD ,INGROUND POOLS CiTRus CouNTY (FL) CHRoNicLE FRIDAY, SEPTEMBER 23, 2005 5A rrU3 ,,LJUJIn vJ (11.9 t,flfl ,,l, 7 FORUM Continued from Page 1A He said the numbers used vary, but there are about 1,000 new residents coming to Florida each day and about 200,000 acres lost to develop- ment each year. He showed two maps that showed a dra- matic loss of wetlands in the state during the last 100 years of development. State Sen. Nancy Argenziano attended the meeting and presented a proclamation from Gov. Jeb Bush to Save Our Waters organizers noticing the signifi- cance of the week's activities. Pat Casselberry accepted for the organizers, and Argenziano said as she pre- sented the proclamation, "I know the people of Citrus County are always very involved. Our waters are so precious." Draper, who has lobbied extensively for environmental groups in Washington, D. C., and Tallahassee, said he want- ed to encourage concerned citizens to stay energized and stay connected with decision- makers to ensure environmen- tal protection is included in growth and water manage- ment policies. Draper said challenges fac- ing the state are threefold: competition for water, pollu- tion and challenges to the pub- lic ownership of water and wetlands in the state. One solution to water use problems might be to let those who recycle water sell-it, he said. Although that would have to be reconciled with the public ownership of water, it illustrates one new way envi- ronmental protection might be able to work with develop- GO ONLINE Visit to read today's headlines, add your thoughts to the weekly opinion poll, search the classified ads, look up movie times or play games. Have friends visit the cam- era at while you're out at the springs in King's Bay.' | ww.allaboutbaths.comni CUSTOM SEATING designed with YOU in mind It's all here Everything you need to create the perfect room from classic to modern You'll appreciate the quality and the prices ment. On pollution, Draper said that nutrient loading is the major source of pollution in the state and it comes from runoff from parking lots, sod- ded suburban lawns, agricul- tural fields, septic tanks and even rainfall carrying power plant pollutants released in the air. He lauded the Everglades cleanup project as a success story, noting that soon there will be 400,000 acres of man- made marshes to help clean up polluted water there, much created by sugar farmers. Targets of of reducing phos- phorus levels to 10 parts per billion are actually being hit, he said. On conservation, Draper said the largest growth in the use of water in the state is in landscape irrigation, and withdrawals are going up all around the state. He acknowl- edged the strong urge to keep one's yard green and thriving, but he said the state must begin to not only conserve water but change the mindset of turf and ornamental plants to native, drought-resistant landscaping. Some developers are already opting for that nat- ural theme instead of building golfing communities, he said. One way to conserve water is though desalination invest- ment, but with energy prices skyrocketing, that gets less viable because of the energy needed, he said. - He quoted Southwest Florida Water Management District Director David Moore, who said that just a 5 percent total conservation in water County BRIEFS Special to the Chronicle State Sen. Nancy Argenziano, R-Dunnellon, delivers a proclamation from Gov. Jeb Bush in commemoration of Save Our Waters Week to member Pat Casselberry. use would equal the produc- tion of five desalination plants. He said the management of water has become more criti- cal and added that we must begin to think of stormwater as an alternative source of water rather than as waste- water. When water levels that nor- mally fluctuate are held too high for public or agricultural FORGET TO PUBUCIZE? * Submit photos of successful community events to be pub lished in the Chronicle. Call 563 5660 for details. .SAVE SAVE SAVE SAVE FAST DELIVERY PROFESSIONAL STAFF FREE * In Home Consulting *Valances * Installation Verticals Wood Blinds Shutters Crystal Pleat Silhouette LECANTO -TREETOPS PLAZA 1657W. GULF TO LAKE HWY 527-0012 c_ HOURS: MON.-FRI. 9AM 5 PM ISA Evenings and Weekends by Appointmp-e *must psent written estimate from competitor for like product Factory Authorized Now through October 4th NORWA SI I KN 1 1 I.i R L " All the latest styles in over 1.000 fabrics & leathers Custom covered, delivered in just 35 days and backed by a lifetime limited warranty Custom Sofas starting at only FURNITURE LIGHTING AREA RUGS UNIQUE ACCESSORIES WINDOW TREATMENTS FABRICS WALL COVERINGS ACCESSORIES INTERIOR DESIGN smart interiors ~ Two Convenient Locations - 97 W. Gulf to Lake Hwy., Lecanto, FL 34461 5141 Mariner Blvd., Spring Hill, FL 34609 352-527-4406 352-688-4633 use, the environment can be affected, too. Draper said that environ- mentalist policy can work with development and business to nature's advantage, with envi- ronmentalists not necessarily being at war with them. That can happen, for exam- ple, if the policy is used to maximize the amount of lands that are left undeveloped. Highway Patrol sets checkpoint sites The Florida Highway Patrol will conduct driver's license and vehi- cle inspection checkpoints during September on the following roads in Citrus County: State Road 200, County Road 486, County Road 491, Elkcam Boulevard, N. Croft Avenue, Green Acres Boulevard, Miss Maggie Drive, Dunklin Avenue, Turner Camp Road, County Road 39, County Road 488, County Road 494, W. Pine Ridge Boulevard, W. Seven Rivers Drive, Fort Island Trail, Gobbler Drive, Yulee Drive West, Istachatta Road, County Road 470, County Road 490, W. Cardinal Street, Dunkenfield Road, W. Venable Street, N. Citrus Avenue, N. Citrus Springs Boulevard, Mustang Boulevard, County Road 480, County Road 490A, Century Boulevard, Rock Crusher Road, Pleasant Grove Road, Fishbowl Drive, Turkey Oak Drive, Grover Cleveland, Old Floral City Highway. Recognizing the danger present- ed to the public by defective vehi- cle equipment, troopers will con- centrate their efforts on vehicles with bad brakes, worn tires and defective lighting equipment. Drivers can make appointments online The Florida Department of Highway Safety and Motor Vehicles (DHSMV) has installed a new Web-based appointment scheduling system available in 42 counties throughout Florida, includ- ing Citrus County. Citrus County customers can schedule driver license appoint- ments with their local state driver license office via the Internet by logging on to. Currently, customers may do this by phone; however, this new option allows them to set the appointment themselves, avoiding the need to call the driver license office directly. This new alternative also reduces the number of tele- phone calls to department staff. -- with Siding, Soffits, & Facias I. I I I A BRIEF LESSON ABOUT Suncoast Schools Federal Credit Union. (And why we can offer you better rates.) Vt So mayvbt mnev', not .eierione's favorite subject. But paying attention no10% ma well keep you from having to pay dearly later. Let's begin with tle coniceit .oF being a member of a credit union \ersus heing a customer at a bank. See ., bank'- main goal is to offer stockholder. wa.s to make inon.e Whereas. a credit union's m.iin goal is to offer members ways to save mnioney. V, You'll find evidence of this at Suncoast. Just ask about our car loan with rates as low as 5.0ao APR'. Or our certificate accounts paving earnings a, hilih as .5"'. APY1 Then there', fiee checking, free ATM access%. Iree on-line banking and bill pay and free advice from financial experts. The e are lust a few reasons Surcoati ha's grown to become the largest credit union in Florida, and the seventh largest in the country. All of this newslfound knowledge kind of makes you s.wonder wh) you didn't look into becoming a member ooner. Let's just consider it a lesson learned. *4 To find out more. call 800-999-5887 or visit joinsnncoast.org. 177-7 WEST MAIN STkEET IN INVERNESS 517 NE 5TH STREET IN CRYSTAL RIVER Suncoast Schools Federal Credit Union WHERE SMART PEOPLE KEEP THEIR MONEY. Twinkle, Twinkle \ Big Bright Star' sVECIALT, GEMS. . Established l98i 14K Gold 795-5900 & Diamonds u.f ,, 600 SE Hs)3 19, Cr3stal Riser .\ailable UTRUS (,OUN7Y (PL) CHRONICLE , - - I % I I I 'Ll 1"IN' i I I t I -. '. -- I I I .- -- l -1 N - I 1- 1, j,- -111, I .- L- I V.I.. N , N CUA ..... . oo I S o 1, 1 Open Mon. -FH. 9:30-5:00; Sat. 10:00-4:00 RA FrM** FP Crnmtr3ER 22.c 2 fl CT00C5 Obituaries Gardner Brown, 93 HOMOSASSA Gardner L. Brown, 93, of Sugarmill Woods, Homosassa, died Thursday, Sept 22, 2005, at Citrus Memorial Hospital, Inverness. Born July 11, 1912, in Somerville, Mass., to Herbert and Hazel (Peck) Brown, he moved here 20 years ago from West Dover, Vt Mr. Brown was a retired banker. He was a graduate of Hebbon Academy, 1930, Dartmouth University, 1934, Tuck School of Business and Ruckers School of Banking in 1947. He was preceded in death by a son, Gardner L. Brown Jr, in 1994. Survivors include his wife of 66 years, Susan (Webber) Brown of Sugarmill Woods, Homosassa; son, Steven M. Brown and wife, Lynda, of Wilmington, Vt.; a sister, Phyllis Phillips of Reno, Nev; and three grandchildren. Wilder Funeral Home, Homosassa Springs. Ruby Kelly, 92 PORT CHARLOTTE Ruby Lee Kelly, 92, of Port Charlotte, former Inverness resident, died at home Thursday, Sept 22,2005, under the care of her family and Hospice. A native of Louisiana, she was born July 28, 1913, to the late Henry and Willie Mae Jackson and moved to Citrus County in 1946 from Georgia. She moved to Port Charlotte three years ago to live with her daughter. Mrs. Kelly was an ordained minister in the Assembly of God Church and co-pastored with her late husband, the Rev. John B. Kelly, who died Nov 17, 1989. She is survived by three daughters, Willie Faye Coppernoll and husband, Dean, of Mt Morris, Ill., Nancy Vuic of Port Charlotte and Linda Ricard and husband, Patrick, of Baton Rouge, La.; 11 grandchildren; and 14 great- grandchildren. Chas. E. Davis Funeral Home With Crematory, Inverness. Marguerite Leinenweber, 81 WEST PALM BEACH Marguerite Leinenweber, 81, Elizabeth Leinen- weber-Wilcox of Dunnellon and Claudia Helen Leinenweber of West Palm Beach; five grandchildren; and five great-grandchildren. Roberts Funeral Home, Dunnellon. Burnie Maynard, 75 BEVERLY HILLS Burnie Maynard, 75, of Beverly Hills, died Wednesday, Sept 21, 2005, in Cirystal River. Born Oct. 14, 1929, in Ferguson, WVa., to Floyd and Georgia Maynard, he moved here in 1993 from Casey, Ill. Mr. Maynard was a retired coal miner and he was a mem- ber of the West Virginia National Guard. He was a member of the West Citrus Church of Christ, Crystal River, where he was a deacon. He was preceded in death by his first wife, Dorothy Maynard, Aug. 23, 1991; son, Burnie "BJ" Maynard Jr, Nov. 11, 1996; and daughter, Gaynell Hall, Nov 17, 1998. - Survivors include his Wife, Betty M. Maynard of Beverly Hills; two sons, Floyd W. Maynard and wife, Lena, of Madison, WVa., and Anthiel "Butch" Maynard and wife, Debbie, of Haines City; daugh- ter-in-law, Auddie Maynard of Casey, Ill.; four daughters, Connie J. Hawker and hus- band, Joseph, of Martinsville, Ill., Martella "Tillie" Evans and husband, Steve, of Beauty, Ky., Myrtie "Joni" Snearley of Martinsville, Ill., and Vivian "Dibber" Grissom and hus- band, Tim, of Toledo, Ill.; four stepsons, Wesley P Hughes and wife, Michelle, of Clearwater, Timothy D. Hughes and wife, Susan, of Inglis, Terry D. Hughes and wife, Janice, of Saginaw, Texas, and Steven E. Hughes and wife, Tina, of Homosassa;. two sisters, Ruby and Jane; 26 grandchildren; and 31 great-grandchildren. Hooper Funeral Home, Beverly Hills. Terrence McNamara, 87 BEVERLY HILLS Terrence A McNamara, 87, of Beverly Hills, died Wednesday, Sept. 21, 2005, in Inverness. Born May 21, 1918, in Brooklyn, N.Y, to Charles and Louise McNamara, he moved here from Seaford, N.Y, in 1977. Mr. McNamara was an iron- worker in the construction industry. He was a member of Our Lady of Grace Catholic Church, Beverly Hills, the Irish American Social Club and the Knights of Columbus Council 6168, Beverly Hills. Survivors include his wife of 61 years, Frances M. McNamara of Beverly Hills; son, Terrence P McNamara of Huntington Station, N.Y.; daughter, Catherine Breckin- ridge of Cerritos, Calif.; and two grandchildren, Emma McNamara and Robin McNamara. Hooper Funeral Home, Beverly Hills. Walter Olson, 82 INVERNESS Walter Harry Olson, 82, of Inverness, died Tuesday, Sept. 20, 2005, at the Arbor Trails Skilled Nursing & Rehabilitation Center in Inverness. Born April 11, 1923, in Jamestown, N.Y, he came here from Rochester, N.Y, in 1975. Mr. Olson was a retired accountant in the construc- tion industry and served with the U.S. Army in the South Pacific during World War II having been honorably dis- charged with the rank of Technician Fifth Grade. He was a past member of the Citrus Good Time Cloggers and he enjoyed square dancing, clogging, reading and playing golf. He was Protestant. Survivors include his wife of 16 years, Mary (Horvat) Olson; two sons, Richard Olson of Seneca Falls, N.Y, and James Olson of Bradenton; and seven grandchildren. Chas. E. Davis Funeral Home With Crematory, Inverness. Click on- cleonline.com to view archived local obituaries. Funeral NOTICES Ruby Lee Kelly. Funeral services will be conducted at 11 a.m. Saturday, Sept. 24, 2005, from the Chas. E. Davis Funeral Home with the Rev. Dairold Rushing officiating. Burial will follow in the Oak Ridge Cemetery. The family will receive friends at the funeral home on Saturday morning.from 10 a.m. until the hour of service. Burnie Maynard. The serv- . ice of remembrance for Mr. Burnie Maynard, 75, of Beverly Hills, will be conducted at 4 p.m. Saturday, Sept. 24,2005, at the Beverly Hills Chapel of Hooper Funeral Homes with Mr. David L. Curry officiating. Interment will be at a later date in Hazeldale Cemetery, Crooked Creek Township, Illinois. Friends may call from 2 to 4 p.m. Saturday at the chapel. Terrence A. McNamara. Friends of Mr. Terrence A. McNamara, age 87, may call from 4 to 6 p.m. Friday, Sept. 23, 2005, at the Beverly Hills Chapel of Hooper Funeral Homes with 5 p.m. prayers given by the Knights of Columbus No. 6168, Beverly Hills. Cremation will be under the direction of Hooper Crematory, Inverness. Walter Harry Olson. A cele- bration of life memorial serv- ice will be conducted at 2:30 p.m. Monday, Sept. 26, 2005, from the Florida National Cemetery in Bushnell with the Floral City VFW Post No. 7122 Honor Guard officiating. Interment of the urn will fol- low. Friends are welcome to meet at the Chas. E. Davis Funeral Home at 1:30 p.m. on Monday to form the procession to the cemetery. There will be no viewing hours. In lieu of flowers, memorials are sug- gested to Hospice of Citrus County, PO. Box 641270, Beverly Hills, FL 34464. Timothy Martin Robers. A funeral mass for Mr. Timothy Martin Robers, age 51, of Beverly Hills, who died Sept. 12, 2005, will be conducted at 10 a.m. Saturday, Oct. 1, 2005, at Our Lady of Grace Catholic Church. Cremation will be under the direction of Hooper Crematory, Inverness. Friends, who wish, may send memorial donations to the Red Cross Katrina Fund. Death :.HE z. .. r Alfredo Jordan Morales, 55 HAVANA, CUBA Agriculture Minister Alfredo Jordan Morales, who rose from humble beginnings to hold a ministerial post and sit on the ruling politburo of Cuba's Communist Party, died Wednesday from cancer, state media reported. He was 55. Jordan continued to work in his position until his death, Cuban television and the domestic National Information Agency said. Jordan had headed Cuba's Agriculture Ministry since 1993, at the height of the severe crisis 'known as the Special Period that followed the loss of the island's former .trading partners in Eastern Europe. Born into a farming family, Jordan began his political career as a leader with the Union of Young Communists and was later president of the National Pioneers Organization, a communist group for schoolchildren. * He also served as first secre- tary of the provincial commit- LZaI. E. Eitaui 'Funeral Htome 'Wick Crematory Betty Jo Hallam Private Cremation Arrangements Ruby Kelly Service: Sat. 11 am Viewing: 10 am Burial: Oak Ridge Cemetery Virginia Garner Services: Fri. 10/7 2:30 pm Florida National Cemetery Geraldine Guy Private cremation arrangements Walter Olson Graveside Service: Mon., 2:30 pm Florida National Cemetery Judith Brinnitzer Mass: Fri. 10 am Our Lady of Fatima ... 726-8323 ONAMNPRMfl0 qaM .D a a -bm a fl -0a S Se COOw S4 O e up o Copyrighted Material Syndicated Content Available from Commercial News Providers - 0 a n - g e a t * -w. q 0 * . - * a -a * a- a.. - - -. -e 0 - a - a- S a- a o* - -e -edo aW 4D- - - a - - o - a The Dignity MemorialTM mark symbolizes respect. But then again, it symbolizes so much S more. It's a sign of trust, superior quality standards, and attentive care in the funeral, cremation, and cemetery profession. With membership by invitation only. Dignity memorial is the world's largest network of funeral and cremation providers and signifies a higher level of - funeral care. 00- Service Beyond Expectation FERO FUNERAL HOME' WITH CREMATOR# Beverly Hills (352) 746-4551 FERO MEMORIAL GARDENS CEMETERY Beverly Hills (352) 746-4646 (352) 489-9613 FERO FUNERAL HOME WITH CREMATORY SDunnellon (352) 489-5363 WILDER FUNERAL HOME Homosassa (352) 628-3344 WEEKLY AQUATIC SPRAY SCHEDULE FOR CITRUS COUNTY Citrus County's Aquatic Services Division plans the following aquatic weed control activities for the week beginning September 26, 2005. HERBICIDE TREATMENTS: Chassahowitzka Hyacinth/Lettuce/Hydrilla' Crystal River Hyacinth/Lettuce Floral City Pool Hydrilla/Salvinia/Sedges/Tussocks/Coontail/ Maidencane/Hyacinth/Lettuce Hernando Pool Nuphar/Grasses/Water Hyacinth/Lettuce/ Hydrilla/Tussocks/Sedges/White Water Lilly/Willows/ Lotus/S. Naiad/Bladderwort Inverness Pool Hydrilla/Frog's Bit/Grasses/Tussocks/Sedges/ Water Hyacinth/Lettuce/Nuphar/Lotus/Fanwort/S. Naiad/ Bladder Wort/Torpedo Grass Chassahowitzka Crystal River Inverness Pool Floral City Pool Homosassa River Hernando Pool MECHANICAL HARVESTING: Lyngbya/Hydrilla Lyngbya/E. Milfoil Tussocks/Fanwort Tussocks Lyngbya Tussocks/Fanwort All treatments are contingent upon weather conditions and water quality. Treated areas will be identified with "Warning Signs" indicating the date of treatment and the necessary water use restrictions. For further information, please call 352-527-7620. Citrus County Division of Aquatic Services SOLATUBE. The Mirade Skylight A revolutionary new way to think about skylights. Professionally installed in 2 hours. 'I. O -fwr Fall is in the air Beautiful Fall Fashions Arriving Daily Muist Hnve's 3388 Gulf to Lake Hwy., Hours: Hwy. 44, Fountain Sq., Inverness It's. Tues-Fri 10 5 L(352) 344-0804 Sat 10'4r, 10 5 Serving You For Two Generations c~Irickland Funeral Home and Crematory Since 1962 Since 1962 352-795-2678 1901 SE Hwy. 19 CRYSTAL RIVER, FL 34423 Retired? Hear What You've Been Missing "Put a face with the voices, and see why we're on radio." PaunIng ForA Better & Safer Retiremen TOPICS INCLUDE: S iledicaid., Pensio hs-RA and 401k *Retirement Investment options - .Durable Power of Att eyTrusts. Wdls LivingWills'Health Car , Hosted fothe Ias3yas by:...b TIranco isousinet Preside.n4 c w,,aninumm'eAdvisoris -evn Bowman Attorney , " ..'... .' I.", .' ''1'"'; :: " "C ., ._, .- :-;, . ,. at r ay a ,t *. - IU*~h$tko&22 ajoL k'RIDAY, -)EPTEMBER Z:), ZUL17) takes C)BFFUAXUES/IL40CA.L CuRus CouNTY (FL) CHRoNicLE I . . '04e /., I I , *1~ 7A FRIDAY SEPTEMBER 23, 2005 Learn about our waters Marion County festival scheduled for weekend Special to the Chronicle Educating Marion County residents and visitors about Florida's freshwater springs and giving everyone the oppor- tunity to enjoy this valuable natural resource is the goal of the Fourth Annual Marion County Springs Festival scheduled at the Rainbow Springs State Park on Saturday and Sunday. Regular park admission is $1 per per- son; children 5 and younger are admit- ted free. The Marion County Springs Festival will kick off Saturday morning at Rainbow Springs State Park with the grand opening of the new Educational Center and Interpretative Room. Both rooms are in and near the existing Visitors Center and Gift Shop. Approximately 186,000 people visited the center last year. With the new dis- plays, park officials expect even more next year. Gary Ellis of Gulf Archeology Research Institute has designed and built the Education Room and the Interpretative Room to help educate visitors to the park on wildlife and ecosystem in and around the springs. The Interpretative Room, which will be open to all park guests at no additional charge, offers a look under water at the headsprings of the river with walls designed to look like the limestone and sand bottom of the springs and hand- carved and -painted creatures that live in the springs. Also in the display is a herpetology headquarters, continuous computer information about the springs, an indi- go snake exhibit and a ceiling painted to look like the surface of the swirling spring water. The Education Center, which is avail- able to educators by reservation, has been designed to spur the imagination of youngsters. Ellis has built a "Tree of Life," complete with a hand-carved woodpecker, tree frog, anole, cardinal, grey and fox squirrels. A DNA double helix model rests on a pedestal in front of a window and offers a view of scien- tific evolution of life. The room is equipped with audiovisual and lab equipment and specimens for .group studies. More displays are planned. Rainbow Springs State Park is on the west side of Marion County off U.S. 41 just north of Dunnellon and south of State Road 40. Call (352) 465-8555 or visit the Web site (currently under construction) at. Catch dance spirit Special to the Chronicle U Oct. 8 "Birthday Dance Party" Complimentary Cake The public is invited to the will be served. Music by Butch dance parties hosted by the Phillips. Spirit of Citrus Dancers. 0 Oct. 22 "Harvest Ball" Dances are held on Saturday Wear your favorite fall colors. nights at the Kellner Music by Butch Phillips. Auditorium, in Beverly Hills. Doors open at 6:45 p.m. A The dance schedule is as fol- complimentary lesson will be lows: given at 7. Open dancing is N Saturday "Showcase from 7:30 to 10. Note the admis- Dance Party" to celebrate sion is now $7 per person. National Ballroom Dance There is a "get acquainted" Week Attendees are invited to table for dancers without bring a goodie to share if they dance partners. Coffee and ice would like. Music .by Butch will be provided. Call Lloyd or Phillips. Kathy at 726-1495. Special to the Chronicle Kenji Kawano will appear at the Old Courthouse Heritage Museum at 2 p.m. today to meet the public and share the story of the Navajo Code Talkers and their contribution to the American efforts during World War II. Kawano came to America in 1973. He was drawn to the mystery and beauty of the Navajo Reservation and became friends with Carl Gorman, a member of the Navajo Code Talkers Association. Kawaho's interest and their trust led to his appointment as the group's official photographer. "The Warriors: Navajo Code Talkers" exhibi- tion at the Old Courthouse Heritage Museum is from the Traveling Exhibits collection owned by the National Atomic Museum, Albuquerque, N.M. For more information, go to- museum.com. The exhibit will be available for viewing through Nov 15. Museum hours are 10 a.m. to 4 p.m. Monday to Friday and 10 a.m. to 2 p.m. Saturday. Call Laurie Diestler at 341-6429. * WHAT: Fourth Annual Marion County Springs Festival. * WHEN: Saturday and Sunday, kicking off Saturday morning. * WHERE: West side of Marion County off U.S. 41 just north of Dunnellon. * GET INFO: Call (352.i 465.3555 p.m. each evening, there will be a special presentation, 'The Appearing" at Advent Hope. This is free for the public. More information is available at. The church Is located at 428 N.E. 3rd Ave. Crystal River. Call 563- 0202. News NOTES Inverness Seventh-day to meet Sabbath services at the Invemess Seventh-day Adventist Church will start at 9:10 a.m. with a song service. After the opening prayer, Superintendent Shirley Shaffer, will welcome guests and mem- bers. Special music by Mission Appeal will precede Shaffer's remarks to end the early serv- ice. Lesson study titled "King of Kings and Lord of Lords" by classes will be followed by the organ prelude by Dick Pike for the worship service. Elder Mercer's sermon is titled "Not Again." A vegetarian fellowship luncheon will be held in Mitchell Hall for guests and members. The evening vesper service will begin at 6:50 p.m. with Bob Baker in charge. Following the evening service, there will be game night in Mitchell Hall. The health food store will open after the vesper service. The church is 4 1/2 miles east of Inverness off of State Road 44 in Eden Gardens. For more information, call 746-3434. Social club sets schedule Citrus American and Italian Social Club of Inverness invites all to its September dinner dance on Friday. Tickets are $12 for nonmembers and $11 for members. The menu is chicken cutlet parmesan with spaghetti, salad, coffee and cake. BYOB. Music by DJ Angelo. Doors open at 5 p.m. with dinner served at 6. For tick- ets, call Angie at 637-5203. MAPP foster training to begin for parents The Family Connection is offering free monthly MAPP training for families interested in becoming foster parents. Classes will be held from 9 to 5 p.m. Saturday and from 6 to 9 p.m. Monday at the Ocala National Bank Building, Suite 600. Transportation can be arranged. For information or registration, call (352) 629-8820. The Family Connection is looking for volunteers to help serve the Foster Care Community in Citrus, Hemando, Lake, Marion and Sumter coun- ties. We need aid in the devel- opment of a support system for the foster-care community. Park to offer monthly bird walk Experienced and novice bird- watchers are invited to partici- pate in the monthly bird walk scheduled for Saturday on the Pepper Creek Trail at Homosassa Springs Wildlife State Park. This is the first bird walk of the fall season. An expe- rienced birder will be leading the walk on Pepper Creek Trail, one of 19 new birding trails in Citrus County that are part of the West Section of the Great Florida Birding Trail. Participants will meet at 7:45 a.m. at the entrance to the Park's Visitor Center, and the bird walk will begin at 8. Plan to bring your binoculars and a field guide. Pepper Creek Trail is approxi- mately 3/4 mile and follows along the park's tram road con- necting the Visitor Center on U.S. 19 and the west entrance on Fish Bowl Drive. There is no charge to use the Pepper Creek trail or for the return boat trip. Monthly bird walks will be scheduled throughout the year except the months of June through August and December. Call Susan Dougherty at 628- 5343, Ext. 102. Advent Hope to meet Saturday On Saturday, our youth will be conducting the service and Nicholas Strain, a 15-year-old student, will present the topic "Signs You Can't Ignore." Bible study starts at 10:15 to 11:15 a.m. The main service begins at 11:30 a.m. Everyone is invited to join us for this exciting event. Also, starting Friday and contin- uing through Tuesday at each 7 HES Box. Top award winners WALT CARLSON/For the Chronicle Students from Mrs. Katie Hughes 3rd grade Hernando Elementary class recently won an award by collecting the most boxtops and soup labels for the month. The money from the boxtops is used to buy equipment for the school. Front row, from left, are: Erica McGraw, Randy Castillo, Draven Ruiz, Andres Gomez, Brandon Daffron, Robert Vaughn, Nikolas Cabrera. Middle row, from left, are: Sidney Rafferty, Anna Davis, Spencer Lindall, Michael Green, Colton Keene, Jaysa Jelks, Chris Rigos. Back row, from left, are: Johnny Cazcau, Ebony Robertson, Brittany Egbert, Jaclyn Wallen, Daniel Millard, Sammantha Sutton and Jerrod Williams. Museum features Navajo Code Talkers American Legion Post 225 Special to the Chronicle American Legion's Herbert Surber Post 225 of Floral City hosted a swearing-in ceremony Sept. 13 of officers for 2005-06. Participating in the ceremony were, from left: Marie Kramer, ser- geant-at-arms for Post 155; Neal Colbath, Post 225 commander; Fred Daniels, Post 225 vice commander; Gayle Coon, Post 225 adjutant; Nate Cyr, Post 225 finance officer; Richard Ray, Post 225 chaplain; Cater J. Conner, Post 225 service officer; Jim Kehoe, Post 225 historian and publicist; Phil Hearlson 4th District commander from Post 284, who officiated the cere- mony; Jim Ramos, vice commander of Post 149; Ray Hall, vice commander of Post 58; and Gerald Montgomery, chaplain for Post 284. Citifinancial donation DAVE SIGLER/CLironicle Recently, Diana Mcintosh, executive director of CASA, accepted a $25,000 donation recently from Nelson Fernandez, Citlfinancial, a member of CitiGroup. The money will go toward CASA's advocacy program. CITRUS COUNTY (FL) CHRONICLE AA F 'a.'*AY2.SEPTEMEanR 23. 2005 MOST ACTIVE ($1 OR MORE) Name Vol (00) Last Chg Genworth 340353 29.50 -.10 Lucent 315874 3.04 -.01 Calpine 303844 2.66 +.01 Coming 272857 18.75 -1.04 ExxonMbt 240388 64.98 +.01 GAINERS ($2 OR MORE) Name Last Chg %Chg ShawGp 24.86 +2.86 +13.0 RiteAid 4.07 +.42 +11.5 vjLeDAL26 3.16 +.25 +8.6 SauerDanf 19.61 +1.52 +8.4 MarineMx 24.23 +1.65 +7.3 LOSERS (52 OR MORE) Name Last Chg %Chg ComPdtss 18.05 -3.21 -15.1 Katynad 2.30 -.29 -11.2 Delphi 3.12 -.36 -10.3 VidSanNig 15.84 -1.58 -9.1 Delphi pfA 8.55 -.85 -9.0 DIARY AdvanrCed Declined Unchanged Total issues New Highs New Lows Volume 14-55- 1,845 147 3,447 106 165 2,396,626,240 MOST ACTIVE ($1 OR MORE) Name Vol (00) Last Chg SPDR 789429 121.34 +.43 iShRs2000s331412 64.93 +.33 SP Engy 253221 53.50 -.40 SemiHTr 229409 35.93 +.17 iShJapan 174718 11.76 +.02 GAINERS (52 OR MORE) Name Last Chg %Chg EnNth g 2.89 +.82 +39.6 Cytomed n 2.45 +.22 +9.9 Cardero gn 3.34 +.24 +7.7 CenucoIf 2.78 +.18 +6.9 IncOpR s 7.00 +.45 +6.9 LOSERS (52 OR MORE) Name Last Chg %Chg GoldRsvg 2.10 -.67 -24.2 MidsthBs 31.34 -3.41 -9.8 TGCIndsn 8.44 -.86 -9.2 HomeSol 4.83 -.46 -8.7 RegeneRx n 3.55 -.30 -7.8 DIARY Advarnce,1 Declined Unchanged Total issues New Highs New Lows Volume MOST ACTIVE ($1 OR MORE) Name Vol (00) Last Chg Nasd100Tr1130718 38.64 +.14 Microsoft 693522 25.34 -.15 Cisco 468974 18.11 +.26 Orade 466917 13.52 +.23 Intel 411925 24.56 +.06 GAINERS (52 OR MORE) Name Last Chg %Chg OmniEnr 3.09 +.87 +39.2 EngSups 40.93 +7.58 +22.7 PressurBio 5.75 +1.06 +22.6 ChinaMed n23.61 +3.84 +19.4 EmpireRst 4.89 +.78 +19.0 LOSERS ($2 OR MORE) Name Last Chg %Chg Flanders 11.95 -2.14 -15.2 DynacqHItn 4.33 -.61 -12.3 Duratek 17.31 -2.27 -11.6 BookMilIlf 8.20 -.99 -10.8 QuakFab 2.56 -.29 -10.2 DIARY 3' Al..an,,eJ 555 Declined 103 Unchanged 1,047 Total issues 37 New Highs 31 New Lows 383,581,113 Volume . 1 4131 1,583 159 3,173 54 100 1,715,350,649 Here are ime 825 most a3Cive socks on Ine New Norle Siock Exchange 765 mo sr at,.,e on the Nasdaq fJatonal Markel and 116 rnost active on the American Stock Exchange. Stocks in bold are worth at leasi 15 and changed 5 percernl or more in price Unoelining for 50 most actl.e on NYSE and Nasdaq and 25 most aclie on Amex Tatles show name price and net cnarnge and one to 1O 3ddiLional fields rolaled through the week. as toliows Div: Current annual dividend iale paid on sock, based on lalesi quarterly or semiannual declaration. unless otherwise foolnoted Name: Stocks appear alphabetically by the company's full name (not its abbreviation) Names consisting ol initials appear at the beginning ol each letter's list. Last: Price stock was trading at when exchange closed for the day Chg: LOSs or gain lor tne day No change indicated by 4~ 4 Ir 'F v.~ 'Sn.' in i,.I Slade Fvootnotes. c.: 7PE ivT83ejimt.n5 4 in 9 d-Iue re'. eec ajtiled Srorel~err'Tion 5y P 1 wc rc~mF'3.e 5d Pj,** m ~a5ic.5 Id Lcm.Ein le' I 12 Iro .: a,- onpanflorrnamri6 i 6l A-' .1 c-r, ir,., Amiitcn Ei.xra n p'zErrsrr~ig &-mparc MariEIPOL'S ,,rrje rr arr. insi.3 aCar,.!ojrri. i ran ii h. rrp~riryr+ sNJpI I ILj.'M N~ aq -: 3P,131 ra iurcrr, I, urn- qualmicaiioin r.'rs, vm j I flee.4;u i. Ingi, ire jrisai r-1r., Nqm i+ Yo U0 e 1 e aat.' oni rno, tru. L[,C3r~flir(I Cit iij-1r9 pi Prasrrwd rc%:k F 4 .r pp Ho-,cmie.,Ca~ir,imir,.r-3nte ,r1ra~cae pni.ov q 'o-rdmaen ;0 Ec uai Sd ri igmiqlc. ha 1r, vm-:waOr .k raswifrprw-.' air.ic-cprijE ipitky mxi ;i+ 20p r.'rrl r..~ ~ uxitrirmuir.' vp34+. winr.mi vii%-11 be riO sae ,,he', bsEt-WK i C 2upd =-j /r,,n 1.. snbuled v*1 w3irni- allcmeing a ruichaiseof c .rai' .t l-isA 5.z ee6, r-o.n ur. .ir, ,.:tduinrj iUrCO11. 0,16 uecwitj, irjiiCorrpari.+ ir, 0..rpic, t c mirv~irierp L, raixng rraoiganri:eovjd hrrdvIF-wi~,luiipi l, vIm kprpar i,,ir.rc~ni t ,ni reem. Dlividend Footnotes: 3SE xr. dirdsr,d; wrarspmd. bt x6 r srILI I-Cij-16d rj nnalrdiurl pus0 imod',c UquidifrFg114 irnd e A 45,0v diiJcar-ad or Pao Fi+r. ai1-0 ,n,:m'r,+ I Currpr,? esrielow rms c Fr, &:r.us, ,ciieeiIb ,nT,351ei ceni di.. ni~o ar,,,omavrxa,,ti ", Sarr. olOir..pad ahar mcki lpiiI no rsegulr aI Surt, i druide,.'l.pOiadr.a Veki 1.1.1 is:6rii 404,50061d rndi adc. /oen~ P. ~kOascI.3ersdc-i pon 111: -,-s! ar,-arulkrr,v e 2*l-E - mu.Bc- viih cd-iderd, r, barriers m. Curirent r,rj.i rate. ewihat. wasdecilaaiLd br meTK)61 , irci aChO~ idsrnd ar.r.)en-:emr~aatp irlirsidiod~rrd. aeria r)al r iothl Pom.., .'3d id v ~ Arorw, I.D.irnS edi rcdr92r ~~ rayuuue.ird I Pai ,, ro appri:..irmr5p5 c5ir .viie.5 rur. eiowribii,*r, I ji& Source: The Associated Press. Sales figures are unofficial. I ~STOCS O OAS ITRS YTD Name Div YId PE Last Chg %Chg AT&T .95 AmSouth 1.00 BkofAm 2.00 B l+.li'. i,, Ir 16 1, Oi,'.i8 t .1 Citigrp 1.76 Disney .24 EKodak .50 ExxonMbl 1.16 FPLGps 1.42 FlaRock s .60 FordM .40 GenElec .88 GnMotr 2.00 HomeDp .40 Intel .32 IBM .80 -.13 +2.8 +.32 -.5 -.07 -10.2 -.10 -7.6 +.25 +2.4 +.36 -6.2 -.10 -16.4 +.52 -21.6 +.01 +26.8 -.36 +19.4 +.28 +48.4 +.06 -33.6 -.03 -8.8 -.27 -24.0 +.40 -9.3 +.06 +5.0 +.65 -20.7 Name Div Yid PE LowesCos .24 .4 21 McDnlds .67 2.0 17 Microsoft .32 1.3 23 Motorola .16 .7 20 Penney .50 1.1 "17 ProgrssEn 2.36 5.4 18 SearsHldgs ... ... 13 SprintNex .10 .4 .. TimeWarn .20 1.1 38 UniFirst .15 .4 16 VerizonCmi.62 5.1 10 Wachovia 2.04 4.2 12 WalMart .60 1.4 17 Walgrn .26 .6 28 YTD Last Chg %Chg 65.30 +2.87 +13.4 33.09 +1.67 +3.2 25.34 -.15 -5.2 22.15 -.11 +28.8 46.72 +1.24 +12.9 43.40 -.22 -4.1 121.91 +6.76 +23.2 24.31 +,.76 -2.2 18.18 +.10 -6.5 35.72 +.94 +26.3 31.94 -.01 -21.2 48.02 +.24 -8.7 43.19 +.70 -18.2 42.84 +.03 +11.6 INEE 52-Week Hiah Low 10,984.46 3,889.97 432.44 7,667.64 1,752.21 2,219.91 1,245.86 688.51 12,478.34 9,708.40 3,166.94 291.92 6,493.18 1,186.14 1,852.59 1,090.19 558.36 10,696.28 Name Net % YTU 52-WK Last Cho Chg % Chg % Chg Dow Jones Industrials Dow Jones Transportation Dow Jones Utilities NYSE Composite Amex Index Nasdaq Composite S&P 500 Russell 2000 DJ Wilshire 5000 10,422.05 3,610.58 418.38 7,519.86 1,720.50 2,110.78 1,214.62 651.16 12,106.89 +44.02 -3.35 +3.62 +44.02 +13.53 -3.40 +4.84 -10.93 +4.14 +4.42 +1.22 +34.99 -3.35 +3.82 -4.94 +13.76 +24.91 +42.75 +3.72 +15.31 +19.95 +36.39 -2.97 +11.89 +.22 +9.59 -.06 +15.09 +1.13 +11.88 NE YRKSTOKECANG YTD Name Last Chg +.9 ArdenRit 38.05 +.59 -12.4 Ashlandn 54.09 +1.94 -5.6 AsdEstat 9.65 -.10 +27.6 ABBLtd 7.22 -.05 +3.2 ATMOS 28.23 -.38 +1.7 ACELtd 43.48 -.57 +3.5 AutoNatn 19.89 +.05 +2.1 ACMInco 8.33 -4.6 AutoData 42.31 -.10 +9.3 AESCplf 14.94 +.05 -2.8 AutoZone 88.72 +2.61 +10.7 AFLAC 44.10 -.21 -45.4 Avaya 9.39 -.04 +9.1 AGLRes 36.26 -.07 -12.0 AveryD 52.80 +.10 -45.7 AK Steel 7.85 -.30 +42.6 Aviall 32.75 +.51 -1.3 AMURs 31.60 ... +37.1 Avnet 25.00 -.07 +.8 AMR 11.04 +.72 -30.8 Avon d26.79 -.21 +12.5 ASALtd 45.51 +.13 -1.8 AXISCap 26.86 -.33 +2.8 AT&T 19.59 -.13 -6.1 BB&TCp 39.50 +.31 -6.8 AUOptron 12.25 -.64 +36.3 BHPBilILt 32.75 +.29 +6.5 AXA 26.35 -.26 -16.3 BISYSIf 13.77 +.04 -5.9 AbtLab 43.91 +.81 +49.4 BJSvcs s 34.76 -.49 -2.0 AberFit 46.00 +1.64 +9.7 BMCSft 20.40 +.15 -40.2 Abitibig 4.14 -.26 +22.2 BPPLC 71.37 -.53 -6.7 Accenture 25.20 -.35 -3.3 BRT 23.53 -.07 -.5 AdamsEx 13.06 +.03 +41.6 BakrHu u60.40 -.39 +4.4 Adesa 22.15 +.10 -18.0 BallCp 36.06 -.06 -7.7 AdvMOpt 37.99 -.36 +1.2 BallyTFIf 4.29 -.12 +.9 AMD 22.21 +.11 +47.7 BanColum 20.86 +.40 -27.6 Aeropst 21.32 +.76 -10.2 BkofAm d42.19 -.07 +29.8 Aetnas 80.94 +1.06 -12.1 BkNY 29.39 +.21 -12.4 AflCmpS 52.73 -.02 +10.7 Banta u49.55 +.90 -22.3 Agerers 10.57 +.17 +4.1 Bard 66.63 +.01 +39.8 Agilent 33.68 +.04 +11.6 BamNbIs 36.02 -.16 +20.7 Agriumg 20.34 -.70 +15.5 BarrPhrm 52.58 -.57 -3.6 Ahold 7.49 -.03 +18.6 BarrickG 28.73. -.32 -5.0 AirProd 55.08 +.08 +19.0 BauschL 76.70 +.09 -1.9 AirTran 10.50 +.46 +16.2 Baxter 40.12 -.07 +6.7 Albertsn 25.48 +.18 +.9 BearSt 103.20 +.61 -26.3 Alcan 32.34 -.38 -3.6 BearingPIf 7.74 -.03 -17.6 Alcoa 25.90 -.18 +18.4 BeazrHms 57.70 +1.87 +34.9 AllegTch 29.23 -.03 -7.8 BectDck 52.39 +.34 +18.6 Allete 43.59 +.50 -7.6 BellSouth 25.69 -.10 +6.4 AllCap 44.70 ... -16.8 Bemis d24.19 -.05 +1.32 Al]Wdd2 12.54 +.02 +6.7 BestBuys 42.20 +1.20 -12.8 AldWaste 8.09 +.05 +37.4 Beverly 12.57 -.03 +19.6 AtlmrFn 39.25 -.13 -9.8 BigLots 10.94 +.34 +.4 Allstate 51.94 +.11 +35.5 Biovail 22.40 -.23 +10.1 Alltel 64.67 +2.52 -6.1 BlackD 82.94 +.76 441.4 Alpharma 23.96 -.27 -+37.6 BIkHICp 42.22 -.26 +17.7 Atria 71.91 +.28 -2.7 BIkFL08 15.42 -.02 +.6 Amdos 26.41 -.01 -1.7 BlockHRs 24.09 +.44 +66.1 AmHess 136.81 -2.57 -51.7 Blockbstr 4.61 +.21 +5.4 Ameren 52.85 -1.06 --1.2 BlueChp .6.60 -.02 +43.8 AMovilLs 25.10 -.10 +20.7 Boeing 62.51 +.10 +23.4 AmWest 8.12 -.03 -14.9 Borders d21.54 +.15 +13.5 AEP 38.96 -.04 +8.9 BostBeer 23.16 +.10 +1.1 AmExf 57.00 ... +10.5 BostProp 71.44 +.42 -11.6 AmHmMtg 29.70 4.98 -33.1 BostonSci d23.79 +.62 -9.6 AmrnntGpl 59.37 -.03 -.7 BoydGm 41.35 +1.35 +9.6 AmStand 45.30 +.58 +23.0 Brascang u44.30 +.79 -11.5 AmSIP3 10.90 -.01 +5.1 Brinker 36.86 +.24 +27.9 AmTower 23.54 -.06 -5.7 BrMySq 24.17 -.14 -1.6 Americdt 24.07 -.16 -24.3 Brunswick 37.48 +.16 +11.5 Amerigas 32.99 -.02 -5.0 BungeLt 54.15 +.71 +.5 Amriprsow 37.20 +.80 +21.1 BurlNSF 57.27 -.22 ? 2 AmerisBrg 77.60, -.44 +81.6, BurlRsc;... 79.01 +.35 .4 i Amphenol 38.25 -.16 -10.4 CFindsn d14.51 -.49 -.5 AmSouth 25.77 +.32 -3.0 CHEngy 46.60 -.22 +48.8 Anadrk u96.42 -1.55 +38.4 CIGNA 112.93 +.98 -2.1 AnalogDev 36.15 -.02 -.5 CITGp 45.60 -.23 +20.9 AnglogldAu43.93 +.56 +51.2 CMSEng 15.80 -.23 -13.2 Anheusr 44.03 -.16 +48.9 :7 i."r 21.37 -.09 +18.1 AnnTaylr 25.43 +.81 +3.5 ,: !i...': 32.88 -.62 -34.1 Annaly 12.93 -.03 +9.2 CSX 43.76 '+.01 +36.4 AonCorp 32.55 +.21 +27.6 .CVSCps 28.76 +.94 +49.8 Apache u75.74 -1.52 +22.4 CablvsnNY 30.47 -.45 +7.6 ApplBio 22.50 -.30 +8.5 CallGolf 14.65 +46.8 AquaAm 36.10 +.40 -32.5 Calpine 2.66 +.01 +7.6 Aquila 3.97 +.16 -1.9 CampSp 29.33 -.04 +88.3 ArchCoal 66.92 -.76 +111.3 CdnNRsgs 45.19 -2,11 +.7 ArchDan 22.46 +.28 -5.8 CapOne 79.35 -.06 +2.6 ArchslnSm 39.29 +.19 -19.4 CapitlSrce 20.70 -.33 -7.6 CapMpfB 12.57 -.17 +5.5 CardnlHIth 61.32 -.30 +23.3 CaremkRx 48.62 -.52 +1.9 CarMax 31.65 +.30 -15.0 Camrnival 49.01 +.21 +19.0 Caterpils 58.00 +.89 +42.3 Cemex 51.83 +.01 -8.3 Cendant 20.43 +.49 -1.4 Centenes 27.95 -.25 +24.4 CenterPnt 14.06 -.30 +7.8 Centex 64.25 +.39 +6.7 CnLtpf 87.00 -2.00 -3.8 CntryTel 34.11 -.11 +10.9 Certegy 39.41 +.61 +22.2 ChmpE 14.44 +,18 +27.4 Checkpnt 23.00 -.01 +1.7 Chemtura 12.00 +.09 +117.3 ChesEna u35.85 -.57 +21.4 Chevron 63.77 -.50 +44.7 ChiMerc u331.00+10.87 +47.0 Chicoss 33.47.+1.57 +14.2 Chubb 87.82 +.64 -13.5 ChungTel 18.20 -.20 +15.6 Cimarex 43.82 -.44 +5.5 CinciBell 4.38 +.07 +3.9 CINergy 43.24 -.23 +3.6 CircCiy 16.21 +.21 -6.2 Citiarp 45.18 +.36 -3.6 CilzComm 13.29 -.13 +11.0 ClairesStrs 23.59 +.29 -5.7 ClearChan 31.59 -.31 -6.3 Clorox 55.22 -.57 +12.1 Coachs 31.62 +1.37 +1.4 CocaCI 42.22 -.03 -7.9 CocaCE 19.20 +.09. +5.1 Coeur 4.13 -.13 +1.6 ColgPal 51.97 +.02 -4.2 Collntln 8.80 +.01 -3.8 CmcBNJs 30.97 +.63 +44.3 CVRD u41.86 -.04 +51.6 CVRDpf u36.96 +.31 -10.8 CompAs 27.69 -.03 -19.7 CompSci 45.28 -.22 +44.6 ComstkRs 31.88 +.01 -22.5 ConAgra 22.81 -.22 +60.7 ConocPhilsu69.76 -.67 +77.1 ConsolEgy 72.70 -.54 +9.7 ConEd 47.98 -.41 +13.8 ConstellAs 26.46 +.65 -28.5 CtlAirB 9.68 -.23 -8.0 Cnvrgys 13.79 -.32 +35.5 CoopCam 72.92 -.55 -32.6 ComPdts sd18.05 -3.21 +59.3 Coming 18.75 -1.04 -10.0 CorusGr 8.84 -.11 -29.6 CottCp d17.40 -1.34 -4.8 CntwdFn 35.25 +1.34 +6.7 CresRE 19.48 +.03 +41.3 CrwnCstle 23.52 -.07 +12.0 CrownHold 15.39 -.25 +24.0 CypSem 14.54 +.20 2. 9' icili r- 1. '+8.6 ,' "- '_ '. :t +15.4 DRHortns 34.90 +.72 +10.2 DRSTech 47.06 -.94 +4.3 DTE ,44.98 -.06 +4.9" DaimlC. 50.41 - -46.6 DanaCp 9.25 i, -8.8 Danaher 52.38 +.60 +4.8 Darden 29.07. +.27 -18.0 Deere 60.98 +.58 -65.4 Delphi 3.12 -.36 -89.0 vjDeltaAir .82 +.05 +70.9 DevonEs u66.52 -.65 +49.5 DiaOffs 59.89 -1.10 -35.5 Diebold d35.93 -1.54 -20.8 Dillards 21.28 +.33 -12.2 DirecTV 14.69 -.01 -16.4 Disney 23.23 -.10 -9.9 DollarG 18.72 +.31 +23.7 DomRes 83.79 -.08 -8.8 Donldson 29.72 +.72 -71.8 .DoralFinif 13.91 +.09 -16,4 DowChm 41.40 +.77 -20.6 DuPont 'd38.96 -.05 +11.6 DukeEgy 28.26 -.26 -7,7 DuqUght 17.40 +.02 -5.6 Dynegy 4.36 -.13 +9.9 ETrade 16.43 +.03 -43.0 ECCCapn d3.85 +.18 -15.3 EMCCp 12.60 +.13 +107.1 EOGRessu73.89 -.15 -20.9 EastChm 45.65 +.95 -21.6 EKodak 25.27 +.52 +40.6 Edisonint 45.04 -.66 +1.8 Edwards 44.00 -1.88 +23.7 ElPasoCp u12.86 -.15 -71.4 Elan 7.80 -.18 -5.7 EDS 21.78 -.07 -3.3 EmrsnEl 67.76 +.68 +1.0 EmpDist 22.91 -.09 +16.7 Emulex 19.65 -.02 +7.0 EnbrEPtrs 55.20 -.29 '+95.7 EnCanas u55.84 +.17 +10.5 Endesa 25.71 +.13 -11.8 EndurSpecd30.16 -.97 +16.9 Energizer 58.09 +.37 +52.3 EngyPrt u30.88 +,23 +21.5 Enerplsg u44.10 -.33 +9.3 EnPro 32.31 +.21 434.7 ENSCO u42.75 +.23 -30.6 Enterasysh 1.25 +.02 +5.1 Entergy 71.03 -1.22 -5.8 EntPrPt 24.36 -.44 +10.5 Eqtylnn 12.97 +.42 +12.1 EqOffPT 32.64 +.23 42.9 EqtyRsd 37.22 +.05 -22.1 .EsteeLdr 35.67 -.31 +4.8 EverestRe 93.88 -1.01 +20.4 Exelon 53.04 -.96 +26.8 ExxonMbl u64.98 +.01 +31.9 FEMSA 69.38 -1.53 +19.4 FPLGps 44.63 -.36 -4.6 FairchdtS 15.52 -.59 -8.0 Fainrmntg 31.86 +1.34 -37.0 FamDIr d19.67 -.39 -35.4 FannieMt d46.01 +.31 -15.4 FedExCp 83.33 +.18 -3.6 FedSignI 17.02 -.05 +14.9 FedrDS 66.40 +2.80 +7.0 Ferreligs 21.73 -.07 -26.6 Ferrolf 17.01 -.17 +25.1 RdINFns 42.97 -.02 -6.1 FirstData 39.94 -.77 -8.7 FFrnFds 19.61 -.14 -13.6 FstHorizond37.24 -.33 -53.2 FstMarb d26.30 -.60 -5.7 ,FtTrFid d18.86 -.36 +29.1 "..:i 51.00 -.50 S i..1,... 62.30 -.30 FReetEn 12.89 +.45 +48.4 RaRocks 58.90 +.28 +13.7 Fluor 62.00 +2.18 -20.9 FootLockr 21.29 +.23 -13. iF: H.nM + ": .".. -19 F,.,.Q.iLat. 42.64 +.73 . i ;,, .:1:2,4 ui 2.47 -1.68, i:, ."..,.,..L. 82.50 +1.49' +61.5 FdtnCoaln 37.25 +.75 +16.5 FrankRes 81.16 +1.66 -23.3 FredMac d56.50 -.06 +17.8 FMCG u45.02 -.26 +23.5 Freescale 22.01 -.34' +21.6 FreescBn 22.32 -.34 -43.7 FdriedBR 10.91 -.08 +233.9 FrontOils u44.51 +1.24 +20.5 Frontline 45.65 -.16 +36.3 GATX 40.30 +.65 -1.6 GabelliET 8.88 +.02 +49.4 GameStp 33.40 +.28 -16.2 Gannett 68.47 +2.22 -18.5 Gap d17.21 +.19 -56.7 Gateway 2.60 +61.6 Genentch 88.00 -.55 +12.7 GenDyn u117.91 +2.71 -8.8 GenBec 33.30 -.03 +17.2 GnGrthPrp 42.39 -.31 -7.0 GnMarit 37.17 -.52 -7.1 GenMills 46.19 +1.51 -24.0 GnMotr 30.43 -.27 +9.3 Genworth 29.50 -.10 -10.0 GaPadf 33.75 +.31 +23.5 Gerdaus 14.82 +.05 +110.3 Gianltn 55.74 -1.44 +22.3 Gillette 54.75 +.74 +22.0 Glamis 20.93 -1.06 +38.6 GIobalSFe 45.89 -.11 +9.9 GoldFLtd 13.71 -.40 +32.6 Goldcrpg 19.95 -.45 -3,0 GoldWFs 59.60 +.82 +13.9 GoldmanS 118.50 +2.82 +29.2 Goodrich 42.17 +.68 +2.3 Goodyear 15.00 -.03 +100.5 GrantPrde u40.20 +.40 -1.5 GtPlainEn 29.82 -.18 +13.6 GMP u32.74 +,39 -9.4 Griffon 24.47 -.16 +29.7 Gtech 33.65 -.02 -22.6 GuangRy 15.85 -.30 -2.4 Guidant 70.35 +.86 +14.9 HCAInc 45.90 -1.51 -2.9 HRPTPrp 12.46 +.06 +66.2 Hallibtn 65.20 -1.05 -5.7 HanJS 14.78 -10.5 HanPtDiv 8.95 +3.4 HanPtDv2 11.90 +.14 -2.1 Hanover 13.84 -.06 +24.4 Hanson 53.40 -.65 -18.1 HarleyD 49.75 +.67 +12.2 HarmonyG 10.40 -.06 -2.9 HarrahE 64.98 +1.38 +6.6 HarftdFn 73.86 +.58 +5.8 Hasbro 20.50 -.02 -6.9 HawaliEl 27.15 -.05 -4.1 HItCrREIT 36.59 +.34 +.6 HItMgt 22.85 +.08 -4.5 HithcrRllf 38.86 +.04 +50.3 HealthNet 43.40 +.78 -28.1 HedaM '4.19 -.02 -11.5 Heinz d34.52 +.32 +11.1 HellnTel 9.78 -.39 -.1 Hershey 55.50 +.02 +33.6 HewlettP 28.01 -.08 +1.1 Hibem 29.84 +.12 +6.4 HighwdPlf 29.47 +.24 -3.1 Hilton 22.04 +.77 -9.3 HomeDp 38.75 +.40 -10.5 HomePropd38.50 -.11 +3,3 HonwllIn0 36.59 -.30 -5.2 HoslMarr 16.40 +.03 +17.0 HoustEx 65.89 +.25 +3.6 HovnanE 51,32 +.94 -3.4 HughSup 31.26 -.04 +59.7 Humana 47.41 +.07 -31.7 Huntsmnnd16.74 -.26 +27.8 ICICIBk 25.75 -1.19 +13.1 IMSHith 26.24 -.04 -2.1 Idacorp 29.94 -.41 -14.2 ITW d79.51 +.65 +28.0 Imation 40.75 -.30 -47.9 ImpacMtg d11.81 -.54 +19.8 INCO 44.08 -.32 +27.4 IndlaFd 37.75 -2.51 +14.8 Indymac 39.54 +.15 -1.7 IngerRds 39.47 +1.31 -20.7 IBM 78.21 +.65 -19.2 IntlGame .27.78 +.42 -27.5 IntPap 30.43 -.19 +2.9 IntRect 45.85 -.45 -17.1 Interpubl9 11.11 +.07 +20.4 IronMtn u36.72 -.16 -12.2 JPMorqCh 34.25 +.24 +13.9 Jabil 29.13 +.09 -22.9 JacklnBox d28.44 +.74 +34.1 Jacobs u64.10 +1.66 -15.5 Jacuzzi 7.35 +.05 -14.5 JanusCap 14.37 +22 +2.0 JohnJn 64.68 -.02 -4.7 JohnsnCtl 60.49 +.39 +41.2 KBHomes 73.70 +2.98 +75.6 KCSEn u25.95 -.10 -7.9 KKR Fn n 22.57 +.46 -16.5 Kaydon 27.58 -1.9 Kellogg 43.83 -.08 -28.6 Kellwood 24.62 +.20 +63.8 KerrMcG 94.65 -2.06 -5.3 Keycorp 32.11 -.11 -5.5 KeySpan 37.28 -.15 -7.1- KimbClk 61.15 +.10 +6.1 Kimcos 30.75 +.12 +29.2 KindMorg 94.52 -1.43 +21.8 KingPhrm 15.10 -.10 +4.4 Kinrossgit 7.35 -.18 +.3 Kohls 49.31 +1.09 -173 Kraft d29.46 -.52 -52.9 KrspKrmnf 5.94 +.05 +15.6 Kroger 20.28 +.17 +9.6 L-3Com 80.25 +1.24 +13.0 LG Philips 20.32 -.38 -27.2 LLE Ry d4.55 -.01 +71.0 LSI Log 9.37 +.02 +5.7 LTCPrp 21.05 -.03 -15.5 LaZBoy 12.98 -.12 -10.7 LaQuinta 8.12 +.09 -4.1 LabCp 47.80 +.09 +1.7 Laclede 31.68 -.93 -3.0 Landrys 28.19 +.57 -32.7 LVSandsn 32.30 +.32 -46.8 LearCorp 32.43 -.13 +46.6 LeggMas s107.40 +3.50 -28.9 LeggPlat 20.21 +.26 +30.2 LehmBr 113.89 +1.39 +.9 LennarA 57.19 +3.70 -26.8 Lexmark 62.23 +.13 -10.1 LbiyASG 5.94 -.02 -12.7 LibtyMA 8.15 -.03 -4.9 LillyEli 53.95 +.26 -12.5 Limited 20.15 +.84 +9.6 LincNat 51.16 +.02 -9.8 ULindsay 23.35 -.06 +6.5 Linens 26.40 +.28 -9.1 UohsGtg 9.65 -.3f +8.8 LockhdM 60.42 -.14 +2.9 LaPac 27.52 +1.13 +13.4 LowesCos 65.30 +2.87 -19.1 Lucent 3.04 -.01 -7.6 Lyondell 26.73 +.43 -2.3 M&TBk 105.35 +.22 -12.7 MBNA 24.62 -.01 +28.1 MDURes 34.17 +.07 +52.3 MEMO 20.18 -.49 -1.1 MCR 8.72 -.01 +19.3 MGMMirs 43.38 +1.16 -11.2 Madeco 9.40 +.02 -11.4 Magnalg 73.16 -.47 -3.8 MgdHi 6.32 -.04 +10.7 Manulifg 51.16 -.36 +87.4 Marathon u70.48 -.35 -3.0 MarlntA 61.06 +1.07 -8.7 MarshM 30.03 +.77 -6.4 MStewrt 27.16 -1.72 -14.5 MarvelE 17.52 +.02 -18.2 Masco 29.89 +.38 +50.4 MasseyEn 52.55 -.95 -19.8 MatSci 14.43 -.72 -15.0 Mattel d16.57 +.13 -4.4 MavTube 28.98 -.49 -18.9 Maxtor 4.30 -.07 -15.1 Maylag 17.91 -.03 +88.3 McDerl 34.57 +.47 +3.2 McDnlds 33.09 +1.67 +3.0 McGrwHs 47.13 +.97 +45.4 McKesson 45.75 +.14 +3.8 McAfee 30.04 -.06 -17.6 MeadWvcod27.92 +.16 +26.9 MedcoHlth 52.81 -.10 -.4 Medicis 34.96 +.62 +12.8 Medtmic 56.02 -.14 +3.2 MellonFnc 32.09 +.25 +26.8 MensWs 27.01 +.94 -14.1 Merck 27.60 -.20 -36.4 MendRes 3.85 +.03 +.3 MenillLyn 59.95 +.26 +19.5 MetLife 48.40 -.60 +7.0 MichStrs 32.06 +.61 -2.3 MicronT 12.06 -.18 +11.8 MidAApt 46.07 +.22 +1.3 Midas 20.25 +.24 -46.0 Milacron 1.83 -.04 +27.6 Millipore 63.55 -.38 -14.9 MillsCp 54.25 -.41 +9.2 MitsuTkyo 11.16 +.07 -23.0 MittalStI 29.75 +25 +14.5 MobileTels 39.64 +.23 +6.9 Monsnto 59.39 -.41 -30.0 Monlpeir d23.37 -.52 +13.6 Moodyss 49.34 -.08 -6.0 MorgStan 52.20 +.45 +20.9 MSEmMkt 21.24 +.02 +28.8 Motorola 22.15 -.11 +5.5 MunienhFd 11.45 -.10 +24.8 MurphOs 50.19 -.73 +1.9 MylanLab 18.01 +.07 -11.9 NCRCps 30.50 +.40 -13.6 NalcoHIdn 16.87 +.98 -8.3 NatlCty 34.45 -.06 +19.0 NatFuGas 33.73 -.03 +1.9 NatGrid 48.90 -.31 +82.0 NOilVarco u64.24 -1.74 +38.7 NatSemi 24.90 +.13 -.5 NewAm 2.18 -39.1 NwCentFn d38.95 -.14 +4.2 NJRscs 45.16 -.21 -18.5 NYCmtyB d16.77 -25.7 NYTimes 30.33 +.33 -7.6 NewellRub 22.34 +.48 - rj,. iE :. 48.79 -1.13 t.,. r[ i..mI.1 46.20 -.03 +41.6' NwpkRs 7.29 -.38 -17.0 NewsCpAn 15.49 +.01 -14.8 NewsCpBn 16.35 -.05 +3.0 NiSource 23.46 -.24 +12.6 Nicor 41.68 +.77 -10.7 NikeB 80.95 +1.55 -40.8 99 Cents f d9.56 +.02 +40.7 NobleCorp 70.00 -.99 +50.9 NobleEn su46.51 -.08 +4.4 NokiaCp 16.36 +.01 +45.0 Nordstrmd s 33.88 +.88 +6.1 NorlikSo 38.41 +.07 -10.1 NortelNet 3.12 -.06 -14.4 NoFrkBcsd24.71 -.46 +4.3 NoestUt 19.66 -.02 -.9 NoBordr 47.73 -.51 -.9 NorthropG 53.85 -.54 -28.3 NovaChern 33.92 +.82 -2.6 Novartis 49.25 -.10 +6.1 NSTARs 28.80 -.24 +11.5 Nucors 58.35 +.37 +3.1 NvFL 15.68 -.05 -4.6 NvlIMO 15.03 -.11 +6.3 OGEEngy 28.18 -.43 +9.6 OMICp 18.47 -.14 .+49.9 OcciPet u87.46 -.92 +69.9 OffcDpt 29.49 +1.16 +1.9 OfficeMax 31.98 +.79 -16.5 Olin 18.38 +.20 +58.8 Omncre 54.97 +.30 +15.5 ONEOK 32.82 -1.12 +19.1 Oshkshs 40.73 +.58 -17.1 OutbkStk d37.97 -.02 -3.5 Owenslll 21.85 +.60 +13.4 PG&ECp 37.74 -.43 -7.9 PMI Grp 38.45 -.4 PNC 57.19 +.38 +11.0 PNMRes 28.08 -.21 -13.1 PPG d59.20 +.07 +19.6 PPLCps 31.87 -.05 -42.0 PXREGrpd14.63 -.92 +35,9 PacifCre 76.81 +.99 -32.4 Pactv d17.09 +.03 +133.3 ParkDr u9.17 +.03 -1.4 PartnerRe 61.06 -.06 440.7 PaylShoe 17.30 +.55 +103.1 PeabdyEs 82.15 -1.25 +19.9 Pengrthg u24.97 +.29 +.6 PenVaRs 52.42 -.19 +12.9 Penney 46.72 +1.24 -26.6 PepBoy 12.53 +.26 -.4 PepsiBoft 26.94 +.14 +3.7 PepsiCo 54,15 +.13 +6.3 PepsiAmer 22.57 +.16 +18.6 Prmian 16.55 +.15 +45.5 PetroKazg 53.99 +.14 +63.0 PelroCgs u41.57 -1.13 +75.2 PetrbrsA u63.45 -1.35 +79.6 Petrobrs u71.43 -1.84 -6.1 Pfizer 25.25 -.06 +18.4 PhelpD 117.10 -.89 -1.0 PhilipsE 26.24 -.60 +6.1 PiedNGs 24.65 -.07 -41.7 Pier1 d11.49 -.20 +2.6 PimcoStrat 12.38 +.09 +53.0 PioNtl 53.70 -.40 -10.4 PitnyBw d41.49 -.23 -11.0 PlacerD 16.78 -.17 +62.5 PlainsEx 42.24 -.90 -9.4 PlatUnd 28.18 -.83 -2.6 PlumCrk 37.45 +.59 +11.5 PoloRL 47.49 +1.07 +5.6 PostPrp 36.85 +.50 +4,2 Praxair 46.00 -.34 +55.7 PrecDdl s 48.88 -.72 +30.8 Pridelnt 26.86 +.04 +12.1 PrinFncl 45.90 -.09 +2.9 ProclGam 56.69 +.79 -4.1 ProgrssEn 43.40 -.22 +22.7 ProgCp u104.06 +4.51 +1.1 ProLogis 43.80 +.18 -9.0 ProsStHiln 3.23 -.03 +10.0 Providian 18.12 -.04 +19.5 Prudent 65.70 -1.27 +22.9 PSEG 63.65 -.54 -7.7 PugetEngy 22.80 -.15 +35.1 PulteHs 43.10 +1.13 +5.4 PHYM 7.01 +.01 +2.1 PIGM 9.74 -.01 -4.3 PPrIT 6.30 -.02 +30.9 Quanexs 59.86 +1.16 +58.1 QuantaSvc 12.65 +.14 +78.0 QksivRess 43.64 -.79 -6.8 Quiksivrs 13.88 -.07 -11.0 QwestCm 3.95 +.03 -11.0 RPM 17.49 -.07 -26.9 RadioShk 24.03 +.22 -.7 Ralcorp 41.62 -.33 +76.2 RangeRsc 36.06 -.36 -1.6 RJamesFn 30.48 -.67 +14.4 Rayonier 55.95 +.04 -4.6 Raytheon 37.03 +.04 -6.5 Rltylncos 23.65 -.14 +28.2 Reebok 56.40 -.05 -2.9 RegalEnt 20.14 +.33 -11.3 RegionsFnd31.56 -.01 -.2 ReliantEn 13.62 +.05 -16.1 RenalsRe 43.70 +.05 +25.3 Repsol u32.70 +:80 +58.3 RetailVent 11.24 -.03 +41.3 Revlon 3.25 -.16 +11.2 RiteAid 4.07 +.42 +17.5 RobtHalf 34.57 +.25 +5.3 RockwlAut 52.20 +.02 -7.7 RoHaas 40.84 +.93 +41.1 Rowan 36.55 -.86 -22.4 RylCarb 42.22 +.22 +6.6 RoyDShAn 66.11 -.34 -2.6 Royce 19.91 -.08 -17.4 RubyTues d21.53 +.01 +26.7 RyersTull 19.95 -1.18 +17.5 Rylands 67.60 +1.63 -4.3 SAPAG 42.29 -.26 -7.5 SBCCom 23.83 -.11 +4.5 SCANA 41.19 -:57 ... SKTicm 22.26 -.58 -.9 SLMCp 52.90 +.43 -14.0 STMicro 16.62 -.30 +25.6 Safeway 24.79 -.43 -.3 StJoe 64.00 +1.97 +10.2 StJudes 46.20 +.73 +13.3 StPaulTrav 41.99 +.01 +28.2 SaksIf 18.60 +.38 +33.1 Salesforce 22.54 -.46 -18.8 SalEMlnc2 13.37 -.34 +6.8 SelmSBF 13.88 ... +57.5 SJuanB 46.36 -.44 +.7 Sanofi 40.35 +.34 -22.7 SaraLee d18.67 +.01 -1.7 SchergPI 20.53 +.06 +26.1 Schlmb 84.43 -.05 +17.5 Schwab 14.05 +.03 +11.5 SciAtlanta 36.80 +.52 +29.7 ScottPw 40.40 -.41 -13.2 SeagateT 14.99 +.32 +23.6 SempraEn 45.35 -.14 -24.2 Sensient d18.18 +14.0 SvceCplf 8.49 -.05 +48.6 7-Eleven 35.59 +.05 +39.3 ShawGp 24.86 +2.86 -3.6 Sherwin 43.04 +1.16 +33.7 ShopKo 24.97 +.03 +20.8 Shurgard 53.15 -.12 +38.8 SiderNac u22.87 -.45 +39.5 SierrPac 14.65 -.07 -54.3 SilcnGph h .79 +.02 +11.2 SimonProp 71.90 +.35 -14.2 SmithAO 25.70 +.34 +20.1 Srnithlnts 32.66 -.63 -32.6 Solectm 3.59 -.10 -12.9 SonyCp 33.95 -2.02 +6.0 SouthnCo 35.54 +.01 +6.2 SoUnCo 24.25 -.56 -12.3 SwstAir 14.28 +.06 +153.8 SwnEngys 64.32 -1.56 -1.3 SovrgnBcp 22.26 +.10 +81.9 SpinkrEx 63.80 -.08 +18.6 SplAulh 30.55 +.36 -2.2 SprintNex 24.31 +.76 +22.5 StdPacs 39.29 +.62 -15.2 Standex 24.15 -.05 -4.9 StarwdHti 55.52 +.79 -1.6 StateStr 48.33 +.36 +16.9 StationCas 63.92 +2.53 +5.0 Steds 24.90 -.18 +5.8 sTGoldn u46.36 -.70 +3.9 Styker 50.15 -.45 -3.2 SturmR 8.74 -.06 -21.1 SunCmis d31.77 +.17 +63.4 Suncorg 57.85 -1.89 +92.2 Sunocos u78.52 +.42 -4.9 SunTrst 70.27 +.29 +50.4 SupEnrgy u23.18 -.44 -12.1 Supvalu 30.36 -.51 -41.3 SymbIT 10.16 -.08 -17.7 Sysco 31.43 -.04 -17.9 TCFFncl 26.39 +.17 +3.1 TDBknorth 30.15 -.19 +14.2 TECO 17.53 -.11 -17.1 TJX d20.83 +.52 +64.1 TXUCorp 105.93 -.63 +48.7 TXU pfD 85.01 -.54 -1.8 TaiwSemi 7.94 -.20 +83.3 TalismEg u49.42 -.50 +1.3 Target 52.60 +1.75 -2.3 TataMotn 11.65 -.22 -3.1 TelNorL 15.68 +.30 +3.2 TelMexLs 19.78 +.07 -46.3 TelspCel d3.65 -.08 +16.9 Templelns 39.99 +.70 -48.2 TempurP d10.98 -.22 +1.7 TenetHlth 11.17 +.03 +2.8 Teppco 40.51 +.07 -7.7 Teradyn 15.76 +.29 +1.4 TerexIf 48.34 -1.11 -29.6 Terra d6.25 -.13 +10.9 TerraNitro 24.75 -.79 +1193 Tesoro u69.86 +3.11 +52.2 TelraTs 28.71 -.50 +32.9 Texinst 32.73 +.54 -10.8 Textron 65.85 -.01 -24.9 Theragen 3.05 -.12 +.4 ThermoB 30.30 +.25 +7.8 ThmBet 33.16 -.28 -13.8 Thombg d24.95 +.08 -11.3 3MCO 72.80 +.47 +26.3 Tidwr u44.98 -.92 +16.5 Tiffany 37.23 +.67 -6.5 TimeWam 18.18 +.10 +9.1 Timken 28.39 +1.12 +88.8 Todco 34.78 -2.13 +3.4 ToddShp 18.721 +.01 +26.4 TollBross 43.35 +1.33 +50.4 THifgrIf 16.96 +.74 +5.5 TorchEn 6.86 +.06 -7.8 Trchmrk 52.58 +.27 +15.9 TorDBkg 48.29 +.06 +22.4. Total SA 134.42 -1.03 -5.1 TotalSys 23.06 r.19 +.2 TwnCtry 27.68 +45.3 Transoon u61.59 -.91 -37.6 Tredgar 12.61 +.08 -.7 TriContl 18.16 +.13 +18.9 TriadH 44.25 -.07 -13.9 Tribune 36.30 +8.7 Tuppwre 22.52 -.36 -2.7 Turkcells 14.00 -.97 -19.7 Tycolntl 28.70 +.42 -5.3 Tyson 17.43 +.17 +.2 UILHold 51.40 +.03 +26.3 UnFirst 35.72 +.94 +3.1 UnionPac 69.31 +.58 -35.3 Unisys 6.59 -.13 -5.8 UDomR 23.36 -.05 +5.6 UtdMicro 3.38 +.02 -19.7 UPSB 68.60 +.68 -7.6 US Bancrp 28.94 +.09 -16.9 USSteel 42.59 -.35 -1.5 UtdTechs 50.89 +.31 +21.8 Utdhlths 53.63 +1.04 -12.0 Uniision 25.77 -.08 +10.2 UnumProv 19.77 -.04 -24.0 ValeantPh 20.02 -.12 +148.5 VeleroEsul12.80 -.34 -7.8 VarianMed 39.85 -.23 +3.4 Vectren 27.70 -.10 -21.2 VerizonCmd31.94 -.01 -9.0 ViacomB 33.12 +.22 +21.6 VimpelCs 43.95 +.14 +92.9 VintgPt 43.77 -.68 -22.6 Vishay 11.62 -.27 -7.4 Visteonlf 9.05 +.12 -3.3 Vodafone 26.48 -.04 +11.8 Vomado 85.15 -.38 -16.1 WMS 28.14 -.84 -27.1 Wabash 19.64 +.07 -8.7 Wachovia 48.02 +.24 -18.2 WalMart d43.19 +.70 +11,6 Walgm 42.84 +.03 +36.3 WalterInd. 45.97 -.09 -3.9 WAMutl 40.63 -.04 -6.1 WsteM[nc 28.10 +.90 -9.9 Waters 42.15 +.19 +35.1 Weathflnt 69.32 -.82 +23.4 Wellcare 40.10 +2.30 -46.1 Wellrnn d5.76 -.15 +27.3 WellPoints 73.19 +.92 -5.4 WellsFrgo 58.80 +.39 +14.5 Wendys 44.94 +1.19 +4.1 Wescolntl 30.85 -.16 +3.2 WestarEn 23.60 -.19 -3.6 WAstTIP2 d12.36 -.04 +17.8 WDigS 12.77 -.23 +.3 Weyerh 67.44 +1,31 +5.1 Whrlpl 72.77 +.99 +30.4 WilmCS u20.83 -.15 +44.6 WmsCos u23.55 -.43 +5.4 WmsSon 36.94 +.29 -6.6 WillisGp 38.45 -.03 -26.5 Winnbgo 28.69 +.44 +15.7 WiscEn 38.99 --.51 +.9 Worthgtn '-19.76:+1.06 -.2 Wrigley 69.08 +.76 +5.4 Wyeth 44.91 +.15 -13.4 XLCap d67.28 +.65 +62.0 XTO Egys u42.99 +.33 +8.2 XcelEngy 19.69 -.02 -18.9 Xerox 13.79 +25 -25.3 YankCdl d24.79 +.05 +61.3 Yorkln 55,70 -.05 +3.2 YumBrds 48.70 +.39 -13.3 Zimmer 69.50 -4.5 ZweigTi 5.11 IIIA E IA N S OCK E XC AN E1 YTD Name Last Chg -35.8 AXS-One 1.65 +.11 +139.7 Abraxas u5.56 +.13 +31.0 AdmRsc 23.10 +.75 +196.4 Adventrx 3.32 +.10 +109.4 AmO&Gn u6.70 +.28 +140.5 AmOrBion 4.45 -.28 -55.6 AWirStar. .28 -.01 -7.5 ApexSilv 15.89 -.59 -58.5 ApolloG g .34 -.01 '-10.3 AvanirPh 3.06 -.24 -62 BemaGold 2.86 -205 +27.2 BiotechT 194.53 -.54 +94.0 BirchMtgn 3.88 +.04 -33.3 CalypteBh .26 ... -16.9 Cambiorg 2.22 -.01 +41.9 CdnSEng u2.27 -.11 +84.3 CanAro 1.99- +.21 +22.4 CavalierH 7.21 -.18 +2.4 CFCdag 5.60 -.03 +22.4 Chenieres 39.00 -1.05 -7.2 ComSys 11.14 -.26 -9.3 CovadCmn 1.17 -61.3 Crystallx d1.39 -.50 -79.3 DHB Inds 3.94- +.10 -3.2 DJIADiam 104.04 +.32 -65.2 DSLnelh .08 +.01 +11.5 DesertSng 1.84 -.09 -60.5 DigilAngel 3.05 '-.17 +185.2 ENGlobl. 8.84 -.24 -75.8 EagleBbnd .16 +20.0 EdorGldg 3.54 -.14 -3.5 Elswth 7.80 -.06 +18.4 Endvrint 4.96 -.06 +325.0 EnNthg 2.89 +.82 -4.5 FfrVLDv 14.74 -.08 +24.5 RaPUlls 15.90 +.40 +39.7 GascoEnn 5.95 -.19 -68.6 GlobeTeln dl.23 .+.02 -53.0 GoldRsvg d2.10 -.67 -11.0 GoldStrg 3.57 -.16 +55.4 GreyWolf 8.19 +.08 +40.4 Harken .73 +.04 +207.6 HomeSol 4.83 -.46 +44.5 iShBrazil 32.14 -.21 +22.0 iShCanada 21.10 -.14 +1.9 iShGerm 18.98 -.03 +9.4 IShHK 13.23 +.02 +7.7 iShJapan 11.76 +.02 +34.8 IShKor 39.42 +.31 +25.9 iShMexico 31.68 -.27 +10.5 iShSing 7.92 -.01 -6.2 iShTaiwan 11.31 -.16 +.9 iShSP500 122.03 +.52 -.3 iShLeAgBd102.05 +.09 +22.6 iShEmMktsu82.50 -.90 +1.0 iShSPBaV 63.52 +.11 +5.4 iSh20TB 93.31 -.09 -.7 iShl-3TB 80.86 +.03 +6.8 iSh EAFE s 57.04 -.06 -5.9 iShGSSft 40.14 +.10 +1.5 iShNqBio 76.50 +.05 +5.8 iShC&SRits72.09 +.25 +3.2 iShRl00OV 68.50 +.08 ... iShRlOOOG 49.14 +.33 +.9 iShR2000Vs64.90 +.34 -.6 iShR2000G 66.89 +.14 +.3 iShRs200 s64.93 +.33 +3.0 iShREsts 63.47 +.45 +3.9 iShSPSnls 56.37 +.08 +36.1 InligSys 2.75 +.14 +110.8 Intermixn 11.91 -.03 -49.5 IntrNAP .47 -18.7 IntnlHTr 57.99 +.70 +66.1 IvaxCorp 26.28 +4.1 KFXInc 15.12 +.07 -44.8 KittyHk d.85 -.10 -.3 Mernimac 9.01 -.14 -13.1 MetroHltn 2.46 +.05 +30.2 Miramar 1.51 +.04 +37.4 Nabors u70.48 -1.24 +215.8 NatGsSvcsu29.78 +.59 -2.7 NOrion g 2.83 -.05 -24.1 NthgtMg 1.29 -.01 443.8 OilSvHT 122.29 -1.11 +19.0 On2Tech .75 -.05 +21.8 PainCare 3.75 -.04 +46.4 PetrofdEgu19.09 -.31 -2.2 PhmHTr 71.08 +.08 +69.1 PionDril 17.06 +.07 -.2 PwSIntDvndl4.93 -.02 -13.3 Prvena .78 +27.0 ProvETg u12.04 -.10 -50.0 Onstakegn .20 -.01 -7.3 RegBkHT 131.60 +.35 +8.0 Rentech 2.42 -.06 -6.4 RetailHT 92.25 +1.96 +7.7 SemiHTr 35.93 +.17 +219.4 SminthWes 5.59 +.28 +.4 SPDR 121.34 +.43 +5.4 SPMid 127.54 +.65 -9.0 SPMatls 27.06 +.16 +4.2 SP HlthC 31.45 +.07 -1.7 SPCnSt 22.69 +.17 -8.8 SPConsum32.17 +.51 +47.3 SPEnoy u53.50 -.40 -4.2 SP Fnc 29.25 +.22 -5.0 SP lands 29.53 +.12 -2.6 SPTech 20.56 +.08 +17.1 SPUfil 32.60 -.18 -18.3 Stonepath .98 +.05 +273.8 TanRrggn u2.99 +.14 +26.0 TransGIb 6,45 -.27 +113.2 UltraPtas u51.31 -.19 -2.1 VaalcoE 3.80 +.20 -14.9 Wstmind 25.92 -.08 +41.4 Yamanag 4.27 -.07 I ASDAQ NATIONALM R EI YTD Name Last Chg -32.6 ACMoore d19.41 -.30 -652 ACTTele .46 +.03 +17.3 ADCTelrs 22.00 +.39 -10.1 AFCEnts 11.07 -.40 +.9 ASMLHId 16.07 -.20 -31.6 ATITech 13.27 -.22 +31.7 ATMIIInc 29.67 +.06 +72.0 ATP O&G 31.97 -1.02 -21.2 ATSMed 3.67 -.05 +66.2 Aastorn 2.36 +.08 +414 Aballx u14.25-1.31 +11.0 Abgenix 11.48 -.24 +434.3 AbleEnr 14.96 +.68 -24.4 AccHme. 37.57 +.67 -35.1 AceCash d19.25 -.33 +29.5 Acdvisns 19.60 -.05 -4.7 Actuate 2.43 -.10 -27.8 Acxiom 18.99 -.14 -56.8 Adaptec 3.28 -.01 -11.1 AdobeSys 27.88 +.01 -2.6 AdololCp 9.66 +.16 +109.2 Adstar u2.28 +.24 +62.0 Adran 31.01 +.04 -11.3 AdvDiginf 8.89 +.09 +20.8 AdvNeuro 47.65 +1.08 +18.0 Advanta 26.69 +.19 +19.5 AdvantB 29.00 +.44 -26.7 Aerolex 8.89 +.07 +15.7 Aftymet 42.30 -.07 -13.5 AgileSft 7.07 +.07 -7.9 AirspanNet 5.00 +.02 +7.1 AkamaiT 13.95 +.41 +1.0 Akzo 42.91 +1.05 +36.6 Alamosa 17.04 +.05 +48.9 Aldila 22.70 -.95 +9.9 Alexion 27.69 +.11 -41.3 AlignTech 6.31 +.04 +20.2 Alkerm 16.93 -.07 +49.7 Allscripts 15.97 -.38 -9.2 AltarNano 2.46 -.03 -10.4 AlteraCo 18.55 -.21 -39.1 Alvarion 8.07 -.25 -5.0 Amazon 42.08 +.83 +15.2 Amedisy 37.32 +.87 -4.3 ArmegyBcp 22.28 +.27 +16.0 ArnrBiowt .29 +10.5 AmCapStr 36.84 -.07 -8.7 AEaleOs 21.50 +1.11 -7.7 AmrMeds 19.30 +.20 +16.8 APwCnv 25.00 +.18 -31.8 AmSupr 10.16 -.43 +2 AmerCass 21.59 +.65 +46.4 Ameritrade 20.82 +.15 +30.9 Amaen 84.00 -.35 +21.1 Arnicas 5.39 +.01 -32.9 AnkorT 4.48 -.16 +29.1 Amrylin 30.15 -.35 -18.1 Anadigc 3.07 +.12 +7.3 Anlogic 48.08 +.12 -31.5 Analysts d2.74 -.09 -55.5 AnlySur 1.49 -.07 -20.4 Andrew d10.85 +.01 -28.5 AndrxGp 15.60 +.63 -29.1 a....:.,;r. 13.05 -.15 -19.0 .i:,1.,.u 65.40 -.06 +61.2 AopleCs 51.90 -,21 -22.6 Applebeesd20.47 +.16 -58.4 AppldDigl 2.81 -.10 +13.8 Apldlnov 3.95 -1.2 ADldMat 16.90 +,08 -30.9 AMCC 2.91 +.03 +119.8 aQuantive 19.65 +20.7 ArchCap 46.71 -.66 -1.6 AradP 7.31 -52.5 Arotech .77 -.03 +57.0 Arris 11.05 +.05 +3.2 Arrowint 31.99 +1.94 -33.3 ArtTech 1.00 -.01 4.30.6 AssetAco 27.81 -.54 -6.5 AsscdBanc 31.06 -.02 -9.9 Atheros 9,24 -.39 -49.5 Atmel di.98 -.02 -59.5 Audible d10.54 +,32 +56.5 Audvox 16.65 +.18 +8.7 Autodsks 41.25 -.11 -74.6 Avanex .84 -.04 -34.0 AvidTch 40.73 -.79 +6.8 Aware 5.18 -.29 -33.7 Axcells d5.39 +.10 -82.4 Axonyx 1.09 +.04 +5.7 AxsysTech 18.50 +.10 +24.8 BEAero 14.53 +.23 -3.4 BEASys 8.56 -.15 +178.1 BTUInt 8.48 -.79 -35.4 Baldun 79.19 -1.11 -18.9 BallardPw 5.50 -.37 +251.1 BeaconP 3.23 -.02 -26.5 BeasleyB 12.89 +.13 -7.7 BebeStrss 16.60 +1.00 -.3 BedBath 39.70 +2.28 -134 Bloenvlsn 7.76 -.44 -41.6 Biogenldc 38.91 -.51 -17.8 Biomet 35.68 -1.06 -36.9 Biomira 1.52 -.08 -66.7 Biopurers 1.18 +233.7 BluDolp 3.27 -.15 -13.7 BobEvn 22.56 +.07 -49.7 Borland 5.87 +.16 +29.2 BrigExp u11.63 +.39 +38.0 Brightpnts 17.98 +.03 +37.0 Brdcom 44.21 -.09 -48.0 Broadwing 4.74 -.05 -49.0 BrodeCmnlf 3.90 -.17 -24.2 BrooksAut 13.06 +.06 -.1 Brookstne 19.54 -.23 -54.7 Bsquare .68 -.01 +141.2 BldgMat 92.34 +3.17 -31.9 C-COR 6.33 -.24 -17.3 CBRLGrp d34.60 -.15 -30.4 CDCCpA 3.21 +.01 -11.8 CDWCorp 58.50 +.46 +10.0 CHRobn 61.09 -.21 -412 CMGI 1.50 -.04 +17.9 CNET 13.24 +26 +103.5 CNS 25.91 +.46 +188.3 CTIInds 4.18 -.30 +14.4 CVThera 26.31 -.79 -30.8 CabotMic 27.74 -.40 +47.3 CalDive 60.04 -.90 +24.9 CalPtzza 28.72 +1.47 -10.9 CanSoPt 6.68 +.24 +7.6 CapAuto 3821 -.01 +2.4 CapCtyBks 34.25 +.25 +126,8 CpstnTrb 4.15 -.24 +70.4 CaptivaSft 17.35 -1.62 -9.9 CareerEd 36.04 +.46 +132.0 Carrizo 26.22 -1.31 +14.3 CasualMal 6.23 -.11 -6.8 Celadon 20.73 -.26 +104.0 Celgenes 54.10 +.12 -74.9 Cellhera d2.04 -.10 +56.0 Centillm 3.79 -.05 +4.2 CenGardn 43.50 -11.2 Cephln 45.17 -.38 +53.3 Cemer 8t.50 -.76 +37.9 CharlRsse 13.93 +.38 +16.6 ChrmSh 10.93 +.45 -30.4 ChartCm 1,56 -.01 +10.5 Chattem 36.57 +1.25 -6.1 ChkPoint 23.13 +.07 +1.3 ChkFree 38.57 +.05 +7.5 Checkers 14.41 -.15 -4,5 Cheesecks31.00 +1.20 -3.4 ChildPIc 35.76+1.59 +45.7 ChlnaMed nu23.61+3.84 +30.4 Chiron 43.45 -,05 +10.1 Chordni 2.51 +.08 -24.0 ChrchllD 33.99 -.18 -34 4 ClenaCp 2.19 -.05 -3.4 CinnFin 40.71 +.24 -10.2 Cintas 39.40 -,14 +25.2 Cirrus 6,90 -.20 -6.3 Cliam a11_ +6 -2.8 CtrxSy 23.77 -.31 +120,7 CleanH 33.30 +,73 -23.6 Cogent 25,21-1,17 +4.9 CogTech 44.00 ..21 +32.0 CldwtuCr 27,17 +2.21 -2.4 Comarm 839 +,04 -13.8 Comcsp 28.31 -.20 -5.9 CompsBc 45.80 +.32 +47.8 CompCrd 40.40 -.34 +45.6 Compuwre 9.33 +.18 +62.1 Comtechsu40.65 +3.37 +2.8 Comvers 25.13 -.07 -40.6 ConcCm 1.70 -10.6 Conexant 1.78 -.08 -1.9 Conmed 27.87 +.27 +53.4 Conns 25.81 -1.45 -4.3 ConsolCmn 13.20 -.24 +143.2 Convera 11.31 +.28 -13.7 Copart 22.71 +.05 -29.7 CorinthC 13.25 +.28 -39.2 CostPlus d19.55 +.66 -11.1 Costco 43.05 +1.57 -79.8 Crayinc d.94 -.04 -17.8 CredSys 7.52 -.17 -40.5 Creeinc 23.86 +.29 +52.0 CubistPh 17.98 -.09 -20.5 CumMed 11.99 -.17 -16.1 Curis 4.38 -.02 +25.2 Cybergrd 7.89 -.16 +52.3 Cyberonic 31.55 -1.65 +8.4 Cymer 32.01 -.49 -12 CyprsBio 13.89 +.13 -65.9 Cytogen 3.93 +.25 -7.1 Cytyc 25.61 -.05 -4.5 DRDGOLD 1.47 -.08 +388.6 DXPEnt u23.50 +1.52 +25.8 DadeBehs 35.22 -.44 -25.9 Danka 2.34 -.04 -51.9 DeckOut 22.59 +.84" +8.3 decdGenet 8.46 +.08 -19.3 DellInc d33.99 +.63 +27.2 DltaPtr 19.95 +.35 -40.2 Dndreon 6.45 -.20 +3.9 Dennysn 4.26 +.04 -5.2 Dentsply 53.28 +1.73 +34.0 DgInsght 24.66 +.08 -15.0 DigRiver 35.35 +.36 +13.5 Dgitas 10.84 -.12 -2.6 DlscHIdAn 14.70 -.09 +1804 DistEnSy 7.01 -.48 +334.3 DobsonCm 7.47 +.28 -23.5 DIrTree d22.01 -.29 -145 DotHII 6.70 +42 -30.5 Duratek 17.31 -2.27 -16.8 Dynamex 15.41 -1.54 +24.3 E-loan 4.20 +.01 -35.2 eBaes 37.72 +.87 -15.1 EGLInc 25.39 +.29 -8.3 eReasrch 14.53 -.11 -5.1 EZEM 13.85 +.05 -40.3 EagleBkkn 16.00 +.01 -11.1 ErthUnk 10.24 -.01 -12.2 EchoStar 29.21 +.01 430.1 eCollege 14.78 -.23 -8.2 eCost.cm d.88 -,08 +61.4 EdgePet 23.53 -1.06 -6.6 EducMgt 30.83 +.05 -9.8 EduDv 9.30 -.26 -48.9 8x8 Inc 2.08 -.08 +11.9 ElectSdi 22.12 +.49 -30,6 Eclrgls 327 -.02 -5.1 ElecAts 58.56 +.10 +30.1 EFII 22.65 +.55 -13.6 ElizArden 20.50 -.10 +56,4 Emcor 5,46 +24 +24,9 E,-,* ;,.P 12.40 -.38 +34.6 E,.,...l',rm 28.27 -.22 +49.6 EndWve 20.11 +1.42 +106,2 EngyConv 3984 +30 .iLEng9sitLA9+7,M +7.3 Enlegrbs 10O + 04 +27,2 Entelrra 24,05 .53 -28.1 EnlroM i '1 r , -5612 EnaonRiPhr ,i I -14,5 E.pl)lony 4.139 1. -67.0 EpiPhar 7.71 .00 +11,0 &knTl I f 30 =9 4 +82,4 Evrgr ir i 7 .'4A -5, Exo r I ,, =.. -1683 opl8(on 20 A -341 6xdllnl 6414 11 -12.3 Explor 5.54 +.50 +54.7 ExpScripts 59.11 -2.30 -33.0 ExtNetw 4.39 -.02 -61.0 Eyetech 17.74 -.6 Ezcorp 15.31 -.74 -9.5 FSNetw 44.11 -.19 -9.9 FLIRSyss a28.74 -.15 -3.1 Fastenal 59.67 +.91 -20.7 FifthThird d37.49 -.11 +2.9 RIeNet 26.50 -1.01 -46,5 Finsar 1.22 -.08 -24.3 FAnUnes ,13.86 +.35 -6.2 FstMerit 26.73 -.24 +10.1 Rserv 44.23 +.12 ,+24.5 Flanders 11.95 -2.14 -10.2 Rextrn 12.41 -.19 -82.5 FLYi .31 +.02 -98.1 yjFoamex .07 -.01 +469.6 Forward 23.81 -1.84 -27.1 Fossil Inc d18.68 -.21 +89.5 FosterWh nu28.21 +.29 -7.8 Foundry 12.13 -.19 -10.6 FmkBTX 16.32 -.52 -29.9 Fredslnc d12.19 +.35 +91.7 FrghlCarnu40.31 -.37 +4.4 FuelCell 10.34 -.19 -12.4 FultonFnsd16.34 +.02 +209.9 GMXRs u21.60 +.20 +7.5 GSICmmrc 19.11 -.04 -2.0 GTCBio 1.49 +.31 +1.3 Garmin 61.61 -1.30 -50.8 Germstar 2.91 +5.0 GenProbe 47.49 +.55 -44.7 Genaera 1.89 -.12 -56.7 GeneLTc .52 -.03 +1.6 .GenBiotc .76 -.01 +25.8 GenesMcr 20.40 -1.00 -11.9 Genta 1.55 -.03 -8.3 Gentexs 16.98 +.08 +26.4 GenVec 2.06 -.03 +20.5 Genzyme 69.95 -.05 +300.0 Geores 12.24 -.03 +28.2 GeronCp 10.22 +.11 -3.3 GigaMed 1,75 -.06 +30.9 GileadSci 45.79 +.79 +56.9 Glenayre 3.42 -.09 +66.6 Globlnd u13.81 -.14 +.6 GIblePnt 5.17 -.38 -54.1 GlycoGenrs 1.01 -.02 +61.5 Gooele u311.37 -.53 -9.5 GrtrBay 25.23 +1.32 +4.8 GuitarC 55.24 +1.36 +1.9 Gymbree 13.06 -21 -1.9 HMNFn 32.35 +122.4 Hansens 40.49 -2.58 +3.8 HarbrFL 35.93 -.02 -36.6 Harmonic 5.29 -.21 -53.6 HayesLm 4.10 -.09 +17.7 HlthCSvs 16.35 +.58 -5.3 HIlhTroncs 1007 -.64 -15.5 HrlndE 1899 -.13 +22.3 HScheina 42,9 -.14 +24.5 HIbbett 33,12 +1.6 +103.4 HokuScin 1090 145 +87.4 ir...i,. 5147 +100 +33,7 ir.r, r..,r. 405 t,10 -17.3 HotTopic 1422 r46i I, II,.h,, i I lI II I'P Il ,rlh~h I h I -8, I I.' 1 nu10 i.1 i 11 i',l...ai..i 41627 r2l I i I I ir ,, I ii 10,7 ,' ,,.. ". i _ 11.4 i'. 090(1 iil. i t ," 29 1 i' i I '. ri -i , =4g9 I F.i'' i. r' In +311 1 .... r In 14. :1 0 Islips lu"unIi .l I i i fliid 0 n ,P i n ir, fina .,'n lu *' -28.5 Incyte 7.14 -.04 -20.1 IndpCmty 34.04 +.75 +.9 Inergy 29.00 +.05 -53.0 InfoSpce 22.35 +.30 -66,9 InFocus d3.03 -.04 +35.1 Informat 10.97 -.07 +1.8 Infosys 70.57 -.44 -22.1 InsitTc 17.67 -1.20 -44.5 Insmed 1.22 +.05 -17.7 Inslinet 4.96 -.03 -4.7 ItgLfSd 35.19 +.02 -9.9 IntoDv 10.41 -.29 +9.9 ISSI 9.01 -.12 +5.0 Intel 24.56 +.06 +118.6 Intellisync 4.46 -.23 -12.7 InterDig 19.29 +.71 +59.8 Intgph 43.04 -1.46 -46.4 IntDIsWkn 5.47 -.33 -2.3 IntSpdw 51.59 -.42 -6.6 IntemtCap 8.41 +.26 +77.6 IntmtIlnitJ 8.65 -.18 +5.1 IntntSec 24.43 +.20 +23.0 Intersil 20.55 -.27 -36.3 Intervoice 8.51 -.96 +31.2 Intevac 9.92 -.30 -35.8 IntraLasen 15.07 -.16 -71.8 Intrawre .33 -.02 +3.3 Intuit 45.45 +.84. +74.7 IntSurg 69.92 +.24 -34.8 InvFnSv d32.59 +.34 +13.0 Invitrogn 75.83 +.13 -19.4 IsleCapri 20.67 -.54 -37.2 IstaPh d6.36 -.29 +85.0 Itron 44.24 -3.06 -17.1 IvanhoeEn 2.09 +.06 +6.6 iVilage 6.59 -.04 -12.4 Ixia 14.72 -.53 -445 JDSUniph 1.76 -.04 -4.8 JackHenry 18.96 +.34 +4.9 Jamdatn 21.66 -1.37 -22.5 JetBlue 17.99 +.21 +9.7 JJillGr 16.34 -.14 +44.1 JosphBnk 40.78 +.02 +59.7 JoyGIbIls 46.25 -.77 -17.5 JnprNtw 22.42 -.28 +1.3 KSwiss 29.49 +1.81 +2.5 KLATnc 47.74 +.04 -66.5 Kintera 3.02 -.09 -22.4 KnghlCap 8.50 +.13 +55.8 Komag 29.25 -.87 +78.6 KopinCp 6.91 +.03 +72.6 Kos Phr 64.98 -.39 -14.5 Kronos 43.71 -.12 -17.6 Kulicke 7.10 -.05 +65.3 Kyphon 42.59 -.48 +51.5 LCAViss 35.44 -1.01 +392 LKQCp 27.93 +.54 +569 LSIInds 17.97 +.08 -50.1 LTX 3,84 +.08 +35.3 LabOne 43.36 +2,0 LamRch 2965 +,21 +13 LamrAdv 43.33 +.06 +2 1 LviieOl o 37,59 -T41 -2219 Lawrrp 7,74 -.8 251 La"tie 427 -01 -ft) Lawaft 1020 ,13 1,] , L I 1I IZI ri 114. 1 m ,, I'1',1 I' .Iil .n i j ,r,1 i : , ir I i, I lu +10.8 MTS 37.47 -.41 +22.0 Macrmdia 37.97 -.04 -29.4 Macrvsn 18.17 -.02 +105.3 MagelPt 2.71 +8.1 MagnaEnt 6.51 +.03 -89.3 Majescon 1.31 +.04 -44.8 Manntch d10.51 +.31 -30.3 Manuglst 2.00 -.02 -29.0 Martek 36.37 -.88 +22.6 MarvelT 43.49 -1.74 -3.8 MatrixSv 7.75 -.35 -17.3 MatrxOIf 6 5.42 +33 -35.1 Mattson 7.28 +.07 +9.8 MaxReCp 23.40 -.97 -1.2 Maxim 41.87 +.12 +25.2 MaxwlIT 12.70 +.15 -17.3 McDataA 4.93 -.07 +14.3 Medlmun 31.00 +.30 -16.2 Medarex 9.03 -.08 -82.6 MediaBay d.27 +.00 +12.8 Mediacm 7.05 +.01 -13.6 MedAct 17.03 -.21 -26.0 MediCo 21.31 -.14 -45.1 MentGr 8.39 +.10 -19.2 MercIntrlf 36.81 -.33 +.3 MesaAir 7.96 +.14 +3,3-Micrel 11.38 -.12 +7.6 Microchp 28.62 -.01 +23.1 Mcromse 6.83 +.02 +38.9 MicroSemi 24.12 -.36 -5.2 Microsoft 25.34 -.15 +11.3 MicroStr 67.08 -.70 -9.3 MIcrotune 5.54 -.31 +51.6 MillCell 1.94 -.05 -24.4 MillPhar 9.18 -.28 +4.7 MillerHer 28.93 +.43 -19.4 Mindspeed 2.24 +.06 +18.3 Misonix 7.70 -.01 +23.5 MobityBec 10.60 -.01 -15.2 Molex 25.44 -.30 +287.8 Momenta 27.38 -.06 -12.2 MnstrWw 29.55 +.10 -32.7 MovieGal 12.83 +,37 +198.5 Myogen 24.09 +.09 -7.0 NABI Bio 13.62 +.32 +31.4 NETgear 23.87 -.05 +137.6 NGASRs u10.86 -.23 +59.8 NIl Hldg 75.84 +.92 -46.9 NPSPhm 9.70 -.20 -15.2 NTLInc 61.84 +.84 -3.2 Nasdl0OTr 38.64 +.14 +132.6 Nasdaqn 24.70 +.19 +12.2 Nastech 13.58 -.30 -3.0 NatlAlHn 11.45 +.40 -66.6 Navarre d5.88 +.01 -19.8 NektarTh 16.24 -.89 -49.1 Net2Phn 1.73 +106.1 NetLogic 20.61 +.01 +56.6 Netease 82.87 +.44 +91.6 Netlix 23.62 +.95 -27.3 NetwkAp 24.14 +.43 -5.3 Neurcrne 48.71 -.62 -24.5 NewFmt 5.98 -42 -463 Newlek 231 +.02 +60 NexMed 1.59 -.03 +2,1 NoxtPrt 2522 +.11 -34,7 NitroMed 17,39 -,11 +278. NobityH 30,00 -410 NoAmne 3118 -.1 -7 NlOTif 41122 +,15 -.-" ,._ ,!tn; .I .1 ^ I NviWri II r It +,60 A4V1 NbvoIo 160 +*11 471 Novil 17 ol00 I.I? ?l,., ', ", =05 .l i ii. i I4 I r m, i, ..I 1 i . JiI < 1,,.1 h i 1 I",n Il' ,JiI 'I 1"ivi : '. -35.1 OpenTxt 13.02 +.01 +5.1 SFBCIntl 41.53 -1.60 -14.3 Telikinc 16.41 +21.3 OpnwvSy 18.76 +.18 -1.4 Safeco 51.49 -.31 +11.4 Tellabs 9.57 +.07 -38.4 Opsware 4.52 +.02 +17.5 SalixPhm 20.66 -.29 +41.3 Terayon 3.83 +.02 +63.8 OptimalAg 19,30 +.89 +75.4 SanDisk 43.79 -1.51 -19.8 TesseraT 29.83 -.22 +17.0 OptionCrs 13.41 -.14 -52.2 Sanmina 4.05 -.15 -1.0 TetraTc 16.58 +.05 -1.5 Oracle 13.52 +.23 -18.2 Sapient 6.47 -.22 +11.2 TevaPhrm 33,19 -.16 +11.4 Orthlx 43.53 +.03 +5.4 Sateen 2.13 -.08 -8.2 TexRdhsAn27.14 -.46 -43.6 Oscient 2.06 -.09 +22.9 ScanSoft 5.15 +.05 -13.2 3Com 3.62 -.03 +18.5 OflerTall 30.26 +.15 -8.0 Schnitzer 31.20 -.56 -384 TibcoSft 8.22 +29 -42.0 Overstk 40.03 -.02 ... Scholastc 36.96 +1.08 -11.6 TiVolnc 5.19 "_ _ +19.6 SdGames 28.52 +.60 +14.7 TomOnlinu17.50 +1.15 -69.0 SeaChng d5.40 -.10 +532 TorRes 33,99 +1.06 -45.3 PETCO d21.59 +.53 +23.2 SearsHIdas121.91+6.78 +26 5 TracSu 47.43 -.44 -21.7 PFChng d44.10-101 +6.8 SecureCmp10.66 -39 +27.5 Trac upp 47.43 -A -22.6 PMCSra 8.71 +01 +7.2 SelCmfirt 19.24 -.01 -14.1 Tmsmeta 1.40 -.02 -14.2 Paccar 69.08 -.02 +7.3 SelclIn 47.49 +.24 ... TnSwic 1.54 -.02 -1.8 PacSunwr 21.87 +.89 -28.6 Semtech 15569 +.16 -76.6 Travelzoo 22.30 -.43 +10.8 PalmInc 34.97 +.66 -7.3 Sepracor 55.01 -.14 +76.7 TridMic 29.55 -,83 +40.7 PalmSrce 17.92 -9.9 SerenaSIt 1946 -32 -.9 TrimbleN 32.75 -.45 +7.1 PanASl 17.12 -.32 +1.9 Serolog 22.54 -.40 -81.2 Trinscrsh .32 +.08 +50.8 Panacos 9.80 -.70 -37.1 Shanda 26.75 -.40 -23.8 TriQuint 3.39 +.04 +23.1 PaneraBrd 49.62 +.41 +16.0 ShirePh 37.06 +43 +4.7 TrueRelgn 15.50 +1.05 +37.8 PapJohn 47.47 +.32 -19.8 ShufflMsts 25.19 -.03 -8.8 TrstNY 12.58 -.04 +145.8 ParPet 13.25 -.38 +114.6 SiRFTch 27.30 +.08 -11.8 Trustmk 27.40 -.05 +11.2 ParmTc 6.55 +.07 -1.9 SiebelSvs 10.29 -.01 -15.5 TuesMm 25.87 +.03 +83.0 Pathmrk 10.63 +.12 -37.8 SierraWr 11.00 -.15 +16.2 TumblwdC 3.88 -.01 -9.2 Pattersons 39.41 +.07 -44.4 SigmaTel 19.74 +.25 -53.8 Tweeter 3.18 -.12 +72.4 PastUTI 33.53 -.28 -15.3 SignatBk 27.40 +.89 +37.2 24/7RealM 5.94 -.05 -3.8 Paychex 32.80 -.04 -45.3 Silicnlmg 9.00 -.09 -63.9 UTStrcm 8.00 -.22 +3.8 PnnNGms 31.44 +.44 -13.7 SilcnLab 30.47 -.53 +27.1 Ubiquin 9.05 +.14 -12.0 Peregrine 1.03 +.01 -18.5 SST 4.85 -.10 -47.1 Ulralife 10.29 +.23 +12.6 PerFood 30.29 -.01 +33.8 SIcnware 5.08 +.13 -21.7 Ultratech 14.76 +.03 -17.4 Perrigo 14.26 +.07 +10.3 SilvStdg 13.33 -.32 +21.1 UFireCs 40.81 -.14 +40.6 PetMed 10.70 +.35 -20.1 Sina 25.63 +.04 +7.6 UIdNtIF 33.45 -.43 +61.1 Petrohwk 13.79 -.2075 -13.5 SiriusS 6.59 +13.7 UtdOnIn 13.11 -.10 +107.1 PetDvi 3815 -.2275 +23.0 SkyWest 24.67 +.18 +39.9 USEnr 4.14 -.13 -38.4 PesMart 21.88 +.03 28.6 SkywSol 6.73 -.11 +29.3 UtdSurgs 35.94 -1.06 +18.7 Photin 19,59 +.17 -33.7 SmIthMcro 5.93 +.39 +290 UnivFor 56.00 +.34 -46.2 SrnurSte 10.05 -.11 +21.3 UrbnOut 53.85 +1.38 -47.7 PinnadA 7.29 +.22 -5.6 Sohu.cnm 16.71 +.13 +213 UraO 53.85+138 -3.4 Pixars d641.30 -.03 -9.6 SonicCorp 27.57 -.44 +27. P ss 16.52 -.2 -1.9 SncWall 6.20 -04 +212 VCAAnt 23.68 -03 +10.5 PlugPower 6.752 -.230 -11.3 Sonus 5.08 -.15 -12.2 ValTech 2.73 -.07 +19.7 Plumtree 5.41 -.02 -22.4 SotMo 14.35 -.65 +16.3 ValueClick 15.50 -31.9 Polycom 15.88 -.12 -50.4 SpaeiaLt 4.44 -.30 +11.8 VarianS 41.20 +.02 -14.2 Popular 24.73 +03 -6.4 StageSts s25.90 +.07 +32.2 VascoDta 8.75 +.01 +10.7 Popullayn 24.731 +.0321 +59.0 StdMic u28.35 +3.58 3 2 . +10.7 PorPlayn 27.31 +.21 -7.0 Sapless 20.89 +20 -56.3 Vasogeng 2.22 -.10 +45.2 PosssWa 120.8931 +.14 -31.6 StarSen 38 -.10 -24.8 Veecolnst 15.85 +.01 45.6 Prowaek 12.31 +14 -22.5 Starbucks 48.31 +1.64 -74.2 VelctyEhrs 3.61 +.07 +1.0 PrceTR 62.80 +99 -16.2 StDyna 31.75 -.81 +12.8 Ventanas 36.08 +.44 19.5 prceline d18.98 -36 +10.2 SeinMt 18.80 +.26 +24.2 Ventiy 25:24 -.60 -66.0 PrimusT 1.08 +10 +22.7 StemCells 5.19 -.07 -36.3 Verisin 21.39 -.04 +27.3 PiHllh 27.71 -.12 +20.0 Stricycle 55.12 +.40 -41.5 VersoTch .42 -.03 238.5 ProgPh 23.77 -33 -6.9 StewEnt 6.51 +.03 +75.6 VerlxPh 18.56 -.47 +.3 ProspBcsh 29.30 +1,00 +81.9 StoltOffsh 11.79 -.18 +435.7 ViroPhrm 17.41 -.72 +37.3 ProtDsg 28.37 -.03 +6.2 Stratex 2.40 -.01 -42.2 Vitesse 2.04 -.02 +44.6 PsycSol 52.88 +19 -180 Strayer 89.99 -1.92 -37.4 Volterra 13.88 +.24 -54.8 QLT d7.27 +.05 +158.5 StrchMb u4,86 +.26 -43.8 WPTEnt 9.55 +.71 -11.0 Qlogic 3269 +29 +611.1 StrMbwt ul.28 +.30 +3.8 Wamaco 22.42 -.36 +3.8 alcom 44.00 +27 -27.8 SunMicro 389 -.05 +48.2 WarrenRsn 13.49 +.03 -38.2 QuantaCapd5.70 -.32 -55.4 SupTech .62 -.03 +26.6 WashGnlt 52.21 +2.07 -37.5 QuanFuel 3.76 -17.0 SuperGen 5.85 -.06 +28.3 WebMD 10.47 +.03 -52 QuestSllw 15.12 +25 -3.6 SusqBnc 24.05 -.12 +50.6 WebSkle u1872 +.68 -17.7 RFMicD 5.63 +.06 -19.5 SwiTTm 17.29 +.59 +3.3 WebEx 24.56 +.03 -34.1 RSASec 13.22 +.02 -J- "-.'- _. ._ .i.. +3.3 Websense 52.38 -.11 -19.0 ROnoD 13.05 -.10 -" .1,"". '- -27.8 WemnerEntd16.34 +11 -515 Rambus 11.15 +.25 +64.5 Synagro 5.00 +.14 -40.4 WsMar dl4.74 -.37 +39,8 ',1,..iu., 1596 +.10 -40.2 Synaptics 18.29 -.28 +8.8 Westaff 4.10 +.01 -19.1 "r.tv. p 2577 +87 +17.6 Syneron 36.00 +.72 +80.2 WetSel 4.09 +.13 -174 RalNwk 5,47 -04 -50 Synopsys 1858 +.12 +34.4 WhleFd 128.13 -1.23 +21.9 RodHatl 1627 .11 -16.5 Synovis 9.03 -.34 -14 WmsScolsn15.75 -190 RedRobin 42.97 +77 +903 SynxCP 15.28 -14 8.0 WindRv 1247 -.06 3m5 Rehback 1037 <,16 +A4 T 34 3 -569 WoidGte 215 -.12 ,1. Rlm n 536 +.07 397 THOQs 21 37 -.09 -49 WgM 2424 -.30 RnlACIt 200 W3 -309 TLCVima d720 -149 WnghlM 2424 -64 ii ".r 14.1 ro4 t 501 2 TOPTank 1541 +23 6732 W" 44,67 +72 1 ,f1 ,,,, i (. a -5 f1akelTws 220~-3 67 SXMSI 3509 28 i*t i i i 40 Tfa .' V 1245 1,-113 -1 X0IA x 7657 4+39 77, 1 i 00 -21,3 xnl t12,99 -1.29 ,u n ', ,, :l -7 i b ri. -, i9 01 ,._5 ,- IN nir li,,,, rii. 3_ tilB 4 1A .411 ,t..h 9' 415 03 i n, Ie ; i. ,-.A i t.l : i,-i el t-l 1.3113 1.2984 Brazil 2.2850 2.2745 Britain 1.7891 1.8100 Canada 1.1684 1.1690 China 8.0876 8.0907 Euro .8233 .8185 Hong Kong 7.7604 7.7617 Hungary 204.12 201.59 India 43,920 43.850 Indnsia 10215.00 10205.00 Israel 4.5870 4.5800 Japan 111.65 111.24 Jordan .7085 .7089 Malaysia 3.7685 3.7685 Mexico 10.8450 10.7960 Pakistan 59.85 59.85 Poland 3.22 3.18 Russia 28.3900 28.3512 SDR .6832 .6830 Singapore 1.6807 1.6795 Slovak Rep 31.70 31.44 So. Africa 6.3246 6.3426 So. Korea 1027.70 1030.20 Sweden 7.6968 7.6395 Switzerlnd 1.2790 1.2700 Taiwan 33.10 33.05 U.A.E. 3.6725 3.6727 British pound expressed in U.S. dollars. All others show dollar in foreign currency. Yesterday Pvs Day Prime Rate 6.75 6.50 Discount Rate 4.75 4.50 Federal Funds Rate 3.75 3.6875 Treasuries 3-month 3.39 3.36 6-month 3.68 3.65 5-year 3.99 4.00 10-year 4.18 4.22 30-year 4.46 4.52 FUTURES Exch Contract Settle Chg Lt Sweet Crude NYMX Nov05 66.50 -.30 Corn CBOT Dec05 2081/4 +13/4 Wheat CBOT Dec 05 3321/4 +7 Soybeans CBOT Nov 05 580V2 +23/4 Cattle CME Dec 05 88.40 +.52 Pork Bellies CME Feb06 85.35 +2.00 Sugar (world) NYBT Mar 06 10.68 +.19 Orange Juice NYBT Nov05 98.30 +1.30 SPOT Yesterday Pvs Day Gold (troy oz., spot) $466.60 $455.50 . -, ,r spot) $7.353 $7.019 - ,,l, , ip .. ~_i-- $ 1 .0 1 U U $i1 .b f/ NMER = New York Mercantile Exchange. CBOT = Chicago ii.,,,t,.1 7-..de. CMER = Chicago Mercantile Exchange. I, -1 rj.w York Cotton, Sugar &Cocoa Exchange. ;;, ] : J.. York Cotton Exchange. CPJ% PRIDAY, 3EP-l-EMBLU Zo, Z.Ukj::) THE MARKET IN REVIEW 4 I - FRIDAY, SEPTEMBER 23, 2005 9A CITRUS COUNTY (FL) CHRONICLE MTALFND 5-Yr. Name NAV Chg %Rtn AARP Invst: CapGrr 45.70 +23 -29.7 GNMA 15.01 +.01 +31.0 Global 30.56 -.16 +22.9 Gthinc 22.37 +.14 -8.2 Il 48.52 -31 -1.6 PthwyCn 11.81 +.02 NS PhwyGr 13.50 +.03 NS ShTrmBd 10.05 +.01 +21.6 SmCoSlk 25.43 +.0 8 +612 AIM Investments A: Agisv p NA BasValAp NA ChatAp NA Consmp 23.56 +.07 -37.8 HYdAp NA InlGrow ... ... NA MdCpCEq 29.85 -.03 +36.6 MuBp 8.15 +.01 +31.1 PremEqty NA SelEqly 17.73 +.06 -39.0 Sunitl 11.46 +.03 -44.2 WelgAp NA AIM Investments B: CapOvBt 17.77 +.03 +6.7 PremEqty NA AIM Investor CI: Eeoy .. NA SinCoGlp NA Uties 1425 -.12 -9.0 AMF Funds: AdMig 9.72 ... +17.1 Advance Capital I: Balancpn 18.04 +.03 +24.6 Retincn 10.03 ... +45.9 Alger Funds B: SmCapGrt 4.77 +.01 -303 AlllanceBem A: AmGvlncA 7.72 -.01 +55.8 BalanApx 17.23 -.02 +29.1 GbTchAp56.07 -.08 -57.3 GrincAp 3.73 +.02 +9.8 SmCpGrA 23.06 +.03 -15.5 AlllanceBem Adv: LgCpGrAd19.70 +.10 -41.7 AllianceBem B: AmGvIncB 7.72 ... +49.8 Cop8dB p 12.05 -.01 +36.0 GbTchBt 50.57 -.07 -589 GrowthBt 24.08 +.12 -26.8 SCpGrBt 19.39 +.02 -18.8 USGovtIBp7.03 ... +24.4 AIllanceBern C: SCpGrCt 19.44 +.02 -18.7 Allianz Funds C: GwthCt 17.63 +.06 -47.6 TagtCt 15,5 +.03 -40.5 AmSouth Fds Cl I: Value 15.74 -.98 +14.4 Amer Century Adv: EqGpn 22.89 +.06 -3.4 Amer Century Inv: Balanced n16.80 +.03 +12.1 Eqlnc n 8.06 +74.1 Growthlin 19.61 +.07 -332 Herilageln13.47 +.01 -14.7 IncGron 3132 +.04 +2.8 In liscrn 15.62 -.07 +212 IntlGroln 9.57 -.06-13.4 LifeSdn 533 ... -73 New0pprn5.68 -.02 -51.3 OneChAgnll24 +.01 NE RealEstin 26.50 +.12+141.9 Selotn 362.82 +.16 -26.8 Uta n 28.56 +21 -26.6 UfM n 13.88 -.07 +4.9 Valuelnvn 7.34 +.02 +71.1 Amer Express A: Cal 525 ... +29.6 Discover 9.01 +.02 +112 DEI 11.95 +.03 +52.8 DiNrBd 4.86 ... +31.0 DvOppA 7.47 -.01 -10.0 EqSel 13.65 +.01 -10.7 Growth 27.82 +.17 -46.4 HiYld 4.46 ... +29.8 Insr 5.46 ... +292 MgdAJlp 9.88 +.01 +10.7 Mass 5.40 ... +29.0 Michi 5.32 ... +309 Minn 5.32 +.01 +30.0 Mutualp 9.85 +.02 -11.6 NwD 2335 +.09 -254 NY 5.14 ... +30.7 Ohio 5.31 +.01 +27.4 PreMt 10.30 -.15+118.1 Sel 8.63 ... +24.9 SDGot 4.77 ... +20.1 Slockp 19.78 +.08 -13.5 TEBd 3.90 ... +30.6 Thdln8 6.30 +.01 -16.8 ThdIlnt 7.77 -.04 -17.7 Amer Express B: EqValp 10.79 +.02 +122 American Funds A: AmcpAp 18.41 +.05 +12.5 AMutlAp 26.81 +.04 +41.8 BalAp 17.88 +.05 +50.8 IBondAp 13.44 -.01 +40.8 CapWAp 19.55 -.06 +63.8 CaplBAp 53.52 -.19 +66.8 CapWGAp3626'-.15 +60.8 EupacAp 39.65 -.30 +242 'idri,4A p '3 -1'i .160 G.CnLA(f. A41I 1 -6 HiTrAF. 1) 2 -t.' 139 IncoAp 18.50 -.03 +56.5 IniBdAp 13.59 +.01 +27.1 ICAAp 31.41 +.09 +18.5 NEcoAp 21.56 -.02 -13.1 NPerAp 29.16 -.14 +21.2 NwWddA 37.17 -23 +69.4 SmCpAp 34.15 -.06 +3.1 TxExAp 12.55 ... +34.0 WshAp 30.69 +.10 +31.1 American Funds B: BalBt1 17.83 +.04 +45.2 CaplBBt 53.52 -.19 +60.3 GrwthBt 28.43 -.01 -5.3 IncoBt 18.40 -.04 +50.6 SICABt 31.30 +.08 +13.9 i WashBt 30.54 +.10 +26.1 I Ariel Mutual Fds: Apprec 47.65 +20 +73.3 Ariel 53.81 +.02 +98.4 I Artisan Funds: r i 23.90 -.09 +7.0 I MCap 30.06 +.05 +3.7 MidCapVal 19.22 +.02 NS Baron Funds: Asset 55.09 +26 +20.4 Growth 45.58 +.13 +72.2 l SmCap 22.45 -.02 +54.6 I Bernstein Fds: S IntDur 13.35 +.01 +33.3 I DvMu 14.13 +.01 +25.4 STxMglntV 24.15 -.13 +40.6 IntVatl 22.70 -.13 +42.2 SlackRock A: SAuroraA 40.85 +.10' +71.6 HiYlnvA 8.10 -.02 +45.5 SLegacy 13.56 +.05 -18.8 Bramwell Funds: i Growthp 20.11 +.10 -23.0 I Brandywine Fds: I Bmdpywnn30.36 -.03 -02 I Brinson FundsY: lHYilYn 7.15 -.01 +38.5 CGM Funds: CapDvn 34.06 +.06 +42.4 Muin 28.71 -.07 +31.8 SCalamos Funds: Gr&lncApx30.84 -.13 +312 i GrVtp 52.83 +14 +14.7 SGrowthC 50.64 +14 +12.1 Calvert Group: I lncop 17.14 +.01 +48.2 I IntEqAp 19.81 -.10 +1.3 I MBCAI 1034 ... +19.7 I Munlni 10.89 -.01 +28.0 SociltAp 228.11 +.07 +074.2 SocBdp 1629 +.01 +45.4 SocEqAp 35.04 +.12 +14.8 TxFU 10.59 ... +13.4 TxFLgp 16.77 .. +342 TxFVT 15.9 ... +28.6 i Causeway IntI: lnslitutrn165.8 -.10 NS I Clipper 87.56 +.17+53.2 Cohen & Steers: Columbia Class A: Acomt 2723 +.05 NS Columbia Class Z: AcomZ 27.85 +.05 +80.3 Columbia Funds: ReEsEqZ 27.19 +.16+108.0 DavIs Funds A: Davis Funds B: NYVenB 30.84 +,12 +12.0 Davis Funds C &Y: Delaware Invest A: i TxUSAp 11.66 ... +38.0 Delaware Invest B: I DelchE 329 -.01 +21.7 Dimensional Fds: IntSmVan 17.56 -.13+1606. USLgVan2123 +.02 +64.7 i US Micro n1527 ... +72.8 USSmalln19.89 +.03 +54.4 SUS SmVa 27.77 +.10+127.7 SntSmCon16.15 -.10+109.1 EmgMkin 19.09 -.16 +942 IntVan 1734 -.14 +71.5 TM USSV 24.56 +.06 +97.7 DFARIEn 2454 +.06+138.5 SDodge&Cox: SBalanced 80.94 +.04 +72.4 Income 12.81 ... +42.8 InlOSk 33.59 -35 NS Stock 134.26 +.07 +82.7 Dreyfus: Aprec 39.98 +.09 -2.6 Discp 32.64 +.14 -19.3 Dreyf 10.30 +.05 -15.1 Dr500lnt 35.70 +,14 -11.3 EirgLd 45.38 +.01 +21.9 FL Int r 13.29 ... +26.' InsMuin 18.02 ... +31.2 StrValAr 29.45 +.08 +28.1 Dreyfus Founders: GrowthS n 9.93 +.02 -47.A D GwhFpn10.44 +.03 -45.0 Dreyfus Premier: CoreEqAt 114.86 +.04 -9.1 ConVlvp 30.69 +.08 +13.1 LtdHYdAp 7.27 -.03 +17,; TTl Ctg 15.90 +.04 -11.7 TcA rVA 22.17 -.10 -64.9 Eaton Vance Cl A: ChinaAp 14.63 -.06 +18.1 GrwthA 7.29 -.04 -9.5 InBosA 6.38 -.01 +33.3 SpEA 4.81 ... -42.2 M "Bdl 10.79 ... +44.4 TradGvA 8.61 +.01 +26.9 Eaton Vance Cl B: FlIMBt 10.95 -.01 +31.9 HthSBt 11.44 +.02 -7.2 NaOMBt 10.57 ... +44.1 Eaton Vance CI C: GovtCp 7.41 ... +22.0 NalMCt 10.06 -.01 +42.1 Evergreen B: DvrEdBt 14.80 .. NS MuBdBt 7.53 ... +29.6 Evergreen C: AstAOCt 13.78 +.02 NS Evergreen I: CorBdl 10.63 ... +39.6 SIMurnil 10.01 ... +225 Excelsior Funds: Energy 28.61 -.32+111.3 HIYeldp 4.55 -.01 NS ValRestr 45.22 -.02 +41.4 FPA Funds: Nwnc 11.04 ... +35 Federated A: Arn.drA 25.02 +.09 +9.6 MidGrStA 32.09 +.12 -232 MuSecA 10.78 -.01 +33.4 Federated B: StrncB 8.69 -.01 4442 Federated Insti: Kaufm 5.57 -.01 +39.4 Fidelity Adv Foc T: HrCarT 22.66 +.04 +1.9 NatResT 42.82 -.41 +96.9 Fidelity Advisor A: DivlnAr 20.56 -.15 +43.0 Fidelity Advisor I: EqGdrn 48.36 +.04 -31.7 Eqlnl n 2927 +.08 +352 IntBdln 11.05 +.01 +36.8 Fidelity Advisor T: BalancT 16.25 +.01 +4.8 DivGrTp 11.52 +.03 -2.5 DynCATp 14.86 +.07 -24.3 EqGrTp 45.83 +.03 -33.6 EqlnT 28.90 +.07 +31,5 GovinT 10.09 +.01 +33.5 GrOppT 30.83 +.15 -19.7 HilnAdTp 9.81 -.05 +49.1 IrntBdT 11.03 ... +34.8 MidCpT p 26.09 -.02 +25.9 MulncTp 13.21 ... +37.2 OmseaT 18.78 -.15 +0.8 STFir 9.46 ... +242 Fidelity Freedom: FF2010n 13.92 +.01 +10.5 FF2020n 14.35 +.01 +32 FF2030n 14.52 +.01 -1.6 FF2040n 8.53 ... -4.9 Fdelty Invest: Agrirrn 16.84 -.06 -66.7 AMgrn 16.16 +.02 +5.6 AMgrGrn 14.77 +.02 -4.4 AMgrlnn 12.93 -.01 +26.6 Balancn 18.13 +.01 +42.4 BlueChGrn41.43 +.16 -28.9 CA Mm n 12.61 +.01 +343 Canadan 41.30 -.32 +80.7 CapApn 26.36 -.02 +8.7 Cplncrn 8.41 -.01 +39.1 ChinaRgn 18.45 -.14 +30.6 CngSn 401.31 +.45 +2.9 CTMunrn11.63 +.01 +33.5 Contran 62.15 +.02 +20.3 CnvSon 22.21 -.05 +16.4 Destln 13.23 +.04 -23.5 Destlln 11.60 -.03 -15.1 DisEqn 26.89 +.10 -2.4 nDivlnn 31.40 -.26 +45.1 DivGtrhn 27.84 +.08 -0.7 EmrMkn 16.34 -.06 +83.8 Eqlncn 52.47 +.0 8 +222 EQII n 23.79 +.07 +21.4 ECapAp 23.97 -.26 +35.7 Europe 38.64 -23 +263 Exch n 27427 +1.94 +7.8 Export n 20.88 +.05 +29.3 Fideln 30.20 +.06-12.7 Fiftyrn 21.19 +.05 +27.0 FLMurn 11.69 ... +34.3 FrinOnen 25.87 +.03 +4.1 GNMAn 10.99 +. +31.9 Gtlncn 10.25 +.01 +35.2 GroCon 58.50 +.03 -32.Q Grolncn 36.69 +.13 -72 Grolnclln 9.79 +.01 -4.6 Highlncrn 8.82 -.02 +23.9 Indepnn 18.45 +.0 -23.6 IntBdn 10.41 +.01 +35.9 IntGovn 10.16 +.01 +31.5 InDiscn 31.08 -.22 +31.9 lntnSCprn2824 -.20 NS InrvGBn 7.47 ... +39.1 Japan n 14.51 -.04 -17.7 JpnSmn 13.94 -.06 +29.4 LatAmn 29.71 -.18+117,8 LevCoStk n25,20 -.07 NS LowPrn 40.54 -.01+1302 Magelnn104.91 +.48 -17.8 MOMurn 11.01 .. +32.8 MAMunn 12.15 .. +37.0 MIlMunn 12.03 +.01 +353 MidCapn 25.12 -.02 +0.3 MNMunn11.56 +.01 +32.6 MtgSecn 11.18 +.01 +35.5 Munilncn 13.09 +.01 +39.3 NJMunrn11.76 .+.01 +352 NwMkIrn 14.64 -.01 +96.4 NwMMn 32.69 -.05 -182 NYMun 13.04 +.01 +37.9 OTCn 35.28 +.11 -39.8 Oh Munn 11.94 +.01 +3.3 Ovrsean 37.86 -.40 +4.1 PcBasn 22.47 -.14 +14.2 PAMunrnI10.06 +.01 +34.4 Puitnn 18.57 +.01 +28.5 RealEn 30.50 +.10+138.5 StIntMun 10.27 +.01 +21.9 STBFn 8.91 ... +264 SmCaplnd n21.16 -.03 +34.3 SmllCpSrn18.10 -.03 +48.3 SEoAsian 19.44 -.09 +60.2 StkScn 23.53 +.04 -12.2 Strallncn 10.60 -.01 +56.4 Trendn 55.01 +.15 -8.5 USBIn 11.04 ... +39.6 Uiltyn 14.86 -.03 -14.6 ValStran 36.03 -.02 +48. Value n 76.75 ..+103.3 Wrldwn 19.13 -.10 +18.8 Fidelity Selects: Airn 35.52 +.17 +14.2 Auto nn 34.42 -.23 +68.4 Bankng n 36.82 +.12 +45.3 Biotchn 59.01 -21 -40.4 Brolkn 63.66 +.25 +25.2 Chemn 62.47 +31+110.5 Compen 35.09 +.03 -80.6 Conlnd n 23.75 +.29 +8.4 Csobn 46.29 +.86+158.5 DIAern 72.98 +.75 +80.9 DvCmn 19.11 -.11 -602 Beclrn 41.28 -.17 -53.2 Enrgyn 49.800-.45+103.8 EngSvn 62.63 -.73 +772 Envirn 15.38 +.05 +342 FinSvn 109.05 +.16 +25.7 Foodn 51.09 +.19 +47.2 Gdldrn 29.79 -.57+106.0 Heath n 143.98 +.23 +4.8 HomFn 55.31 +24 +67.7 IndMtn 39.96 -.09+129.5 Insurn 63.71 -.08 +56.1 Leisn 73.57 +.38 +14.4 MedDIn 51.76 +.13+147.5 MdEqSysn24.99 +.07 +67.0 Mulolrn 4421 +.01 +11.5 NtGasn 41.42 -.42+1103 Papern 27.28 +.14 +33.1 Pharmn 9.58 ... NS Retain 49.82 +1.18 +11.9 Sottwn 50.30 -.18 -28.5 Techn 60.52 +.06 -58.8 Telcn n 37.19 +.08 -422 Transn 42.70 -.09 +80.7 FIdelIty Spartan: Eqldxn 43.16 +.17 -9.7 InvGrtdn 10.64 ... +40.8 First Eagle: GalA 42.44 -.12+128.1 OeerseasA24.16 -.18+1313 First Investors A SBl~hpAp 20.52 +.06 -26.5 GlobiAp 6.92 -.02 -5.5 GovtAp 10.93 +.01 +28.4 GrolnAp 13.51 +.05 -8.6 IncoAp 3.07 -.01 +28.4 IlnGrAp 9.84 ... +37.0 MATFAp 12.04 +.01 +33.0 MITFAp 12.69 +.01 +30.0 MidCpAp 27.69 +.05 +10.6 NJTFAp 13.03 +.01 +30.0 NYTFAp 14.49 ... +30.6 PATFAp 13.23 +.01 +31.8 SpsttAp 19.89 +.03 -23.8 TxExAp 10.15 +.01 +30.7 TotRtAp 13.89 +.03 +40 9 ValueBp 6.56 +.01 -7.8 Firsthand Funds: 6 GbTech 3.72 -.05 NS S TechVal 30.71 -.10 -72.2 Frank/Temp Frnk A: S AGEAp 2.09 -.01 +42.3 2 A4USp 8.98 ... +18.0 5 ALTFAp 11.57 ... +34.5 SAZFAp 11.15 +.01 +33.4 5 Ballnp 61.67 +.04+105.4 CallnsAp 12.80 ... +34.3 4 CAIntAp 11.62 +.01 +27.8 8 CaITFAp 737 ... +34.6 9 CapGrA 10.67 +.07 -35.7 7 COTFAp 12.08 ... +36.0 CiTFAp 11.16 ... +35.7 6 CvlScAp 16.65 +.03 +39.2 I DblTFA 12.02 ... +34.4 DynTchA 24.54 -.02 -12.7 3 EqlncAp 20.69 +.02 +26,7 I Fedlntp 11.52 +.01 +31.5 I FedTFAp 12.19 ... +34.5 2 FLTFAp 12.00 +.01 +36.5 8 FoundAlp 12.70 -.04 NS GATFAp 12.19 ... +352 I GoIdPrMA21.57 -.13+187.1 0 GwlhAp 34.44 +.09 -0.9 HYTFAp 10,84 -.01 +36.6 6 IncomAp 2.48 -.01 +59.7 1 InsTFAp 12.40 +.01 +35.1 7 NYITFp 11.02 +.01 +30.3 I ~ .O3o E D TH U T A U N A BE* Here are the 1.000 biggest mutual funds listed on Nasdaq. Tables snow thne fund name. sell price or Net Asset Value (NAV) and daily net change, as well as one total relumr figure as follows. Thie: 4-wk total return (%) Wed: 12-mo total return (%) Thu: 3-yr cumulative total return (%) Fri: 5-yr cumulative Iotal return (%) Name: Name of mutual tuna and family. NAV: Net asset value Chg: Net change in price of NAV Total return: Percent change in NAV for the time period shown, with dividends reinvested. If period longer than 1 year. return Is cumula- live Data based on NAVs reported to Lipper by 6 p m. Eastern Footnotes: e Ex-capital gains distribution t Previous day's quote n No-load fund. p Fund assets used to pay distribution costs. r - Redemption fee or contingent deferred sales load may apply. s - Stock dividend or split. t Both p and r. x Ex-cash dividend NA - No Inormation available. NE Data in question NN Fund does not wish to be tracked. NS Fund did not eKist at start dale Source: UpOer. Inc. and The Associated Press LATFAp 11.59 ... +34.9 LMGvScA 10.03 ... +22.8 MDTFAp 11.82 ... +35.1 MATFAp 12.01 ... +35 MlTFAp 1235 +.01 +34.1 MNInsA 12.19 ... +33.4 MOTFAp 12.38 ... +37.1 NJTFAp 1222 +.01 +36.3 NYInsAp 11.68 ... +33.2 NYTFAp 11.96 +.01 .342 NCTFAp 12.36 ... +36.8 OhiolAp 12.65 +.01 +34.1 ORTFAp 11.95 +.01 +352 PATFAp 10.50 ... +34.6 ReEScAp 28.02 +.04+125.3 RisDvAp 30.78 +.04 +71.2 SMCpGrA35.72 +.02 -28.3 USGovAp 6.56 +.01 +31.2 UtilsAp 12.33 -.10 +562 VATFAp 11.91 ... 434.6` Frank/Temp Frnk B: IncomB1 p 2.48 -.01 +55.8 IncmeBt 2.47 -.01 NS Frank/temp Frnk C: IncomCt 2.49 -.01 +55.4 Frank/Temp Mil A&B: DiscA 26.16 -.10 +61.7 QualfdAt 20.39 -.07 +57.0 SharesA 24.18 -.04 +43.0 Frank/Temp Temp A: DvMklAp 21.80 -.05+103.0 ForgnAp 13.15 -.07 +49.6 GIBdAp 10.46 -.03 +79.2 GrwthAp 24.04 -.10 +60.3 IntxEMp 15.71 -.09 +442 WorkdAp 19.24 -.07 +34.8 Frank/Temp Tmp Adv: GrhAv 24.09 -.10 +62.3 Frank/Temp Tmp B&C: DevMktC 2134 -.05 +96.7 ForgnCp 12.93 -.07 +44.0 GE Elfun S&S: S&Slnc 11.42 ... +39.2 S&S PM 45.61 +.15 -0.6 GMO Trust III: EmMkr 20.37 -.04+168.8 For 15.56 -.05 +61.5 GMO Trust IV: EmrMkt 20.33 -.04+167.8 Gabelll Funds: Asset 42.78 +.03 +35.6 Gartmore Fds D: Bond 9.69 ... +41.0 GvtBdD 10.33 ... +369 GrowlhD 6.80 +.03 -45.1 NafonwD 20.87 +.06 -0.9 TxFrr 10.64 +.01 +33.5 Gateway Funds: Gateway 2520 +.03 +11.1 Goldman Sachs A: GrIncA 25.56 +.07 +12.8 MdCVAp 36.37 +.12+109.8 SmCapA 41.91 +.01 +95.5 Guardian Funds: GBGInGrA14.47 -.08 -5.1 ParkAA 30.98 +.14-38.7 Harbor Funds: Bond 11.95 ... +44.7 CapAplnst3027 +.15 -29.7 Int r 47.77 -24 +53.3. Hartford Fds A: AdvosAp 15.48 +.06 +22 CpAppAp3639 +.02 +21.8 A 19.38 +.06 +26.8 SmlCoAp 1832 -.01 -0.3 Hartford HLS IA: Bond 11.82 +.01 +44.9 CapApp 55.45 +.04 +29.5 Div&Gr 21.20 +.07 +30.1 Advisers 23.61 +.07 +3.4 Stock 47.41 +.22 -13.1 Hartford HLS IB: CapAppp 55.14 +.05 +28.1 HollBalFdn15.36 +.02 -4.4 Hotchks & Wiley: , LgCpVLAp23.44 +.10 NS M'idCpVal 28.4 +.06+1472 ISlI Funds: NoAmp 753 ... +385 JPMorgan A Class: MCpValp 23.24 +.08 NS JPMorgan Sel CIs: CoreBdn 10.81 +.01 +40.8 Janus: Balanced 21.83 +.06 +11.0 Contrarian 14.46 -.11 +36.6 CoreEq 22.51 +.02 +5.8 Enterprn 39.41 +.02 -49.8 FedTEn 7.07 ... +27.5 FIbBnd n 959 +.01 +36.3 Fund n 24.62 +.07 -393 GIUfeScirn19.57 +.05 -12.1 GITechrn 10.96 -.06 -64.8 Gdnc 34.75 ... -10.1 Mercury 21.82 +.04 -41.8 MdCpVal 23.46 +.02+104.9 Olympus n30.34 +.05 -44.0 Orionn 7.93 -.01 -18.0 Ovrseasr 28,61 -.30 -3.4 ShTmBd 2.89 ... +22.4 Twenty 48.04 +.13 -34.6 Venturn 5821 -29 -21.1 WrkldWr 41.84 -30 -35.5 JennlsonDryden A: BlendA 17.03 +.01 NE HiYldAp 5.71- -.01 +29.8 InsuredA 10.98 ... NE UtiityA 14.96 -.13 +42.9 JennlsonDryden B: GrowthB 13.82 +.07 NE HiYldBt 5.70 -.01 +26.5 InsuredB 11.00 ... +29.3 Jensenx 23.33 +.03+12.3 John Hancock A: BondAp 15.16 ... +38.4 StnInAp 7.10 ... +46.0 John Hancock B: SrncB 7.10 ... +41.1 Julius Baer Funds: IntlEql r 36.04 -.27 +47.8 InOEqA 35.36 -.27 +44.7 Legg Mason: Fd OpporTrt 16.05 +.14 +47.7 Splnvp 46.53 +.34 +50.0 VaLTrp 63.53 +.82 +7.4 Legg Mason Insti: Varrdnst 69.75 +.90 +12.9 Longleaf Partners: Partners 31.75 -.03 +664 Intl 16.71 -.12 +60.2 SmCap 3132 +.09 +82.8 Loomis Sayles: LSBondl 13.98 -.03 +73.7 Lord Abbett A: AflilAp 14.61 +.03 +205 BdDebAp 7.88 -.01 +325 GIIncAp 7.29 -.02 +445 MidCpAp 22.86 +.04 +84.8 MFS Funds A: MlTAp 17.77 +.07 -10.5 MIGAp 12.41 +.05 -36.8 GrOpAp 8.79 +.03 -36.7 HilnAp 3.86 -.01 +28.6 MFLAp 1021 ... +35.8 TolRAp 16.05 +.03 +34.4 ValueAp 23.81 +.05 +32.6 MFS Funds B: MIGB 11.38 +.05 -38.8 GvScBt 9.64 +.01 +27.7 HilnBt 327 -.01 +24.3 MulnBt 8.68 +.01 +29.8 TotRBt 16.04 +.03 +30.1 MaIlnStay Funds B: CapApBt 27.75 +21 -42.9 ConvBt 13,42-.02 +9.9 GovtBt 822 ... +25.5 HYIdBBt 6.29 -.01 +41.5 IntlEqB 13.12 -.11 +22.2 SmCGBp 14.47 +.06 -32.9 TotRBt 19.15 +.08 -16.7 Matrs & Power: Growth 68.99 +22 +65.0 Managers Funds: SpdEqn 89.63 +27 +2.5 Maralco Funds: Focusp 17230 +20 -13.6 Merrill Lynch A: GIAIA p 17.39 -.05 +62.0 HealthAp 6.75 +.01 +10.4 NJMunBd 10.69 ... +35.0 Merrill Lynch B: BalCapB 28.04 +.04 +7.0 BaVIBt 29.56 +02 +16.1 BdHlnc 5.04 -.01 +25.9 CalnsMB 11.65 -.01 +293 CrBPRBt 11.76 +.01 +32.1 CplTBt 11.93 ... +32.6 EquityDiv 15.77 ... +40.4 EuroBt 15.50 -.13 +39.6 FocVall 12.17 +.02 +21.0 FndlGBt 16.23 +.02 -33.5 FLMBt 10.48 ... +35.2 GIAIBt 17.04 -.06 +55.8 HeallhBt 5.05 +.01 +46.2 LalABt 3259 -.13+118.3 MnlnBt 7.93 .. +32.1 ShTUSGt 9.16 .. +17.0 MuShtT 9.97 ... +12.7 MulniBl 10.52 ... +282 MNrIBt 10.59 ... +35.2 NJMBt 10.68 -.01 +32.2 NYMBt 11.11 ... +30.8 NatRsTB 148.45 -.45+158.7 PacBt 21.09 -.02 +13.6 PAMBt 11.38 ... +33.3 ValueOpp 12454 +.02 +60.3 USGovt 1021 ... +27.1 UtfTarnt 12.45 -.06 +20.8 WIdlnBt 630 -.03 +50.6 Merrill Lynch C: GIAICt 16.56 -.06 +55.7 Merrill Lynch I: BalCapl 26.84 +.04 +12.6 BaVII 3027 +.02 +22.2 BdHilnc 5.03 -.02 +30.6 CalnsMB 11.65 ... +32.8 CrBPtIt 11.76 +.01 +37.2 Cpm 11.93 ... +36.1 DvCap p 20.37 -.02 +76.6 EquityDv 15.75 ... +47.8 Eurolt 18.12 -.15 +47.0 FocVall 13.37 +.02 +27.4 FLMI 10.48 ... +38.6 GIAIlt 17.44 -.06 443.9 HealthI 7.33 +.01 +11.7 LatAI 34.32 -.13+130.2 Mnlnl 7.94 ... +37.4 MnShtT 9.97 ... +14.7 MulTI 10.52 .,. +30.1 MNatll 10.59 -.01 +40.4 NaIRsTrt 51.34 -.48+172.4 Pacl 23.09 -.02 +19.7 ValueOpp 2725 +.02 +68.7 %SGovt 1021 ... +32.1 UtlTcmhlt 12.50 -.05 +25.7 WIdlncl 6.30 -.04 +56.3 Midas Funds: MkasFd 2.48 -.03+188.4 Monetta Funds: Monetlan 11.47 +.04 -22.4 Morgan Stanley A: DivGthA 35.33 +.13 +13.7 Morgan Stanley B: GbDivB 14.33 -.02 +32.9 GrwthB 12.58 +.10 -30.1 StraB 18.26 +.02 +2.6 MorganStanley Inst: GIValEqAn1l.12 -.03 +27.8 IntEqn 21.87 -.14 +56.5 Muhlenk 83.48 +.44+80.6 Under Funds A: IntetlA 18.35 +.08 -72.9 Mutual Series: BacnZ 16.72 -.02 +57.5 DiscZ 26.43 -.09 +64.6 QualtdZ 20.53 -.07 +59.9 SharesZ 24.35 -.04 +55.6 Nations Fds CI B: FocEqBt 1821 +21 -14.1 MarsGrBt 16.98 +.16 -13.9 Neuberger&Berm Inv: Focus 36.77 +.04 -8.0 Ingr 21.58 -.15 +48.7 Partner 28.64 +.09 +35.7 Neuberger&Berm Tr: Genesis 48.49 +04+115.5 Nicholas Applegate: EmgGroln10.78 +.02 -35.8 Nicholas Group: Nichn 61.04 +.19 -13 Nchlnin 2.15 -.01 +20.4 Northern Funds: SmCpldxnlO.33 +.02 +29.4 Technlyn 11.16 +.02 -69.4 Nuveen Cl R: InMunR 11.01 ... +33.6 Oak Assoc Fds: WhitOkSGn31.93+.15 -61.0 Oakmark Funds I: tiviNrn?2n +.6 +.06 +79.5 ,I||MI|". 23 72 -.05+137.4 Inimrn 23.33 -.14 +75.3 Oaknmarkrn40.60 +31 +58.5 Selectrn 33.58 +21 +74.4 Oppenhelmer A: AMTFMu 10.18 ... +42.0 AMTFrNY 12.97 ... +39.4 CAMuniAp11.55 ... +48.1 CapApAp41.10 +.17 -20.5 CapIncAp12.44 ... +34.6 ChlncAp 9.40 -.02 +29.4 DvMktAp 33.49 -.18+1403 Disep 4254 +.10 -17.4 EquityA 11.29 +.02 -7.4 GlobAp 64.94 -.30 +19.9 GIbOppA 33.82 +.01 +18.1 Goldp 20.95 -26+214.2 HYdA p 9.41 -.02 +26.6 LtdTrrMu 15.89 ... +42.2 MnSIFdA 36.28 +.13 -8.1 MidCapA 17.12 +.13 -52.0 PAMunAp 12.85 ... +52.0 StdnA p 4.35 ... +49.6 USGvp 9.67 ... +33.8 Oppenheimer B: AMTFMu 10.14 ...+36.5 AMTFrNY 12.97 -.01 +34.0 CplncBt 12.32 ... +29.2 ChlncBt 9.39 -.02 +24.7 EquityB 10.87 +.02-11.4 HiYIdBt 9.26 -.02 +21.7 StrncBt 4.36 -.01 +44.0 Oppenhelm Quest: QBalA 18,07 +.06 +27.3 Oppenheimer Roch: RoMuAp 18.34 ... +43.9 PBHG Funds: SelGrwthn21.19 +.11 -71.8 PIMCO Admin PIMS: TotRIAd 10.74 +.01 +43.3 PIMCO Instl PIMS: AllAssetx 13.19 -.12 NS ComodRRx17.42-.37 NS HiYld 9.78 -.02 +42.4 LowDu .10.11 ... +27.0 RealRtnl 11.55 +.02 +61.8 TotRt 10.74 +.01 +45.1 PIMCO Funds A: ReaIRtAp 11.55 +.02 +58.3 ToIRtA 10.74 +.01 +41.8 PIMCO Funds C: RealRtCp11.55 +.02 +54.4 TotRtCt 10.74 +.01 +36.6 PIMCO Funds D: TRItnp 10.74 +.01 +42.8 PhoenixFunds A: BalanAx 14.72 -.02 +11.7 CapGrA 14.67. +.07 -50.2 IntIA 10.94 -.03 -1.4 Pioneer Funds A: BalanApx 9.82 -.02 +7.0 BondAp 9.29 ... +433 EqlncApx 29.62 -.13 +26.8 EurSelEqA31.61 -.12 NS GrwthAp 12.34 +.06 -33.5 HiYdAp 11.33 -.03 +52.6 InlValA 18.79 -.04 -5.2 MdCpGrA 15.02 ... -22.4 MdCVAp 23.42 +.05 +75.8 PionFdAp42.78 +.16 -2.2 TxFreAp 11.74 +.01 +34.7 ValueAp 17.33 ... +23.3 Pioneer Funds B: HindBt 11.38 -.03 +47.2 MdCpVB 20.63 +.04 +68.4 Pioneer Funds C: HiYndCt 11.48 -.03 +47.1 Price Funds: Balancen 19.91 +.04 +21.6 BChipn 31.01 +.18 -17.3 CABondn 11.10 ... +32.5 CapAppn 20.21 +.01 +84.0 DivGron 22.81 +.07 +15.4 Eqlncn 26.64 +.08 +44.3 Eqlndexn 32.77 +.12 -10.3 Europen 20.90 -.10 +10.2 FLIntmn n 10.90 ... +27.2 GNMAn 954 ... +32.8 Growth n 26.93 +.08 -7.3 Gr&lnn 21.76 +.06 +5.8 HSiSdn 24.42 +.01 +13.9 HIeldn 1.98 -.02 +443 ForEqn 16.69 -.07 -0.7 IntmBodn 9.82 -.04 +55.7 IntDisnn 3824 -27 +26.4 IlnlStkn 13.95 -.05 -2.9 Japanon 9.7 +.02-15.7 LatAmn 23.42 -.16+137.4 MDShrtn "5.16 ... +16.0 MDBondnlO.77' ... +34.1 MidCap n 5324 +.06 +32.3 MCapVal n23.41 +.06+106.6 NAmpern 3267 +.14 -16.7 NAsxan 11.90 -.10 +42.0 NewEran42.43 -22+115.9 NHmrizn 30.94 +.04 +14.6 NIncn 9.09 ... +38.3 NYBond n 11.43 ... +34.4 PsInon 15.07 +.02 +334 RealEsIn 18.89 +.08+139.7 ScoTecn 19.00 +.02 -65.1 ShIBdn 4.71 ... +25.8 SmCptr n32.45 ... +49.4 SmCapVal n37.57 +.03+1263 SpecGrn 17.55 +.03 +143 Speclnn 11.02 ... +46.1 TFIncn 10.06 ... +35,5 TxFrHn 11.98 ... +37.1 TFInirnn 1122 ... +28.8 TxFrsln 5.38 ... +21.1 USTInIn 5.41 ... +333 USTLgn 12.14 +.01 +46.8 VABOndn 11.75 ... +35.1 Value n 2322 +.06 +46.4 Putnam Funds A: AmGvAp 9.02 +.01 +27.4 AZTE 9.34 ... +31.0 ClscEqAp 13.06 +.08 +102 Convpx 17.23 -.14 +18.1 DiscGr 17.41 +.06 -50.2 DvrInAp 10.23 -.02 +47.0 EuEq 22.20 -.19 +3.5 FLTxA 9.32 ... +32.0 GeoAp 18.27 +.06 +27.7 GIGvApx 12.53 -.11 449.4 GIbEqtyp 8.95 -.01 -6.6 GrinAp 19.62 +.09 +15.4 HtlthAp 65.11 -.03 -9.9 HiYdAp 7.99 -.02 +383 HYAdAp 6.02 -.02 +37.3 IncmAp 6.84 ... +34.8 InUEqp 25.35 -.23 +4.2 InIGrinp 12.75 -.07 +26.5 InvAp 12.98 +.08 -28.8 MITxp 9.06 ... +30.2 MNTxp 9.07 .. +31.9 NJTxAp 9,31 +.01 +31.6 NwOpAp 42.92 +.18 -48.4 TCAp 7.39 +.01 -69,4 PATE 9.18 ... +33.6 TxExAp 8.89 ... +32.1 TFInAp 15.11 +.01 +32.8 TFHYA 13.02 ... +29.7 USGvAp 13.22 +.01 +28.4 UtiApx 11.27 -.13 +6.3 VstaAp 10.00 +.03 -39.1 VoyAp 16.71 +.12 -36.7 Putnam Funds B: CapAprt 18.19 +.08 -14.7 CIscEqB1t 12.96 +.08 +62 DiscGr 16.06 +.05 -52.1 DvrlnBt 10.15 -.02 +41.3 Eqlnctx 17.66 +.04 +32.8 EuEq 21.36 -.18 -0.3 FLTxBt 9.32 +.01 +27.8 GeoBt 18.10 +.06 +23.1 GlIncBtx 12.50 -.09 +44.1 GibEqt 8.14 -.02 -10.0 GINtRst 30.99 -.17+100.1 GrtnBt 19.34 +,09 +11.1 HthBt 59.25 -.03 -132 HiYdBt 7.95 -.02 +33.2 HYAdBt 5.94 -.02 +31.5 IncmB1t 6.80 ... +29.8 IntGrInt 12.48 -.07 +21.8 IntlNopt 12.28 -.08 -17.8 InvBt 11.88 +.07 -31.4 NJTxBt 9.30 ... +272 NwOpBt 38.57 +.16 -503 NwValp 18.03 +.09 +472 NYTxBt 8.81 ... +28.4 OTCBt 6.53 ... -70.6 TxExBt 8.89 +.01 +28.1 TFHYBt 13.04 ... +26.1 TFInBt 15.13 +.01 +28.9 USGvBt 13.15 +.01 +23.7 U BlBtx 11.22 -.11 +2.4 VistaBt 8.73 +.03 -41.4 VoyBt 14.55 +.10 -39.0 Royce Funds: LwPrStkr 15.58 -.09 +71.5 MicroCapl 16.70 -.09 +943 Premier 16.21 -.03 +842 TotRetlr 12.63 +.01 +91.6 Russell Funds S: QuantEqS38.64 +.13 -8.7 Rydex Advisor: OTC 10.18 :+.04 -61.9 SEI Portfolios: CoreFxA nO.50 ... +383 InlEqAn 11.90 -.07 +3.7 LgCGroAn1895 +.09 -45.6 LgCValAn22.17 +,04 +32.1 STI Classic: , CpAppAp 11.43 +.06 -20.4 CpAppCp10.79 +.06 -22.1 LCpVIEqA 12.48 +.04 +34.1 QuGrStkCt 12325 +13 -31.5 TxSnGrip 24.83 +.14 -27.8 Salomon Brothers: BalancBp 12.82 ... +19.4 Opport 50.39 +.09 +23.0 Schwab Funds: 10001nvrn3538 +.12 -7.8 S&Plnvn 18.89 +.09 -10.4 S&P Setln 18.97 +.08 -9.6 YIdPIsSI 9.67 ... +192 Scudder Funds A: DrHiRA 44.35 -04 +532 FIgComAp18.41 +.05 -443 USGovA 8.56 +.01 +30.1 Scudder Funds S: EmMkIn 11.59 -.01+112.7 EmMkGrr21.14 -.19 +82.9 GbBdSr 10.28 -.02 +44.1 GIbDis 38.54 -.08 +14.4 GlobalS 30.56 -.16 +23.0 Gold&Pro 17.79 -.29+280.6 GrEuGr 29.44 -24 -0.1 GrolncS 22.34 +.14 -8.3 HiYldTx 12.92 ... +38.5 IncomeS 12.97 +.01 +35.1 IntTxAMT 11.33 -.01 +28.4 IntlFdS 48.67 -31 -1.0 LgCoGro 24.59 +.12 -39.9 LatAmr 45,40 -.30+113.5 MgdMunlS 9.20 ... +34.8 MATFS 14.56 -.01 +35.0 PacOppsr 14.84 -.11 +39,5 ShtTmBdS 10.05 ... +21.7 SmCoVIS r26.78 +.06+102.1 Selected Funds: AmShSp 38.55 +.14 +14.6 Seligman Group: FronAt 12.51 -.05-16.3 FrontrDt 11.01 -.05 -19.6 GIbSmnA 17.04 -.06 +3.1 GibTchA 12.75 -.04 -438 HYdBAp 3.37 -.01 -2.1 Sentinel Group: ComS A p 30.06 +.08 +14.5 Sequoia n147.62+1.67+50.5 Sit Funds: SjgCpGr 35.70 +.15 -37.3 Smith Barney A: AgGrAp 103.06 +.07 -1.4 ApprAp 14.67 +.04 +12.2 FdValAp 15.22 ... +4.1 HilncAt 6.86 -.02 +21.7 InAICGAp 14.35 -.10 -24.1 LgCpGAp22.06 +.11 -13.4 Smith Barney B&P: FValBI 14.29 ... 0.0 LgCpGBt 20.78 +.10 -16.5 SBCphnct 16.90 -.02 +27.6 Smith Barney 1: DvStrI 17.09 +.05 -29.3 GrIncm1 15,30 +.05 -10.5 St FermAssoc: Gwth 49.37 +.02 -1.7 Stratton Funds: Dividend 35.64 +.18+119.1 Growth 43.97 +31 +79.1 SmCap 42.81 +.31+124.8 SunAmerlca Funds: USGvBt 9.47 +.01 +32.9 SunAmerica Focus: FLgCpAp 17.74 +.15 -232 TCW Galileo Fds: SelEqty 18.02 +.22 -26.0 TD Waterhouse Fds: Dow30O 0.0 TIAA-CREF Funds: BdPlus 10.28 +.01 +395 Eqlndex 8.78 +.03 -63 Grolnc 12.37 +.04 -15.8 GroEq 9.25 +.05 -43.8 HiYIdBd 9.20 -.02 +41.0 IntlEq 11.56 -.08 +7.4 MgdAlc 11.30 +.01 +3.5 ShtTr8d 10.45 ... +29.9 SocChEq 9.42 +.03 -3. TxExBd 10.92 +.02 +36.5 Tamarack Funds: EntSmCp 32.33 +.15 +58.4 Value 45.31 +.19 +305 Templeton Instlt: ForEqS 21.73 -.18 +41.7 Third Avenue Fds: Intr 2021 -.09 NS RIEstVIr 29.42 +16+146.8 Value 58.17 -.02 +75.5 Thrivent Fds A: HiVld 5.10 -.01 +13.7 Incom 8.72 ... +34.6 LgCpStk 26.01 +13 -109 TA IDEX A: FdTEAp 11.80 +.01 +312 JanGrowp2433 +10 -45.0 GCGIbbp 24.96 -.08 -36.8 TrCHYBp 9.13 -.02 +363 TAlxIn p 9.49 ... +35.8 Turner Funds: SmlCpGrn29.71 -.03 -24.5 Tweedy Browne: GlobVal 25.74 -.05 +43.0 US Global Investors: AIIAmn 25.70 -.07 -25.0 GIbRs 15.16 -.13+307.6 GIdShr 924 -.14+2613 USChina 7.38 -.03 +43.6 WIdPrcMn 18.25 -.26+302.7 USAA Group: AgvGt 29.99 +.31 -49.7 CABO 11.28 ... +34.1 CmstSIr 27.52 +.03 +26.3 GNMA 9.67 .,. +32.1 GrTxSIr 15.03 +.04 +7.0 Grth 14.34 +.12 -39.9 3 .1~ .41 - dod Gr&lnc 19.01 +.08 +12.1 Inc.k 17.09 +.04 +21.8 Inco 1241 +.01 437.4 Int 23.36 -.15 +25.0 NYBd 12.10 ... +3.7 PrecMM 17.65 -.19+310.4 SciTech 9.82 -.04 -565 ShITBnd 8.89 ... +15.6 SmCpStk 14.28 +.02 +4.1 TxElt 1330 .. +32.7 TxELT 14.22 ... +40.5 TxESh 10.67 ... +19.1 VABd 11.72 ... +35,5 W1dGr 18.51 -.05 -0.5 Value Line Fd: LevGtn 27.19 -.07 -27.0 Van Kamp Funds A: CATFAp 18.91 ... +32.8 CmstAp 18.17 +.03 +43.1 CpBdAp 6.70 ... +384 EGAp 39.69 +.12 -53.6 EqlncAp 8.84 ... +33.6 Exch 368.14 -.43 -5.5 GdnAp 2120 +.02 +29.1 HarbAp 14.40 -.03 -10.7 HiYIdA 3.58 ... +11.3 HYMuAp 10.93 ... +38.1 InTFAp 18.96 ... +34.5 MunlAp 14.79 ... +32.2 PATFAp 17.51 ... +0.9 SrMunnc 1320 ... +32.4 US MtgeA 13.80 .. +31.1 UtilAp 19.37 -.10 +6.5 Van Kamp Funds B: CmstBl 18.18 +.04 +37.8 EGBt 33.90 +.10 -55.4 EnlerpBt 11.37 +.6 -42.7 EqIncBt 8.71 ... +2.7 HYMuBI 10.93 ... +33.0 MulB 14.76 -.01 +27.3 PATFBt 17.46 ... +26.0 StrMunInc 13.29 -.01 +27.5 US Mtge 13.74 ... +26.1 UtIIB 19.34 -.10 +2.5 Vanguard Admiral: CpOpAdln72.26 -.11 NS 500Adrmn112.43 +.44 NS GNMAAdnl1.36 ... NS HhCrn 58.85 +.26 NS HiYldCpn 6.22 ... NS HiYldAdrnnl0.87 ... NS ITAdmIn 13.45 -.01 NS LdTrAdn 10.78 ... NS PnnCaprn66.19 +.09 NS STsyAdrmlnlO.39 ... NS ShtTrAdn 15.57 ... NS STIGrAdn 10.57 ... NS TlBAdmlnlO.19 +.01 NS TStkAdmn29.22 +.10 NS WeinlAdmon53.08 +.04 NS WelhrAdnn53.89 +.10 NS Windsorn 61.01 +.16 NS WdsrllAdn562.9 +.02 NS Vanguard Fds: AssetAn 24.79 +.10 +13.0 CALTn 11.83 ... +34.1 Cap0ppn3126 -.05 +7.4 Convrtn 13.19 -.03 +13.8 DLidGron 12.13 +.04 -5.0 Energy 5928 -.43+185.4 Eqlncn 23.68 +.04 +30.7 ExpMrn 76.67 +.08 +19.9 FLLTn 11.80 ... +375 GNMAn 10.36 ... +34.8 Grolncn 30.97 +.11 -7.6 GdrthEqn 9.79 +.02 -482 HYCorpon 622 ... +30.8 HLhCren139.39 +.61 +412 InflaPron 12.65 +.03 +57.4 IntlExpIrn 18.56 -.11 +42.7 IntIGrn 20.33 -.10 +14.6 IntlValn 34.03 -.15 +43.6 ITIGraden 9.94 ... +43.6 ITITsyn 11.13 +.01 +41.1 LfeConn 15.45 +.03 +21.0 UfeGron 20.52 +.05 +7.9 Ufelncn 13.61 +.02 +272 LfeModn 18.24 +.03 +15,.5 LTGrads n 9.71 .. +60.2 LTTsryn 11.80 +.01 +53.7 Morgn 16.70 +.05 -14.6 MuHYn 10.87 ... +35.6 Mulnslgn 12,0 ... +37.1 Mulntn 13.45 -.01 +28.9 MuUdn 10.78 ... +20.8 MuLongn 11.43 ... +36.6 MuStn 15.57 ... +14.6 NJLTn 12.02 +.0'1 +35.3 NYLTn 11.48 ... +36.5 OHLTrEn12.18 ... +37.1 PALTn 11.52 ... +36.5 PrecMlsr n21.64 -.12+302.4 Prrcprn 63.75 +.10 -1.2 SelValurn1932 ... +94.4 STARn 19.31 ... +32.5 STIGrade n0.57 ... +26.5 STFedn 10.32 +.01 +27.0 StratEqn 22.60 +.04 +702 USGron 16.62 +.08 -55.6 USValuen14.18 +.05 +41.5 Wellslyn 21.90 +.02 +47.6 Welltnn 31.19 +.06 +47.5 Wndsrn 18.07 +.04 +433 Wndslln 32.09 +.01 +413 Vanguard Idx Fds: 500 n 112.40 +.43 -9.6 Balanced n19.68 +.04 +122 EMiktn 17.67 -.08 +95.7 Europen 27.51 -.19 +18.8 Extend n 32.86 +.03 +4.2 Growth n 26.45 +.13 -27.7 ITBOdn 1055 ... +45.6 LgCaplxn21.78 +.08 NS MNdCapn 16.83 +.03 +45.4 Pacific n 1028 ... +6.1 REITrn 19.70 +.06+131.7 SmCapn 27.71 +.05 +394 SnICpVIn 14.42 +.03 +8723 STBndo n 10.02 +.01 +26.8 TolBndn 10.19 +.01 +36.0 Tollntn 13.68 -.06 +21.1 TotStan 2921 +.09 -5.0 Value 22.02 +.04 +15.1 Vanguard Instl Fds: Instlden 111.51 +.43 -9.0 InsRn 111.52 +.43 -8S TBIstn 10.19 +.01 +36.8 TSInstn 2922 +.09 -44 Vantagepoint Fds: Growth 826 +.03 -24.4 Victory Funds: DvsStA 1625 .+.02 +203 Waddell & Reed Adv: CorelnvA 525 +.02 -13.1 Wasatch: SmCpGr 40.75 -.02 +51. Weiz Funds: Value 35.40 +.12 .335 Wells Fargo Adv: OpptylnO 47.03 +.07 +19.8 Western Asset: CorePlus 10.67 -201 +53.0 Core 11.46 ... +46.1 William Blair N: GrowthN 10.90 +.03 -253 InlGihN 24.79 -.13 +31.1 Yacktman Funds: Fundrp 15.05 -.03+11329 up-" o-t - do IN-. ~ ~ - ,woo b * ann- U - ~- - w = 0 -- ---E- # "-GW 'Mom. - -* Copyrighted Material - ""Z- Syndicated Content p Available from Commercial News Providers * lap -~ m- -w 0 Is- mm 40MON- W db ow- . qft qw u__ amob&- -p P- -M- -S - a~ RD W.,G~G, ,,- - 410 ft w .b 40 Gp io- llllw Gip -f -gni Gmia I* t m O 890-0923-FCRN NOTICE OF BUDGET HEARING The Homosassa Special Water District has tentatively adopted a budget for fiscal year 2005-2006. A public hearing to make a FINAL DECISION on the budget AND TAXES will be held on Monday, September 26,2005,5:01 PJM. at Homosassa Special Water District Office 7922 W. Grover Cleveland Blvd. Homosassa, FL 34448 891-0923-FCRN BUDGET SUMMARY HOMOSASSA SPECIAL WATER DISTRICT - FISCAL YEAR 2005-2006 *THE PROPOSED OPERATING BUDGET EXPENDITURES OF HOMOSASSA SPECIAL WATER DISTRICT ARE 4.8% MORE THAN LAST YEAR'S TOTAL OPERATING EXPENDITURES. General Fund 0.6948 WATER REVENUE GENERAL TOTAL ALL ESTIMATED REVENUES: FUND FUND FUNDS Taxes: Millage Per $1,000 Ad Valorem Taxes 0.6948 272,363 272,363 Metered Water Sales 610,000 610,000 Connection & Reconnection Fees 6,000 6,000 Late Penalties 7,000 7,000 Interest Income 16,000 1,800 17,800 Water Meter Sales 16,000 16,000 Special Assessment Income-Principal 5,415 5,415 Miscellaneous Revenues 8,500 200 8,700 TOTAL SOURCES 668,915 274,363 943,278 Transfers In $215,000 $0 215,000 Fund Balances/Reserves/Net Assets 1,087,882 33,818 1,121,700 TOTAL REVENUES, TRANSFERS & BALANCES $1,971,797 $308,181 $2,279,978 EXPENDITURES Salaries 385,826 12,000 $397,826 Payroll Taxes 29,516 918 $30,434 Field Supply & Expense 55,000 $55,000 Office Supply & Expense 27,000 $27,000 Insurance 70,969 $70,969 Group Insurance 63,000 $63,000 Utilities 44,000 $44,000 Gas & Oil 18,000 $18,000 Repairs & Maintenance 48,000 $48,000 Retirement 31,370 1,828 $33,198 Miscellaneous Expense 42,000 $42,000 Legal Services 10,000 $10,000 Engineering Services 5,000 $5,000 Audit & Accounting Services 14,000 $14,000 Assessment Fees 14,000 $14,000 District Election Expense 2,500 $2,500 Capital Improvements 1,063,000 $1,063,000 TOTAL EXPENDITURES $1,877,681 $60,246 1,937,927 Transfers Out 215,000 215,000 Fund Balances/Reserves/Net Assets 94,116 32,935 127,051 TOTAL APPROPRIATED EXPENDITURES TRANSFERS, RESERVES & BALANCES $1,971,797 $308,181 $2,279,978 THE TENTATIVE, ADOPTED, AND/OR FINAL BUDGETS ARE ON FILE IN THE OFFICE OF THE ABOVE MENTIONED TAXING AUTHORITY AS A PUBLIC RECORD. dft dim 4WD 10A FRIDAY SEPTEMBER 23, 2005 Opinion > "There can be no daily democracy without daily citizenship." Ralph Nader C TRUS COUNTY CHRONICLE EDITORIAL BOARD Gerry Mulligan ............................ publisher Charlie Brennan .............................. editor Neale Brennan ...... promotions/community affairs Kathle Stewart ....... advertising services director Mike Arnold ........................ managing editor Andy Marks .............................sports editor TAXING DECISION County backs off huge tax increase he county commission made the correct decision Tuesday in lowering the county's proposed tax rate. Commissioners Vicki Phillips, Joyce Valentino and Gary Bartell reacted to citizen demands that they back off of a 22 percent increase in spending. At a Tuesday pub- lic hearing, the board voted 3-2 to reduce the tax rate THE I1 from 8.5553 to The boa 8.1450. The 22 per- ba cent increase in spending was going OUR OP to take place because .the The right assessed value of new and existing property in our community has increased that much. The huge increase in available- dollars permitted the county to meet all of its existing 2006 bud- geted needs with a surplus of $3.3 million left on the table. A couple of commissioners wanted to keep those surplus dollars for hurricane prepara- tion and infrastructure improve- ments. While both needs are important, it was more impor- tant that the county demonstrate a more conservative approach to spending. The majority appro- Pick and choose S o I want to find if some- body, the county commis- sioners, could find out why Waste Management we live in Ozello sends you a letter and says that they're no longer going to furnish garbage service out here, When they have a CAL. contract to provide 5634 garbage service for Citrus County, how can they pick and choose different areas of where they want to pick up garbage at? Maybe the Chronicle or somebody or the county commissioners can find out exactly what it is ... Stop the war Reading your Sound Off column today, it's amazing to me that some Republicans can say that it's the Democrats that caused these wars. And also I am reading Charley Reese's column and there's no truer facts. As a veteran, I'm saying this: It really does hurt your personality, your ways of thoughts and every- thing else combined, to have these wars and the killings that go with them. It's a shame we can't stop this war before more American boys are killed. We support our Army and our troops. We don't need them all. killed or mangled ... I'm sorry that I can't agree with these Republicans who say that the Democrats should apologize for their part in voting for the war. They have been turned around and say that they were lied to like all the rest of the country. But this president has got us in a war that should not be in and we should get out of. Return windfall Just having finished reading Tues- day's (Sept. 13) paper, the article "Board at odds about windfall," and that they found a $3.3 million sur- plus, I don't see where that should be any kind of a problem with them. I have to most definitely agree with the commissioners Vicki Phillips, Joyce Valentino and Gary Bartell. I privately voted to give the $3.3 million back to the taxpayers. Being prepared for hurricanes and finding matching dollars for state sewer grants are both important items, but we believe the dollars exist in the current county budget to fund those pri- orities. If a Category 4 or 5 hurricane hits this part of the world, iSUE: the county's $1 mil- rd gives lion in reserve ck. funds would have run dry the first day. I|NION: While the $3.3 million was decision. returned to taxpay- ers, most home and business owners will experience substantial tax increases this year via the value assessment increases. With ris- ing gas prices, insurance rates going up and property values, soaring, cifizenis are being stressed on all sides. Even with the reduction, coun- ty spending is going to increase and, according to Vicki Phillips, county commission chairwoman, the level of county services will remain the same. A final budget hearing will be at 5:01 p.m. this coming Tuesday. The budget year begins Oct. 1. t mean the taxpayers paid that money. Why would anybody feel that we're not entitled to get it back? And we're taxpayers who have been here for many years L and are longstanding (citi- zens). Why should we see that money go to other things? If there's money W0579 needed for waterlines for 07Ju n I new residents and stuff like that, that's their prob- lem, that's not our problem. Roads being rebuilt? You should have that money put aside. You know that roads need maintenance. Relief sessions Could the person organizing the hurricane relief reconsider doing it either on the weekend or at night where those of us who are employed during the week will be able to partici- pate? There's many young people in the county that really want to help and most of us work Tuesday at 10 a.m. So I'm asking if they would reconsider. Either that or hold two sessions so we can all give a lending hand. Forced out Beware, county government. Sept. 13's issue saying, "County windfall $3.3 million should be spent wise- ly." What about saving some for a rainy day? Thanks, commissioners, for the raise in our water and outra- geous sewer bills. We service people who have lived in Citrus County all our lives, who cut your grass, paint your houses and service your needs, will be leaving, as we can no longer afford to live here. Let Citrus County go to the rich ... who are flooding our county and building these humongous, monstrosity-type homes and have them pay all the amenities now required. Cleaning lakes This is Pine Lake in Floral City. I'm reading in the paper today that they're cleaning up all the rivers and lakes. What about us down here in Floral City at Pine Lake? h ar c I I I Rita ID 't .m -in-- tlinin -in - - -Q S . ft. w - %-in - no 0. ft-- b- - - in w in- ~ -~ - -- - - ~ - - - - ,Iowa -: Copyrighted Material - ---- Syndicated Content- Available from Commercial News Providers f -. _ --m ___ iomw 41b ft- OAmw p .om fto -Mam- mmw o- #N lmmm mo WN Mm q-. amm -*m --. 4mmoe-W0 t* o m- o 4b.am -1M- ~ 4004S qU 41b *w qm- 4M 0 LETTERS to the 'Action leads to reaction In his letter, William Dixon says American soldiers died fighting to contain the spread of communism in Southeast Asia. Ho Chi Minh was a populist and a Nationalist who helped us defeat the Japanese in that area but, pandering to deGaulle of France, President Truman ordered our agents to stop working with him. Later, the Eisenhower administration escalated the conflict and, when polls showed Ho Chi Minh with 80 percent of the vote in an election we promoted in Vietnam, Ike cancelled the election. Like Fidel Castro, Ho became a com- munist because of our action. China, the capitalist over-achiever, is still communist. Eventually, it may kick communism, which, like martial law, is an effective way to govern in chaos, but wouldn't survive in an established, thriving society. The United States, which had a legal com- munist party for decades that got neg- ligible attention, was never in danger from communism. But it served as a scare tactic to make Americans sup- port the overthrow of foreign leaders we couldn't control. Since many Americans believe democracy and capitalism are syn- onymous, our leaders have always been successful in convincing us we are exporting democracy. Just as we created communists in our war against communism and drug dealers in our war on drugs, we are now creating terrorists in our misdi- rected war against terrorism. Of course, it's the people at home who are criticizing the war. Our troops in Iraq don't dare. Once out of uniform, they can speak out, as Veterans Against the War have done. Dixon says if we keep our optimism and maintain our American spirit, we will prevail. If we prevail, it will be because.we are a super power, notcleonline.com. because we clap to show we believe in Tinkerbelle. Mary B Gregory Homosassa Don't forget gas tax Since October, Citrus County's tax- able property values have increased by $1.2 billion. And then there are those impact fees, an increase obvi- ously being held in abeyance by the dictates of the building interests. That's a lot of tax money that will - or could come pouring into the county coffers. But that's not enough... We're going to have an increase in gasoline taxes. But fortunately for commissioners who will be running again, not effective until Jan. 1 after those November elections. Apparently, we, as motorist taxpayers, will have forgotten about that huge increase until we fill up in 2006 at - - - dW0-. - lp-.O 40-p 4a - 4b-wn Mv at.ew ft -s Nw Mob Goiism IM ~ .1i- 4b- kMqw b- wo--ftlm- Editor more than $3 a gallon. At least, I sus- pect, those commissioners who are running again will hope we forget Maybe it's time to sit back and ask the basic question: Do we really want to spend all that money on highways to encourage even more residents to Citrus County? Whatever happened to, pay-as-you-go (not a rhetorical ques- tion)? More expensive? Possibly ... Why not do as we did many years ago, right after World War II pay for these "necessities" when we have the money. With a huge pot of cash coming out of the 6-cents-a-gallon gas tax, the local government will have t free rein to build roads everywhere, , resulting in a "touch-of-the-hat" to the; road builders, and encouraging even more potential residents to rush here to live. Meanwhile, it's a tax that probably will never go away. Do you remember that attempt at increasing our sales tax? Citrus Countians turned it down because we had a chance to vote on it Unfortunately, we don't have that option with the gas tax. We do have options at election time. Patrick S. Bange Lecanto' Go after offenders I know what a degenerate is. However, what do you call a person who rapes a young girl who is desper- ately seeking shelter and safety from a devastating natural disaster as Hurricane Katrina? I think the low-lifes who assaulted the young women in the Superdome should be arrested and punished severely for their despicable actions. What were the New Orleans police and 20,000 evacuees who were in the Superdome doing when these unfor- tunate people were being victimized? T. J. LaManna. this one up . - AV*q% jqq AAN r=FURLIS COUNTY (".'HRONICLE .-.Mkm ow -- q) - - -'W qm O I FRIDAY, SEPTEMBER 23, 2005 11A Onus CUo I.uUPiy (FL) UJ1RoNicLE - e~Spamiwmk empdod m z, a^B^^h^ Drm^^^^ B .& - - -wm .go-~- -MOO am S-aam. --AN-- 40 no -mbM t- qm-- - - m-- MNI- MP a- -%b a a. a 41. bul v ago 4b 4W am o 0 -b . 40 o ftoo- - . Im- 0 - a 41. * ~ Go- Couple fled Katrina They luck out with damages CRISTY LOFTIS cloftis@chronicleonline.com Chronicle Like thousands of people who fled Hurricane Katrina, Mike Wilson anxiously awaited news of how his home fared. "It was pretty nerve wrack- ing not knowing, if you can imagine," Wilson said, a 1998 Citrus High School graduate. - Wilson, now a staff sergeant in the U.S. Air Force, and his wife Amber live in Biloxi, -- PIECES 0 - .0 S - a. a- a - -~ w * - - - - a. a __ a. a.. ~ a - - S - a. a ~0~ ~ -a. 0 - U a ~- =- - ~a - - a. - a -a a.- a - a - * a Continued from Page 1A for all of his 51 'years, said less than half of the town's 8,100 residents evacuated when Katrina hit Aug. 29. "This storm hit everyone, from the richest to the poor- __ est," he said. If he had a chance to prepare again, Favre said he would make evacuation a top priority. "The first thing- is make damn sure everybody got out, whether they wanted to or not," t he said. "The first two days were hell. Those first two days S were tough." -- Bay St. Louis and Waveland, - which share a single city school -- district, lost two elementary - schools. -* They're hoping. to reopen school by Nov. 1 with portable - - classrooms provided by the * Federal Emergency * Management Agency _** -- Vehicle and rail bridges that cross the Bay of St Louis to ... -- Pass Christian are gone with .~ support beams all that remain. -. -, County government build- .ings, including the courthouse, Miss., an area ravaged by Hurricane Katrina. As the storm approached weeks ago, he was working in Alaska. "I had no idea this hurricane was even out there," Wilson said. Amber evacuated the Sunday before Katrina hit to her family's home in Valdosta, Ga. About a week after the hurri- cane hit, they decided to go to Inverness to see his dad, Dave were destroyed. No one knows what happened to the official records. The county's emer- gency operations center flood- ed and was useless; officials set up a temporary EOC in Hancock County High School, which is located at Stennis International Airport near Kiln (pronounced "Kil," or as locals say, "The Kil"). Landline phones are out. Cell phone service is spotty, and BellSouth set up satellite phone banks in parts of the county. Electric service is available to most buildings that were not destroyed. Kellar, who is an appointed county administrator and elected county clerk, pegged FEMA cleanup costs alone at $300 million. He had no finan- cial estimate on losses to homes and businesses. "It will be severe," he said. Most deaths were attributed to drowning, he said. The homeless are staying in some scattered shelters. Many people are staying outside their demolished homes. Hancock County has an immediate need for cleaning supplies, tents and shovels (see Wilson, an ROTC instructor at Citrus High School. Throughout the weeks, the Wilsons watched the news and saw the images of devastation. They figured, like everyone else, their home was destroyed. Thrilled doesn't come close to describing the couple's feel- ings when they learned their Biloxi beachfront apartment weathered the storm. "We were so relieved, it was like Christmas morning around here when they found out," his father said. The apartment manager information box with this story), Kellar and Favre said. Kiln, the hometown of Green Bay Packers quarterback Brett Favre (Mayor Favre said the two are distant cousins), is housing volunteers in the Kiln Public Library. The two-lane road through town is constantly jammed with,traffic. Those volunteers this week included Citrus County Circuit Court Judge Patricia Thomas and Dottie Smith, worship min- ister at the First United Methodist Church in Inverness. Tuesday afternoon, they helped at a distribution center in downtown Bay St. Louis. Homeless hurricane victims wandered in to get food and water. "It's hard to know exactly what to do," Thomas said. Smith said children are eager to return to school, but not because of boredom. "They want to know if their friends are alive," she said. "They've gone through this unimaginable thing and they're just little kids." While New Orleans and Biloxi, Miss., are getting most said there was a crack in their bedroom wall and a little bit of water damage, but on whole, they lucked out. "It's unreal," Wilson said. Of the six people from Biloxi he was with. in Alaska, three lost everything, Wilson said. Now that Wilson's found he has a place to stay, Keesler Air Force Base has asked he return. After receiving an update from Biloxi earlier in the week, Wilson is staying optimistic. "Food, water and gas," Wilson said, "there's the mini- mums at least." of the national media atten- tion, Katrina's eye passed directly over Hancock County, according to a report in an online newspaper, gulfcoast- news.com. U.S. 90, the main road that runs through Waveland and Bay St Louis, is lined with businesses that suffered vari- ous degrees of damage. A boat sat in the drive-through of a Burger King. Outsiders are everywhere. Power company trucks from neighboring states. Religious groups are volunteering. Florida's law enforcement has a huge presence, including National Guard units and the Florida Highway Patrol. Kellar, the county adminis- trator, was thrilled to learn that Citrus County has adopted Hancock County for a long-term relief relationship. He was quick to note that Citrus and other Florida counties provid- ed valuable assistance in set- ting up the temporary EOC. "Make sure you tell them how much we appreciate their help," he told a reporter while sitting in a makeshift command center. "Without them, we would have been sunk." U0 1 .- .f i. 4 b. mm 0I, "--.-et .0JCCopyrighted Material 0 t g 41 ,_ __ _ .-. _ --"World'Syndicated ContentA OP- 10110 7n&rdci Available from Comfimercial-News-Pr OP 4W-f-400--am- 0 1 ---- -va am -O 00-. o ,- O ,,- 11. t e-4--i n e~6d-fat. do s-em. --ig d -and ga. med -o rnMft- 0P a dai -- d s c c a l a -o _a mx- -n *- - -mom 's -- ---._ 40giagg ogGt--$ 0m0 Cool ash0- _-m ggm---_World_ Smartest Air Con - o --- Inrdcn th ieSa dto fth re niiy Sse th-ol' is a-mno rd t -ir cn n se ..D e ad p g .. _,adaiydiagnostic check, itatal d a m m W ft W b f 41-~ mom&a ftm -.4 -411 40,.00~- - -40 41110- o- g- 4100- a - -I -gm N-NE OOMI 41- .1b.9111 a: - g- 400- _aa-.010-t a b __0114W a- a -- 40-~ a - 0 4b MOO -40- 642747 ,ENO qwlp qg a.f q -ml ofm- -1011-u o Get $1,200 Coolu cash Worldsq Smartes't Air -Cond Introducing the Five Star Edition of the Carrier lnfinilyTM System the world's first self-monitoring residential air conditioning system. Designed and programmed to run ft.W* .% aa daily diagnostic check, it actually adjusts itself to maintain maximum-efficiency. 'l 4110 .Qpa. a 4 mo-ow -di o O a - ft 44 - 0 You stay cooler, drier and save money.. You also get the best COoo C-') ish' System. Smart air conditioner. Smart deal. * 100% Satisfaction Guarantee * 25% Minimum Cooling & Heating Cost Savings * 10-Year Factory Parts & Labor Guarantee FACTOR AMH~IE wwwYO--eGt RAwWrte = ww*naftx-zor a- - 4b- -- -Now Dviders-*-do a--- a - a.- a. - ~- ~* - - a~ 0 * Di KNO o [ BASIC.~ i NEW X U24726.7700 ..^ 4474 S. Florida Ave.# Inverness 3/4 mi, south of Fairgrounds* Hwy, 41 in The litioner! Now get your Cool Cash A instantly! '; *6 turn to the Experts 0 ssa\ * 10-Year Rust Through Guarantee * 10-Year Lightning Protection Guarantee * 30 Times More Moisture Removal Citris Marion Levy Hernanido CAC010415 Puron is a registered trademark of Carder Corporation & Infinity is a trademark of Carrier Corporation. Five Star Edition is optional. Offers end 11/11/05. See Carrier Factory Authorized Dealer for details as restrictions apply to limited warranties. Models 38YDB, 38TDB with FE4 or 58CVA with branded indoor coil and Infinity Controller. Homeowner/occupants only. 6 0 I 795-^ /\~ 489 4476 688- G E LI Tuam totbe EvpeniI r- .- .- .- a- -,W-.: 'V' I C--- /PT) 1--- I-=E E Ga icrl ftmkh D lqw, 12A FRIDAY SEPTEMBER 23, 2005 Nation _, WO 1 ^(tLJL -lAV^V^TV^JL-I cmninnmm __$way& -or *FROM SCopyrighted Material Syndicated Content Available from Commercial News Providers..... am ..-- *qw Ai m A nn40" Of af q ,a. ... ..........Sa Mw a U -ledm ma @mmmon eme - om 4 m*a 40 - 4f -____ - 4w4m is .-:, 04 moa so owa4e 00llll es om ------. _-mmKain blamed mforlDUC ku jo64 -~m m-ot ob mm .m ___.. -.A- A *o.- ANW- *. ....-O - m q o s 4. .-L - -.OL,-qm-Sa 'Am "NW 0mqD rA -f DM or- '7772 . j7.I Sneaking to the top Mayfield is quietly eyeing the Chase Cup. PAGE 5B B FRI DAY SEPTEMBER 23, 2005 Sports BRIEFS Hurricane girls shut down Lecanto The Citrus girls golf team defeated the Panthers Thursday afternoon by a score of 185-211. The Hurricanes' Brianna Carlson won low medal with a score of 42 while Christine Bang followed with a 47. Lecanto's leading golfer was Carly Lewis, who shot a 48. Citrus improved to 13-0 and plays 4 p.m. Monday at the Villages on Palmer Legends golf course. Panthers girls and boys swim to victory The Lecanto boys and girls swim teams each improved to 4-0 overall Thursday afternoon by beating Springstead. The boys won by a score of 100-81 while the girls won 115-70. For the Panthers boys, Lou Tamposi won the 200 freestyle (2:02.25) and the 100 breast- :stroke (1:16.16) while David Rundio posted ,victories in the `100 freestyle ,(58.25) and S '100 back- ,stroke (1:10.47). Garrett LeMon 'tallied a career-best 220.3 points to place first in diving. I For thegirls, Chelsea :Peterson was a double winner, pking first in the 50 freestyle (27.97) and the 100 freestyle -(59.15). Jamie Girdwain also pulled off ,wins in the 100 fly (1:17) and ;diving (152.8 points). Taylor Cooke took the 500 freestyle ,with a time of (5:51.50) and the ,quartet of Veronica Adams, :Elizabeth Lyons, Gridwain and ,jessica Hoggaerd finished first 1h the 200 medley relay (2:21.88). Both teams next swim at 5 'p.m. Tuesday against Citrus at Whispering Pines Park. ... .: S- . ~ ~ - .- 'S - n - 'S .5 .-. a.-rn. .~ .5 - From staff, wire reports Canes look for After last season s loss,Citrus eyes Raiders defeat C.J. RiSAK cjrisak@chronicleonline.com . Chronicle Last season, Citrus com- bined a potent offense with a capable defense to create a playoff team. However, one game during that season, nei- ther ingredient could quite measure up was against state- ranked South Sumter. The Raiders steamrolled the Hurricanes, 56-14, taking advantage of numerous mis- takes and playing through some of their own. Now Citrus must travel to South Sumter to face another state powerhouse. Not much has changed for the 3-1 Raiders, who seem to score at will while surrendering points grudgingly. Citrus, now 1-3, has discov- ered its offense in its past two games, but the defense is still a work in progress. To stay in the game against South Sumter, that must change. The Hurricanes haven't been able to stop anybody thus far. The reason, according to coach Rik Haines, is simple enough. "Tackle, tackle, tackle, tack- le," he said. "We improved last week (in a win over Lecanto), but you wouldn't know it. We gave Richard Chaney a couple runs due to poor tackling, but he's a good back, too. "We just don't tackle, and we always work on tackling in practice. We need to tackle bet- ter. That's all there is to it "If we don't tackle better this week, they might score 200." South Sumter runs several offenses, from a Wing-T to a Power-I and a shotgun. The Raiders also have a lot of depth, and a special quarter- back in Jarrod Fleming. The Hurricanes discovered a weapon of their own in the 39- 35 win over Lecanto in fresh- man Scriven Panthe which psycho "100 Haines gave hi SThe prep Herr PA falling "We tailback Anot upset ,p mistake against revenge running back Antoin Hurricanes threw a first-quar- n. Scriven burned the ter interception that led to a rs for 282 rushing yards, touchdown, had a bad snap on had to give the offense a a punt that gave South Sumter logical boost the ball at the Citrus 8, result- percent," was how ing in another TD, and then measured the lift it they fumbled the ensuing kick- is team. "We ran the ball off that gave the Raiders the the week ball at the Hurricane 40, which Tige for before pretty led to yet another score. nando well, but we "Defensively, at the start of GE jus4B have a lot of the game we were pretty good," GE4B have aruns (after said Haines, referring to an way behind), (after opening three-downs-and-out knew what we had at series for South Sumter. Then knew what we had atn came the mistakes and... k, so thatwastheplan. "You're down 21-0 before you her vital part of Citrus'can blink, and that kind of plan will be to trim the changes some things. es. In last years game t the Raiders, the mound 4". 14 Copyrighted Material .. Syndicated Content \,, Available from Commercial News Providers ;7 va~r - W 1imo M ab q p. 4 41m :m Nk -40 m.m o w For No. 5 Florida it's all about defense - I-Unp MN- WW.- 4h- hw-- 4.-o -:mwmdw Amm W.-w Showdown on the - Please see WARRIORS/Page 3B Please see CITRUS/Page 3B Rattlers defeat Citrus C.J. RISAK cjrisak@chronicleonline.com Chronicle Momentum can be a power- ful weapon, and Thursday at Citrus it was the Belleview vol- leyball team that got it in the second game and never gave it up. The Rattlers bounced back from a 25-18 opening-game loss to edge the Hurricanes 25- 22, 25-23, 25-18 in the next three. The win'gave Belleview the advantage in the district race with a 7-2 record; Citrus is 5-3. "We've got the height across the front line, and I thought that was too much for them," said Rattlers coach Gary Greer "They were so, scrappy the first time we met them, and they were this time too." That height allowed Belleview to block 20 Hurricane shots, with Rebecca Akaji leading with seven blocks. Suzie Rhoads, who missed the first match against Citrus, had six. The first game went just like Please see RATTLERS/Page 3B Seffner tops Warriors DON RUA For the Chronicle The Seven Rivers soccer team slipped to 7-1 in district play with a 3-1 loss to Seffner Christian Academy Crusaders in a hard fought game Thursday afternoon. The Crusaders, a young but disciplined soccer team, stymied the Warriors' offense for most of the game. While Seven Rivers had some oppor- tunities and got several shots, just two were on target Seffner's defense contained the quick Warriors players for most ] of the game bymo shutting down the front of the net Seven Rivers always seemed to be just off the ball. "When you make a pass in the middle of the field you have to put some zip on it said Warriors coach Steve Ekeli. "If we're going to put hostile pass- es in the middle of the field we might as well just get the meat- Vwagon out here and load up our guys." The Crusaders took a 2-0 lead into the half on goals by freshmen Brian Greco and Brian Kelly Seffner was quick in transi- tion and broke into the open in front of the Warriors net on m -idfe *SSr * : . SPORTS 213 FeRiAV 'SEPPTF1AHR 23, 2005 CITRUS COUNTY (FL) CHRONICLE --.- Syndicated Content -- - Available from Commercial News Providers -ii .F -> *, ,l 0 111i I * J. ..- .m A- -, a 4N ,M 01, w .. -W 10 4 .- Ak*. a 4.~- * ~. ~. 4. - C 4. S-. ~ U- - -=, % but Yanks win -M 20 0mq Mo. 4 b 9 o__ -- Ss MLB SCOREBOARD New York Boston Toronto Baltimore Tampa Bay Chicago Cleveland Minnesota Detroit Kansas City Los Angeles Oakland Texas Seattle Atlanta Philadelphia Florida Washington New York x-St. Louis Houston Milwaukee Chicago Cincinnati Pittsburgh San Diego San Francisco Arizona Los Angeles Colorado x-clinched division AMERICAN LEAGUE East Division W L Pct GB L10 89 63 .586 z-9-1 88 64 .579 1 z-5-5 75 77 .493 14 4-6 70 82 .461 19 z-3-7 64 89 .41825% z-5-5 Central Division W L Pct GB L10 91 61 .599 z-4-6 89 63 .586 2 z-8-2 78 74 .513 13 z-5-5 67 85 .441 24 2-8 52 99 .34438% 6-4 West Division W L Pct GB L10 86 65 .570 z-6-4 84 68 .553 2% z-5-5 75 77 .493 11% z-6-4 66 87 .431 21 z-4-6 NATIONAL LEAGUE East Division W L Pct GB L10 86 67 .562 3-7 82 71 .536 4 z-7-3 80 73 .523 6 z-4-6 78 75 .510 8 5-5 75 77 .49310% z-5-5 Central Division W L Pct GB L10 96 58 .623 z-5-5 84 69 .54911% 8-2 75 77 .493 20 z-5-5 75 78 .49020% 4-6 71 81 .467 24 z-5-5 62 91 .40533% 5-5 West Division z-first game was a win AMERICAN LEAGUE Thursday's Games N.Y. Yankees 7, Baltimore 6 Toronto 7, Seattle 5 .Minnesota 4, Chicago White Sox 1, 11 innings Cleveland at Kansas City, 8:10 p.m. Texas at L.A. Angels, 10:05 p.m. Friday's Games Toronto (Lilly 9-10) at N.Y. Yankees (Chacon 5-3), 7:05 p.m. Seattle (R.Franklin 6-15) at Detroit (Douglass 5-4), 7:05 p.m. Boston (Arroyo 13-9) at Baltimore (Cabrera 10-11), 7:35 p.m. Minnesota (Lohse 9-12) at Chicago White Sox (Contreras 13-7), 8:05 p.m. Cleveland (Sabathia 14-10) at Kansas City (Lima 5-16), 8:10 p.m. Texas (Rogers 13-7) at Oakland (Haren 13-11), 10:05 p.m. Tampa Bay (Fossum 8-11) at L.A. Angels (Byrd 12-10), 10:05 p.m. ', Saturday's Games Toronto at N.Y. Yankees, 1:05 p.m. Texas at Oakland, 4:05 p.m. Boston at Baltimore, 4:35 p.m. Seattle at Detroit, 7:05 p.m. Minnesota at Chicago White Sox, 7:05 p.m. Cleveland at Kansas City, 7:10 p.m. Tampa Bay at L.A. Angels, 10:05 p.m. Marlins 2, Mets 1 FLORIDA NEW YORK ab rhbi ab r hbi Pierre cf 402 0 Reyes ss 4 0 1 0 Conine If 5 01 1'Cairo 2b 4 0 0 0' CDIgdo lb 2 01 0 Beltran cf 4 0 2'0 AGnzlz pr 0 00 0 Floyd If 4 0 00 TJonesp 0 000 Wright 3b 4 0 1 0 JEcrcn rf 5 01 1 Diaz rf 4 0 1 0 L Duca c 4000 RCstro c 3 1 1 1 Lowell 3b 201 0 Wdwrd lb 2 000 Willisp 4 01 0 PMrtnz p 1 0 0 0 Aguila If 00000 Offrmn ph 1 0 00 Dillon 2b 3 10 0 JuPdla p 0 00 0 LCstillo 2b 0 00 0 Piazza ph 1 000 Andino ss 3 11 0 Heilmn p 0 0 0 0 Totals 322 8 2 Totals 32 1 6 1 Florida 001 010 000- 2 New York 001 000 000- 1 E-Dillon (1), Cairo (5). DP-Florida 1, New York 2. LOB-Florida 11, New York 6. 2B-Pierre (16), CDelgado (40), JEncarnacion (27), Andino (4). 3B- Conine (2). HR-RCastro (8). SB-Pierre (53). CS-Reyes (14). S-Pierre, Andino. IP H RERBBSO Florida Willis W,22-9 8 5 1 1 2 7 TJones S,38 1 1 0 0 0 2 New York PMartinez L,15-8 5 6 2 2 2 1 JuPadilla 2 1 0 0 1 1 Heilman 2 1 .0 0 2 1 HBP-by PMartinez (Dillon). Umpires-Home, Dana DeMuth; First, Marty Foster; Second, Laz Diaz; Third,* Bob Davidson. T-2:18. A-25,093 (57,369). Astros 2, Pirates 1 HOUSTON PITTSBURGH ab rhbi ab r hbi Tveras cf 321 0 Snchez 3b 4 0 1 0 Burke If 2000 JWilsn ss 4 00 0 Ensbrg 3b 4 00 0 Bay If 4 00 0 Brkmn lb 2 02 2 Mckwkcf 4 0 1 0 Lane rf 2 00 0 CWilsn rf 3 1 1 1 Brntlett2b 4 01 0 Ward lb 4 0 1 0 Lidge p 0000 Doumitc 3 000 AEvrtt ss 4 00 0 Frmnk 2b 3 0 0 0 Asmusc 4 01 0 Duke p 1 0 0 0 Backe p 3 00 0 McLth ph 1 0 0 0 Qualls p 0000 Grabow p 0 00 0 JVzcno2b 1 000 Gnzalez p 0 00 0 TRdmn ph 1 0 1 0 STorres p 0 0 00 Totals 292 5 2 Totals 32 1 5 1 Houston 101 000 000- 2 Pittsburgh 000 010 000- 1 LOB-Houston 7, Pittsburgh 5. 2B- Taveras (12). HR-CWilson (3). CS- Berkman (1). S-Burke 2. IP H RERBBSO Houston Backe W,10-8 7 2 1 1 0 6 Quails 2-3 2 0 0 0 0 Lidge S,38 11-3 1 0 0 0 2 Pittsburgh Duke L,6-2 6 5 2 2 3 1 Grabow 1 0 0 0 0 3 Gonzalez 1 0 0 0 2 2 STorres 1 0 0 0 0 1 HBP-by Backe (CWilson). Umpires-Home, Ron Kulpa; First, Dan lassogna; Second, Dale Scott; Third, Tim Tschida. T-2:30. A-12,587 (38,496). Phillies 4, Braves 0 PHILA ATLANTA ab rhbi ab r h bi Rollins ss 5 02 0 Furcal ss 4 0 1 0 Lofton cf 3000 MGiles 2b 4 0 1 0 Utley 2b 3 00 0 CJones 3b 4 0 0 0 BAbreurf 2 11 0 AJonescf 4 0 1 0 Burrell If 4 000 LaRche lb 2 0 1 0 Lbrthal c 0 00 0 JuFrco ph 1 00 0 Howard lb 4 11 0 Fmcur rf 3 000 DaBell 3b 400 0 Lngrhn If 3 02 0 Pratt c 3 00 0 McCnn c 3 0 0 0 Tucker ph 1 11 1 THudsn p 3 00 0 BWgnr p 0 000 Mcbrde p 0 000 Lieber p 3 00 0 Vctrno If 1 11 3 Totals 334 6 4 Totals 31 0 6 0 Home 51-27 50-24 41-37 35-39 40-38 Home 44-34 42-33 40-34 35-39 33-44 Home 46-31 43-31 44-34 37-38 Home 49-26 45-33 42-33 41-34 45-32 Home 47-29 51-26 41-33 36-40 41-37 32-46 Home 41-33 36-42 33-44 37-37 39-39 Away Intr 38-36 11-7 38-40 12-6 - 34-40 8-10 35-43 8-10 24-51 3-15 Away Intr 47-27 12-6 47-30 15-3 38-40 8-10 32-46 9-9 19-55 9-9 Away Intr - 40-34 12-6 41-37 10-8 31-43 9-9 29-49 10-8 Away Intr - 37-41 7-8 37-38 7-8 38-40 10-5- - 37-41 12-6 30-45 5-10 - Away Intr 49-29 10-5 33-43 7-8 34-44 8-7 39-38 6-9 30-44 7-8 30-45 5-7 Away Intr 35-43 7-11 35-39 6-12 - 36-39 8-10 30-47 5-13 24-50 6-9 NATIONAL LEAGUE Thursday's Games Houston 2, Pittsburgh 1 Philadelphia 4, Atlanta 0 Chicago Cubs 3, Milwaukee 0 Colorado 4, San Diego 2 Washington 2, San Francisco 0 Florida 2, N.Y. Mets 1 Cincinnati 6, St. Louis 2 L.A. Dodgers at Arizona, 9:40 p.m. Friday's Games Houston (Rodriguez 10-8) at Chicagp tubs (Rusch 7-8), 3:20 p.m. N.Y. Mets (Trachsel 1-3) at Washington (Loaiza 11-10), 7:05 p.m. Philadelphia (Padilla 8-12) at Cincinnati, (Harang 10-13), 7:10 p.m. Florida (Beckett 15-8) at Atlanta (Smoltz .X 14-7), 7:35 p.m. San Francisco (Kinney 2-0) at Colorado;,, (Francis 13-12), 8:05 p.m. St. Louis (Carpenter 21-4) at Milwaukeoe \, (Capuano 17-10), 8:05 p.m. San Diego (P.Astacio 2-2) at Arizona ,, (Vargas 9-8), 9:40 p.m. ,, Pittsburgh (Maholm 2-0) at L.A. Dodgers., (Houlton 5-9), 10:40 p.m. Saturday's Games Houston at Chicago Cubs, 2:20 p.m. Florida at Atlanta, 7:05 p.m. N.Y. Mets at Washington, 7:05 p.m. St. Louis at Milwaukee, 7:05 p.m. Philadelphia at Cincinnati, 7:10 p.m. San Francisco at Colorado, 8:05 p.m. '., San Diego at Arizona, 9:40 p.m. Pittsburgh at L.A. Dodgers, 10:10 p.m. Philadelphia 000 000 004-- 4 Atlanta : 000:000 000- 0 E-LaRoche (7). DP-Atlanta 1. LOB- Philadelphia 6, Atlanta 5. 2B-Rollins (34), Furcal (30), Langerhans (21). HR--- "Victdrino (1). CS-Langerhans (2). S- LaRoche. IP H.RERBBSO ' Philadelphia LieberW,16-12 8 5 0 0 0 7-' BWagner 1 1 0 0 0 2 Atlanta THudson L,13-9 82-3 6 4 4 4 3 Mcbride 1-3 0 0 0 0 0 Umpires-Home, Jeff Nelson; First, Bill- Miller; Second, Joe Brinkman; Third, Derryl Cousins. T-2:23. A-26,301 (50,091). Cubs 3, Brewers 0 -- CHICAGO MILWAUKEE ab rhbi ab r hbi - NPerez ss 4 13 1 BClark cf 4 0 00 TWalkr2b 301 1 Weeks 2b 3 000, DeLeelb 401 0Ovrbaylb 4 000, Grcprr 3b 3 00 0 CaLee If 3 0 0 0 Burnitz rf 300 0 Jenkins rf 3 0 1 0 Murton If 4 01 0 BHall ss 3 0 1 0 - CPttson cf 4000 Bmyan 3b 3 0 1 0- Barrett c 2 21 0 DMiller c 3 0 1 0- Mddux p 3 00 0 HlIIngp 0 000 0 Dmpstrp 0000 Drgtnph 1 0 00 KDavis p 0 000 . Cpllan p 0 0 0 0 Cirillo ph 1 0 00 Totals 303 7 2 Totals 28 0 4 0: Chicago 001 020 000- 3 Milwaukee 000 000 000- 0 DP--Chicago 2, Milwaukee 3. LOB-, Chicago 4, Milwaukee 3. 2B-NPerez (32), Barrett (30), BHall (35). SB-NPerez (8).. CS-NPerez (4). S-Helling. SF- TWalker. IP H RERBBSO Chicago MadduxW,13-13 8 4 0 0 0 4 DempsterS,29 1 0 0 0 1 1 . Milwaukee Helling'L,2-1 6 5 3 3 3 5, KDavis 2 1 0 0 0 3 Capellan 1 1 0 0 0 0 WP-Helling. Umpires-Home, Chuck Meriwether;- First, Mike Everitt; Second, Tim Timmons; Third, Tim McClelland. T-2:19. A-31,137 (41,900). Nationals 2, Giants 0 SAN FRAN WASHINGTON ab rhbi ab r hbi Winn cf 4 00 0 Watson If 2 0 0 0 Vizquelss 4 000 JGillen rf 1 00 0 Niekro lb 400 0 Byrd cf 4 000 Alou rf 3020 Baerga lb 3 0 0 0 Drham 2b 2 000 NJhnsn lb 1 000.' Alfonzo 3b 3 000 Zmrmn 3b 4 1 20-., Linden If 3 01 0 Church rf 3 0 1 6 Mtheny c 3 00 0 Short 2b 3 1 2 1 Tomko p 3 01 0 DCruz ss 3 0 2 1 Accrdo p 0 00 0 GBnntt c 2 0 0 0" Tschnr p 0 00 0 HCrsco p 1 0 00'.. Ayala p 0 000 Vidro ph 1 0 1 0 Spivey pr 0 0 0 0 Rauch p 0 00 0 Castilla ph 1 000 0.. Mjwski p 0 0 0 0 CCrdro p 0 000 . Totals 290 4 0 .Totals 29 2 8 2' San Francisco 000 000 000- 0 Washington 000 000 20x- 2', E-Niekro (5). DP-San Francisco 1,- Washington 1. LOB-San Francisco 6, Washington 5. 2B--Alou (18), Short 2 (2). CS-Church (2). S-Watson. San Francisco Tomko L,7-15 Accardo Taschner Washington HCarrasco Ayala Rauch W,2-4 Majewski CCordero S,47 IP 61-3 1-3 11-3 52-3 1-3 1 1 1 H RERBBSO 8 2 2 0 4 . 00 0 1 0 0 0 0 0 1 4W 1 -Kim- A -. .- - w~ ~ 'U 4.4. ,m M"m I AL*LAite,.n, wr. J.:i t" ow::. .*-::.. XI :HjfI .... =-: -- -... :: " ,. ., .... ... .. . ,;Wk . :l " . J - * J::" xt "E *"s" WAND- . """ :, : Crptl(?nILUUINITV(rl (Pff CU.irj.r BASEBALL Rockies 4, Padres 2 SAN DIEGO COLORADO ab rhbi ab r hbi DRbrts cf 4 01 0 Barmes ss 4 11 1 EYong2b 401 0 Sllivancf 1 1 1 Alxndr2b 000 0 Helton lb 3 1 1 2 BGiles rf 4 12 0 Hlliday If 3 0 0 0 Klesko If 4 11 0 Atkins 3b 4 0 2 0 KGreen ss 4 01 2 Hawpe rf 4 0 1 0 RaHrdz c 4 020 TGreen c 4000 Randa 3b 4 03 0 Fentes p 0000 Fick lb 3 00 0 LuGnzl2b 4 1 2 0 Hnsley p 0 00 0 Cook p 3 0 0 0 Jhnson ph 1 00 0 Ardon c 0 00 0 Eaton p 2000 MaSwylb 1000 Totals 35211 2 Totals 30 4 8 4 San Diego 000 000 002- 2 Colorado 001 010 20x- 4 DP-San Diego 1, Colorado 2. LOB- San Diego 6, Colorado 8. 2B-KGreene (29), RaHernandez (19), Randa (41), Sullivan (13), LuGonzalez (24). HR- Helton (18). SB-EYoung (7), Barmes (6). S-Cook. IP H RERBBSO San Diego Eaton L,10-5 61-3 7 4 4 5 3 Hensley 12-3 1 0 0 0 1 Colorado Cook W,6-1 8 10 2 2 0 1 FuentesS,30 1 1 0 0 0 1 Cook pitched to 2 batters in the 9th. WP-Eaton, Fuentes. Umpires-Home, Jeff Kellogg; First, Travis Reininger; Second, Mike Reilly; Third, Andy Fletcher. T-2:16. A-18,119 (50,449). Reds 6, Cardinals 2 ST. LOUIS CINCINNATI ab rhbi ab r hbi Eckstinss 5 01 0 Freel If 4 22 0 Edmndcf 4 02 1 FLopezss 4 1 1 1 Pujols lb 3 00 0 Dunn lb 3 1 1 0 RSndrs If 4 00 0 Aurilia 2b 4 0 0 0 Schmkr if 0 00 0 LaRuec 2 0 0 0 Tguchi rf 4 01 0 Keams rf 4 1 0 1 Tvarezp 0000 WPena cf .2 000 Eldredp 0000 0JaCruzph 0 1 00 Grdzin 2b 4 130 Wthers p 0 0 0 0 YMlina c 4 01 1 EEcrcn 3b 3 0 1 3 Nunez 3b 4 000 Clausen p 2 0 00 Morris p 1 100 Vlentin ph 1 000 Gall ph 1 000 Coffey p 0 000 Thmpsp 0 000 Dnorfia cf 1 00 0 King p 0 000 Mabryrf 1 00 0 Totals 352 8 2 Totals 30 6 5 5 St Louis 010 010 000- 2 Cincinnati 000 100 05x- 6 ELPujols (12), Nunez (13). DP-St. Louis 1. LOB-St. Louis 8, Cincinnati 6. 2B--Edmonds (36), Freel 2 (19), EEncamacion (14). 3B--:Grudzielanek (3). SB-Freel (34). IP H RERBBSO St.Louis Morris 6 1 1 0 3 4 Th6mpson 1 1 1 1 0 1 KingL, pitched to 4-4 0 2 2 2 0 0 Tav-arez ,2-3 1 2 2 2 0 Eldred 1-3 0 0 0 0 0 Cincinnati Claussen 7 6 2 2 2 5 Coffey W,4-0 1 2 0 0 0 0 Weathers 1 0 0 0 0 0 Thompson pitched to 1 batter in the 8th, King pitched to 2 batters in the 8th. HBP-by Thompson (EEncarnacion). Umpires-Home, Tom Hallion; First, Chris Guccione; Second, Angel Hernandez; Third; Greg Gibson. T-2:37. A-17,461 (42,271). S American League Blue Jays 7, Mariners 5 SEAT7,7 TORONTO Sab rhbi ab, r hb, ISuzuki rf 5000 Aaams ss 4 1.1 0 YBtcrtss ,..2 01 0 Ctlnotto dh 4 1 2.0 Hansenph 1 00 0 VWellscf 4 01 1 Ibanez If 410 0 Koskie 3b 3 21 1 Sexson lb 322 0 HInbrnlb 4 1 00 Beltre 3b 4 02 2 Rios rf 4 2 2 3 Morse dh 3 11 0 Gross If 4 02 1 Dobbs dh 1 00 0 AHill 2b 3 0 01 Reed cf 4 12 1 Quiroz c 3 0 1 0 JoLjez2b 4 01 2 Trralba c 3 01 0 RSntgo ph 0 00 0 Totals 34510 5 Totals 33 710 7 Seattle 000 320 000- 5 Toronto 500 000' 02x- 7 E-JoLopez (6). DP-Seattle 1, Toronto 2. LOB-Seattle 7, Toronto 4. 2B-Sexson (34), Beltre (34), Reed (32), JoLopez (15), Koskie (18), Gross (3), Quiroz (2). HR- Rio's (10). SB-Reed (12). CS- YBetancourt (3). SF-AHill. IP H RERBBSO Seattle Pineiro L,7-10 72-3 10 7 7 1 8 RSoriano 1-3 0 0 0 0 0 Tor6nto Chacin 41-3 7 .5 5 4 3 McGowan 22-3 1 0 0 0 3 SpeierW,3-2 1 2 0 0 0 0 Schoeneweis 1-3 0 0 0 0 0 MB1tista S,29 2-3 0 0 0 0 0 HBP-by Schoeneweis (RSantiago). Ufnpires-Home, Ed Rapuano; First, C.B. Bucknor; Second, Phil Cuzzi; Third, James Hoye. T-2:40. A-23,118 (50,598). Yankees 7, Orioles 6 BALTIMORE NEW YORK ab rhbi ab r hbi BCstro2b 4 11 1 Jeterss 5 02 0 Mora 3b 421 1 Cano2b 4 2 1 0 Tejada ss 5 12 1 ARod 3b 3 00 1 Gbbons rf 41"2 1 Shffield dh 4 22 1 Surhofflb 4 00 1 Matsui If 3 1 1 1 JvLopz c 3 01 1 Posada c 4 2 24 WYong dh 2 00 0 BWIImscf 4 0 0 0 Freire dh 2 000 TMrtnz lb 2 0 0 0 CITRUS Continued from Page 1B ",You're playing a program - you're not just playing a team - and we're still a young, rebuild- ing program. We're going to go over there and play good." For the Citrus defense to neutralize South Sumter, it must handle its speed. 'You just can't simulate their speed in practice with your scout-team players," Haines noted. "They want to pound on yoti. Hopefully, you can make them go the long field for touchdowns instead of big runs or. getting the ball (on turnovers) in plus-territory." If the offense which scored just once against the Raiders last season (the other was on an interception return)- can establish Scriven and a ground game, it may be able to keep it close. Haines believes the defense may be starting to come around. "The thing about the Lecanto For the record On the AIRWAVES TODAY'S SPORTS BASEBALL 12:30 p.m. (ESPN) MLB Baseball Houston Astros at Pittsburgh Pirates. From PNC Park in Pittsburgh. (Live) (CC) 1 p.m. (TBS) MLB Baseball Philadelphia Phillies at Atlanta Braves. From Turner Field in Atlanta. (Live) (CC) 7 p.m. (FSNFL) MLB Baseball Florida Marlins at New York Mets. From Shea Stadium in Flushing, N.Y. (Live) FOOTBALL 7:30 p.m. (ESPN) College Football Air Force at Utah. (Live) (CC) GOLF 8 a.m. (GOLF) European PGA Golf Seve Trophy First Round. From Wynyard Golf Club in Stockton, England. (Live) 1 p.m. (TNT) Golf The Presidents Cup Day 1. From the Robert Trent Jones Golf Club in Prince William County, Va. (Live) 4 p.m. (ESPN) PGA Golf Valero Texas Open First Round. From the LaCantera Golf Club in San Antonio. (Live) (CC) 5 p.m. (GOLF) PGA Golf Nationwide Tour Albertson's Boise Open First Round. From Boise, Idaho. (Live) Prep CALENDAR TODAY'S PREP SPORTS FOOTBALL 7:30 p.m. Trinity Catholic at Crystal River 7:30 p.m. Central at Lecanto. 7:30 p.m. Citrus at South Sumter 7:30 p.m. Dunnellon at Hernando. BOYS SOCCER Seven Rivers at Pinellas Christian VOLLEYBALL 6 p.m. First Academy of Leesburg at Seven Rivers Matos cf 4 1 1 0 Lawton rf 2 0 0 0 Newhn If 2 00 0 Sierra ph 1 0 0 0 Byrnes If 2 00 0 Crosby rf 0 0 0 0 Totals 366 8 6 Totals 32 7 8 7 Baltimore 001 000 041- 6 New York 000 014 20x- 7 E-BCastro (2), Tejada (20), Jeter (15), TMartinez (8). DP-New York 1. LOB- Baltimore 6, New York 7. 2B-Tejada (49), Gibbons (29), JvLopez (21). 3B-Cano (4). HR-Mora (21), Sheffield (30), Posada 2 (19). SB-TMartinez (2). S-Cano. SF- ARodriguez. IP H RERBBSO Baltimore BChenL,12-10 51-3 5 5 4 1 8 Byrdak 1-3 00 0 2 0 Rakers 1 2 2 2 1 0 Kline 1 0 0 0 0 0 Williams 1-3 1 0 0 0 0 New York Mussina W,13-8 6 4 .1 0 0 6 Leiter 1 2 4 4 2 1 Sturtze 1 1 0 0 0 1 Gordon S,2 1 1 1 1 0 0 Leiter pitched to 4 batters in the 8th. HBP-by Mussina (JvLopez). Umpires-Home,. Randy Marsh; First, Jim Wolf; Second, Sam Holbrook; Third, Larry Vanover. T-3:07. A-52,368 (57,478). Twins 4, White Sox 1, 11 Innings MINNESOTA CHICAGO S ab rhbi ab r h,bi Tyner If 301 0 Ozuna If 4 0 00 LFord If 1 11 0 Przynsc .0 0 00 Bartlett ss' 4 00 0 Iguchi 2b 5 0 1 0 Mauer c 4 10 0 CEvrtt dh 5 0 0 0 LeCroy dh 501 1 Knerko Ib 4 0 1 0 Punto dh 0 100. Rwand cf 4 0 1 0 JJones cf 4 123 Dye rf 5 0 1 0 Cddyer rf 5 01 0 Uribe ss 4 0 0 0 Mmeau lb 5 010 Widgerc 3 0 1 0 Tiffe 3b 301 0 Pdsdnk If 1 0 0 0 JCastro 3b 0000 Crede 3b 3 1 2 1 Rivas2b 300 0 Totals 374 8 4 Totals 38 1 7 1 Minnesota 000 000 100 03- 4 Chicago 000 001 000 00- 1 E-Bartlett (7). DP-Minnesota 2, Chicago 4: LOB-Minnesota 6, Chicago 8. 2B-LFord (29), JJones (22), Dye (28). HR-JJones (23), Crede (20). SB-LFord (13). S-Crede. IP H RERBBSO Minnesota JoSantana 8 4 1 1 1 3 JRincon 1 2 0 0 1 1 Crain W,11-5 1 0 0 0 1 0 Nathan S,39 1 1 0 0 0 1 Chicago McCarthy 8 4 1 1 1 4 Marte 0 0 0 0 1 0 Politte 2-3 0 0 0 1 0 Cotts 11-3 1 0 0: 1 0 JenksL,1-1 1 3. 3 3 1 1 Marte pitched to 1 batter in the 9th. HBP-by McCarthy (Rivas). Umpires-Home, Wally Bell; First, Jim Reynolds; Second, Lance Barksdale; Third, Rob Drake. T-3:12. A-25,112 (40,61,5). GOLF Presidents Cup Cards Thursday At Robert Trent Jones Golf Club Gainesville, Va. Yardage: 7,335 Par: 72 game was when we needed to make a stop on defense, we made a stop," he said. "Our defense won that game for us last week because they made a crucial stop at the start and they made a crucial stop at the end. "Sometimes when you get a lot of points scored on you, it ain't the defense's fault. It's where the offense is giving them the ball." If the Hurricane offense can hold onto the ball and keep putting points on the board, the defense won't have to worry. But against one of the state's best teams, that is a tall order indeed. Chronicle sports editor Andy Marks contributed to this story. Lecanto to host Central It was so very close. Lecanto could have come into tonight's Homecoming game against Central at 2-1 if the Panthers could have pulled off a second-straight comeback win, this one at Citrus. Instead, they had to settle for a second-consecutive close loss to the Hurricanes, this one by a 39-35 OVERALL SCORE FOURSOMES Score Par 435-445-343-545-434-444 Tiger Woods-Fred Couples, U.S. 434-555- 343-444-435-xxx Adam Scott-Retief Goosen, Intl. 434-454- 245-443-434-xxx International, 4 and 3. Par 435-445-343-545-434-444 Fred Funk-Jim Furyk, U.S 534-345-344- 544-424-544 Vijay Singh-Mark Hensby, Intl. 435-445- 344-435-334-4x4 Halved. Par 435-445-343-545-434-444 Phil Mickelson-Chris DiMarco, U.S. 335- 445-343-544-52x-444 Nick O'Hern-Tim Clark, Intl. 435-445-433- 553-433-544, United States, 1 up. Par 435-445-343-545-434-444 Justin Leonard-Scott Verplank, U.S. 445- 344-x43-434-434-3xx Peter Lonard-Stuart Appleby, Intl.436-445- 353-444-434-4xx United States, 4 and 2. Par 435-445-343-545-434-444 Davis Love III-Kenny Perry, U.S. 435-545- 344-434-444-53x Michael Campbell-Angel Cabrera, Intl. 444-544-343-544-434-43x International, 2 and 1. Par ', .. ,43-445-343-545,-44-444, David Toms-Stewart Cink, U.S. 434-445- 34x-545-4xx-xxx ' Trevor Immelman-Mike Weir, Intl. 334-335- 343-444-4xx-xxx Intemarnonal. 6 and 5. NOTE: x-hole was not played or no score was recorded. JHOdk EY Hurricanes 5, Ughtning 2 TampaBay 0 2 0 2 Carolina 2 2 1 5 First Period-1, Carolina, Larose 1 (penalty shot), 2:29. 2, Carolina, Richmond 1 (Cole, Vasicek), 5:29 (pp). Second Period-3, Tampa Bay, Afanasenkov 1 (Modin, Sydor), 5:08 (pp). 4; Carolina, Vasicek 3 (Cole, Larose), 5:28. 5, Carolina, Boulerice 1 (Cole, Richmond), 10:56. 6, Tampa Bay, Sydor 1 (Boyle, Modin), 17:04. Third Period-7, Carolina, Vasicek 4 (Cole, Commodore), 19:18. Shots on goal-Tampa Bay 4-8-5-17. Carolina 7-12-11-30. Goalies-Tampa Bay, Grahame. Carolina, Gerber. A-6,654. Blackhawks 3, Wild 2 Chicago 0 1 1 0 3 Minnesota 1 0 1 0 2 Blackhawks won shootout 1-0 First Period-1, Minnesota, Chouinard 1 ,(Rolston, Bouchard), 18:00 (pp). Second Period-2, Chicago, Lee 1 (Bourque), 9:44. Third Period-3, Chicago, Vorobiev 1 (Babchuk, Wisniewski), 3:26 (pp). 4, Minnesota, Burns 1 (Bouchard, Veilleux), 11:44 (pp). Overtime-None. Shootout-Chicago 1 (Rene Bourque NG, Tyler Arnason NG, Kyle Calder NG, Duistin Byfuglien NG, Pavel Vorobiev G); Minnesota 0 (Pierre-Marc Bouchard NG, Mikko Koivu NG, Alexandre Daigle NG, margin. "I was disappointed Friday night, and I was disappointed on Saturday," said Lecanto coach Bob LeCours. "But I know what our kids are capable of. I believe in them." And he is certain they will bounce back with a solid effort against Central. It won't be easy - the Bears are 2-2 overall and 2-0 in the district, with a 33-0 win over Hernando and a 41-6 trounc- ing of Crystal River. Their losses came to Sarasota Booker, 50-0, and last week to Tarpon Springs, 44-14. What Central brings is a double- wing offense that features several backs. The one that concerns LeCours most is DuJuan Harris, the Bears' leading rusher. As far as what to expect from them, their first-year coach, Greg Bigham, doesn't mince words. "We're going to try and mix it up, but I won't make any bones about it we're a running team," he said. Indeed, quarterback Gary Owen has only thrown for approximately 100 yards this season, according to Bigham. Benoit Pouliot NG, Peter Olvecky NG). Shots on goal-Chicago 9-13-6-1-29. Minnesota 11-07-2-3-23. Goalies-Chicago, Munro. Minnesota, Roloson. A-18,064. Maple Leafs 4, Canadiens 3 Montreal 1 0 2 3 Toronto 1 3 0 4 First Period-1, Toronto, McCabe 1 (Sundin, Ponikarovsky), 14:01 (pp). 2, Montreal, Bulis 1 (Sundstrom), 16:58. Second Period-3, Toronto, Wellwood 1 (White), 4:00. 4, Toronto, Thomas 1 (Stajan, White), 14:35. 5, Toronto, Wellwood 2 (unassisted), 19:45. Third Period-6, Montreal, Plekanec 2 (Rivet, Streit), 4:51 (pp). 7, Montreal, Dagenais 1 (Plekanec, Ribeiro), 19:56 (PP). Shots on goal-Montreal 9-9-16-34. Toronto 8-18-5-31. Goalies-Montreal, Danis, Price. Toronto, Racine, Tellqvist. A-18,853. Panthers 4, Thrashers 3 Florida 0 3 1 4 Atlanta 1 1 1 3 First Period-1, Atlanta, Holik 1 (Modry, Kozlov), 13:54 (pp). Second Period-2, Florida, Kolnik 1 (Bouwmeester, Krajicek), 3:45 (pp). 3, Florida, Weiss 2 (Van Ryn, Gratton), 7:03 (pp). 4, Florida, Weiss 3 (Jokinen, Van Ryn), 13:31 (pp). 5, Atlanta, Bondra 2 (Holik), 12:22. Third Period-6, Florida, Stewart 2 (Gratton, Van Ryn), 0:53 (pp). 7, Atlanta, Bondra 3 (Havelid), 18:08 (pp). Shots on goal-Florida 6-8-5-19. Atlanta 24-13-17-54. Goalies-Florida, Pelletier, Luongo. Atlanta, Dunham. A-NA. Blue Jackets 3, Red Wings 2 Detroit 0 1 1 0 2 Columbus 1 1 0 1 3 First Period- 1, Columbus, Motzko 1 (Vyborny, Brule), 17:21. Second Period-2, Columbus, Lindstrom 1 (Zherdev), 0:46. 3, Detroit, Lang 1 (Delmore, Kronwall), 1:54 (pp). Third Period-4, Detroit, Mowers 1 (Lebda, Hudler), 19:16 (pp). Overtime-5, Columbus, Brule 1 (Beauchemin, Zherdev), 4:33. Shots on goal-Detroit 10-15-1-3-29. Columbus 9-7-8-4-28. Goalies-Detroit, Howard. Columbus, Leclaire. A-13,040. TRANSACTIONS BASEBALL National League MILWAUKEE BREWERS-Activated RHP Julio Santana from the 15-day DL. Cam-Am League ELMIRA PIONEERS-Released OF Samone Peters. BASKETBALL National Basketball Association MIAMI HEAT-Signed G Gary Payton. PHILADELPHIA 76ERS-Agreed to terms with F Lee Nailon. FOOTBALL National Football League ARIZONA CARDINALS-Placed TE John Brsoson'liJ'c McNei to in. ECHL LAS VEGAS WRANGLERS-Re-signed D Christian Chartier. Signed D Scott Schoneck. VICTORIA SALMON KINGS-Acquired C Dustan Heintz from Johnstown for cash. Signed RW Derek Allan. Central Hockey League LUBBOCK COTTON KINGS-Re- .signed G Shawn Conschafter. Signed G Brett Koscielny. ODESSA JACKALOPES-Signed G Paul Schonfelder and G Michael Shimek. TULSA OILERS-Signed D Dan Hodge. United Hockey League ADIRONDACK FROSTBITE-Re- signed G Kris Tebbs to a one-year con- tract. KALAMAZOO WINGS-Signed F Scott Turner and D Casey Handrahan. QUAD CITY MALLARDS-Signed D Samy Nasreddine. COLLEGE NCAA-Placed Texas Christian on two years probation for violations by former track coaches, including impermissible inducements, extra benefits, academic fraud, unethical conduct, and for failing to monitor its track & field program. MID-CONTINENT CONFERENCE- Named Tom Douple commissioner, effec- tive Oct. 10. Others to watch offensively for Central are backs Bryan Nutter and Carlos Becaria. Lecanto will try to offset that with its own backfield of running back Richard Chaney, fullback Dustin Young, wingback Garrett Frieberg and quarterback Mychal Nichols. Both teams will try to do some- thing similar: Hold onto the ball. "We want to control the tempo of the game on offense," said LeCours, adding, "Those are my famous last words. And our defen- sive line must control the line of scrimmage." That won't be easy. "They're a bigger, stronger and faster football team than we are. But our guys are competitors." Bigham wants to do the same: "Like Lecanto, we like to control the ball and keep our offense on the field. So it's going to be a battle to see who can do it best." If Lecanto can mix it up offen- sively and put points on the board, the defense may be able to contain the Bears. But that will be a tough challenge. WARRIORS Continued from Page 1B several occasions. Often, the only thing between them and another goal was keeper Chad Peets who had to come out of the net several times to take the ball himself. "We had three things we wanted to try to do today," said Crusaders coach Mark Canterbury. "Be first to the ball, contain their good ath- letes, and communicate among ourselves. We did all three well." It seemed only a matter of time before the Warriors would score and make a game of it RATTLERS Continued from Page 1B Citrus wanted it to. Belleview had a 13-10 lead until Ashley Hoglund stepped in to serve. Seven of her serves later, the Hurricane lead was 17-14. Hoglund and Rachel Filtz sparked Citrus throughout the match, nearly overcoming the Rattlers' strong net play. Filtz, who struggled with her serve at times, did serve three-straight points to take Citrus from a 21- 17 lead to a 24-17 advantage in that first game. But the momentum began to switch in the second set. Belleview took the lead at 3-2 and never did trail in the game, although the Rattlers never led by more than four. The Hurricanes rallied on several occasions, tying it three times and pulling to within one seven times. However, they could never quite manage to pass Belleview. Trailing 23-21 and with Hoglund serving, Citrus got a hitting error from Belleview's Rachel Healy to pull to within one. But a block kill by Akaji regained the serve for the Rattlers and a service ace by Temetria James ended it "I think a lot of it had to do with our mental attitude," said Citrus coach Alice Christian. "And that's something I can't control. Things start going wrong and they get down on themselves. In the third and Ov. 4b l- o *AM__ *___ Seven Rivers managed over a dozen shots but, due to the Crusaders tight defense in front of the net, they were forced to send most of them in from long distance. Julian Cousinet played a great game on defense and offense and took several shots himself, along with Drew Donovan, and Taylor Swander, but no one could find the back of the net The Warriors scored their first and only goal with less than 15 minutes to go. The score now 2-1, Seven Rivers had a chance to tie the game when they were awarded a penalty shot with less than five minutes left, but the Seffner wall held firm denying it fourth games we showed a lot of poor errors, some bad judge- ment" Citrus' best opportunity to take control of the match was in the third game. With Fultz serving, the Hurricanes pulled ahead 5-0 to start, but the Rattlers kept chipping away at that advan- tage until they knotted it at 11- all. From that point on, it was one or two point game (Belleview did lead once, 15- 12). The final point summarized the game: A seemingly endless rally, with Mary-Ann Masson's kill attempt missing to give Belleview the game. If the Hurricanes were slow- ly sinking, they were complete- ly deflated by Game 4. They did lead 8-6, but James served four-straight points and the Rattlers never trailed again. Rachel Rudolf put together another four-point serve that carried Belleview to a 23-17 lead; Healy's ace for the final point clinched the match. It was the second meeting of the district rivals; in the first, Citrus came from two games down to win in five. "We beat them at home, so they came in here and wanted to beat us in our house," said Christian. "But we let our atti- tudes get to us, and you can't do that" Fultz led the Hurricanes with 9 kills, 7 blocks and 3 aces, while Hoglund had 9 kills and Jackie White had 4 kills. Citrus hosts district leader Crystal River Tuesday in its next match. - bqm_ A- _ -mo -op-mm 4 qu S -wmm =No .0-amob-4 4M -o 4wo~o -go ~ - --f dpom.0 - &W--gow o qp 4o am a~m-mm -gaw a S qw - dim. '40 4- 4-l- 0 a - S. a. S. a. S.- a - ~- S. - ,. S. - -~ ,~ .-.. - S. a.. - - U' a -. C - a - S. S. S. a a a. * -^ Aloe--- dk- .0 u~m--. -f ow u-AIIP - 0 -m f- A- A- SA .Am.m" Am S.~ - 0 - - 9 - a. S.- S. a - -r - .- __ -=6- a -- - - -~ - 0 - * -. or S S.. - - .0 S 0 a. - - S.. - -.-.w - a - v - Sg Copyrighted Material - -- Syndicated Content - ."" Available from Commercial News Providers FRIDAY, SEPTEMBER 23, 2005 313 S-PORTS Cmus CouN7y (FL) CHRoNicLE - CITRUS COUNTY (FL) CHRONICLE SPORTS *5FRIDA, SEPTEMBER Z~fl j, ZUU.2 Copyrighted Material. -O S'Syndicated Content - = - .Available from Commercial News Providers *0 0 ~- - - 00 . lot ___ -1b ftm. 40b mw- 404a - ft.- -0 qmw --- - q- -Nww - - -0 -- A - - - -- - - -.~ - .0 S S -~ * .a ~. ~ - -b mom~ - ft 'a -40 qw -.Om- wm-. - mm- 0 - - "Moom qb ob ab- 4b 4m - q- 0 - 40--.q- - ~0 0-~ - --. - a S * 0-~ - 0 C - -. C 0~ ~ U' o -. -~ 0~ - - - 0 ~.* ~ - - S Sc -C S 5 - - - Tigers take on Hernando Pirates prepare for battle with Trinity Catholic JON-MICHAEL SORACCHI jmsoracchi@hotmail.com Chronicle As Dunnellon travels to Brooksville tonight to face Hernando, air traffic control can stay home. Both teams pride themselves on powerful running games and running right at the defense on the other side of the ball. If the ball goes to the air with any frequency from either team, be surprised. :. , '"We're going to run the ball," said Tigers coach Frank Beasley, who has led Dunnellon to a 4-0 record and a No. 7 state ranking in Class 3A. The Tigers have racked up 602 rushing yards and 7 TDs on the ground in their last two games, outscoring Vanguard and Williston by a combined 56-6. Rodney Jones has six of those TDs, but the offensive line deserves some major cred- it Bevon James, Rusty Leone, Bobby Mbrgan, David Chancey, Josh Dodge and tight end Derrick Parrea have helped pave the way all season as Dunnellon has run roughshod over their first four opponents. "Defenses are coming out and doing different things," Beasley said. "They (the offen- sive line) are adjusting." Teams that try running right at Dunnellon should take notice: it won't be easy. Beasley noted that Crystal River, who the Tigers beat 41- 10 for their second win, has a similar "run the ball right at you" style that Hernando showcased on game film. "They are very physical on offense," Beasley said of the Leopards. "They've got a cou- ple of good backs. We'd really like to limit what they can do." So far this season, Dunnellon has been able to make the opposing team look one-dimensional. Aside from giving up 183 yards to Vanguard's J.J. Smith, no other player has come close to having a 100-yard rusher. Even in Vanguard's case, the Tigers' defense tightened when it needed to, forcing two turnovers in the red zone and not allowing a touchdown. Dunnellon's defensive line, led by Tommy Nichols, Bradley Burns and James, has come together and played well, helping open up lanes for the Tigers' line-backing duo of Andrew Barrett and Austin Grybko and allowing the defensive backfield of Coley Burns, James Davis, Jones and Marquis Browdy to play more aggressively The Leopards didn't gain many yards in last week's 21-7 loss against Zephyrhills, total- ing just 156, falling to 1-2 over- all. But the stat that really tells the story for Hernando: four turnovers against the Bulldogs, two of which were returned for touchdowns. But this game could be important for other reasons. The Tigers and Leopards (3A-6) are in opposing districts. That means that if both advance through their districts to the playoffs, there is the pos- sibility that they could face each other again. "I've never seen our kids more focused on a football game," Beasley said. Trinity Catholic at Crystal River Walking around the grounds of Crystal River High School Thursday afternoon, there was a noticeable buzz in the air. Students took turns filling a dunk tank with water and stood outside the football field, talking excitedly about the Pirates' homecoming festivities. The culmination of the week for Crystal River is the team's football contest against Trinity Catholic. Let's just say that the Pirates couldn't have picked a more daunt- ing team to help celebrate Homecoming. The Celtics come onto Earl Bramlett Field tonight sporting two important numbers: 1 and 0. The "1" stands for the team's ranking in the Class 2B poll while the "0" alludes to the amount of points Trinity Catholic has allowed in four games this season. Yet, in spite of this, Crystal River coach Craig Frederick put his team's goal bluntly. "We need a good showing against a good team," said Frederick, whose team sits at 1-3 overall. "I told them to step it up and take the challenge." For the Pirates to be competi- tive, they will have to hold onto the ball much better. Although they earned a 17-13 win over Nature Coast last Friday, Crystal River turned the ball over three times and had a punt blocked and returned for a touch- down. The Crystal River defense came up big, forcing five turnovers but will be hard-pressed to duplicate the same success against a big- ger, faster Trinity Catholic squad. "We really don't look at our opponents as much as we look at ourselves," said Celtics coach KerwinrBell.-"We-want to continue- to focus on getting better." Trinity Catholic runs a pro-style offense in which a different player could star on any night. . Running back Bradley Grant' has already rushed for over 3,000 yards in his career. : Quarterback John Brantley went 13-of-22 for 271 yards and three touchdowns in a 43-0 win over P.K. Yonge last week. Receiver Dion Lecorn snagged eight of those passes for 231 yards and two touchdowns. But Frederick insisted that fac- ing this unique obstacle will only help later on. "The competition is making us better," he said. "We're looking to stay healthy heading into next week's district game (against Hernando.)." The Most Up-To-Date News, Maps, & Information About Citrus County 0 U8 CU NTY u 0 8-74-09-23C- I I ..- . .- . dw -. o C a e o 0 - - 41 --.m OW 0 0 874-0923-FCRN City of Crystal River 123 Mah~l WassI Hitway 19121! Crpal ximR ~FW" 34428-3990 ffTetaptwao(35217054216 Fax (352) 795-6351 PUBLIC NOTICE NOTICE IS HEREBY GIVEN by the City Council of the City of Crystal River, Florida. that a PUBLIC HEARING will be held to consider, on final reading, the. following ' proposed Ordinance at 7:00 p.m., on Monday, September 26, 2005 in the Council. Chambers at City Hall, 123 NW Highway 19, Crystal River, Florida. The Ordinance, in- its entirety, may be inspected at the office of the City Clerk during regular working hours.; ORDINANCE NO. 05-012 AN ORDINANCE AMENDING SECTION 2 OF ORDINANCE NO. 05-0-11 INCORPORATING REMAINDER OF ROAD RIGHT-OF-WAY IDENTIFIED IN THE M P H, LLC PETITION FOR VOLUNTARY ANNEXTION INTO THE CORPORATE LIMITS OF THE CITY OF CRYSTAL RIVER, FLORIDA, PURSUANT TO SECTION 171.044, FLORIDA STATUTES: PROVIDING AN EFFECTIVE DATE. The area proposed to be annexed by this ordinance consists generally of unincorporated platted roadways South of Turkey Oak Drive and West of North Citrus Avenue. The, complete metes and bounds description of the properties proposed to be annexed may be obtained from the office of the City Clerk. ram $.P "'3 MA dmE1 NpJim mr'l - 4 - if ~W0"' -~-'- qp .rn I Ii.. ~ii2a. U E'dilibi"A 4a all mW F- Ls-" L~fL~L.J LLL~ ~j ir li ,A, 466'. I ~ 13E40 2. ~6 24000 ~-~ .. 4 H I M A a m m a r -~+--- --:- --+- "* ^ E E---- -rn-il :3f^t~ :;l ::;*^T - >^ A. <** '"+.2. EJ2>*'# .".42! .** Ar. Parcel Map # 161817,2002 Roll, Printed 04/ 0812003 Copyright 1997-2002 Sykes Enterprises, Inc. and Citrus County Property Appraiser w .1 I05 Florida Statutes) Any person requiring reasonable accommodation at this meeting because of a disability or physical impairment should contact the City of Crystal River, City Manager's Office,. 123 NW Highway 19, Crystal River, FL 34428, (352) 795-4216, at least two (2) days before the meeting. By: Darcy H. Chase City Clerk - -. qw ~. .~ ox 1'- ~ : #05-LN09t601 s K it WWMW ffm"=Aww=mm -I AM P-- ->.2. 200.; qlbO -- 6 Q - low o - q --------y,--- FAST FACT: 4 Ryan Briscoe had a con- # 1 cussion, two broken clavi- cles and a bruised lung after his Chicago crash. FRID 'Y SEPTEMBER 23, 2005 www chromncleonline.com Points STANDINGS= NEXTEL CUP 1. Tony Stewart, 5,230 2. Greg Biffle, 5,210 3. Ryan Newman, 5,190 (tie) Rusty Wallace, 5,190 .5. Matt Kenseth, 5,180 6. Jimmie Johnson, 5,177 7. Mark Martin, 5,176 8. Jeremy Mayfield, 5,135 9. Carl Edwards, 5,121 10tO. Kurt Busch, 5,088 11. Jamie McMurray, 3,099 12. Jeff Gordon, 3,098 13. Kevin Harvick, 3,076 .14. Elliott Sadler, 3,067 '15. Dale Earnhardt Jr., 2,999 :16. Joe Nemechek, 2,967 S(tie) Dale Jarrett, 2,967 '18. Brian Vickers, 2,936 .19. Jeff Burton, 2,834 '20. Kyle Busch, 2,830 BUSCH SERIES '11. Greg Biffle, 2,965 :12. Ashton Lewis, 2,941 ,13. J.J. Yeley, 2,906 '14. Johnny Sauter, 2,905 ,15. Stacy Compton, 2,684 !16. Randy LaJoie, 2,667 :17. Jon Wood, 2,588 '18. Justin Labonte, 2,563 ,19. Kevin Harvick, 2,493 .20. Stanton Barrett, 2,252 CRAFTSMAN TRUCKS ,1. Dennis Setzer, 2,756 '2. Ted Musgrave, 2,697 3. Ron Hornaday Jr., 2,553 '4. Jimmy Spencer, 2,523 '5. Mike Skinner, 2,472 ,6. Bobby Hamilton, 2,422 '7. Todd Bodine, 2,403 :8. David Reutimann, 2,366 9. Matt Crafton, 2,353 '10. David Starr, 2,342 11. Jack Sprague, 2,291 *12. Ricky Craven, 2,282 :13. Terry Cook, 2,266 '14. Johnny Benson, 2,245 :15. Todd Kluever, 2,205 ;16. Rick Crawford, 2,200 '17. Steve Park, 2,082 i18. Bill Lester, 2,042 19. Brendan Gaughan, 2,016 :20. Robert Pressley, 1,977 CITRUS COUNTY SPEEDWAY LATE MODELS 1' Herb Neumann 1538 2. Chris Hooker 1529 3: Mike Bell 1472 4: Gary Grubbs 1464 5i Jim Smith 1440 6, Danny Johnson .1375 7, Raymond Lovelady 1244 8: Rick Bates 1219 9: Perry Lovelady 1031 10. Dale Sanders 1003 SPORTSMAN 1. Rick Kase 1525 2: Johnny Sanders 1440 3; John Smith 1402 4. Mike Veltman 1399 5. Frank Buchanan 1325 6. Maloy Kelly 1150 7, Bob Masciarelli 1144 8. Stephen Anderson 1107 9! James Batson 1039 10.Kyle Maynard 910 MODIFIEDS 1; Billy Bechtelheimer 1581 2; Jimmy Wagner 1474 3 Kyle Bookmiller 1382 4 Robert Ray 1347 5. Tommy Schnader 1337 6. Curtis Neumann 1202 7T Butch Bassett 1195 8: Mitch Korzenski 1189 9: Mike Bell 1185 10. Stephen Harbuck 1144 SUPER STOCKS 1: Bobby Taylor 1166 2. Rusty Bremer 1038 3: Tom Posavic 1000 4' Rob Perry 986 5; James Batson 890 6; Scott Hendrickson 875 7, Rob Canfield 820 8! Dusty Bouchard 757 9: Ernie Reed 641 10. James Green 634 MINI STOCKS 1: Chris Hooker 2765 2: Mike Lawhorn 2685 3'. George Neumann 2604 4: Johnny Siner 2452, 5; Jay McKenzie 2406 6. Pete Cracolici 2166 7: Jason Reynolds 1667 8. Don Faunce 1604 9: Mike Curry 1475 10. Clint Foley 1288 HOBBY STOCKS 1: Bill Ryan3293 2. Curtis Flanagan 3283 3: John Zuidema 2923 41 James Batson 2734 5; George Webb 2654 6: Mike Wedlick 2581 7. Jay Witfoth 2570 8: Tony Trancucci 2522 9 Larry Triana 2466 10. Artie Hewitt 2441 FIGURE 8 1: Darryl Hage 1425 2: Rodney Davis 1371 3. Bob Hage 1365 4: Scott Gullett 1279 5: John Thomas 1124 6; Dwayne Fults 1106 7, Clifford Rousseau 8: Eddie Davis 947 9: Robert Aaron 928 10. Charlie Myer 841 THUNDER STOCKS 1. Steve Stineduf 3434 2: Louie Cole 3029 3. D.J. Macklin 2954 4, Victor Shahid 2919 5: Glen Colyer 2886 6: Mike Dubbs 2879 7, Wayne Heater 2780 8: Mike Loudy 2752 9: Gary Johnson 2648 10. Michael Bocija 2627 : 4-CYLINDER BOMBERS 1, Tim Herrington 3210 2: Kevin Stone 3103 3; Rusty Adams 2347 4, Jesse Mullis 2265 5! Donald Guy 1845 6 .James Pate 1195 7; Roger Blevins 1165 8; Will Curry 1078 9, John Crichton 964 10. Missy Wagner 952 I qljjj amat ICopyrighted Material Svnc dicate Content am- m Ava~ab~frL ~ommerciaI-News-Providr -hm m 40m" V 4& ENOWk~ 4 '0-91 i-4O lb -M t 0 -ftA-O A- -' 0MW a -nom -tmft9la__ am*__w -mum mwpo a-ma Iftl qumo-m Mavfied qwc~ ~~a~g ~*itj' t1ti mil 4 Omm- o___ -- %o muof Mm 4 od~ m--"&- - mo4bdm o-womsupmomoo-a.-0*0* 9 - 9 Mb a Am 0 10 4manow -gommmmamama an.0 AROUND THE TRACKS . .. . .... .. .. .. . NASCARNEXTEL CUP MBNA 400 Site: Dover, Del. Schedule: Friday, qualifying (Speed Channel, 3:10 p.m.); Sunday, race (TNT, 12:30 p.m.). Track: Dover Downs International Speedway (oval, 1 mile, 24 degrees banking in turns). Race distance: 400 miles, 400 laps. Last race: The Chase for the championship began with Ryan Newman winning the Sylvania 300 at New Hampshire International Speedway. Newman passed a dominant Tony Stewart with two laps remaining for his first win of the season. Last year: Ryan Newman easily won the MBNA America 400 at Dover International Speedway, while Jeff Gordon took the points lead with his third-place finish. Fast facts: Kasey Kahne and Robby Gordon were fined but not suspended by NASCAR on Monday for road-rage incidents during last week's race at Loudon. Gordon was fined a total of $35,000 and docked 50 points in the driver standings for intentionally trying to hit Michael Waltrip's car, throwing his helmet at Waltrip's car and cursing during a television interview. Kahne was fined $25,000 and docked 25 points in the driver standings for intentionally hitting Kyle Busch's car as retaliation for an earlier accident.... Defending champion Kurt Busch was involved in a sec- ond-lap crash at Loudon, relegating him to a 35th-place finish and last place in the Chase. ... Stewart has finished eighth or better in each of his last 13 races. Next race: UAW-Ford 500, Oct. 2, Talladega, Ala. On the Net: http:/A/ww.nascar.com NASCAR BUSCH Dover 200 Site: Dover, Del. Schedule: Friday, qualifying (Speed Channel, 1:35 p.m.); Saturday, race (TNT, 1 p.m.). Track: Dover Downs International Speedway (oval. 1 mile, 24 degrees banking n lumi-) Race distance: 200 miles, 200 laps. Last race: Kevin Harvick pulled away from Paul Menard in a two-lap dash to the finish for his third victory of the season on Sept. 9. The points race tightened after leader and defend- ing series champion Martin Truex Jr. crashed spectacularly with about 50 laps to go and wound up 27th. Last year: Truex took the lead with 12 laps to go and drove to an easy victory in the Stacker 200 at Dover International Speedway. Fast facts: Truex's lead over Clint Bowyer in the standings has shrunk from a season- high 204 points to 69 over the last four races. ... David Green is expected to make his 350th career Busch start this weekend. ... Ryan Newman will be trying to become just the sec- ond Busch driver to win in four straight starts. Newman did not compete in the previous two events at Fontana, Calif. and Richmond. Sam Ard first did it in 1983. Next race: United Way 300, Oct. 8, Kansas City, Kan. On the Net http// NASCAR CRAFTSMAN TRUCKS Las Vegas 350 Schedule: Saturday, qualifying, 6 p.m., race (Speed Channel, 9 p.m.). Track: Las Vegas Motor Speedway (tri-oval 1.5 miles, 12 degrees banking in turns). Race distance: 219 miles, 146 laps. Last race: Rick Crawford fought off series points leaders Dennis Setzer and Ted Musgrave to win the Sylvania 200 at New Hampshire International Speedway. The win was the fourth for Crawford and his first since April 2004 at Martinsville. Last year Shane Hmiel nipped veteran Todd Bodine heading into the final lap to win the Las Vegas 350. It was Hmiel's first career truck victory. Fast facts: Setzer's lead over Musgrave in the standings increased to 59 points with his second-place finish at New Hampshire.... The polesitter has won two of the last three truck races at Las Vegas.... The 1998 event decid- ed the closest championship finish in series history, with Ron Homaday Jr claiming the title ovrJc pau D ne ''r over Jack -Sprague by inree p-ntiri- Next race: Kroger 200, Oct. 22, Martinsville, Va. On the Net: CHAMP CAR WORLD SERIES Champ Car 400 Site: Las Vegas Schedule:, Friday, qualifying, 7:30 p.m.; Saturday, race, 11:30 p.m. (Sunday, Speed Channel, 3:30 p.m., tape). Track: Las Vegas Motor Speedway (tri-oval 1.5 miles, 12 degrees banking in turns). Race distance: 249 miles, 166 laps. Last race: Oriol Servia was handed his first Champ Car victory when series officials ordered rookie limo Glock to let him pass on the final lap of the Montreal Molson Indy race on Aug. 28. Servia, filling in for the injured Bruno Junqueira, beat Glock to the finish line by exactly 1 second about 10 car lengths - to earn his first win in 95 Champ Car races. Last year Sebastien Bourdais held off Newman-Haas teammate Bruno Junquiera in a side-by-side battle to win the Las Vegas 400 for his sixth victory of 2004. Bourdais won by 0.066 seconds. Fast facts: Servia moved past Paul Tracy into second place in the season standings, trailing teammate Bourdais by 61 points with four races remaining. Tracy, who finished eighth at Montreal, is another four points back. Servia has finished in the top three in six straight races and seven of eight since replac- ing the injured Junqueira. ... Bourdais sur- passed 1,000 career laps led at Montreal. ... This is the seventh and final American race of the season. Next race: Grand Prix of Ansan, Oct. 16, Seoul, South Korea. On the Net FORMULA ONE Brazilian Grand Prix Site: Sao Paulo. Schedule: Saturday, qualifying (Speed Channel, Noon); Sunday, race (Speed Channel, 12:30 p.m.). Track: Interlagos, Jose Carlos Pace (road course 2.671 miles). Race distance: 189 F-1 n1 mie 71 lap. Last race: Kimi Raikkonen prevented Femando Alonso from clinching his first career F1 title by winning the Belgian Grand Prix on Sept. 11. Alonso, a 24-year-old Spaniard trying to become the series' youngest world champi- on, finished second and Jenson Button was third. Last year: Juan Pablo Montoya won in his final race for Williams-BMW, beating future McLaren teammate Kimi Raikkonen in the Brazilian Grand Prix. Fast facts: Alonso needs to finish in the top three of any of the three remaining races to clinch the title. ... Michael Schumacher fin- ished in the top three in 10 of the last 13 Brazilian races, and won four.... Rubens Barrichello finished third in last year's race, his best performance in 12 attempts at Interlagos. Next race: Japanese Grand Prix, Oct. 9, Suzuka. On the Net: INDY RACING LEAGUE Watkins Glen Indy Grand Prix Site: Watkins Glen, N.Y. Schedule: Saturday, qualifying, 1 p.m.; Sunday, race (ABC, 3:30 p.m.). Track: Watkins Glen Intemational (perma- nent road course, 3.4 miles, 11 turns). Race distance: 204 miles, 60 laps. Last race: Dan Wheldon set an IRL record with his sixth victory of the season and all but clinched the series title by taking the PEAK Antifreeze Indy 300 at Chicagoland Speedway. Wheldon only needs to start at Watkins Glen to officially win the champi- onship. Last year Inaugural race. Fast facts: Ryan Briscoe had a concussion, two broken clavicles, a bruised lung and bruis- es to his arms and legs after a fiery crash at Chicagoland Speedway ... Danica Patrick fin- ished sixth at Joliet, her seventh top-10 finish of the season ... Honda-powered cars have won 25 of the last 31 races. Next race: Toyota Indy 400, Oct. 16, Fontana, Calif. On the Net httn:// ...................................... F m . . . . . . . . . . . . . . . . ............... 1 1-:- . K. *a N--as%,,af'lnsicler BR- FRD-. SETME 3 05S.sCmsCun (F)CROIL IRL the Aklo poimd to clinch Fl title Copyrighted Material S Sydicatedciontent Available from Commercial News Provi maum * a nIIIIIIIh Smhp ders: --mo emi=as.. e. o ah-:-- L f ,l wwm ,.M I= -M4m a m elmi meab as W O. -w n.j ar o, I a a * 0- Sm .*Sr. S .-. a 5 ' jFREE with Servic I $39.95 o I Must present Louupcn when ord. L. Chftvruler.lCr ..'yler Dodg' 8 j WE WLHsons Anr OMEwR SERVwCE COUPON 'WASH FR27E iE RENTAlSUPER SAVER COUPON ANDVAC EINSPECI1ONI rlUE CAR ,I '*.." ows... ... You Spend This: You-SaveThis: e Work of I Factory Trained Technicians will perform a 27 Point Vehiclel O $50.00 $99.00 Save $5.00 : Inspection at no charge to you.TheseTechnicians will conduct One Day REE rental car* with any Save )r more. ananalysis using the latest electronic equipment and service or repair of $299.99 or more $200.00 $299.00 Save $20.00 t rs e. provide you with written report of your vehicle's condition- service or repair of $299.99 or more- $00.00 $99.00Save$0 eep 1riE, nlEd at xpre C]Crvi This service is absolutely FREE. and there is no obligation tog BY APPOINTMENT ONLY I $300.00 $399.00 Save $30.00 buep ocon sEp 3005 u y any suggested service. Ut28 50 per aPlus Pa e caalac o rerv ur rental car $400.00 or More Save $40.00 Must present r coupon evten order a .r ien Va,d t all Crystal Cherole. Mut preset coupon on Order ,s Ten. Valid at all Crya l CChevrolet C *ryler. |u1 EaL.iudf s models C'PnoteW e Cr n le |ip .lart r cA d Chrysier Dodge& Jeep locauons Exires 9p T 5 DodeL jeeI eonmi. i 30 t 3 Va lIal Craa ru Chwroi t h rein Dop e iese ,Are All Services Performed With Today's Manufacturers Recommended Cleaners. Fluids & Conditioners SGlRYSLEHR*ODGE*JEEPe (T CHRYSLER*DODGE*JEEP --4 2077 Hwy. 44 West Inverness 0FIVE STAR 05 S. Suncocuast Blvd. Homosssa A 352s) 726-1238 E-w **** 352a 1563-2277 1 i q Onus CouNTY (FL) CHRoNicLE 6B FIUDAY, SFvrEmBER 23, 2005 I I SPORTS ri mi" *x" *ritti' ==_. =u= XK .XI. * *Wc *W 1!1 :it .. LM FRIDAY SEPTEMBER 23, 2005 com Local stage to get d.U WALTER CARLSON/Chronicle Art League members rehearse the play "Last of the Red Hot Lovers" by Neil Simon Tuesday evening. Hannah Lowther takes the stage as Elaine Navazio and Richard David Easter is Barney Cashman. Tickets are on sale for $15 for the production, which begins Sept. 30 and runs through Oct. 16. Neil Simon'sfamous romantic comedy opens at Art Center Theatre this month CHERI HARRIS charris@chronicleonline.com Chronicle middle-aged man still married to his high school sweetheart decides to sample some forbidden fruit in "Last of the Red Hot Lovers." The Neil Simon comedy opens Sept 30 at the Art Center Theatre and will continue on stage week- ends through Oct 16. Jacquelyn de Torres is direct- ing the show. Barney Cashman is worried that the sexual revo- lution of the "sexy '60s" passed him by. When his mother starts volunteering for two hours a week at Arts & CRAFTS Art Group resumes painting classes The Beverly Hills Art Group has resumed painting classes from 9:30 a.m. to 12:30 p.m. Thursday in the Community Building on Civic Circle. Classes are open to every- one. Beginners and would-be artists are welcome. Watercolor classes are taught by George Sobota, and oil painting by Ellen Reinhart. This is a friendly group, and members help each other. The group's monthly member- ship meeting will be at 1 p.m. Monday at the Central Ridge Library. One important topic for dis- cussion will be the group's finances. The group's teachers are volunteers; however, for the weekly painting classes, the group has to pay rent to the community hall and required insurance. For information, call Alice at 746- 5731. Sewing group to meet Wednesday The Sewphisticates, the Pine Ridge Neighborhood Group of the Ocala Chapter of the American Sewing Guild, will host its next meeting at 10:30 a.m. Wednesday in the Pine Ridge Community Center. Members and guests may bring their sewing machines, basic sewing supplies and fabric to work on various projects including chil- dren's clothing, pillowcases and "cool-ties'" for our troops overseas. For information, call Dee at 527- 8229. KidzArt classes slated to begin Oct. 1 Citrus County Parks and Recreation, along with Jennifer Barber, will offer KidzArt Classes at Lecanto Community Building Please see ARTS/Page 7C Aspiring male actors invited to audition Special to the Chronicle Gulf Islands Civic Theatre invites all aspiring male actors between the ages of 30 to 65 to auditions on Tuesday, Wednesday and Thursday. Six men are required for Neil Simon's classic comedy, "The Odd Couple." Audition time is 7 p.m. at Gulf Islands' new location in Three Rivers Commerce Park, State Road 44 between Crystal River and Lecanto. The rehearsal hall is at the west end of the Citrus Gymnastics building, two units behind the Cash Carpet build- ing. Show dates are Nov. 11, 12, 13, 18, 19 and 20 at the West Citrus Community Center. For additional information, call director Jane Smith at 795- 8009 or 527-9061. the local hospital, however, he sees her home as the perfect spot for his adventures in seduction. The 47-year-old seafood restaurant owner trysts with a pot-smoking hippie who wants to be an actress, a depressed housewife out to get even with her cheating husband and a woman who is only looking for a romp between the sheets. De Torres said the show covers adult themes, so it is not appropriate for children. In this production, Richard David Easter is Barney Cashman, Hannah Lowther is Elaine Navazio, Brannon Degras is Bobbie Michele, Pam Schreck is Jeannette Fisher and Wiz Wilson is the announcer. Production staff members include: Jane Vicari, stage manager; Dave Marden, assistant stage man- ager; Sharon Harris, set design; Bob Vicari and Glen Wasche, set construction; Jane Vicari and Merry Williams, set dressing; Ann Christ, Jeanne Quinn and Bonnie Peterson, scenic artists; Howard Christ III and Bob Vicari, light design; Glen Wasche, light effects; David Easter, costumes and sound effects; Jane Vicari, props; Lillian Matos, David Marden and Paul Sullivan, backstage staff; Lee Proctor, house manager; and Irene Rendall, box office. Show times are 7:30 p.m. for Friday and Saturday shows and 2 p.m. for Sunday performances. Tickets are $15 each. The theater is at 2644 N. Annapolis Blvd., Hernando. For more information, call 746-7606. Get ready for holidays at annual art, craft show Pilot Club to offer lots of crafts, gifts, fooda fan CHERi HARRIS charris@chronicleonline.com Chronicle Sure, it still feels like summer, but Christmas is only about three months away . That's just three months to deck the halls, put up the tree, hang the stockings and buy all WHAT: 10th those presents. annual The 10th annual Christmas in Christmas in September September Art Art and Craft Show on and Craft Saturday will offer a vari- Show. ety of ideas for holiday WHEN: 9 a.m. gifts and decorating. to 4 p.m. Craft show hours are 9 Saturday a.m. to 4 p.m. at the *WHERE: National Guard Armory, Nat WHEREiona 8551 W Venable St., Guard Armory, Crystal River Admission 8551 W. is $1 per person. Venable St The Pilot Club of Crystal River. Crystal River hosts the event B.J. Lesbirel, club W COST: $1 president, said about 80 donation. vendors will have items GET INFO: for sale at the show. B.J. Lesbirel, Handmade merchan- 795-3616 or dise for sale will include Kathy Grazio, candles, soaps, children's 527-8679. toys, clothing for dogs, quilted wall hangings and jewelry, as well as season- al decorations. Sweet Georgia Browns will have breakfast snacks such as coffee and muffins for sale in the morning. Oysters Restaurant will sell lunch Special to the Chronicle Dottie Robinson will be one of many crafters on hand Saturday at the 10th annual Christmas in September Art and Craft Show at the National Guard Armory. treats such as hamburgers and hot dogs. The Sundowners will perform live country- western tunes and the Nature Coast Knights will have about 10 classic cars on display "Since it's our 10th year," Lesbirel said, "we Please see SHOW/Page 8C Out & AsGur BayFest Nature Festival coming up Kings Bay Waterfronts Florida Partnership will sponsor the BayFest Nature Festival on Oct. 1 and 2. Kings Bay Park, at the end of N.W. Third Street, Crystal River, comes alive on Saturday, Oct. 1, with the dedication of the infor- mation kiosk and the Blessing of the Manatee at the BayFest Nature Festival. BayFest Nature Festival has activities for the whole family and it's free. At 11 a.m. there will be the dedication of the informa- tion kiosk and the Kings Bay Park as the beginning of the development of the beautiful park and home site. The park was acquired through a grant from the State of Florida Communities Trust at the value of $1 million. At noon there will be the Blessing of the Manatees by the Rev. Harbin of the Church of Today on the Third Street Pier. From 11 a.m. to 3:30 p.m., environmental displays will be in the park from the different organizations such as Audubon, Crystal River Preserve State Park, Crystal River Archeological State Park, Friends of Chassahowitzka National Wildlife Refuge Complex, Florida Yards and Neighborhoods, Homosassa Springs Wildlife State Park, Southwest Florida Water Management District and Environmental Academy. There will be eco-explore activities that the whole family can participate in with photographs without a camera, scavenger hunt, cast- ing and other events. Visit the home site where the Yeoman Environmental and Cultural Education and Research Center will be. Storytelling by author Fran Thomas will be at 1 p.m. and S p.m. at the center. Come learn about her friends, Joda, Gub and Zeebee in the Wiggly World. The Navy Band Southeast Brass Quintet will play an old- fashioned concert in the park at 4 p.m. Bring a chair or blanket and enjoy the sounds of the Armed Forces Medley, jazz standards and other favorites. On Sunday, Oct. 2, the com- petition heats up at Hunter Springs, Crystal River, with the environmental fundraiser, Paddle the Bay Kayak Poker Run, check out the Web site for all the race information. The Kiwanis and the Waterfronts Florida Partnership Board have teamed up to raise scholarship funds for environmental educa- tion. Paddle for prizes so get yourself or a team registered by visiting the Web site. Come ride the 'Rails to Trails' The 11th annual Rails to Trails of the Withlacoochee Bike Ride will be Sunday, Oct. 2. This ride spotlights the Withla- coochee State Trail, which runs from Citrus County on the north to Pasco County on the south. The asphalt trail 46 miles - has been converted from rail- road track on even or slightly hilly terrain. Participants can ride from one mile to 100 miles on this day and there is no mass start. Registration/packet pick-up is from 7 to 9 a.m. at the main trailhead at North Apopka Avenue in Inverness. Six SAG stops are provided along the Trail. A continental breakfast and a lite lunch will be served at the main trailhead. Registration is $20. Applications are available at area Chamber of Commerce offices and libraries. To down- load an application for the ride, just go to- line.com. Also, you can e-mail harnage@atlantic.net or call (352) 527-3263 for more infor- mation. Dunnellon gets jazzy in October Come stroll our tree-lined main street while sipping some wine or beer available from the Dunnellon Chamber of Commerce beverage booths, Please see OUT/Page 8C , . ,.'-.. ., ,, ' --" -. -- '- - isillj 21 e" c S ne CITRUS CouNTY (FL) CHRONICLE 2C FRIDAY, SEPTEMBER 23, 2005 k"/ What started out in 1997 as an Internet Coffeehouse, The Gypsy's Den has since grown into a full blown Classic Rock and Roll t Nightclub. In 2000 we became a full Liquor Bar and changed our name from The Cybersurf Cafe' to The Gypsy's Den. We started in April of 2003 the remodeling phase of the Den. We finished up phase 1 in July, bringing a lot of new space and a whole new look. We hope you like it!!! We have for your enjoyment a Billiards Room with 2 tables, Game "Your Host" Mark & Jane room with football, pinball, and some of your favorite arcade games, Tabletop games, and TV's throughout so you can watch your favorite sport or your favorite show. You can try your hand at our Texas Hold'em Poker table on Friday and Saturday nights. We still have a couple of computers too so you can check your e-mail or just surf the web. Jane (your hostess at "the Den") and the girls behind the bar will always make you feel right at home, and make some of the best drinks around. On Friday & Saturday you'll find another local classic rock and blues band for your enjoyment. On Thursday, come sing with Cindy from P.O.E.T.S. Karaoke. Sunday & Monday, we are closed. Our list is a good blend of classic rock, ranging from Aerosmith to Zeppelin, Pink Floyd to The Doobies, and much more. With over 5600 watts of stereo sound, and a light show ranging from lasers to FST moving heads, and a decor that sports finished wood, tie-dye, vintage concert o, r posters, a lava-lamp or two, and much more, we hope that you'll find a nice S comfortable place to "hang out", and see, hear, and feel a little bit of yesterday. Hope to see you here! - Mark and Jane 623999 I - ---------- 10% oFF I TOTAL BILL IN A. -I b: 1.... .51-- ," '- _E F Under 3 FREE j1 USHwy. 19 EKFC Bank of Chin a Fir.tBoff SothT t 1XEAmerica SAVA Baf j / j"Chocolate Shoppe" Denny Lynn's Fudge Factory Cooters Are Here..... Made Fresh Daily! Small Medium Large Monday-Friday 10-6; Saturday 10-5; Closed Sunday 2746 N. Florida Ave. 22M2 O- " Hernando, FL 34442 J5243"0 4 438 , SM,**- You're Inv ited to a . - Dining Experience I, I. oy ' """" """"" fu if "Fig i, ,; ; u t 4f,,; Ssamplinpg of our Fine Dining Focaccia de Genoa Poiulet a la IVenetienne 44 Salade Mi xed Grill Bourguignonne Tilapia Ananas Bisque de Homard Pasta Romana Chateaubriand au ,, Bearnaise ).'e . ..h-.. .. ..... li( in,fnA \p -,, *Dci.'tt r Ela De\ *. .-. J nt 'S 4/ir .i 6ame if 6 JC r lftiLaiAd September Special Happy Hour 5 to 7pm Full Liquor Bar September Special S appfor I Cocktails C rVan derValk 637-1140 Fine Dining a istro o f ri I-., ,Alln I I. l l w /t,' l l i h'.l I a i lln d ,// ( .I C n I I A Salute i uto Elvis An Intimate Performance of America's Most Beloved Music ... The Music of Elvis ': Curtis Peterson Auditorium " Lecanto, Florida. 8:00 pm 'A 2" Presented by Rick Stines Productions, Inc. For Information & Group Sales 352.489.9380 '*,*. ,-. i The late J.D. Sumner of the legendary "Stamps Quarter' who sang back up and recorded with Evis said, Eddie Miles is r. GROUP DISCOUNTS AVAILABLE. (~K~~IJ: China First i Buffet L November 4th 8 5th For Local Sales and Group Sales 352.489-9380 *Your Check is Welcome B I .1. i Fi-com Memphis to I-ecaitto .... With Respect I r- H - Cimus COUNTY (FL) CHRONICLE SCENE FRIDAY, SEPTEMBER 23, 2005 3C SA D t On Hwy. 491 in the Beverly Hills Plaza SUN. 12 NOON. 9 P.M. MON. THURS. 11 A.M. 9 P.M. STA RANT FR. & SAT. 11A.M. TO 10 P.M. NOON 4 6 PM Wed.-Fri. All U Can Eat T s Fish & Chips $695J e a Steak Night Ad*ult09 $1995^__ ___ _^^^^^^ I-5Lt LjLxCL I I ~I I M.i, A R I V E RSI Irww I ^ ~~jt Ap I Iiir ^E^^^^33lBB3llW'Bl>lBBlnlus]B^L MNQNAY Shrimp Parmiglana Stuffed Shells with side of pasta plus dinner salad & bread.......$.. 9. soup or fresh garden s TUESDAY All-You-Can Eat Spaght ii '1 .'i Veal PaPR liai WED./THURSDAY with side of pasta, cho Large Cheese Pizza Large Antipaste Hot farc RIl ls s 5.5 cheese orMea (sreas.34). $1. .9 withmeatball; choice THURSDAY Baked Lasagna Parmiglana Medium hees plus garden salad & bread .. .t7.49 Me um Chefse I Prime Rib Evrg T rs .......... 0.95 thtoppingPLUS Lg. Cheese Pizza. Large Antllpast. 2 People $10.49wit Hot garlic rolls (serves 3) .....$................... $15.95 FBI1AY Chicken Cutlet 2 pounds of Steamed CGrb Legs withsideofpasta&ve with choice of pasta plus garden salad ......................... $15t95 I pound for............................................................. $ 10.95 oBaked Ziti with Fried Catfish wth French Fries or baked potato, salad phi. V., ,:,' : :',I- and bread............................................................ 9 .9 5 SATURDAY Chicken srdse Chicken Cacclatore withchoiceofpastaplusgardensalad& withsideofpast bread ................................. g y ...................... $ 9 .9 5 . Baked Stuffed Flounder with choice of pasta plus garden salad & bread................ $8.95 Eggplant Parm Homestyle Italian Meat Loaf with side of pasta & ve with pasta plus garden salad & bread........................ ......$8.49 All Early Bird Specfias include Super Salad, Bread, or Manicotti salad ......... ......... .................. ... 7 9 i a ice of soup or fresh garden salad.. $7-49 t MOwlV l, soup or fresh garden salad ............... $7.49 lh 2 soups or 2 fresh garden salads getable, choice of salad or soup $7,49 h Meatball n Bleu g. choice of soup or fresh garden salad or [II e .'irt i i, ')ij ':" ;,|) ,:|,f;cr i. i ,. S '.- ' iglana getable, choice of salad orsoup $7.49 everyday LUNCH SPECIALS S S A ~COMEDY NIGHT -- Segatembelr 23rel - FEATwURING TIM JONES THURSDAY .ngS AeT FRIDAY Music Fe ng nce The Night ee Buffet 4-7p4 -oo mu In The Aays Inn On Hwy. 19 Crystal River, FL u seoiIn The Days Inn On Hwy. 19 Crystal River, Fl. [jie Entertainen M 0 S AN CAM A BSTAND FrdaSatuda FeaturnlascOldies 50s 0 s7' NIGHT SHIFT com.mntyakOt acdragedLUoqrW M 2 A.A. Fri. 9123 9 pm 1 am &Takeouat Food Noon to 9 P.. Sat. 9/24 9 pm 1 am wlShouroaivegrlwndow SETH PARKER Tues. 9/27 8 pm 11 pm SAMMY J 7 Wed. 9/28 8 pm 12 am LONNIE & LILY Thurs. 9/29 8 PM-12 am 563-5255 MON-SAT 12-2 AM -SUN. 1 PM-2 AM Fax 563-5275 2581 US 19 N -1/2 MI N Of Mall -Crystal River * Minue10 LunchQ^ Cmus CouNTY (H) CHRoNicLE SCENE FRiDAY, SEFFFMBER 23, 2005 3C CITRUS COUNTY (FL) CHRONICLE Closing Vacation Sept.26 564-1116 1239 S. Suncoast Blvd. Reopen Oct. 3rd NouWiiiuni inrS q ett to Eki lc Buaa e AJ r----w* r ITALIAN RESTALRALY HwY. 41 & 44 W INVERNESS -- --1 I I Buy 1 Get 1 $6.50 Value Expires Sept. 30, 2001 63 71 5 Im OPEN 7 DAYS. BfST 7-13 5~l LO UNCH & DINNER OT/ P.S. "YOU'LL NEVER LEAVE HUNGRY" PLANTATION INN Crystal River, Florida 9301 W. Ft. Island Trail, Crystal River For information please call 352-795-4211 Sand Hill Saloon Coldest Beer In Lecanto Pool .Nascar 3782 West Gulf to Lake Hwy. Rte. 44 (352) 527-6759 S APPLIANCES*PARTS DISHES GLASSWARE FLATWARE Schools Restaurants Bars Day Cares Churches Nursing Homes Clubs Are You Looking For A local Supplier? ^ CALL US! 621-3712 .__-- SHAFFER WHOLESALE S. DISTRIBUTORS, INC. S":... ;'- 54 15 W. Homrnosassa Tr. Lecanto '- Located Across From Anson Nursery M1ondoay Fr.d 3 r -J C n iInusI & Things Sports Pub Inverness Regional Shopping Center Near Kmart, Inverness For Take Out Orders Call (352) 726-5665 tz-rr- N L 20 TV Sets, 2 Big Screens - Enjoy a night out on the town December' Same Great Food as You Remembered Famous for Seafood & Steaks WEDNESDAY NIGHT WEEKEND FEATURES CREATE YOUR SESAME SEED CRUSTED OWN PASTA SALMON WIRED PEPPER COULIS * Introducing Chef Thomas McCarthy * Now Serving Steak Certified Angus Beef Night $ .*95 We Are Worth Every Thursday The Drive! (352) 447-3451 Private Parties Available US Hwy. 19, Inglis Open 6 Days A Week Closed Mon. Sunday 12 6 PM Breakfast: 8 AM-11 AM Sunday 1 Lunch: 11 AM 4 PM Complete $895 Dinner: 4 PM- 9 PM Dinner 0 HOURS: Includes Dessert Sunday Close @ 6 PM Tuc J3d% Cloc s 2 PMI "s %% .inglisdining.com F 2 WK i, Formerly American Italian Club 4th Annual Fund Raiser 832 K.9 Deputy Dogs Sat, Sept 24, 6-i1Opm Tickets On Sale Now Open until 3pm for members N*Wf|i Fri & Sat-7:00pm $20 Buy in (sign up Wed) (F E Snack Bar Open 11am-10Opm FREE Dinner Fri-Sun 6:00pm with Match Play open7 Dys Free O F &WnirclP to bership 64026 A Fun & Winning Place to Be 341771 o29 Guf o*LkeHwy-Lcano Hwy44 7715 GULF-TO-LAKE HWY 1-1/4 MILES E. OF 19 ON RT. 44, CRYSTAL RIVER Are You Hungry Yet? Steas & PIZ Rd Pasta Seafood Starting Oct. 1st Reopening 7 days a week Lunch Monday-Sunday 11-3 Dinner Sun-Thurs 5-9 pm S, :Pinner Fri &Sat,51 Opm Beginning Oct. 7th Horse & Carriage Rides U.S. 19 North To Citrus Avenue Turn West on Citrus (toward the River), Left on N.E. 5th 352-795-4046 114 N.E. 5th Street-* Crystal River, FL 34429 9DZL^' 7L7L7h7@ /?Z7L WQV NEW wKI I3E~I~WL Ii I Small, Medium or Large ( I Limit one coupon per order. Expires 10/31/05 T 4 ALLAN ICES / (: ) 206 NE HWY. 19 .Il1 CRYSTAL RIVER (Next to Jones Restaurant) 220-9006 I S7Fri &Sat12 pm -l10pm . U 795-4546 -T rscia-. ! -g B s- l h 4t; FRIDAY, SEPTFMBER 2:5, ZVO!> suli Sid musi6,-..8 ,3:00 72-00, F. n * I R X, itig CabiftRenWs..l Assa, h 0.-.vm.nwp 22, 2.00 P r - - - - " AV FU FITTUS COUNTY TNTCHRONICLE IDAY.A SEPMEMBFRl 23v 2005I5C .rmr.Nr nu. IrFr T (F'T) 2 rrnNflhrtC EF FRIDAY EVENING SEPTEMBER 23, 1WESH 1 9 News 491 NBC News Ent. Tonight Access Dateline NBC (N) 'PG' % Three Wishes "Sonora, Inconceivable "Pilot" (N) News Tonight 19 1919 Hollywood 2439 California" 'PG' 9 2675 '14' c9 5762 6563965 Show WEDU BBC World Business The NewsHour With Jim Washington Tampa Bay McLaughlin NOW (N) Art in the Twenty-First In the Balance PBS U 3 News 'G' Rpt. Lehrer 9 3197 WWeek eek Group 74946 Century (N) 'PG'9588 "BioAttack" (N) cc 48168 WUT BBC News Business The NewsHour With Jim Washington NOW (N) Antiques Roadshow Art in the Twenty-First Being Tavis Smiley PBS 8 5 5 5 9120 Rpt. Lehrer (N) 61410 Week 1 6168 "Memphis" 'G' 67694 Century (N) 'PG' 60781 Served 26472 WFLA 8 8 8 News 2830 NBC News Ent. Tonight Extra (N) Dateline NBC (N) 'PG' c9 Three Wishes "Sonora, Inconceivable "Pilot" (N) News Tonight NBC 8 8 8 8 'PG' O[ 70168 California" 'PG' 9 50304 '14' [9 53491 5486588 Show WFVNews ABC WId Jeopardyl Wheel of Supemanny "Minyon Supernanny "Webb 20/20 'PG' 74697 News Nightline ABC 20 20 20 20 2236 News 'G'G 4101 Fortune 'G' Family"'PG, L' 83656 Family" 9 96120 4659491 88712025 W rSP News 9138 CBS Wheel of Jeopardy! Ghost Whisperer "Pilot" Threshold "Blood of the NUMB3RS "Judgment News Late Show 0CBS Q1 10 10 10 Evening Fortune 'G' 'G' 9994 (N) 'PG' [ 14526 Children" (N) 'PG' 94762 Call" (N) '14' RE 74679 4657033 (WT) News 1[ 72101 A Current The Bernie The Bernie Mac Show Killer Instinct "Pilot" (N) News [ 42323 M*A*S*H The Bemie FOX 13 13 Affair'PG' Mac Show (N) 'PG, D,L' [ 29472 '14, L,V' 9 49236 'PG' 11965 Mac Show WCJB News 99236 ABC Wid Ent. Tonight Inside Supemanny "Minyon Supernanny "Webb 20/20 'PG' 9 33217 News Nightline A11 11 News Edition Family"'PG, L' [043694 Family" [ 23830 7674435 99381526 WCLF Richard and Lindsay In His Ted In Touch Extraordinary Good Life 9301168 Live From Liberty The 700 Club 'PG' E 2 2 2 2 2 oberts 'G' 2451014 Image 'G' Shuttleswort life. 'PG' B9 9381304 9304255 4135217 WFT 11 11 News 88168 ABC WId Inside The Insider Supernanny "MinMon Supemnanny "Webb 20/20 'PG' [ 39439 News Nightline 11 11 News Edition 68304 Family"'PG, L' Bc 16588 Family" B] 29052 3166472 78371897 (WMOli) Will & Grace Just Shoot Will & Grace Access Movie: "Species II" (1998) Michael Madsen, Fear Factor Driving with Access Cheaters IND 12 12 12 12 '14' Me'PG' 'PG' Hollywood Natasha Henstridge. 9 49830 teamwork. 'PG'68965 Hollywood 34694 WTTA Seinfeld Every- Every- Sex and the What I Like Twins (N) Reba (N) Living With News Yes, Dear Seinfeld Sex and the D 6 6 6 6 'PG' Raymond Raymond City'14, '14, D,L' 'PG' Fran 'PG' 3188304 'PG' 'PG' City '14, (WTOGI) The Malcolm in The Friends '14' WWE Friday Night SmackDownl (N) (In Stereo) 'PG, The King of The King of South Park South Park IND E 4 4 4 4 Simpsons the Middle Simpsons 9 9168 D,LV' 9 21830 Queens Queens '14' 19507 '14'26566 FWYKEM] ANN News Art TV County Style Show Florida U-Talk Inside Connect Janet Parshall's America! Circuit Court ANN News FAM 16 16 16 16 66174 92946 Court 81830 Angler 58014 Business Zone 75255 18656 WOGX Friends '14' Friends 'PG' King of the The The Bernie Mac Show Killer Instinct "Pilot" (N) News (In Stereo) c9 A Current Home 13 13 9 7304 ] 8656 Hill'PG, Simpsons (N) 'PG, D,L' cc 24192 '14, L,V' 98588 91675 Affair (N) Improvemen WACX 21 21 21 Variety 1588 The 700 Club 'PG' 9 Now Abiding Right Jump. This Is Your Mike Praise the Lord 9 36236 IND e 21 21 21 492255 Faith Connection Ministries Day 'G' Murdock [1 SE 15 15 15 15 Noticias 62 Noticiero Inocente dei 176507 Contra Viento y Marea La Esposa Virgen 165491 Gilberto Par de Ases Noticias 62 Noticiero UNI 1 15 15 15 815 g859 1niv5isiona18555 lss 437120 Univisi6n (WxP-x) Shop Til On the Pyramid'G' Family Feud America's Most Talented Movie: * "Mary Higgins Clark's All Around Superstars Paid PAX 17 You Drop Cover 'G' 96675 'PG' Kids 'G' 65830 the Twn"(2002) Kim Sc iraner'14' 75217 of Country Prooram 54 48 54 5 City Confidental'P American Justice "A Star Wars: Empire of Dreams 'PG' SB 517755 Biography "Marion American Justice ) 54 48 54 54 337120 Model Murder" 'PG' Brando" 'PG' 9 848502 "Stacey's Story" 'PG' AM 55 64 55 Movie: *** "Black Rain" (1989) Michael Movie: ***K "The Usual Suspects" (1995) Movies Movie: **'A "Alien Resurrection" 55 64 55 55 Douglas, Andy Garcia. BB 54786675 Stephen Baldwin, Gabriel Byrne. 442491 Shook (1997) c9 5483694 52i'35 52 52 The Crocodile Hunter The Most Extreme "Dads" Corwin's Quest 'The Animal Cops Houston Miami Animal Police 'PG' Corwin's Quest 'The U 52 35 52 52 'PG' g 2453472 'G' I9 9374014 Sardines Run"'G' "Survivors" 'PG' 9303526 c9 9373385 Sardines Run" 'G' V 77 Battle of the Network Battle of the Network Battle of the Network All-Star Reality Reunion The Most Outrageous All-Star Reality Reunion 77U 11 Reality Stars 'PG' 351236 Reality Stars 'PG' 909897 Reality Stars 'PG' 985217 'PG' c9 998781 Moments on Live TV '14' 'PG' c[ 680385 S 7 61 27 27 Mad TV (In Stereo) '14, David Com.- Daily Show Com.- Premium Com.- Com.- Coim.- Weekends David I(1 27 61 27 27 DL' [ 91526 Spade Presents Presents Blend 'PG' Presents Presents Presents at the D.L. Spade 98 45 98 98 100 Greatest Duets Dukes of Hazzard 'G' Inside the Real Coyote Wynonna: Her Story (N) Stacked Class of Dukes of Hazzard 'G' C) 98 45 8 concert 57694 74526 Ugly 50946 63410 37830 1985 (N) 56304 95 60 60 Life Is Great El News El News (N) The Soup Filthy Rich: Cattle Drive The Girls The Girls The Soup El News What Hollywood Taught VSpecial (N) 'PG' 185120 (N) 'PG, 'PG, L' 170323 Next Door Next Door 'PG, D,L' Special 'PG' Us About Sex n 96 65 96 96 Catholic Way of Daily Mass: Our Lady of The World Over 3613435 Worth Living The Holy Defending Carpenter Rome Good or E 96 65 96 9 Teach Cross the Angels 5613615 .Rosary Life 'G' Shop Reports Evil? f m 29 52 29 29 o 7th Heaven "Little White Smallville "Nocturne" 'PG, Movie: "The Sandlot 2" (2005) James Earl Jones, Whose Whose The 700 Club 'PG' c9 1 ) 29 52 29 29 Lies" 'G' 502472 V' B 150033 Cole Evan Weiss. cc 170897 Line? Line? 855101 30 60 30 30 King of the King of the That '70s That '70s That '70s That '70s That '70s That '70s Nip/Tuck 'MA, L,S,V' 7074859 That '70s (___ 0 3 Hill 'PGL' Hill'PG L' Show'PG, Show'PG, Show'PG, Show'14, Show'PG, Show'PG, Show 'PG; HTV 23 57 23 23 Weekend Landscaper Curb Appeal House Get Color Mission: Designed to Design House House Debbie Travis' Facelift (N) Warriors 'G' s 'G' Hunters 'G' 7082014 Orqnz Sell 'G' Remix Hunters Hunters (In Stereo) 2386491 51 25- 51 51 Sodom & Gomorrah 'PG' Oil 'G' 9 3918287 UFO Files "UFO Hot Decoding the Past'PG' Mail Call Mail Call Man Moment Machine J 51 25 51 51 4810694 Spots"'PG' 9 1918007 B9 1013651 'PG, L' 'PG, L' 'PG' 9 1829052 24 38 24 24 Golden Girls Golden Girls Movie: * "Deadly Web" (1996, Drama) Gigi Movie: "Identity Theft: The Michelle Brown Will & Grace Will & Grace IFJ 24 38 24 24 Rice, Andrew Lawrence. 'PG, LV' c 862491 Story" (2004) Kimberly Williams-Paisle 'PG, L' 'PG' 'PG' IK 28 36 28 28 All Grown Danny SpongeBob Catscratch Avatar-Last Danny Danny Phantom (In Full House Fresh Fresh The Cosby Up 'Y' Phantom 'Y' (N) 732491 Air Phantom Stereo) 'Y7, FV' It 'G' 600588 Prince Prince Show 'G' 31 59 31 31 Surface (In Stereo) 'PG' Firefly "Ariel" (In Stereo) Stargate Atlantis "Aurora/The Lost Boys" The Battlestar Galactica Stargate Atlantis In SCuIF[K 31 59 31 31 ] 5936507 'PG, L,V' c9 6734101 Wraith's technology weakness. 'PG, V' 9 6754965 "Pegasus" (N) 'PG' Stereo) 'PG, V S 7 43 37 37 World's Wildest Police CSI: Crime Scene CSI: Crime Scene Viva Baseball The influence of Latin baseball players CSI: Crime Scene ISEV 37 4 Videos 'PG' c 700588 Investigation'14, S,V Investigation '14, L,V' in the United States. (N) 474526 Investigation 'PG, D,L,V' ) 4923 49 49 Seinfeld Seinfeld Every- MLB Baseball Florida Marlins at Atlanta Braves. From Turner Field in Atlanta. Movie: ** "The 6th Day" (2000, S'PG' 262217 'PG, D' Raymond (Live) ] 721052 Science Fiction) 9 499781 Movie: * "Babes in Arms" 1939) Judy Movie: * "The World of Henry Orient" Movie: *** "Same Time, Next Year" (1978) 53 Garland, Mickey Rooney. cc (DVS 30357385 (1964, Comedy) Peter Sellers. 6117859 Ellen Burstyn, Alan Alda. c[ 73317168 53 34 53 53 Monster Garage 'PG' c[ American Chopper 'PG' MythBusters "Breaking Dirty Jobs "Pig Farmer" Going Tribal 'PG' ] MythBusters "Breaking 342052 9[ 793633 Glass" 'PG' X 793453 '14, L' c 393697 143174 Glass" 'PG' [9 604439 5046 50 50 Martha 'G' c9 795656 in a Fix 'PG, L' 9 457859 America's Ugliest What Not to Wear (N) What Not to Wear America's Ugliest TC 50 46 50 50 ____Bedroom (N) 'G' E 'PG' 9 446743 "Melanie A." 'PG' 449830 Bedroom 'G' 9 918435 483348 48 Charmed "Size Matters" Law & Order "Punk"'14, Movie: *** "The Wedding Singer" (1998, Movie: *** 'The Mask"(1994, Fantasy) Jim 4848 4 'PG LV' [9 726526 D,L' c[ (DVS) 448101 Comedy) Adam Sandier. c9 (DVS) 468965 Carrey, Cameron Diaz. B 742439 R V 9 9 Top Ten Spooky Places Grand Castles of America Universal Orlando's Most Haunted Welsh cas- Most Haunted "Jamaica Universal Orlando's 5AV) 9 54 9 9 'P' [] 2476120 'G'3052472 Horror Nights 'PG' tie. (N) 'PG, D' 3058656 Inn" 'PG' 3051743 Horror Nights 'PG' USA 47 A 32 47 47 Movie: ** "Major Law & Order: Special Law & Order: Criminal. Law & Order: Special Monk "Mr. Monk Goes to Law & Order: Special S 4ayne"(1995).251236 Victims Unit '14' 642439 Intent "Badge" '14' 1 Victims Unit '14'631323 the Office" 'PG' 634410 Victims Unit '14' 233965 S 18 18 18 18 Tenth Inning Home America's Funniest Home Movie: *A "Landspeed" (2002, Action) Billy Zane, WGN News at Nine (In Sex and the Becker 'PG, 1_____8 8__18]o Improvemen Videos 'PG, L' 996323 Pamela Gidley. (In Stereo) 983859 Stereo) 9 995694 City '14, D' 951385 FRIDAY EVENING SEPTEMBER 23, 2005 A: Adelphia,Citrus B: Bright House D: Adelphia,Dunnellon I: Adelphia, Inglis A B TD I 6:00 6:30 7:00 7:30 8:00 8:30 9:00 9:30 10:00 10:30 11:00 11:30 Sister, Phil of the Zack & That's So Movie: ** "The Country Bears" (2002, Comedy) Zack & Sister, That's So That's So 5il 46 40 46" 46 Sister 'G Future (N) Cody Raven 'G' Christopher Walken. S 981491 Cody Sister 'G' Raven 'Y7' Raven 'G' 68 M*'A*S*H M*A*S*H Walker, Texas Ranger Walker, Texas Ranger Movie: *** "Sarah, Plain and Tall" (1991) M*A*S*H M*A*S*H 68ii) 68 'PG' 'PG' 'PG, V' [3 9390052 ". Bounty" 'PG, V' 9376472 Glenn Close, Christopher Walken. cc 9386859 'PG'- 'PG' Movie: "Batman & Inside the NFL (In Stereo) Movie: ** "The Grudge" (2004, Corpse Rome "Stealing From Real Time (In Stereo I_____ Robin" cc 53117531 'G' 9 444859 Horror) BB 773033 Bride Saturn" 'MA' 1[ 436830 Live) 'MA' C] 395435 Movie: * "Runaway Jury" (2003) John Cusack. A man Movie: ** "Torque" (2004) Martin Movie: * "Dodgeball: A True "The Sex tries to manipulate an explosive trial. []c 66870743 Henderson. BB 313656 Underdog Story" 1943410 Spa" c M 7 66 97 7 The Real The Real The Real The Real The Real The Real The Real The Real MTV Unplugged Alicia The Reality The Reality IM 66 9 World'14' '14ld 14 World'14' World '14' World'14' World '14' World '14' World '14' Keys. (N) 157946 Show Show 71 Ultimate Jaws 4456236 Be the Creature King Cobra 'PG' 3498472 Snakebite! 'G' 3418236 Elephants: The Dark Side King Cobra 'PG' 1380588 71 "Galapagos" 'G' 3412052 'PG'3411323 6_2_ Movie *** "The Glass Shield" Movie: * "Out of the Darkness" Movie: "Medusa's Child" (1997) Christopher Noth. A doomsday device PLE "62 (1994) B9 1488304 (1985, Drama) 'PG' 40141694 is on a plane headed for Washington, D.C. 'PG, L,S,V' B9 12001120 NMC 43 42 43 43 Mad Money 4006526 Hurricane Katrina: Crisis Late Night With Conan Mad Money 7582205 The Big Idea With Donny The Apprentice (In and Recovery O'Brien '14' E 1982061 (Deutsch Stereo) 'PG' [ 8108743 CNN 40 29 40 40 Lou Dobbs Tonight c9 Anderson Cooper 360 9f Paula Zahn Now cc Larry King Live B9 NewsNight With Aaron Lou Dobbs Tonight 986410 617743 626491 646255 Brown cc 616014 248897 HollHollywood Hollywood Cops 'PG, L' Cops '14, D' The Investigators '14' Forensic Forensic Forensic Forensic Mystery in Smoking 25 55 25 25 Heat Justice 'PG' 6966255 5200453 9182089 Files 'PG' Files 'PG' Files 'PG' Files 'PG' Aruba Gun TV 39 50 39 39 House of Representatives (Live) 9167743 Tonight From Washington 373762 Capital News Today S ?364014 4 744 37 44 44 Special Report (Live) 9 The Fox Report With The O'Reilly Factor (Live). Hannity & Colmes (Live) On the Record With The O'Reilly Factor 5921675 Shepard Smith g9 9C 6745217 cK 6758781 Greta Van Susteren 9538762 MSN8C 42 41 42 42 The Abrams Report Hardball BB 6732743 Countdown With Keith Rita Cosby Live & Direct Scarborough Country The Situation With Tucker S4 42 5934149 Olbermann 6741491 6761255 6731014 Carlson )EsP 33 27 33 33 7SportsCenter (Live) cc MLB Baseball Teams to Be Announced. (Subject to Blackout) (Live) c9 542507 College Football California at New Mexico State. _3d 797588__1(Live) c 263588 ESPN 34 28 34 34 ESPN Quite Frankly With NFL College Football Iowa State at Army. (Live) BB 6016052 SportsCenter (Live) 9) Hollywood Stephen A. mith Matchup (N) 2388859 FFL 35 39 35 35 FSN Ship Shape Marlins on MLB Baseball.Florida Marlins at Atlanta Braves. From Turner Field in Atlanta. FSN Pro Football Preview Best-Sports Baseball TV'G' Deck (Live) (Live) 730236 790656 SN 36 31 Seminole SEC TV College Kickoff (Live) Women's College Soccer Alabama at Florida. (Live) College Kickoff 60385 FHSAA Sports Report Uprising 26304 61014 81878 85878. If you have cable service, pleas your cable .channel numbers are channel numbers in this guide. If no perform a simple one-time procedui The channel lineup for LB Cable customers is in F~ m.tt a .~ - *o -aMft f ea__ 0 _ 00 0 Owft0Available fr M p - m .,-b - - -.11ili-4b - -a sow ~, p :i: -- -~ 0" 0 a S - S - p - B' low I ar - S . - -W -- J a 1 as L-s1 -OT I v : del Mom .0 .t Gum f- M a.A mom % si la 4b-.l -w --.e 4100, -- 40---o .10 w -.0101 0- ,-am -~ as, to .p -m, -d ___ -400 0" qo& a-sa- Q 1b 4 qmm abedo*-mm __ -mmm - f WS -0W -0 w MO4MMED - --.d= __ --O 40000D -go. - - ---.- * ** . 0*0 0 0 0 0 0.00 *O S * 6 0* o SO - - V I I ~ I 0 0 F 0 0 - - T S .- . . - - a - Local RADIO = == *. * * * 0 *0 * S 0 cable channels with the guide channel numbers using B^ se make sure that the convenient chart printed in the Viewfinder. This - the same as the procedure is described in your VCR user's manual. ot, you will need to Should you have questions about your VCR Plus+ sys- * re to match up the tem, please contact your VCR manufacturer. the Sunday Viewfinder on page 70. up A *f in Copyrighted Material - W.. I wI Syndicated Content om Commercial News -- I I - 0 * U S **0 Ta.- * Providers - * - /~ :^ 0Pt woa- It'I - - B' FRiDAY, SEPTFMBFR 23, 2005 SC FM'EITIryA TTIM1RN-T . *-M.. .1 - - . w CITRUS COUNTY (FL) CHRONICLE ;C FRIDAY, SEPTEMBER 23, 2005-"IU -- - w * 0 le a 0 4 -aglo-4at 4 - a-o .. ain..041m S 'V -. - r.0. r 16'u o w- "- -- L &L - W a C Copyrighted -Material S_ Syndicated Content. SjAvailable from Commercial Newsl Providers I a ~ 0 *~ 4 & .a- m a U'..' 4'. m a * 11 ...-U~ - - 43 4- . ~ *9~ * -h b * 4 0~a -w - m . 00 V-- a^ - -U' a 0b .m, 4b a U At U 0 P% A 1 'K' Iva ( 9 Bs p ~2L3?4bb a,~ * U '9 PA 6k do#*a S* Vp Citrus Cinemas 6 Inverness Box Office 637-3377 "Lord of War" (R) 1 p.m., 4 p.m., 7 p.m., 9:45 p.m. "Just Like Heaven" (PG-13) 1:20 p.m., 4:20 p.m., 7:30 p.m., 10:05 p.m. "Exorcism of Emily Rose" (PG-13) 12:50 p.m., 3:50 p.m., 7:10 p.m., 9:50 p.m. "40-Year-Old Virgin" (R) 1:05 p.m., 4:05 p.m., 7:05 p.m., 9:40 p.m. "Flight Plan" (PG-13) 1:15 p.m., 4:15 p.m., 7:20 p.m., 9:55 p.m. "Corpse Bride" (PG) 12:45 p.m., 2:50 p.m., 5 p.m., 7:40 p.m., 10 p.m. Digital. Crystal River Mall. Times sublact to cha ot Iolatahoo, - ~- C * Your Birthday: In. Scorpio (Oct. 24-Nov. 22) Psychological forces within you may open the way for learning more about yourself and cause changes that will help you work o- with an unconscious drive to be more successful. Sagittarius (Nov. 23-Dec. 21) It is OK to ideal- ize the relationship you have with a loved one today, so long as it isn't way out of proportion to reality. Capricorn (Dec. 22-Jan. 19) The more you are attached to material things, the more likely you are to lose perspective on the value of other things. Aquarius (Jan. 20-Feb. 19) Spending quality time with good friends today may be your highest pri- ority, which is fine. However, if you set your sights too high, no one will be able to live up., stand up for your pal and stop it at the source. Taurus (April 20-May 20) -An issue could arise today which may cause you to have to make a choice, between being materialistic or idealistic. There's noth- ing more valuable than to bring honor to your person. Gemini (May 21-June 20) If you are denied cooperation you were expecting from an associate today, take it in stride and be philosophical about it. Someone else will step forward and help you out. Cancer (June 21-July 22) You'll no longer think that being successful on the material plane alone is adequate. You'll want a spiritual understanding. Leo (July 23-Aug. 22) Be careful how you judge people today, because you could have a ten- dency to relate to them as you want them to be rather than what they really are. Virgo (Aug. 23-Sept. 22) What wins you the admiration and respect of others that you're seeking today will be putting yourself before others. i I. - demo- 4-I- - ~ Today's MOVIES Today's HOROSCOPE CtO-MCT - 6 FmDAY, SEPTEMBER 23, 2005 ...,,.... ...... AMP 0 0 amw &MONO *mambo Alftw 4ft lad Ir Mzmww as IDbA#6L 0 Cimus COUNTY (FL) CHRONICLE SCENE FRIDAY. SEPTEMBER 23. 2005 70 Across the LINE Ocala Junior League market this weekend OCALA-- Come and shop 'til you drop at the Junior League of Ocala's 10th Annual Autumn Gift Market from 9:30 a.m. to 6 p.m. today and Saturday, and 10 a.m. to 4 p.m. Sunday at the Central Florida Community College (CFCC) gymnasium. Admission is $5 for day passes or $8 for weekend passes. Merchants from across the coun- try will descend on Ocala for this three-day shopping extravaganza, offering unique items such as gour- met foods, distinctive jewelry, cloth- ing, fabulous pewter and more, For ticket information call 368-2827. To kick off this weekend event, the third Annual Harvest Gala will be from 7 to 11 p.m. today at Golden Ocala Golf and Country Club. The Harvest Gala is black-tie optional and includes live music and dancing, live and silent auc- tions, complimentary valet parking and diamonds featured by Wilson Diamond Brokers. Gala tickets are $75 each. Springs Festival will be this weekend RAINBOW SPRINGS - Educating Marion County residents and visitors about Florida's fresh- water springs and giving everyone the opportunity to enjoy this valu- able natural resource is the goal of the Fourth Annual Marion County Springs Festival scheduled at the Rainbow Springs State Park on Saturday and Sunday. Regular park admission is $1 per person, children 5 and younger are admit- ted free. The Marion County Springs Festival will kick off Saturday mom- ing at Rainbow Springs State Park with the grand opening of the new Educational Center and Interpretative Room. Saturday will feature the grand opening of the park's new features, the Interactive Room and the Education Room, a full day touring interactive exhibits and booths set up by various agencies such as Marion County Clean Water, Southwest Florida Water Management District, St. Johns River Water Management District, Rainbow River Aquatic Preserve, U.S. and Florida Geological Survey, Silver Springs Attraction and the USDA Forest Service. Booth operators will be showcasing Florida's aquifer. Representatives from various state environmental agencies will be making presenta- tions on the current status of Florida's springs and supply of freshwater. Guests will enjoy watching demonstrations on water-wise landscaping, learning new irrigation techniques and the latest water conservation techniques and much more. Children will also enjoy a visit from characters Smokey Bear from the USDA Forest Service and Silver Springs' mascot Swampy the Alligator. There will also be live music by Jon Semmes and the Florida Friends, performances from vari- ous groups that entered the "Springs Festival's song 'contest," a professional art show and student art show featuring the first-, sec- ond- and third-place winners of the Marion County Public Schools and Hpome School Associations "Springs Festival Art contest." Rainbow Springs State Park is on the west side of Marion County off U.S. 41, just north of Dunnellon and south of State Road 40. For more information or directions to the park, call (352) 465-8555. Opera league shows film on Sunday PINELLAS COUNTY The Pinellas Opera League, in partner- ship with the Gulf Coast Museum of Art in the Pinewood Cultural Center Park in Largo, the Pinellas Opera League will show "La Juive," by Jacques Fromental Halevy, a powerful opera production by the Vienna State Opera, at 1 p.m. Sunday. There will be a lecture at .12:30 preceding the opera show- ing. This is a continuation of an ongoing program of opera DVDs shown on the fourth Sunday monthly at the center. The auditori- um is at 12211 Walsingham Road, Largo. Phone (727) 518-6833. Zephyrhills Main Street cruise is Saturday ZEPHYRHILLS Main Street Zephyrhills Inc. Saturday Nite Cruise has moved to the fourth Saturday monthly from 4 to 9 p.m. The next dates are Saturday, then on Oct. 22 and Nov. 26. Featured events are live music by Mugshot, DJ Bob Storer, random prize drawings, popular crafts, a food court and face painting by Candy the Clown. For more information, call Bob and Lynn Storer at (813) 783-1838 or Sue Harvey at (813) 780-1414. Come play this fall at Silver Springs SILVER SPRINGS -Silver Springs' fall and winter 2005 sea- son is packed with weekly special events ranging from live concerts .and cultural festivals to car shows and holiday celebrations. Silver Springs' fall calendar includes more Italian Festival on Saturday and Sunday and Oktoberfest on Oct. 8 and 9, Oct. 15 and 16, and Oct. 22 and 23. Other events include the eighth annual Corvette Show and Lovin' Spoonful concert on Nov. 5, Fall Festival on Nov. 5 and 6 and Nov. 12 and 13, and Native American Festival on Nov. 17 through 19. The last event of the year will be the 13th Annual Festival of Lights on Nov. 25 and 26, Dec. 2 and 3, Dec. 9 and 10 and Dec. 16 30, and country music's Crystal Gayle will perform on Dec. 10. All of Silver Springs' special events and con- certs are included in the price of admission. Silver Springs is east of Ocala on State Road 40; exit 352 east off 1-95 or exit 268 west off 1-95. For more information, call Silver . Springs at (352) 236-2121 or visit the Web site. Horse park, museum support relief efforts WEIRSDALE The organiza- tion STRIDE, in conjunction with Austin Horse Park and Carriage Museum, is now designated as a drop-off point for animal relief sup- plies. In efforts to relieve added stresses of pet owners devastated by Hurricane Katrina, feed, halters, lead ropes, hay, veterinarian sup- plies and drugs, buckets and all the items needed to maintain horses are being collected. Dry food for cats and dogs, as well as kennels and other pet supplies are also being accepted. In addition, the Austin Horse Park is contributing the proceeds of its upcoming communitywide hoe- down from 6 to 9 p.m. the second and fourth Tuesday of each month to this relief effort, and the commu- nity is invited to participate. For those wishing to donate to this animal relief cause, monetary contributions are welcomed and can be delivered through the Austin Foundation, a nonprofit philan- thropic organization, and can be accepted at the hoedown or by contacting (352) 753-5500, Ext. 245. All proceeds collected are going to this effort. Fall Theater Festival begins Sept. 30 OCALA Theatre CFCC will present three full-length plays in its Fall Theater Festival that begins Friday, Sept. 30 at 7:30 p.m. with Noel Coward's classic comedy "Blithe Spirit." Audiences can also enjoy the show Saturday, Oct. 1, at 3 and 7:30 p.m. and Sunday, Oct. 2, at 3 p.m. All performances are in the college's Fine Arts Auditorium, 3001 S.W. College Road. The festival continues in November with two sweet, thought- provoking comedies, "Little Old Ladies in Tennis Shoes" by Sandra Fenichel Asher, and "Sketching the Soul" by Jacqueline Lynch. Show times for "Little Old Ladies" are: Friday, Nov. 4 at 7:30 p.m. Sunday, Nov. 6 at 3 p.m. Saturday, Nov. 12 at 3 and 7:30 p.m. Show times for "Sketching the Soul" are: Saturday, Nov. 5 at 3 and 7:30 p.m. Friday, Nov. 11 at 7:30 p.m. Sunday, Nov. 13 at 3 p.m. Festival tickets cost $25. Single tickets cost $10 for adults and $5 for non-CFCC students. CFCC fac- ulty, staff and students are admitted free of charge with valid ID. In addition to the plays per- formed by Theatre CFCC, drama students will perform One Act Plays on Dec. 6, 7 and 8 at 7:30 p.m. Admission is $2 and free for festival ticket holders. For more information or to pur- chase tickets, call the Theatre Box Office at (352) 873-5810. Council taps artist James Rosenquist BROOKSVILLE The Hernando County Fine Arts Council has announced that it will honor one of Hernando County's major celebrity artists, James Rosenquist, at its sixth annual evening of Classical Elegance on Friday evening, Oct. 21, at the Silverthorn Country Club, 4550 Golf Club Lane (off Barclay) in Brooksville. Rosenquist will be honored with a commemorative plaque for "his contribution to the enhancement and promotion of the creative art environment in Hernando County, Florida." Also featured at this year's evening of Classical Elegance is the University of South Florida Chamber Singers, the University's premier chorale ensemble. The event begins at 6 p.m. and includes a social hour and sit-down dinner. Tickets are $55 each or $100 per couple. Tables of eight are available. For information or to purchase tickets call (352) 797-7402: Talent showcase will benefit ministries SPRING HILL- The Leadership Hernando class of 2005 will present "Hernando's Talent Showcase" from 7 to 9 p.m. Saturday, Oct. 1, at the Stage West Community Playhouse, 8390 Forest Oaks Blvd. The talent Showcase will feature the extraordinary talents of John Leggio's Center for the Performing Arts, the SunCoast School of the Arts Inc., the Suzuki Strings Inc., and the talents of the students of Chocachatti Elementary School. All seats are $15 and are avail- able at the Stage West box office. Call (352) 683-5113. Tickets are also available at Chick-fil-A, 13143 Cortez Blvd., Brooksville and all Hernando County branches of Regions Bank. Hernando's Talent Showcase is a benefit for Jericho Road Ministries. For more information, call Jerry Haines, (352) 754-4424. Orchid show, sale set for Sept. 30 LARGO The Florida West Coast Orchid Society and the Florida Botanical Gardens present the Orchids of Autumn annual show and sale from Friday, Sept. 30 to Sunday, Oct. 2, at Florida Botartical Gardens, 12175 125th St. north, Largo (next to Heritage Park). Friday: from noon to 4 p.m. (sale only). Saturday: from 9 a.m. to 5 p.m. (show and sale). Sunday: from 10 a.m. to 4 p.m. (show and sale). Admission is $2, and there will be hourly door-prize drawings, as well as orchid culture experts to answer questions. For more information, call Bill at (727) 392-6864. Fall harvest show in Weeki Wachee WEEK WACHEE The 32nd Annual Arts and Crafts Show is slated for Saturday and Sunday, Nov. 19 and 20, inside at Weeki Wachee Springs at State Road 50 and U.S. 19, Weeki Wachee. Hours are 10 a.m. to 5 p.m. Saturday, and 10 a.m. to 4 p.m. Sunday. The $3 admission gives the pub- lic an opportunity to enjoy the park's attractions. A juried show requires three slides or photos of set-up. There will be 12-by-12-foot outdoor spaces; 8-by-10-foot indoor spaces for fine art and fine crafts only. Deadline is Oct. 31. For applications and information, call Pat Hartman at (352) 666- 0876, Louise Voscinar at (352) 796-1189 or Virginia Thompson at (352) 596-7467. ARTS Continued from Page 1C beginning Saturday, Oct. 1, and lasting for 10 weeks. Class for children from kinder- garten through fifth grade will be from 9:30 to 10:30 a.m., and mid- dle school-aged children, sixth through eighth grade, will meet from 10:50 to 11:50 a.m. The cost is $12 per class along with a $25 registration fee per child. For additional information and to pre-register a child, call the Parks and Recreation office at 527- 7677. Homosassa Lions annual sale Oct. 1 The Homosassa Lions Club will host its fifth annual Arts and Crafts Sale at the Homosassa Lions Club on Saturday, Oct. 1.' This year, in addition to the October sale, there will also be a special Christmas Arts and Craft Sale Saturday, Nov. 5, and it will be called "The Christmas Square Arts and Crafts Sale." Crafters for this sale will be asked to present a Christmas theme either with the crafts that they plan to show, or in the deco- rations they plan to use in their space. Registration requests are now being accepted for either or both dates and as a special offer, crafters who register for both dates will receive a $5 discount on the November fee. Call Barbara Pellerin at 621- 7586 to receive an informational packet and registration form. Embroiderers' guild meets in October The Sandhill Crane Chapter of the Embroiderers' Guild of America will have its next meeting from 9:30 a.m. to 2:30 p.m. Oct. 5 at the Christ Lutheran Church on North Avenue and Zoller in Brooksville. Members work on various proj- ects and help is available for all kinds of stitches. Members are from Citrus, Hernando and Pasco counties. Guests are welcome. B.H. Lions to have annual Craft Fair The Beverly Hills Lions Foundation will host its eighth annual Craft Fair from 9 a.m. to 3 p.m. Saturday, Nov. 5, at 72 Civic Circle, the "Lions Den." The fee is $20 per space. You may use your own tables and coverings of your choice. A table and two chairs will be provided if needed. This will be a mostly indoor fair on a first-come, first-served basis. If you prefer to set up outdoors, make sure you request it and are prepared for inclement weather. Local craftsmen, hobbyists and artists can show their products under one roof, just in time for the holiday season. For additional information and/or forms to request space, call Lion Janet Mize at 527-0962. Elk's ladies accept sale applications The ladies of the West Citrus Elks are accepting applications for their annual arts and crafts show in November. The show will be from 9 a.m. to 3 p.m. Saturday, Nov. 5, at the West Citrus Elks Lodge on West Grover Cleveland Boulevard in Homosassa. Setup will be at 3 p.m. Friday, Nov. 4, or at 8 a.m. Saturday, Nov. 5. Contact Eleanor at 746-0112 or JoAnn at 382-1138 for information or an application. Nature Coast fine art, craft show slated The third Nature Coast Fine Art & True Craft Show will be Saturday and Sunday, Oct. 9 and 10, from 9 a.m. to 4 p.m. rain or shine - on the grass area south of the parking lot at the Homosassa Springs Wildlife State Park on U.S. 19 in Homosassa Springs. Only fine art and "true" crafts (potters, glass and wood workers, jewelers and other types of highly technical crafts) will be displayed. There will be no country crafts, kits, buy/sell or imported items for sale. There is no admission or park- ing fee. This show is set up as shows were 20 or more years ago. The artists were invited to participate because they were professionals, whether it is by the sales of their work or maintaining careers in their fields in other manners such as teaching and gallery ownership. No middle person is arranging this event and collecting monies for their efforts. It is a by artists for artists show for the public to enjoy. There are no awards given at the show, as we feel that the reward comes from receiving an invitation to show. Instead of requesting monies in the way of purchase awards from local businesses, we encourage the business community to come out and support these professional artists and craft persons. A portion of the payment the YBR Af'iR Preseted bY Citruu ,"" :'- ,, Homosassa Trail | beverages 1 I- (C.R. 490- across from the Homosassa Fire Station) ,- ..., c .... Proceeds to benefit the Homosassa uons Foundation. A donation of a non perishable food Item at the door would help to replenish our community food pantries. For information call 352-621-7586. -- artist makes to set up is donated to the "Friends of the Wildlife Park." Food concessions are provided by the Boy Scouts as a fundraiser to help send the young men to summer camp. Reserve space now for November sale The Brentwood Homeowners Organization is seeking crafters to reserve space for its annual sale to be Nov. 5 (rain date Nov. 6) in the Brentwood Community by the com- munity pool. For reservations and details, contact Kay Fitzsimmons at 249- 7239 or Mary Bonanno at 249- 1085. D SfLE i!n-' Home Conununiriv Educanon October 1 8 a.m. to 2 p.m. Citrus County Auditorium US 41, Inverness A or more information please call Citrus county University of Florida Extensions Office 527-5700 Get A $1200 Summer Rebate On The World's Smartest Air Conditioner! Introducing the Florida Five Star InfinityT System with PuronO- I Factory Authorized Dealer and replace your old air conditioner with a new, two-speed Florida Five Star InfinityTM System with Puron. Smart air conditioner. Smart deal. * 10-Year Lightning Protection Guarantee * 10-Year Factory Parts & Labor Guarantee * 25% Minimum Cooling & Heating Cost Savings * 100% Satisfaction Guarantee * 10-Year Rust Through Guarantee * 30 Times More Moisture Removal Visit us at: 1803 US 19 S, Crystal River 1-352-795-9685 1-352-621-0707 Toll Free: 1-877-489-9686 or visit asg =3 -I-- State License CAC0082268 State License CFC057025 - . .. . . . .Then to he Expertts 418420 LA', SCENE CiTRus CouNTY (FL) CHRoNicLE FRlDAY, SEPTEMBER 23, 2005 7C F R~ FEInAY SEPTEMBER 23. 2005 SCENE Cimus COUNTY (FL) CHRONICLE OUT Continued from Page 1C sample Cajun/Creole-inspired food from our street vendors, and enjoy listening to a variety of jazz styles on a cool October Saturday night, from 5 to 10 p.m. Oct. 8. Entertainers scheduled to per- form at this year's festival are: Joe Michel QuintetNalerie Levy, Nino Castenada, Rick Dahlinger Trio, Spectacular Gimmicks, Ocalaco, The Bluz Bustors, Liz Pennock & Dr. Blues, Dunnellon Male Chorus, Saxaltation, and the Mike McKinley Trio. Street food vendors are: JR's Sports Bar, Always Cooking I BBQ, VIP, First Bethel Missionary Baptist Church, Bob's Concessions, Gary's Nuts, Cookin' Good, Tyndal Concessions, Rainbow Caf6, St. John the Baptist Catholic Community, Mc Donald's, and Joe's Express Deli. Ocala Carriage & Tours will offer carnage rides along the entertain- ment route. Captain Mike's Lazy River Cruises will offer 45-minute river trips on the hour from 10 a.m. to 6 p.m. at $10 per person. Tickets will be available at the City Boat Ramp. Also on display will be motorcy- cles of Dunnellon Goldwing Rainbow Riders, plus antique and classic cars. Use of the Dunnellon Middle School off Cedar Street (County Road 40) as a parking area is encouraged. There will be a shuttle service available from Dunnellon Middle School to the library. Scally's Lube & Go will provide a free "Ride and Tow" to overly. enthusiastic guests. The Dunnellon Area Chamber of Commerce is offering wristbands for $1 to help offset expenses of Jazz Up Dunnellon! Street food vendors will offer a discount on food purchases to those persons who are wearing wristbands. Contact Dunnellon Area Chamber of Commerce at (352) 489-2320, or e-mail dchamber@atlantic.net, or Web page for information. Citrus STAGE 'Cyrano' playing on local stage Playhouse 19 presents the lav- sh season opener "Cyrano," the musical, based on the immortal love story of Edmond Rostand's classic Cyrano de Bergerac. The swashbuckler hero with the extraordinarily large nose pens romantic letters for a handsome, but inarticulate, soldier to win the hand of the beautiful Roxana, who is also Cyrano's secret love. The tale is told with soaring bal- lads, swordplay, and comedic wit. The director is Jacki Doxey Hull. Showtimes are 8 p.m. today and Saturday and 2 p.m. Sunday. Tickets are $15 for adults and $10 students and may be obtained at the box office, 865 N. Suncoast Blvd. in Crystal River. Call 563-1333 for reservations and box office hours. Carol Kline to perform at Oct. 16 show Continuing its increasingly pop- ular monthly "Sunday in the Hills" events, the Beverly Hills Recreation Association has arranged for the delightful and tal- ented Carol Kline to perform her 90-minute cabaret show at 2 p.m. Sunday, Oct. 16. The cost of $5, plus tax, includes coffee and cake. Come join your friends and neighbors for a delightful way to spend a enjoyable Sunday after- noon. Everyone is welcome. Auditions upcoming for 'Legends' Auditions for "Legends", written by James Kirkwood and directed by Fran Barg, will be Nov. 7 and 8 at the Art League cultural center, at the intersection of County Road 486 and Annapolis Avenue. If you are interested in audition- ing, call Fran at 628-0639. SHOW , Continued from Page 1C wanted to do something differ- ent." Proceeds from the event will benefit local charities and scholarships supported by the . club. The craft show usually makes about $5,000, from ven- dor booth rental and sponsors, Lesbirel, said last year's craft show was disappointing because organizers decided to close early last year because officials were talking about evacuating all areas west of U.S. 109 i th ('jonl3yN bause " of Tropical Storm Jeanne., Art Center Theatre season lineup revealed Tickets for the 2005-06 Art Center Theatre Season are on 'sale at the box office. The great season includes: "Last of the Red Hot Lovers" by Neil Simon; Sept. 30 Oct. 16. Directed by Jackie deTorres. "Sleuth" by Anthony Shaffer; Nov. 11-27. Directed by Peter Abrams. "Legends!" by James Kirkwood; Jan. 20 Feb. 5. Directed by Fran Barg. Dates for "The Miracle Worker" and "Love, Sex and the IRS" are to - be announced. The season runs from Sept. 30 to May 7. Season tickets are $60 for all five performances. The box office is located at the intersection of County Road 486 and Annapolis Avenue, across from Citrus Hills. Hours are 1 to 4 p.m. Tuesday through Saturday. Last season had many sold-out per- formances, so don't miss the opportunity to support and enjoy community theater. For information call 746-7606 or visit the Web site at. Veterans' appreciation show set for Nov. 6 The Fifth Annual Veterans Appreciation U.S. Show will be from noon to 4 p.m. Nov. 6 at Rock Crusher Canyon, 275 S. Rock Crusher Road, Crystal River, under the beautiful covered pavilion that can host 1,500 people who will enjoy this year's salute to the troops.. The Veterans Appreciation U.S. -Show will feature performers assuming the personalities of indi- vidual and group entertainers of past eras. This year's show will be a spectacular presentation that will include a multimedia presentation with film clips from 1942 to current affairs. Volunteers are needed for the event. Proceeds benefit funding for transitional housing to support homeless veterans in Citrus County; the fundraising goal of $35,000 must be achieved to build the transitional housing, In addition, CCFC supports veterans and their families who are in need of imme- diate assistance. Admission for veterans is free and the public will pay $10 per per- son. To raise additional money, a : deluxe brunch buffet will be offered, catered by Kim Dillon of The Gourmet Affair, foffr$2Zper person, which will include VIP seat- ing at the show and a souvenir pro- gram. For information, contact Amy Virgo at (352) 564-9197, e-mail: amyvrrgo@shipshorecruise.com, or Chris Gregoriou at (352) 795-7000, e-mail: allprestige@yahoo.com. Citrus Music Country-western show to benefit New Orleans A country-western music show to benefit the people of New Orleans who are suffering the after- math of Hurricane Katrina will start at 2 p.m. Saturday, Oct. 8, at Cowboy Junction Opry, State Road I 44 at Junction 490, Lecanto. Buddy Max will perform, together with Leo Vargason, Elwood (Woody) Faltinowski, Chuck and Martha Puckett, Freeland Sneden, Harold Johnson, Tom Wayble, Country Bob Desaulniers, Cowboy Dave Bierley, Tom Jones, Miss Dixie Rose Maxine, Don Suleski and a host of other fine entertain- ers. The show is free, but if one wishes to give a dollar or two, every penny will be given to the people of New Orleans. For infor- mation, call 746-4754. Art League presents 'Strings & Keys' Tickets are available for the upcoming Dec. 3 "Strings & Keys" concert at the Art Center Theater. The Citrus County Art League announced last week the confirma- tion of this event that will be per- formed by master guitarist Richard Gilewitz and special guest pianist David Webb. Gilewitz, well-known for his command of the six- and 12-string guitars and his humorous tales from the road, and Webb, who has toured with such noted artists as Marcia Ball, Jimmy Lafave and Arlo Guthrie, have put together a memorable performance spanning the world of blues, coun- try, jazz, folk, classical and more. The concert starts at 8 p.m. A meet-and-greet reception will pre- cede the concert at 7. Tickets can be purchased online at or from the Art League box office at 746- 7606. Adults are $15 and students are $12. The Art Center Theater is in Hemando at Annapolis Avenue and County Road 486 in Citrus County. Proceeds from the concert will be directed toward the Art Center Theater Building Fund. The box office is open Tuesday through Sunday. Nature Coast singers rehearsing now Nature Coast Festival Singers have begun fall rehearsals at Nativity Lutheran Church, U.S. 19, Crystal River. Music is available for purchase before rehearsals and singers in all four parts are invited. Scheduled concerts are as fol- lows: Sunday, Nov. 27, at 3 p.m. at Nativity Lutheran Church. Sunday, Dec. 4,3 p.m. at first United Church of Christ. Monday, Dec. 5, at 7 p.m. at Christ Lutheran Church.' 'Fcr more information, call Shirley at (352) 597-2235 or Carol at (352) 754-8739. Sunday Sampler series has begun The Sunday Sampler Concert Series has begun its 10th season. Concerts are on the second Sunday of the listed months at the Lions Club in historic Dunnellon, located on the comer of Cedar (State Road 40W) and Walnut streets. These concerts feature the best of Florida musicians. You will hear numerous original songs about this lovely but fragile state, along with outstanding folk, country, rock, and blues. Music begins at 2:30 p.m. and continues until 4:45. Complimentary refreshments are always served at intermission. Who cares? Meet this year's goodwill all-stars. Plus, celebrate America's Most Caring Coaches! The rest of the 2005-06 sched- ule is: Oct. 9: Amy Carol Webb. Nov. 13: Patchwork. Jan. 8: Roadside Revue. Feb. 12: 2 P.M., featuring Pete Price, Pete Hennings and Mike Jurgensen. April 9: Mindy Simmons. Admission is $8 at the door. For more information, call (352) 489- 2181 or (352) 489-3766. Citrus DANCES Homosassa Elks jam session Sunday The West Citrus Elks Lodge in Homosassa will kick off its new series of Jam Sessions at 1:30 p.m. Sunday. After taking the sum- mer off, the 10 or 12 "old pro" musicians are ready to get on stage and play and sing some golden oldies, blues, jazz, country and big band music that will bring back some wonderful memories. They will play until 4 p.m. The dance floor is always busy at these events and the kitchen is open for sandwich-type food. Guests are welcome after sign- ing the guest book. There is a $3 per person cover charge that will be earmarked for local charities. Come and enjoy a Sunday after- noon of really great music. B.H. Lions to host sock-hop today Come and join us for fun and dancing to continuous '50s and '60s music and socialize with friends at the Beverly Hills Lions, 72 Civic Circle, Beverly Hills, from 7 to 11 p.m. today. From Forest Ridge Boulevard, turn in to Lake Beverly. The hall is on the right, at the stop sign. Attendance is limited, call 527- 2614 or 527-1556 for ticket pur- chases. Snacks, pretzels and chips will be served and door prizes and gifts will be given out. Spirit of Citrus dances upcoming The public is invited dance par- ties hosted by the Spirit of Citrus Dancers. The dances are held on Saturday nights at the Kellner Auditorium, in Beverly Hills. The dance schedule is as follows: Saturday "Showcase Dance Party" to celebrate National Ballroom Dance Week. Attendees are invited to bring a goodie to share if they would like. Music by Butch Phillips. Oct. 8- -'Birthday-Dance Party" Complimentary Cake will be served. Music by Butch Phillips. FINANCING AVAILABLE WSW m m_ Oct. 22 "Harvest Ball" Wear your favorite fall colors. Music by Butch Phillips. Doors open at 6:45 p.m. A com- plimentary lesson will be given at 7. Open dancing is from 7:30 to 10. Admission is $7 per person. There is a "get-acquainted" table for dancers without dance partners. Coffee and ice will be provided. For additional information call Lloyd or Kathy at 726-1495. Social club plans dinner/dance today Citrus American and Italian Social Club of Inverness invites all to its September dinner/dance on today. Tickets are $12 for nonmem- bers and $11 for members. The menu is chicken cutlet parmesan with spaghetti, salad, coffee and cake. BYOB, Music by DJ Angelo. Doors open at 5 p.m. with dinner served at 6. For tickets, call Angie at 637-5203. Homosassa Elks plan dinner/dance Sept. 30 The West Citrus Elks of Homosassa will have a dinner/ TENTH dance at their lodge on Friday, Sept. 30. Serving times for dinner are from 5 to 7:30 p.m. and the menu will feature a choice of baked ham or stuffed grouper, each served with salad bar, rolls, veggie, potato, and dessert. Ticket price for Elks and guests is $8 per person. If you wish to dance or listen only, the cover charge is $3 per person. No reser- vations. Pay at the door. Italian Social Club to have harvest dance The Italian Social Club on County Road 486 in Hemando is having a pre-Halloween Harvest Dinner Dance at 5:30 p.m. Saturday, Oct. 8. Dinner will feature roast beef, potato and vegetable with salad and dessert, as well as setups for the beverage of your choice. Although a bit early for Halloween, we encourage costumes, but they are only optional. Music will be pro- vided by the Carriers. Tickets and reservations are $12 by calling John at 726-1328 or Marie at 726-8406. .ANNUAL Cristmas In September Saturday, September 24 9:OOAM-4:OOPM Crystal River Armory SUS 19 and Venable Street, Crystal River Over 85 exhibitors with hand crafted items, decorations, food available and gifts galore! Nature Coast Knights Classic Car Club Display $1 Donation appreciated Presented By the Pilot Club of Crystal River Proceedsfrom this event wtill-bused tcvbenefit local charities throughout Citrus County. F hALLie Coeit ErluFo ApI I Come In' early For SBest Selection! arancVE ON HUNDREDS OF SAVE ON -HUNDREDS OF odds enUs? FALL CLEARANCE SALE PRICES THROUGH SEPTEMBER 30TH! Ffr o Dook Drastically Reduced! Some Items Marked Below Cost! IOvaln 2530 SW 19th Ave, Rd., u, 0i4,ft. (opn!.eIm~ ow S -i~t,'I i a~tti 4 it), 861-3009 Moan 4dr. 10ai 7pm, Sat. f~am 6pm, Stit, Noo -5Spin OTRus CouNTY (FL) CHRoNicLE B k N I F U k I C"I A SCENE SC FIUDAY, SEPTEMBER 23, 2005 V4 ..9 . . .. 7 . dIKU3 Ls (Y)ryINTV(I'F t.)CrUMUrrr LFID-,SETE BE-2, 00 - Canterbury Lake Estates Citrus Hills 3/2/2 hoe on a quest cul-de-sac. A parklike 2/2/2 split plan. Handyman special,. setting overlooking the lake. Beautifully decorated w/lots of tile and upgrades. needs work, being sold as-is. 2 Locations Open 7Days A Week! Citrus Hills Office Pine Ridge Office N p Prudential 20W.NorvellBryant Hwy. 1411 Pine Ridge Blvd. Hernando,FL 34442 Beverly Hills, FL 34465 Florida Showcase 352-746-0744 352-527-1820 Flora Showcase Toll Free 888-222-0856 Toll Free 888-553-2223 Properties An independentlyowned and operatedmemberThe Prudential Real Estate Affiliates,Inc. A2 51 MARY EBHARDT c t pr., For Service from the Heart 352-228-0024 W - 352-344-0880 REALTY LEADERS SUPER BUY Beautiful high & dry acre... Easy to build your / dream home... Cul-de-sac... View... Utilities... Lovely & just reduced to $69,900. SBEVERLY HILLS 2 bedroom, 2 bath. $124,900. HOUSE FOR RENT Cute 3/2 on 1/4 acre. Open floor plan, washer & dryer, possible RV parking, lawn service. Available 11/1/05. $850/mo. :J 4S 5 generous sized rooms 18" white tile in most rooms 2 bedrooms & 2 baths French doors to lanai 2 car attached garage Sugarmill Woods On deep greenbelt Updated & clean Neutral decor Priced to sell at $210,000 Call for private showing: 352-382-5579 SJ. W. Morton Real Estate, Inc.. l -... ...- Property Management 1645 W. Main Street ,- Inverness, FL 34450 (352) 726-9010 Visit our Website: HOMES FOR RENT SEASONAL RENTALS AVAILABLE INVERNESS Single family homes & 55 and over community. Call for more details PINE RIDGE 3BR, 2BA home with 2 car garage and screened patio on an acre. $1,300 P96 INVERNESS HOUSE Newer 3BR, 2BA house. Screen room, 2- car garage. $850 P310 PRITCHARD ISLAND -, 2BR, 2BA ground floor condo overlooking Lake Henderson. Tennis courts, community pool, boat docks. $850 RIVER LAKES MANOR 3BR, 2BA with 1 car garage in Hernando. Private boat dock. Water access to Hernando chain of lakes. $775. P216 INVERNESS APARTMENT 55 and older complex. Upstairs unit. Laundry facilities onsite. City water-and trash pickup included with rent. $450 P231 BEVERLY HILLS 2BR, 2BA home. Family room, single car garage. $550 P27 m HOLDER 3BR. 2BA mobile home. Carport, deck, screen porch. SATURDAY 9/24/05 12PM-3PM a SUNDAY 9/25/05 12PM-3PM Fenced yard. $650 P305 SImerial Executive II GREENBRIAR CONDO 2BR, 2BA upstairs condo w/carport located in Citrus Hills. $650 P134 645175 Beverly Hills Home 2/2/2 situated on a lot & a half. Give me a call A today to take a look. EXIT l- Douglas Lindsey REALTY -212-7056 LEADERS S' . Bus: (352) 794-0888 Directions: 491 to Roosevelt to right on Jeffery. (See sign). Toll Free: (866) 795-3396 Alison Markham Steven McClory American Realty & Investments Realto 730 N. Suncoast Blvd. Crystal River, FL 34429 Realtoory Hwy. 491 & Roosevelt e info@naturecoastliving.com j .... o Indeoendentlv Owned & Ooerated awuc 5 --U I E11A CiaL inhia 13521 746-360 O ffice tISJCii 2-4.3-4Y4O1 Toll Freue -Cell 13521 212-,056 BRAND NEW CONSTRUCTION $279,900 4i2.2 Two rcomer. a.Vaiable Seller offering i,?.,OCi' louward Bu.,er Closinl3 :ostsl EX3541R & EYX3542R Cali Allionr i6970.u7611 or Siee t22.3998i * Go to to view s00 wiruual Tours S: ~ LISTING WITH A CENTURY 21@ HOME PROTECTION PLAN COULD LEAVE YOU 3I FEELING |I I l- GOOD. LIST WITH US AND GET A AND NO TRANSACTION FEES! A SAVINGS OF $585.00! IF YOU BUY FROM US, THERE ARE NO TRANSACTION FEES! BURKE REALTY, INC. 344-1113 BEAUTIFUL COUNTRY LIVING w/1995 4 bedroom, 2 bath home. Caged in-ground pool, gas fireplace, New A/C unit w/ warranty, this house shows like new. Plus a 4/2 doublewide mobile. MLS#3140184 Priced at $375,000 Ask for Bob. 2 H 4W ClialPl Get ResulIts In The Homefront Class ifieds! ELLEN ARONEO PAT WADSWORTH REALTOR' FE4LT.R'l h z'/,,, 634-2345 634-2209 The .ht-di Cn frop ellen aroneo@yahoo.com pat2@ndip*ebnet con, .. 5 William Tell Lane Beverly Hills FL 34465 u 2504 W. Pine Ridge Blvd. CUSTOM BUILT HOME featuring 4 beds, 2 baths, g formal dining room BEAT THE RUSH COME BUY MEI Enjoy your retirement w/money in the bank & I have been reduced & offer 3/2 on almost 2 smart buying on this 2/2 manufactured home on acres of land located in River Lakes Manor I I"l" lot ii sllcr.' i'p,. t: ... I, T, Iuhr- a lai.'g.e 3'pen ::. .,r ,l, ., reer, 3 r.:.,m w. r.q O,1, $54.900. i." Ci M 5, ,i :-,'l:,6,: ,c.d .,.iqri S89.900. eCRf.A,.3 ONE FAMILY NEED 2 HOMES? How about side-by-side manufactured homes on FLORAL CITY PARK OUT YOUR BACK DOORI Parsons Point? 1 is a 2/2 & the other is a 2/1. This needs very little TLC to be a great retirement Offers covered porches, bonus room, laundry home in Florida. Kitchen has been upgraded, room, corner lot, good location. Only $85,000 for wood cathedral ceilings in large LR. Tile floor in both. Call Lisa, owner/agent. ,302-0840. BA. Features 2 BRs. Asking $98,500. Call Kathy #CRM037 & #CRM038 for info. 212-1069. #CRR0052 LOOKING FOR THAT SPECIAL HOUSE? j l ? ji l s Tr ..z r.vI 3 .... E ilal'r:e I... La E .5 I I 41' 4 1 .I r) I l..-I.J Ti N KING OF SELLING? area, attached carport, landscaped property w/ Don'tknowwhichway to turn? Have Questions? garden & fishpond, huge screened lanai w/ We market and sell property throughout Citrus County. Call Jacuzzi & wood decking. Also a 19x12 glassed-in our professional reactors for help. We have been serving clients since 1987 and would be happy to help you. lanai w/summer kitchen. Only $137,900. Call Call Craven Realty, Inc. 726-1515 Cindy 613-6136 for showing. #CRR0053 or e-mail us at: cravenrealty@tampabay.rr.com JIM HOFFIS j : L^J Realtor 1_ J'.l ii" lll . I Direct: 352-464-2761 E-mail: jamesihof@aol.com 3766 W. GALLEON ST. Citrus Springs........................ 0.23 Acres.................. $34,000 2797 N. HYTHE PT. Canterbury Lake Estates.........0.22 Acres.................. $55,000 8468 N. ERIN DR. Crystal Manor................1.20 Acres..............$59,000 1303 E. HOBART LN. Presidential Estates ..................1.00 Acres.....................$69,000 1213 E. CLEVELAND ST. Presidential Estates............... 1.00 Acres.................. $69,900 1248 E. BISMARK ST. Presidential Estates............... 1.00 Acres.................. $85,000 1401 E. BISMARK ST. Presidential Estates............... 1.00 Acres.................. $85,000 4987 N. CIMARRON DR. Pine Ridge............................. 1.00 Acres.................. $95,000 I fm- & living rooms, family room with -fireplace and built- ins. Screened pool with outdoor shower and wet bar all set on a one acre lot. #429211 $500,000. 3579 W. Cogwood Circle PINE RIDGE 3 bed, 2 bath home with family room and wood burning stove. Caged in- ground spa, large workshop with electricity,. Ceramic tile in kitchen, breakfast and family room. Roof 6 months old. Home warranty. #429330. $239,900. Prolit roin 0111-Expe'..", 71 iNtT, -, , FRiDAY, SEPTEMBER 23, 2005 ID i:mus CouNTY (FL) CHRONICLE I --- I CITRUS COUNTY (FL) CHRONICLE C TRP US a.", OU N. V.563pm Tuesday Thursday Issue........ 1pm Wednesday Friday Issue..............1 pm Thursday Saturday Issue............. 1 pm Friday 6 Lines for 10 Days! 2 items totaling 1 '150 ...................$50 $151 -$400.............$1050 $401 -'800 .... 5...$1550 $801 -$1,500..........$2050 Restrictions apply. Offer applies to private parties only. SCar&s. SEI AL OIE 0205HL A NTD15-6 IANCAL 8-91SRI CES21-66A NIA LS 4 00-1 M BL*HMSAO*EN R AE50 4 PINE RIDGE gro to..? Ihr.- I '.,, ., ,1 P M .i AI.I'in i I! r DOLLAR PRODUCER Cathi Schenck 634-0886 P S .. RPF76B ; I~~E ,r,-|,--|, SUGARMILL FW WSf- OODS S152,500 Calhich-nca. kBR L"MultPrudenti f'" flu .. '"1 5Florida Showcase Cathi Schenck Properties SMulti-Million BILL H THINGS . Dollar Producer o REALTY LEADER R97.-11 22 .r.e.i..U.....3 LARKUt 40 MUIVIC on oeauliiuI selling Has 181,10 office wlprivate entrance that was 3rd car bay, could be converted back to garage The 15x30 pool & spa are gas heated Pool area has large deck area. Private backyard wished which has water & electric Well has reverse osmosis water treatment EX869RB THIS IHr1ii. E 1 1 l.t LArJlJ5. -APEllC H ME O h ,A i luI i Tl "d liN ated burning FP, master BR has a walk-in oset. Enclosed lanai central would air, security sys, smoke detectors, sprinkler sys, wet bar, & pond w/a tree fountain. All this & more in a greal family neighborhood. Home is across the street from the community pool & tennis courts. EX897RB IE AFFfllRABLE 21 H .., ME1;].' .,, ...TI S$1,000 carpet allowance. Beautiful fruit trees in backyard. You n have a delicious breakfast of ruby red & white grapefruit & naval - ,L IN JAMON 10 1E .1 h..ll il.11' a i V I m. I hi open tloor plan in beauiuti Cinnamon Raoge. New meiai root, new flooring, 8x31 carpeted front porch &i 10x25 Fl. room w/doubte paned windows. Buyers hurry, this will not last long. EX115MB p Br---- *.*'ist AUTIFUL 3/2/2 FRESHLY PAINTED, new carpet, open r plan, and vinyl enclosed lanai. This home is on a quiet cul- sac with great curb appeal. Citrus Hills social membership juired. EX965RBI PINE RIDGE LOT 1 ,ie $94 900 E'4.LB [W ~ GREAT VILLA LOT SW *HI1 'HH' Thri I .1 I., I',J"a [,,jhl'jl LduJ'PI l'1' Tr, a II I 3 ,Tui I st,' S39 900. E .iiOLLB t 7--. '- ... Mli6 B:------------- EPR LOT HOME 3Iri.u tull GREAT LOT te, dal zone air condition system This lot is on the most desirable street in the lovely d w/maestarm Woods Oak Vae. Only $69.900. EXoaks Only $19250031LB slbshinsc 9973133. FX942RR Sugarmill Woods Oak Village. Only $69.901. EX331LB , ne, Lenora Lupari , ySu Realty, Inc. ) REALTOR Office 746-9572 *Home 746-7330 "Your New Home Specialist" Cell 634-2640 4067 N. Lecanto Hwy. Beverly Hills, FL This newly finished home sits on a 1 acre treed lot. A home that will wow you with over 3,000 sq. ft. of living area. Gourmet kitchen with Corian counters, tile flooring and upgraded wood cabinets. Beautiful center island, decorator lighting and large pantry. Master bedroom with deluxe master bath, dual sinks and jetted tub. Large family room opens onto screened lanai with pool bath. Formal living and dining, and den/office. Offered at $372,000. I 0 3,900 ON YOUR LOT Other packages available. 3/2/I + laundry. Atkinson Construction, Inc. (352) 637-4138 CBC059685 WATERFRONT 11939 WATERWOOD DR. CRYSTAL RIVER Directions: From Hwy. 19 take Fort Island Trail west 4.6 miles to 1" Waterwood Dr. Turn left, 5 h" house on the right. $395,000 CINDY RE Red 'One HIGGINS 2421 N.Lecanto Hwy. Reao Lecanto, FL 34461 W Realtorm 2 2 offie: 527-7842 cen: 212-1676 Get Results In The Homefront Classifieds! Inverness 2n FRIDAY- SEPTEMBER 23. 2005 I i F t .'. . .CrrRUS COUNTY (FL) CHRONICLE ARE YOU A WF ? Slender 30/50 I am 53 successful & handsome WM. let's talk 476-8657 Handsome SWM, Lean Muscular body, 36 year old, 6'1', 215lbs. Tired of the games, looking for monoga- mous relationship with a good woman. I laugh easily and love hard, country boy at heart, financially secure. Plan to relocate to this area In the fall. If interested, send letter and photo to PJ., 1150 Alta Ave, Atlanta, GA 30307 NEW GUY IN TOWN Black male,50yrs old 6'5" Looking for serious relationship. Lives in Beverly Hills, Looking for female companion 35-47yrs old Race unimportant. Enjoys swimming, boat- Ing, movies and more, Call (352) 746-1659 Wanted: Band & Entertainers In exch. for recognition (352) 527-3177 icA FREE SERVICE- Cars/Trucks/Metal Removed FREE. No title OK 352-476-4392 Andy Tax Deductible Receipt Search 100's of Local Autos Online at wheels.com 2 Free Kittens, 1 male neutered, 1 female spayed. (352) 563-0434 5 Yr. Old Goat FREE Healthy, Male (352) 637-2206 Australian Sphperd Mix 5 yrs. Neu. male. Happy Healthy, Smart FREE to good home. "Our Loss is Your GAIN" Shots up to date. (352) 382-2488 CAT ADOPTIONS CAT ADOPTIONS There will be an Adopt A Thon every Saturday during the month of September COMMUNITY SERVICE The Path Shelter is available for people who need to serve their community service. (352) 527-6500 or (352) 794-0001 Leave Message Firewood cut & dry, you haul it (352) 628-3570 FREE German Shep/Rott, 2yrs, female, no small children (352) 628-3441 FREE 2 Med Size male dogs. German Shep/Pit mix (352) 465-8642 FREE 24X40 DOUBLEWIDE, plus 30x10 screen room, you remove. (352) 344-1118 (352) 228-2526 FREE CHICKENS, Long Island Reds, Roosters must go too. PETS, also Bennies (352) 287-9182 FREE GROUP COUNSELING Depression/ Anxiety (352) 637-3196 or 628-3831 FREE HICKORY FIREWOOD (352) 726-0135 Free Oak Firewood Leave message If not home. (352) 621-3594 FREE POND FISH (352) 564-0373 KEN BELL 352-302-6813 Free Home Warranty for Buyers & Sellers No Transaction Fee, centurv21.com NATURE COAST 352-302-6813 FREE REMOVAL OF Mowers, motorcycles, Cars. ATV's, jet ski's, 3 wheelers, 628-2084 rescued petcom Adoption Sat. Sept. 24 9:30 to 12:30. Barrington Place Hwy 486 Lecanto Requested donations are tax deductible Kittens 16 weeks gray M neutered sweet, socialized, ok with dogs 489-8966 Kittens 10wk tuxedo 5 M cats & dogs ok 527-0434 Kittens to young adults M&F various colors all ready for their special family 746-6186 Come see our selection of dog and cats: Siberian Husky, (4)Lhasa Apso, Chihuahua Mix, Lab Mix, Wanted poodles and small dogs suitable for seniors adoptive homes available 527-9050 Or 341-2436. Will Take Small " Puppies... Adoptive Homes available...341-2436. All pets are spayed / neutered, cats tested for leukemia/aids, dogs are tested for heart worm and all shots are current CLASS KITTENS PURRFECT PETS spayed, neutered, ready for permanent loving homes. Available at Eleen's Foster Care (352) 341-4125 Roller for Solar Pool Blanket. Free (352) 860-1230 VOLUNTEERS For caring, helping, repairing & maintenance for animals. One person only. Possible room & board. Community Services possible without room & board. after 11 am (352) 795-2959 black and white 50 to 601bs lost on 9/20 minifarms 495 area green collar male. ', Bull Terrier, large, black & white, green collar, mini farms area/495 352-563-1260, 613-4375 Cat Neutered male, Himalayan mix, tan & white, recently groom- ed, blue eyes, vic, of , Basllico & Pinehaven, (352) 563-0358 Cat Orange Tiger Stripe, small young female. VIc. Pine Ridge Off Bonanza, On meds, REWARD. 352-302-2180 CHIHUAHUA, brown, 2 yrs. old recently spayed, lost In Vicinity Deltona Blvd. Citrus Springs, (352) 465-3062 Diamond & Gold Bracelet Lost In vicinity of Three Sisters Springs, Chrs. Riv. (352) 795-5040 LOST Golden Retriever, male In Sugarmlll Woods answers to Ranger, REWARD (352) 249-6320 CARPET FACTORY Direct . Restretch Clean * Repair Vinyl* Tile * Wood (352) 341-0909 SHOP AT HOME CUTTING EDGE Ceramic Tile. Uc.#2713, Insured. Free Estimates. (352) 422-2019 Richard Nabbfeld Hardwood & Laminate. 6 yrs. exp. Prices start at$1.50 sq.ft. LLC Uc./lhs. RIP RAP SEAWALLS & CONCRETE WORK Llc CERAMIC TILE INSTALLER Bathroom remodeling, handicap bathrooms, Uc/Ins, #2441 634-1584 10-- REPAIRS, Wall & ceiling sprays. Interior Painting LIc/Ins 73490247757 220-4845 FluDAYSEPTEMBER 29. 2005 3 Lost Siamese Cat In vicinity of Redbird & Cardinal. (352) 726-3200 or 621-9831 LOST Yorkle, last seen on Star Jasmin in Beverly Hills (352) 746-9858 2 ADORABLE KITTENS Free to good home 1 solid smokey grey, 1 tiger striped, (352) 447-1244 2 Kittens W River Rd. 1 solid smokey grey, 1 tiger striped, (352)447-1244 3 PUPPIES FOUND In mini farm area. Call to Identify. (352) 564-0764 CORDLESS DRILL found on Deltona Blvd In Citrus springs. Call to Identify (352) 427-7695, Ocala DACHSHUND Found Periwinkle & Ohio, Homosassa, male bik, brown on feet. (352) 628-0757 "MR CIRUSCOUNTY' Divorces Bankruptcy SNameChange l e .............ess 63740221 *CHRONICLE. INV. OFFICE 106 W. MAIN ST. Courthouse Sq. next to Angelo's Pizzeria Mon-Frl 8:30a-5p Closed tor Lunch DISCOVER A NEW YOUI See yourself in a whole new way with a free makeover Find a look that expresses your style, your personality, your life. Call me to create a fabulous look. that's uniquely you, You'll love what you discover. Rita O'Brochta Sales Director Oyster's Restaurant 606 NE Hwy 19 Crystal River SATURDAY 10AM- 12PM vice Director n -i 10% OFF NEW ACCTS JOE'S TREE SERVICE All types of tree work 60' BUCKET Uc.& Ins. (352)344-2689 Split Fire Wood for Sale A WHOLE HAULING & TREE SERVICE 352-697-1421 V/MC/D r AFFORDABLE, | DEPENDABLE, | HAULING CLEANUP, I PROMPT SERVICE I I Trash, Trees, Brush, Appl. Furn, Const, I Debris & Garages L 352-697-1126 COLEMAN TREE SERVICE A Remove, trim & clean Sup. Lb. Ins. No job too sm. or too Ig. Guar. 10% lower than any written proposal. 344-1102 DAVID'S ECONOMY TREE SERVICE, Removal, S& trim. Ins, AC 24006. 352-637-0681 220-8621 .D's Landscape & Expert Tree Svce Personalized design. Cleanup & Bobcat work. Fill/rock & SSod: 352-563-0272. Dwayne Parsler's Tree Removal. Free estimate Satisfaction guaranteed Lic. (352) 628-7962 JOHN MILL'S TREE SERV., Trim, top, remove Uc #7830208687 (352) 341-5936 or 302-4942 R WRIGHT TREE SERVICE, tree removal, stump grind, trim, Ins.& Lic #0256879 352-341-6827 STUMP GRINDING Lic. & Ins. Free Est. Billy (BJ) McLaughlln 352-212-6067 STUMPS FOR LE$$ "Quote so cheap you, won't believe iti" (352) 476-9730 TREE SURGEON LUic#000783-0257763 & ins. Exp'd friendly serve. Lowest rates Free estimates,352-860-1452 COMPUTER TECHMEDICS On site Computer Repair. Internet & Network Specialist. (352) 628-6688 B- - *'Chris Satchell Painting & Wallcoverlng.All work 2 full coats.25 yrs. Exp. Exc. Ref. Uc#001721/ Ins. (352) 795-6533 All Phase Construction Quality painting & re- pairs. Faux fin. #0255709 352-586-1026 637-3632 CHEAP/CHEAP/CHEAP DP Pressure Cleaning & Painting. Ucensed & Insured. 637-3765 George Swedlige Painting- Int./Ext. Pressure Cleaning- Free est. 794-0400 /628-2245 INTERIOR & EXTERIOR 25 yrs, exp. also Kitch- en/Cabinet, LIc. & Ins. Jimmy 352-212-9067 iNiEKIuK/EXAEKlUK & ODD JOBS. 30 yrs J. Hupchick Uc./Ins. (352) 726-9998 Mike Anderson Painting Int/Ext Painting & Stain- ing, Pressure Washing also. Call a profession- al, Mike (352) 628-7277 PICK YOUR COLOR S PAINTING Interior*Exterior* Faux Fair Prices. Owner on Job. Free Est., Insur. (352) 212-6521 RELIABLE Interior & ex- terlor painting & more. 'Reasonable rates, Lic.#f 99990003108 795-3024 Unique Effects-Painting, In Bus. since 2000, Interior/Exterior 17210224487 One Call,To Coat It All 352-344-9053 Wall & Ceiling Repairs Drywall, Texturing, Painting, Vinyl. Tile work. 30 yrs. exp. 3AA44O-1 52CBCnROA8 . Affordable Boat Maint. & Repair, Mechanical, Electrical, Custom Rig. John (352) 746-4521 avail. 697-TUBS (8827) COUNTER TOP Resurfacing & repair, Sr. citizen disc. Uc. 28417 (352) 212-7110 "No Me- CUSTOM UPHOLSTERY Modern & antique. Denny, 628-5595 or 464-2738 Elderly Care In my Secure Home, lovely priv. rm & bath. Call for details. 352-270-1865 IN HOME HEALTH AID for prominent Prince- ton, NJ gentleman, relocating to FLA, seeking similar pus. 17 yrs. exp. w/ mental & physical diss. Ref.avall. tosA o kAof iAO I VChris Satchell Painting & Wallcoverlng.AII work 2 full coats.25 yrs. Exp. Exc. Ref. Lic#001721/ Ins. (352) 795-6533 CHERYL'S IN HOME CLEANING Weekly & Biweekly, Licensed, 352-344-8826 FAITH DEAN'S Cleaning Family Busn. Since '96 Free Est. Llc# 0256943 Insured. (352) 341-8439 Cell 476-4603 HOMES & WINDOWS Serving Citrus County over 16 years. Kathy (352) 465-7334 Liz's Quality Cleaning Service Reliable, Affordable, Weekly, Bi Monthly, Licensed (352) 489-4512 Handcraftted Custom Cabinets - Hardwoods specialist (352) 795-5444 Additions/ REMODELING New construction Bathrooms/Kitchens Uc. & Ins. CBC 058484 (352) 344-1620 ROGERS Construction Additions, remodels, new homes. Most home repairs. 637-4373 r /C'- I 7, FL RESCREEN 1 panel or comp. cage. 28yrs exp 0001004. ins. CGC avail 352-563-0104/228-1281 FREEDOM RESCREEN Pool Cages, Window Scrns, etc. Will beat all estimates. ULc# 2815. (352) 795-2332 Screen ims, rescreening Carports, vinyl & acrylic windows, awnings. Llc# 2708 (352) 628-0562 Amen Grounds Maint. Complete lawn care & pressure washlng.Free Est. (352) 201-0777 AUGIE'S PRESSURE Cleaning Quality "HOME REPAIRS" Painting, power wash jobs big & smalr#1453 (Eng./ Spanlsh)746-3720 "The Handyman" Joe, Home Maintenance & Repair, Power washing, Painting, Lawn Service & Hauling, Liec 0253851 (352) 563-2328 #1 IN HOME REPAIRS, paint, press.wash, clean roof&gutters, clean up, haul #0169757 344-4409 A nrilncK wcRJWK Ceiling fans, Ughts, etc. Lic. #999900022251 422-4308/344-1466 AFFORDABLE, DEPENDABLE .HAULING CLEANUP. I PROMPT SERVICE I i Trash, Trees, Brush, | Appl. Furn, Const, SDebris & Garages 352-697-1126 L ,- - All Around Handvman Free est. Will Do Any- thing. Uc.#73490257751 352-299-4241/563-5746 ALL TYPES OF HOME IMPROVEMENTS & REPAIRS #0256687 352-422-2708 Andrew Joehl Handyman. General Maintenance/Repairs Ftessure &I Movlng,Cleanauts, & Handyman Service Lic.99990000665 (352) 302-2902 HOME REPAIR ,uJ need It done, we'll do It. 30 yrs. exp. Lc., Ins, #73490256935, 489-9051 HUSBAND & WIFE TEAM, 30 yrs exp Sm. jobs. Sr. citizen disc. Uc. 28415 (352) 212-7110 NATURE COAST HOME REPAIR & MAINT. INC. Offering a full range of services.LIc.0257615/lns, (352) 628-4282 Visa/MC Wall & Ceiling Repairs Drywall, Texturing, Painting, Vinyl. Tile work. 30 yrs. exp. 344-1952 CBC058263 F-- CITRUS ELECTRIC All electrical work. Lic & Ins ER13013233 352-527-7414/220-8171 CUSTOM LIGHTING, fans, remotes. Dimmers, etc. Professionally Installed. Llc#0256991 (352) 422-5000 All of Citrus Hauling/ Moving items delivered, clean ups. Everything from A to Z 628-6790 AFFORDABLE, DEPENDABLE, I HAULING CLEANUP, PROMPT SERVICE I Trash, Trees, Brush, Apple. Furn, Const. , SDebris & Garages | 352-697-1126 GOT STUFF? You Call We Haul CONSIDER IT DONEI MovlngCleanouts, & SHandyhan Service LIc. 99990000665 (352) 3029D2 HAULING & GENERAL Debris Cleanup and Clearing. Call for free estimates 352-447-3713 WE MOVE SHEDS 564-0000 ALA,UKAIC nuiviC INSPECTIONS Buy with confidence. Pre-sale, Re-sale, New homes. Lic. Acct. 28305 & RAINDANCER Seamless Gutters, Soffit Fascia, Siding. Free Est. Uc. & Ins. 352-860-0714 Violin Lessons Flexible Hours (352) 726-2449 Wall & Ceiling Repairs Drywall, Texturing, Painting, Vinyl. Tile .work. 30 yrs. exp. 344-1952 CBC058263. Ins.(352)302-7096 FILL, ROCK, CLAY, ETC. All taes of Dirt Service Call Mike 352-564-1411 Mobile 239-470-0572 FLIPS TRUCK & TRACTOR, Fill Dirt, Rock, Top Soil, Mulch & Clay. You Need It, I'll Get ItI (352) 382-2253 Cell (352) 458-1023 VanDykes Backhoe Service. Landclearing, Pond Digging & Ditching (352) 344-4288 or (352) 302-7234 cell All Tractor & Truck Work, Deliver/Spread. Clean Ups, Lot & Tree Clearing Bush Hog, 302-6955 HAMM'S BUSHHOG SERVICE. Pasture Mowing, lots, acreage. Licensed & Insured D's Landscape & Expert Tree Svce Personalized design. Cleanups & Bobcat work. Fill/rock & Sod: 352-563-0272 MARK'S LAWN CARE Specializing in hedge trimming, landscaping, +llln (3 I5 17 9/O A A 411'1 PRO-SCAPES Complete lawn service. Spend time with your Family, not your lawn. Uc./Ins. (352) 613-0528 A DEAD LAWN? BROWN SPOTS? We specialize In replugging your yard. LiUc/Ins. (352) 527-9247 r ---= E=I AFFORDABLE, I DEPENDABLE, m HAULING CLEANUP, PROMPT SERVICE I STrash, Trees, Brush, Appl. Furn, Const,. SDebris & Garages | S 352-697-1126 Amen Grounds Maint. Complete lawn care & pressure washing.Free Est. (352) 201-0777 Bill's Landscaping & Complete Lawn Service Mulch, Plants, Shrubs, Sod, Clean Ups, Trees Free est. (352) 628-4258 Blade Runners Lawn Maintenance. Llc S:: ':'r t.. . ULc. Anytime, 344-2556, Richard ATTRACTIVE SWF seeking male companion. Candl, 352-628-1036 IN HOME HEALTH AID for prominent Prince- ton, NJ gentleman, relocating to FLA, seeking similar pos. 17 yrs. exp. w/ mental & physical diss. Ref.avail. (215) 262-1042 JOBS GALORE!!! EMPLOYMENT.NET LOOKING FOR SELF MOTIVATED & ENERGETIC LIC. INSURANCE AGENT Salary & high commis- sion, (352) 427-6914 OFFICE/PERSONAL ASSISTANT For In Home business. Email resume to: comoaoDs@ bellsouth.net WEEKEND RECEPTIONIST 10-6 Fun, positive person needed, Tasks Include: customer relation, multi-line phone system and data entry. Dependability a mustPlease come see us at: Arbor rail 611 Turner camp Rd Inverness, Fl EOE Regal Nails Now hiring nall tech, Commission 60/40. Contact Dustin Lee at (352) 860-2911 $$$$$$$$ SIGN-ON BONUS NEW OPPORTUNITIES PAY SCALE & BONUSES LPN's FT/PT 5AM-1:30PM PT 1:30PM-10:15PM For ALF. Benefits after 60 days Vacation After Jan 1st. Apply in Person: Brentwood Retirement Community Commons Build. 1900 W. Alpha Ct. Lecanto 352-746-6611 DFWP/EOE BILLING ASSISTANT Full time, competitive salary & benefits.. Great work environ- ment w/ experienced and professional.staff. 2 years minimum experience in Medical setting CITRUS PODIATRY PO Box, 1120 Lecanto. 34460 S 34461. EOE ic.n Medical DENTAL ASSISTANT Quality dental practice in Dunnellon needs experienced F/T dental assistant, excellent pay & benefits. Must be a team player. Fax Resumes to: (352) 331-0439 FT BILLING & COLLECTIONS PERSON Experience w/ICD 9, CPT coding & A/R, Fax resume to: (352) 746-6333 HOSPICE- ACr lM"CCA.h IC. 34465 ithacher@hosolceof citruscDountv.oraFW DFW *. , < .1 Every day hundreds of people like you turn to the Classifieds to find the items they need at prices they can afford. If you've got something to sell, go to and place your. classified ad with us! CL AS F. I E S CH ONCLASSIIE S I F I FED S What is ez? It's the 24-hour, do-it-yourself website for creating ads that will appear in the Chronicle's classified section Copyrighted Material Syndicated Content a Available from Commercial News Providers L "D 4po Sm 0 0mft Advertise Here for less'than you think!!! Call Today! 563-5966 , Fm cm Medical CNAs 3-11 & 11-7 Avante at Inverness is currently accepting applications for CNAs for 3-11 & 11-7 shifts. Avante offers excellent pay for years of experience shift differential, week- end differential, bo- nuses for extra shifts, excellent benefits package for fulltime employees. Please apply in person at: 304 S. Citrus Inverness, EARN AS YOU LEARN CNA Test Prep/CPR Continuing Education 341-2311/Cell 422-3656 FULLTIME MA/LPN DON (F/ RN Per Diem Diabetic Nurse HHA Homemaker/ Companion ULTIMATE NURSING CARE eAgency resumeto (352) 726-7174 LPN / RN Needed for busy Primary Care/Pain Management practice. Team player, work well independently & with/ instruction Fax resume & salary req to: 352-746-1972 MEDICAL OFFICE Needs Medical Assistant with front Apply in person. 9030 W; Ft Island Trail, Suite 9-A, Crystal River. MRI/CT TECHNOLOGIST Advanced Imaging Center at the Villages Position Immediately available for MRI/CT Technologist. Competitive salary with benefits. Fax resume to 352-205-7551 or call 352-750-1551. Nurse Practitioner F/T with Benefits, for a busy GIl doctors office, Fax resume to (352) 563-2512 NOW HIRING CNA's/HHA's or People who would like to become a CNA . CALL LOVING CARE P/T X-RAY TECH Phlebotomist P.T.. 8-2. M-TH Fax resume to: (352) 795-9205. Physical Therapist Needed for PERM. Full-time or Contracted position. Mon. Fri, 8a-4:30p working with in-and out-patients. Hospital setting. GREAT PAY!I Work where you know you make a difference and are appreciated, Work for the best Agency around Interim HealthCare Staffingll Easy & quick hiring process. Paid time off, Instant Pay, Great /kI i1rn r...ri r. other ,... I .I '."j Pamr 352-572 8072 / 866-356-9723 or E-mail: PamBlairinterim @aol.com -VI-0 JL-IUDAYaEFIV-N CYR Medical *BARTENDERS *COOKS *SERVERS High volume . environment. Exp. preferred. Positions available in Inverness & Dunnellon. COACH'S Pub&Eatery 114 W. Main St., Inv. 11582 N, Williams St., Dunnellon EOE DISHWASHERS/ SERVERS Apply at: Fisherman's Restaurant, 12311 E Gulf to Lake Hwy, Inverness 352-637-5888 Exp. Line Cook & Walt Staff Exc, wages. Apply at: CRACKERS BAR & GRILL Crystal River ;ti imuhK 4-.:), zuu-, for day and night shift available. Apply in person to Metal Industries, 400 W. Walker Ave., Bushnell, Fl 33513 or call Rhonda Black at 352-793-8610 for more details. Excellent benefits package, 401k with company contributions. DFW, EOE MASONS & MASON TENDERS Steady Citrus Co. work. $10/hour to start. Start Immediately 352-302-2395 MASONS & LABORERS Must have own trans. 352-795-6481 or 352-302-3771 CITRUS COUNTY (FL) CHRONICLED CLASSIFIED PT/FT POSITION IN ORTHO. OFFICE Ins. Billing & Acct. Receivable exp. necessary. Immediate opening. Fax resume to Nettie e-mail resume to: tcvpreWlavante 9l.UR. COm RNs Needed immediately for Facility Staffing! 13-week Contracts, full-time and PRN, shifts available. Hospitals, Doctor Ofcs, etc. Great Pay! Work for the BEST agency and get benefits tool! Paid time off accrual, daily pay, health Ins. avail- able; with flexibllitylll Easy orientation process Call Pam 352-572-8072 or 866-356-9723'or Email me todaylI PamBlairlnterim @aol.com RN'S LPN'S CNA'S Instant Payl Great Payl Apply online -E FULL CHARGE BOOKKEEPER Quick Books Pro Exp Preferred. Good Working Environment] Pay & benefits. Mon-Fri 8am-5pm Apply at 352-726-7474 Pro Line Boats Now Hiring in Accounts Payable & Purchasing: Accounts payable must have exp. w/ Lotus, Excel & switchboard. Purchasing must have exp. placing & tracking orders & have good communi- cation skills. Full Time w/ good pay & benefits. Including: Heath & dental Ins. 401K, Holidays & vacation. Fax Resume to: 352-795-1275: EOE /DFWP *LICENSED, EXP. PROPERTY MGR. *EXP. REAL ESTATE SECRETARY 352-795-0784 BARTENDER ' Energetic & enthusiastic bartender for nights & weekends. Apply In person to Lars-Manatee Lanes. DFWP FT WAIT STAFF & FT COOK For Retirement living facility. Positions Include vacation after Jan. 1st. Health Insurance available after 60 days Apply In person Brentwood Retirement Community Commons Building 1900 W. Alpha Ct Lecanto 746-6611 EOE, DFWP VAN DER VALK FINE DINING HIRING LINE COOK & DAY TIME SERVER Please contact (352) 637-1140 $$$ SELL AVON $$$ FREE gift. Earn up to 50% Your own hrs, be your own boss. Call Jackie I/S/R 1-866-405-AVON RV SALES PERSONS See Jerry Laverne COMO AUTO SALES 1601 W. Main St. Hwy. 44, Inverness I- i ni i Color Country Nursery Is looking for Career Minded, Self Motivated dependable Individuals for SALES HELP, PLANT CARE, LANDSCAPING, ETC Pay commensurate w/experience. Please apply in person at: 1405 W. Hwyy44 Lecanto Previous work history a must. Mon-Fri 9am-4pm Drug Free Workplace NO PHONE CALLS PLEASE Previous applicants need not apply. EOE INDEPENDENT SALES REPS Air/ water purification Retirees welcome. (352) 684-1373 Looking for Career Minded Self Starter Dependable with flexible schedule. Mall resume to 255 E. Highland Blvd. Inverness 34452 SEASONAL P/T SALES Includes weekends. Retail boutique exp. preferred. Fax resume: 352-563-1667 $$$$$$$$$$$$$$$I CMD INDUSTRIES 352-795-0089 AN EXP. FRAMER & LABORERS NEEDED (352) 637-3496 BLOCK MASONS & HELPERS DRIVER/ SERVICEMAN Monday thru Friday 8-5. Must have CDL with Hazmat. Class B. Apply in person at: Economy Tru-Gas 6654 W.Gulf to Lake Hwy. Crystal River DRYWALL STOCKER Needed for Building Supply Co. Monday thru Friday, 7am-5pm, (352) 527-0578 DFWP ELECTRICIAN APPRENTICE Immediate openings! Will train If necessary Gaudette Electric Inc. Apply in person or on-line Electric.com Or call 352-628-3064 FINISHER NEEDED Must past back- ground check, must have own hand tools, pay rate based on exp. & skills, contact 352-637-9225 for Interviews EXP. ELECTRICIAN For Service Work Must have valid Florida drivers license, top pay w/ retire- ment package. Call 352-465-4569 To set up interview EXP. MASON TENDERS Must have own trans. 352-628-5651 EXP. PRESSMAN Wanted Immediately to run Ryobi 3302 Press For Process Color Fax Resume to: 352-795-2980 Exp'd Plasterers, Apprentice; Lathers & Non-Experienced Laborers Wanted ?tead',' wor' and paid .,acrl.,rn i[r 3rpportor. r a r.u.' r. .i ..:.p o.n: 527-4224, Iv msg EXPERIENCED BUCKET TRUCK OPERATOR For Busy Tree Service. Must have CDL Good benefits & pay. (352) 637-0004 EXPERIENCED MAYCO CONCRETE PUMPER WANTED Start at $13. hr. &up Call for interview, (352) 726-9475 INSTRUMENT MAN OR CREW CHIEF needed for Crystal River Land Surveying Company. 352-563-0315 KELLY'S HEALTH CLUB NOW HIRING Smiling, Friendly Faces, must be good with people. Please no ohone calls. Apply in person. 6860 W Kelly Ct. Crystal River LAKE COUNTY COMPANY NEEDS *FINISH DOZER & GRADER OPERATORS 5 yrs exp,. DFWP Call Ron at 352-267-5352 .-~ _- --- a --"- RME%-- Manufacturer of A/C grilles, registers and diffusers has immediate openings. *Production Workers per week, Apply Cash Carpet & Tile 776 N Enterprise Pt Lecanto(352) 746-7830 POOL MAINT. TECHNICIAN Needed Full Time w/ benefits. Experience necessary. Apply in person: 2436 N. Essex Ave (352) 527-1700 ROOF TRUSS PLANT Now hiring truss builders. Full time. Will train. Apply: 2591W. Hwy. 488, Dunnellon 352-465-0968 FRAMERS & LABORERS NEEDED (352) 726-2041 MECHANIC Exp. Heavy Duty Truck (352) 344-2544 METAL BUILDING Erectors, Laborers All phases pre- engineered bldgs. Local work. Good starting salary. Paid holidays & vacation. Call Mon-Fri, 8-2, toll free, 877-447-3632 PLASTERERS/ APPRENTICES 352-302-7925 r PLUMBER 4 I S Starting Wage * between $16-18/hr. Benefits, Health, I Holidays & Paid | Vacation. 621-7705 PLUMBERS & HELPERS- For Commercial Work Call 1-800-728-6053 PLUMBERS' HELPERS Exp'd preferred, Full time. 621-7705 Plywood Sheeters & Laborers Needed In Dunnellon area. (352) 266-6940 POOL CAGE INSTALLERS Exo. Only. To LABORERS PLASTERERS (352) 302-5798 TILE/CARPET INSTALLER Experienced only West Coast Flooring 352-564-2772 WAREHOUSE PERSON Experienced, apply Accent carpet, 3232 E Thomas St. Inverness. WEST COAST RELIEF DRIVER Approx. 2 turns a month in new equipment. Reefer exp. Class A CDL, non-smoker. Call Tony at 1-800-451-7022 A/C LEAD CHANGEOUTS & SERVICE Needed Immediately $15 Hourly & Upl S(3 2) A982R-57nn 4 r2 LOT PORTERS I I See Jerry I COMO AUTO SALES 1601 W. Main St. | Hwy. 44, Inverness Color Country Nursery is looking for Career Minded, Self Motivated dependable individuals for SALES HELP, PLANT CARE, LANDSCAPING, ETC Pay commensurate w/experience. Please apply in person at: 1405 W. Hwy 44 Lecanto Previous work history a must. Mon-Fri 9am-4pm Drug Free Workplace NO PHONE CALLS PLEASE Previous applicants need not apply. EOE Exp. Dump Truck Mechanic Top wages Bailey's Trucking 352-585-6455 F/T Office Cleaner Nights & weekends. $7 per hour to start. Lecanto area (352) 344-8567 FULLTIME POSITIONS In a challenging career of roofing. Must be 18 and drug free, No exp needed. Apply in person, Boulerice Roofing & Supply, 4551 W. Cardinal St., Suite #4, Homosassa. Gardener Maintain business/ home/empty lots, knowledge & complete upkeep of maint. of these outdoor spaces. Sm. engine repairs a plus. Ideal for energetic retiree. Call 352-465-5015 for details and interview. GENERAL MAINTENANCE Part Time/Full Time Hours Vary. Able To Work Weekends. Able To Lift 50 Ibs. Relate Well To People. Accepting Applications. Rainbow Rivers Club 20510 The Granada Dunnellon (352)489-9983 GLAZIERS Experienced MIDSTATE GLASS (352) 726-5946 Fax Resume to 352-726-8959, Inverness GOLF COURSE IRRIGATION TECH. NEEDED Pay DOE. Apply Seven Rivers Country Club, 7395 W. Pinebrook St. JOBS GALORE!!! EMPLOYMENT.NET LABORER NEEDED For Local Curbing Co., Exp Pref, trans req., will tralnl 563-1981 LABORERS Mobile Home Set-Up for MH Services (352) 628-5641 7075 W Homosassa T1 LABORERS NEEDED No exp. necessary Benefits offered. Valid Drivers Uc. & Heavy Lifting Required Gardners Concrete 8030 Homosassa Tr. MR B'S CAR WASH Help wanted. Apply in person only. No phone calls! 750 S.E. U.S. Hwy. 19, Crystal River MUNRO'S LANDSCAPING Is seeking exp'd land- scaping personnel. Must have valid driver's license. (352)621-1944 OFFICE/SALES ASSISTANT Individual w/ excellent organizational & customer service skills needed. Must be able to multi task. 35-40 hrs MUSIC DIRECTOR Position Open at First United Methodist Church of Dunnellon Send Resume to: 21501 W. Hwy 40 Dunnellon fl 34431 No Phone Calls - SATELLITE INSTALLER Company Truck, Overtime + Commission, Paid Vacation. 860-1888 TOWER HAND Bldg Communication Towers. Travel, Good Pay & Benefits. OT, DFWP. Valid Driver's License, Steady Work. Will Train 352-694-8017 Mon-Fri Truck Driver/Rolloff Equip. Operator Sand Land of Florida (352) 489-6912 WAREHOUSE Position available. Heavy lifting, fork lift use & driver's license. Michael's Floor Covering. 341-0813 WE BUY HOUSES Ca$h........Fast I 352-637-2973 1homesold.com. (352) 895-1400 ACCOUNTING Also Gen. office duties. Corp. tax. prep, Using Peachtree & Pro Series, (352) 489-0202 ADVERTISING NOTICE: This newspaper does not knowlingly accept ads that are not bonafide employment offerings. Please use caution when responding to employment ads. g-4 TELLER POSITION AT CENTER STATE BANK CRYSTAL RIVER OFFICE Previous bank or cash handling experience preferred. Please call 813-780-4274 for application. EOE HOUSE CLEANING BUSINESS Over 40 accounts & all equip, included, asking $10,000. obo, Call for details. 352-527-8000 LIQUOR LICENSE 4 COP Citrus County On-site Consumption ni ,- 35l2n -c2nnn -jl22 20 Cubic Ft. Sears Upright Freezer, frostfree Like new, $175. (352) 795-5228 After 6pm Cleanina Visa, M/C., A/E. Checks 352-795-8882 Chest Freezer, $50; Small Dryer $50. (352) 628-0831 FEDDERS12,000 BTU HEAT & COOL, 220 volt, 18x26, works great, $110. Haler mini refriger- ator/freezer, brand new $100. (352) 637-6407 ELECTRIC STOVE, almond color, $25. Refrigerator, $20. 352-344-5049 GE FREEZER Upright GE Freezer with shelves. $100.00. Call 352-746-9109 after 5pm. GE MICROWAVE $50; (352) 795-5096 GE Washer & Dryer Washer 3 yrs old, dryer 6 yrs old, needs timer. Extra large capacity. $125 for the pair. (352) 563-1518 HERNANDO Big yard sale. Fri. & Sat. Washer, dryer, sm. freezer, exc. cond. Queen bed, head & foot board, Irg. & sm. turn. Can't list all. Misc. Household items. 4289 E. Louisiana Lane, off Hwy. 41, look for signs REFRIGERATOR, Magic Chef, Side by side, 22 cubic ft, water in door, almond, Exc cond, $325 obo (352) 860-2945 STOVE $200: RANGE HOOD, $25 (352) 795-5096 Beautiful Rosewood Office ensemble. 2 desk spaces, book- shelves, glass disp. cab., lots of shelves. $1500. (352)726-6791 Tag Sale/ Auction Sept. 28 @ 8am edandsuemesser.com AU252 AB1015 AIR COMPRESSOR, horizontal tank, recent motor, $65. Ext. ladder, very good cond, $40. (352) 746-7856-'A" FLOOR " T DRILL PRESS, $175 7'i .-l2" PORTABLE PLANER $125 (352) 344-5831 Mechanics Tool Box, standing on wheels Craftsman, 13 drawer, $250. (352)341-2259 2 AUDIO SPEAKERS, Polk, model rl 5, black ash Vinyl, 105/8"H x61/2"Wx71/4"D $20. FM STEREO, Sony, FM/AM Receiver, model D\STR-DE185 $30. (352) 746-9504 WOW! If really pays fo work ftor he If you would like to run your own business with a focus on customer service, we would like to talk to you. As an independent distributor delivering the . Citrus County Chronicle. you knc..A you re proa.dring a quality product ak'.ved ',- a company that's been in business for more ilan 100 years YOu musI ha'e reliable iransponaiion, be at leasi 18 years old and be seriou aoiul wo r 2iang early morrng riours. , seven da)y a wee' If this snoundS I.he a business rppnunrity ,, tha s rignt for you cal 8h 2.ee a Cnrc.nirte at 1-352-563-3282. C I' Ii)R"N-I( A CA-" General c= Help 0 -~0 Advertise Here for less than you think!!! Call Today! 563-5966 Trades c.n /Skills I Dale Earnhardt Print by Sam Bass, "Future is Now" No. 26 signed by Dale & Dale Jr. Angela Trotta Thomas train prints, first 5, Artists Proofs No. 3/25 Naberkid Dolls, early 90's, 352-621-0286. HANDCRAFTED MINIATURE DOLL HOUSES. 3/4" scale, all cedar, 19" wide, 21" long, 22" height. Also 12" wide, 26" length x 22" height. Both $90. 795-2625 HOT TUB/SPA, 5 person, like new, 24 jets, Red- wood cabinet, 5 HP pump. Sacrifice $1475 (352) 286-5647 SPA W/Therapy Jets. 110 Svolt, water fail, never used $1795. G neral C= H :lp - IW-- Copyrighted Material " Syndicated Content Available from Commercial News Providers r 4DFRIDAY.SEPTFMBER 23. 2005 CONSTRUCTION SUPERINTENDENT DECCA Is seeking a Experienced Home Builder for a diverse supervisory position. Decca Offers; Great Benefits....... The Following Are Available To Full Time Employees: * 401K * Medical Insurance * Dental Insurance * Ufe Exp'd and reliable. Masons starting at $18/hour. Helpers starting at $10.50/hour. 352-400-0274 352-220-9000 BOXBLADE OPERATOR Experienced with clean driving record. 352-621-3478 dfwp C PROGRAMMER Additional skills preferred, Apache, PHP, MYSQL, Python, Please call (352) 344-5618 CABINET SHOP All phases 352-795-5313 Cable Modem Installer HDTV, VOIP. Truck/Van/ SUV req. Start now $800-$1000 wk. Will train hard working Individuals, Call 386-785-0911 "LIVE AUCTIONS" For Upcoming Auctions 1-800-542-3877 2 Antique High chairs Cane bottoms, $200 each. (352) 621-0286 40 Yr. Camera Collection, over 100 cameras & accessories, $1000 (352) 621-4927 ANTIQUE BRASS BED with rails, fullsize, $400 obo (352) 726-8021 FRIDAY,SEPTEMBER 23, 2005 5D '40" Mitzublshl Colored Television. Glass picture tube,W/Stand, Like new cond. $400. (352) 746-9311 AM/FM STEREO RECEIVER Plus Multi CD player + Multi cassette player. All 3 Pioneer, exc. cond. Incl. extras $500. (352) 344-5436, after 6p I Comp. Entertainment Center w/Hitachi 52" Ultravision digital HD TV, w/surround sound & custom built cabinet. $1200. (352) 465-5361 Complete Entertain- ment Center, Toshiba 36" free standing TV, w/ pioneer tuner, double cassette player.multi -play compact 6 disc player, VCR, 3 design acoustic speakers. $400. (352) 382-0022 ' HP Computer Package, Incl. printer, scanner, 15" monitor, desk & chair $500. (352) 860-2205 NEVER USED MP3 DIGITAL PLAYER, many features, $65 (352) 344-0293 Oak Computer Desk, SHutch, printer stand. Locking drawers, solid & heavy. Cost $1000 new. Will sell for $400. (352) 489-0882 PC COMPUTER Complete, Internet ready, WIN 98, $100 (352) 726-3856 PC, Win XP.Pro, Office XP Pro, dial-up, dsl, cable space internet ready, excel. cond. complete system. $150. (352) 220-8608 '05 FARMTRAC w/loader, 5' bushhog;. 5' boxblade, 13 hrs. 27HP diesel, $14,000 (352) 637-3188 SNEW 25HP 4X4 E? .:.,I ,i :l turf tires, car.op, I yr. warr. $5,995. (352) 400-1430 -A Lanai Furniture 4 chairs w/ rollers, 42' table, 2 lounge chairs, 1 straight back chair w/ ottoman, roller cart & outdoor lamp $400. (352) 527-9735 PATIO SET, 10 pc. PVC, hexagon 43" table w/4 chairs, 1 lounge chair w/ottoman, 1 coffee table, 1 loveseat, I lamp tbl. white, $300 352-746-5051 9a-3p SWIVEL BAR STOOLS,CHROMCRAFT Brand new, never used, paid $590, asking $390 firm. (352) 527-3367R CITRUSCCOUNTffr ALAN NUSSO BROKER Associate Real Estate Sales Exit Realty Leaders (352) 422-6956 BED: 155, New Queen. No Flipped Pillow Top ISet. 5 yrs warr, King Set $195. Delivery 352-597-3112 BED: 495 Nassa Memory Foam Set, Seen on TV. 20yr Warr. Never Used. Cost $1399. Can Deliver 352-398-7202 Bedroom set 4pc Like New including mattress and box spring, $600 obo (352) 228-0460 BUNK BEDS Red, like new, bottom full size. top twin size $150. (352)341-4449 CHESJ OF DRAWERS $50; COMPUTER DESK, $25. Both in good cond. (352)465-1934 CHEST OF DRAWERS Solid Oak, 2 top Drawers, Armoire & Vanity. Very unique. Excellent cond. $80. (352) 628-2119 COUCH, brown & blue w/ 2 built in recliners, nice cond, $100. Wood Bar & 2 matching stools $75. (352) 628-5358 Country dining room set, inc. 4 chairs, 2 Ig. ext., china cab. & sideboard. $350. (352) 746-3842 Futon Brand new, $150. (352) 637-0634 Girl's Bedroom Furniture 6 & 3 drawer dressers, desk, hutch, chair, mirror, $350. ORO (352) 344-4505 GOLDEN OAK dining table, 5 chairs, matching china cabinet- lighted. Priced to sell, $400. Pine Ridge, (352) 527-7732 GREEN BROCADE COUCH. Exc. cond. Ask- ing $350. Exeptionl style mirror, table + wall mirror, exc cond, asking $450. (352) 746-5445 KING KOIL FULLSIZE Mattress, boxspring & frame. Spotless, $65 obo (352) 726-8021 King Size Simmons BackCare Pillow Top SMattress& Box Springs. Hvy. duty frame, pad & sheets, excel, cond. $75. (352) 382-2687 King size soft side waterbed, $500; China Cabinet, $60 (352) 795-5096 KITCHEN & DINETTE SETS, 4 chairs In each, $50 & $100. LARGE COMPUTER DESK, $50 (352) 527-3199 Kitchen Set $60. obo Grill $70. obo (352) 564-0195 LARGE SOLID LITE OAK Entertainment Center Only 1 year old, perfect condition. Paid $1100, will sell for $750. (352) 447-4270 Leather Loveseat & Matching OS chair. exc. cond. $350 Sofa, Ivory Brocade, 78", 3 seat, like new, $200. (352) 726-4324 LIVING ROOM SET NEW. Couch, loveseat, light multi- recliner, light blue, like new, $50. (352) 746-7856 NICE CALIFORNIA KING bed with headboard and dresser. $550. (352)637-0108 PAUL'S FURNITURE We're Open Again Store Full of BargalnsI Tues-Sat. 9am-2pm Homosassa 628-2306 PIANO, needs tuning, $70 SLEEPER COUCH, $35 352-344-5049 QUEEN SLEIGH BED headboard, footboard side rails vllle chair, Org., $1300 Asking $595 OBO. , (352) 746-0688 Rock Maple two pc. dining hutch & buffet, $350. obo Ethen Allen Qn. sz. Sofa Bed $150. obo (352) 382-5756 FULL/QUEEN BED with head & footboard, $175. (352) 527-3199 SIDE TABLE, light oak, 18"x22"x19' high, $25 DRESSER BASE, 6 draw- ers, blonde finish, 18x52"x40 high, $50 (352) 344-9668 SLEEPER SOFA & Matching Love Seat $175; 2 TWIN BEDS, frames & headboards $95. (352) 382-7335 Sofa & Loveseat white brocade covering, very good condition, $150. (352) 726-3681 SOFA/LOVESEAT Bassett, Contemporary, Exc Cond. $300 both or make offer. TABLE & 4 Chairs, $50 (352) 476-8828 SOLID MAPLE WOOD Dresser, with original metal drawer handles, $35. WHITE PLATFORM ROCKER, good cond., $25. (352) 860-1889 Solid Teak Dining Table, 8 chairs, very unusual $1,500. (352) 795-0527 TABLE, 4 CHAIRS, suede mocha color, 2 match- Ing bar stools, $900 obo OAK CHINA CABINET $500 obo All exc. cond. (352) 746-0196 The Path's Graduates, Single Mothers, Needs your furniture. Dining tables, dressers & beds are needed. Call (352) 527-6500 Trundle Bed with headboard Like new $75. (352) 795-5228 After 6pm Twin Bedroom Set Complete room. Like new. $1,500.00 OBO (352) 613-8039 White Leather Sofa & Loveseat $300. 2 yellow upholstered chairs 2 for $125.(352) 527-8868 Wood Bar With TiM Top & 4 Stools $1,500. (352) 795-0527 2 GRASSHOPPER MOWERS- 1996 721, Kubota eng. $1,500. 1999 618, new 18HP B&S Vanguard eng. $2,500 or $3,000 for both. (352) 860-1135 32" Torro Rider w/ bagger, 8HP Brigg's engine, $350. (352) 527-0749 DUNNELLON Sofa, chairs, clothes, lamps & many household items, Fri & Sat 8-3 * 8485 SW 209th Court NEW UTILITY DUMP CART, in carton, $75 (352) 860-1889 NOW AVAILABLE AT GUNTHER'S FARM, FEED & NURSERY' Wholesale Patio Stones prices as low as .99sqowers, 30"Murray 10hp, $200. 36" Bolens, 11 TROY-BILT LAWN TRACTOR 42" 16HP Kohler engine, w/bagger, exc. cond., $700 (352) 726-4715 YAZOO tractor mower, areat EXTRA LARGE CENTURY PLANT, $30 LARGE CENTURY PLANT $20. (352) 726-8361 BEVERLY HILLS Entire contents of Living room. Call after 9am (352) 613-4940 BEVERLY HILLS ESTATE SALE HOME FURNISHINGS 29 S Monroe St. Fri. Sat. BEVERLY HILLS Fri. & Sat., 7- 12N Hshold. Items, turn., etc. 1889 W. Bagonia Dr. BEVERLY HILLS Sat. Sept 24, 8 3pm 10 Illinois Avenue off Barbour Street BEVERLY HILLS Super Sale Sat.only 8-4, 316 S. Washington St. BEVERLY HILLS Yard Sale, adjustable bed, oil paintings, art supplies & more. Fri, Sat. 9-4. 36 S. Jefferson St. BRENTWOOD MOVING SALE 3 bdrm house, all must gol Sat. 9-4, Sun. 10-1 1971 W Marsten Ct. CHASSAHOWITZKA Fri. & Sat., 8 3 pm 8371 W. Dixie Court CITRUS SPRINGS 2332 W. Green Ct. Baby Items, clothes, toys, furniture & misc. Fri. & Sat. 8am-1pm. CITRUS SPRINGS 3868 W. Findlay St. near elementary school. Saturday, 10-4 CITRUS SPRINGS Estate Sale Fri & Sat 9-2 9791 N. Elkcam Blvd. CRYSTAL RIVER Fri-Sun.2566 N Reynolds Av.Dolls,JDmower,more Dunnellon Antiques, books, horse items, new lego's, cam- era, misc. Fri & Sat. 8-4. St. Rd. 488 next to Feed Store FLORAL CITY Estate Sale. Too much to list. Good quality 9a-9p (352) 860-1885 (352) 697-2290 FLORAL CITY Fri & Sat 8am-3pm Maple Table & chairs, Novelties, some collectibles, Dale Chave Tack,& more 9805 S. Istachatta Rd FLORAL CITY Sat. 9am-? Furnishings from foreclosed houses. All contents of house, lots of furn, appliances & Christmas deco's End of S. Heather Pt. Follow Estate Sale signs INGLIS Fri. & Sat. 8am 1pm No early birdsll Crafts decor. items and more 18134 SE Hwy. 19 2.5 mi, N. of Inglls Inter. INVERNESS SATONLY 8am-2pm Boat Motor, Tools, Furn, & Misc. 8715 E. Devonshire Rd Off Gospel Island INVERNESS ESTATE SALE Dining & Bdrm sets, appliances, orchid & sewing sup- plies. Fri. Sat. 8a-3p. Kimberly Lane RAIN OR SHINE! INVERNESS MOVING SALE, Sept. 24, 8-2p, 1219 Orchid Ave. (352) 344-5185 INVERNESS Thurs, Fri, Sat. 2 Family Yard Sale, Bass Circle LECANTO Multi Family- Fri. & Sat. 9-2 South Easy Street LECANTO Sat. 8-3, Sun,11-3 700 N. Enterprise Pt. 3 Rivers Commerce Park E. of Stokes Flea Mkt. Books, tools, etc. PAUL'S FURNITURE We're Open Again Store Full of Bargalnsl Tues-Sat. 9am-2pm Homosasso '628-2306 PINE RIDGE ESTATE SALE HOME FURNISHINGS 4693 W Tomahawk Dr. off Mustang. Fri. Sat. 8-4 PINE RIDGE Moving-in sale. Too much stuff. Fri. & Sat. 8-4. 3409 W. Promontory SUGARMILL WOODS 5 Plum Court MOVING SALE Fri. & Sat. 9-4 (352) 382-4841 2005 SPECIALS 6 lines 10 days Items totalling $1-$150...........$-.50 $151-$400......$10.50 $401-$800.......$15.50 $801-$1,500....$20.50 CALL CHRONICLE CUSTOMER SERVICE 726-1441 OR 563-5966 Two general merchandise items per ad, private party only. (Non-Refundable) Some Restrictions May Apply 1HP PAINT SPRAYER needs comp., good motor, tank & gauges. $20.-(352) 628-5708 14FT ALUM. BOAT 5HP motor and trailer, $850 4X8 UTILITY TRAILER $200 (352) 344-5831 18FT ABOVE GROUND POOL, brand new Hay- ward filter, all access. Must take down. $500 obo (352) 726-0289 ANTENNA TOWER, 50'. First $75 takes it. (352) 628-7050 CARPET 1000's of Yards/In Stock. Many colors. Sacriflce. Uc#0256991 (352) 422-5000 DRINK COOLER $200 352-637-5262 Eureka 12amp Excalibur tank sweeper, like new cond. $45., Freespirit bicycle, 10 speed, good cond. $35. (352) 637-4453 FOODSAVER V835 Only used a few times. W/acc. $50.00 Sony surround sound $65.00 Call 795-1140 FREE OAK FIREWOOD 8' LONG- COULD BE USED FOR FENCE POST OR FIREPLACE. (352) 560-6137 GE Washer Dryer Large capacity, $395. Like new (352) 746-2382 GENERATOR HONDA 13HP, 6800/7800 4 hours, extension cord, $999. (352) 795-3091 GENERATOR 10HP 6250 watt, used one week, $600 (352) 637-7150 GENERATOR 4kw, Bns/Coleman, used very little w/ manuals.$270, (352) 628-4522 GOT STUFF? You Call We Haul CONSIDER IT DONEI Moving,Cleanouts. & Handyman Service Lic. OIL PAINTING 29x53, framed, old mill & bridge scenery, $100 OIL PAINTING 22x26, fruit scene, framed, $30 (352) 344-9668 Pallet Jack $175. (352) 726-6034 PATIO FURNITURE metal 5-pc. New, $1,200 or sell $300. Power Washer, $60 (352) 860-1731 Xerox copier XC 830 ,$75. Misc. office supplies, $50. (352) 860-1731 POOL COVER blue plastic, large size $20. (352) 344-4591 ggJL 18', filter system & ladder, $500. ' Dinette Set w/ table, 4 chairs & 2 leafs, wood $400. OBO.. (352) 341-1982 SLEEPER SOFA, 6'6"L, lime green with flocked white & yellow flowers, spindle arms good cond. $80. Pro-Form treadmill, model 565 Space Saver, used very little, $200. 746-5516 VALLEY weight distributing hitch and Reese straight tongue adapter with instruction sheets. $150. (352) 746-0321 WE MOVE SHEDS 564-0000 WHITE DOOR Inside, .24x80, with hardware, $20. VENITIAN SHADE 72" wide by 52" long, 1" slats, white, $15 (352) 344-9668 Xerox copier XC 830 $75. Misc. office supplies, $50. (352) 860-1731 CRAFTMATIC TWIN BED good mattress $100. Breast pump(electric) $100. Call Meg 522-1029 Electric Hospital Bed, walkers, commode, bed lift, trapeze bars, /All for $425. (352) 344-2500 JAZZY ELEC. WHEELCHAIR, $650; THRESHOLD ALUM. Portable ramp, $50. (352) 527-3276 LIFT CHAIR electric, like new, hardly used, Cost new $800 Asking $345. Firm. Pine Ridge (352) 212-9593 LIFT CHAIR, tan, large, $350. Occasional chair, gold brocade. $40. Both excellent. (352) 628-2119 CITRUS COUNTY (FL) CHRONICLE From Crib to Toddler to Regular daybed. Mattress not lnc.$60. (352) 795-5905 COLLECTOR BUYING TOY TRAINS Any kind any amount, top cash paid call (352) 257-3016, If no answer leave message. Grandpa's Old Fishing Tackle, equipment, pictures top $$ paid Call Bob (352) 628-0033 I WANT TO PURCHASE In good condition: 8-track cassette player/ recorder. 352-465-7884 TOOLS OF ANY value, rods, reels, tackle, collectibles, hunting equipment, 352-564-2421 ACOUSTIC/ELECTRIC MANDOLIN $100. Basic mandolin, Like new $50. (352) 746-4063 Electric Organ Yamaha Electone Upper & lower key- boards w/ bench & books. Lots of extra functions. Excel. Cond. Moving must sell. $175. (352) 382-0725 Hobart M Cable Spinet Piano good condition $450. (352) 621-8027 VIOLIN plus case Good condition $50 (352) 382-2149 VIOLIN, $500 or trade for banlo- ???? 352-397-5007 YAMAHA KEYBOARD Floor model, 76 keys, very good condition $125 or best offer. (352) 726-9728 Home Gym, Welder, 3 station, Exercise Bike, Wesslow w/ monitor & support for back. Treadmill, Wesslow. Asking $350 for all (352) 726-3111 Total Gym Complete, $350. (352) 795-0622 3 Rain Suits Sz. Medium, US army, West Marine, Mariner, all new $60. (352) 795-4405 12 Point Elk Wall Mount $250 (352) 621-4927 Bicycle, Giant, Cypress ST, .19", mint, 21spd., great bike for trail & around town, $100. (352) 637-2153 CLUB CAR Loaded $2,900. (352) 795-0527 FLYFISHING EQUIP- Teton 10 wt reel w/9 wt rod. 350 + saltwater flies, box full of fly tying equip. $400. (352) 527-2792 GO-CARTS 2-GX150 Go-carts. 2 seats 1300ea or 2000 both.Call 382-1678 GOLDEN EAGLE BOW "Lightspeed", like new $200 (352) 527-2792 Older Golf Cart Good Cond., new batteries w/ charger $1000. (352) 637-6557 Penn 310-GTI Reel w/rod, $70; Penn 320-GTI Reel w/rod, $80. (352) 527-2792 POOL TABLE 8 ft. Slatetron, for sale $500. (352) 341-0015 POOL TABLE, Gorgeous, 8', 1" Slate, new In crate, $1350. 352-597-3519 16' Trailer w/Ramps, duel axle, stainless steel bpx on tonge, chains & binders Inc. $1,200. (352) 726-1187 (352) 650-2601 23FT TRAVEL TRAILER, exc, shape, $2,900 , '96 ENCLOSED 20'x8'x9' exc. $4,500 (352) 726-4710 302-4310 BUY, SELL, TRADE, PARTS REPAIR, CUSTOM BUILD Hwy 44 & 486 EQUIPMENT TRAILER Tandem axle, Lowboy, tilt bed, $800 obo (352) 628-2769 Top,of the Line, 7x 14 Enclosed Trailer Tandem axle, as new $3,900. (352) 746-6212 (352) 397-5007 CONVERTIBLE BED Skyline, Southern Energy 352-628-0041 - 866-466-3729 homesfl.com ATTENTION BRAND NEW DOUBLEWIDE Deliver and Set Up $35,900 Includes 10 Year Warranty. Homemart Mobile Homes (352)307-2244 NOTICE Pets for Sale In the State of Florida per stature 828.29 all dogs or cats offered for sale are required to be at least 8 weeks of age with a health certificate per Florida Statute. 2 Animal Cages Very nice Caage w/ double doors & slide out cleaning tray for a lizard, ferret or bird, $1250BO DoQggen w/ door, -$125 OBO. (352) 637-3620 (352) 613-3006 4 FEMALE YORKIE PUPPIES. Ready to go in 2 weeks. Taking deposits. 352-628-6914 AKC BOXER PUPS 6 weeks old Champion bloodlines. Taking de- posits, (352) 637-3599 AKC GERMAN SHEPHERD PUPS Ready on 10/04 (352) 489-7031 Canaries, females $55. males $65, Singers garaunteed. (352) 489, $60. ea. parents on premises 1. #esc 7203 (352) 726-5422, 9-3pm (352) 212-6225, 3-8pm Humanitarians of Florida Low Cost Spay & Neuter by Appt: Cat Neutered $20 Cat Soaved $25 Dog Neutered & Spayed start at $35 (352) 563-2370 LIONHEAD RABBITS New Dwarf Breed Show & Pet quality. All colors, both sexes Pedigree, Great for 4H or FFA projects, $50-$75 352-344-5015/476-3843 MINIATURE POODLES Apricot,. male, female (352) 476-3282 or (352) 344-1861 SABLE & WHITE male Collie. 1 yr old, $300 obo. (352) 795-7513 Shih Tzu 9 wks, Cute & Cuddly (352) 465-6659 SHIH IZU PUPPIES CKC Reg., w/ 1st shots & papers, unique colors $500. (352) 628-5249 3 YR. OLD BUCKSKIN FILLY, ready to train your way, $700/obo 16 MO. OLD PAINT male, $1',000/obo (352) 795-4525 ALPACAS The Huggable Investment, Call for information, 352-628-0156 PIGS; 8 wks. old $35. Also Sow & Boar, $150. (352) 564-0258 -U DW 2/2 $525 up IBR furn w/carport $450 up. No smoking, no pets. (352) 628-4441 HIGHWAY 488 Lg., extra clean 3/2, Ig. FI rm., no pets. $700. $500.00 DOWN FHA Financing 1st time buyer, poor credit, recent bankruptcy, we have financing available. New 3 & 4 bedroom homes up to 2300 sq.ft, with land available. Call 352-621-9181 12X50 MOBILE HOME for sale by owner. 1/1, AC. furnished. Must Sell! $6950. 1-888-282-1912 12X60 MOBILE HOME Ready for you to move.$ 150. (352) 726-0321 2/2 BDRM 24'X50' needs some work. $5000+Moving expenses. (352)489-2063 (352)219-0057 SAmerican Homes your Discount Dealer for Homes of Merit, Call for directions 352-621-0119 33' Vacation Home in Turtle Creek Resorts ww carpet, fridge & stove, 20' scr. porch w/ carpet, 20x11 carport, $16,000.(352) 628-4608 CRYSTAL RIVER 55+ Park, like new inside & out. 2/11/2. By owner. Never smoked in, $16,500. (423) 476-3554 FOR IMMEDIATE SALE in Inverness Park. 12x70 totally furnished 2 BR Exc. cond. Includes W/D in utility shed, TV. also computer, new dinette set w/4 chairs, front & back porch, recently painted, reasonably priced. (352) 476-4178 4 LOTS ON AIRBOAT CANAL to Witala.. Rvr, Completely SLake Henderson. $115,000. (727) 492-1442 or (352) 726-5292 Over 3,000 Homes and Properties listed at homefront.com. Cdll Bruce at 795-5112 or Jeanne at 564-4158 DOUBLEWIDE 3/2 on 1.32 acres, in-ground pool, Jacuzz, HERNANDO 2/1 $500 1st. last & sec, 352-527-0033 or Iv. msg. HOMOSASSA 2/1, completely remod- eled, pool. Quiet, treed area. Water, garbage, maintenance incl., Year lease $650 a mo. 1st, last, sec. No Pets! 352-628-6700 INVERNESS 1/1 Downtown, W/D hook-up, $400 mo. 344-8584 after 6pm or weeeknds INVERNESS Large 2/1. carport, Irg. porch, downtown area, Crystal Palms Apts 1& 2 Bdrm Easy Terms. Crystal River. 564-0882 - eno~la CRYSTAL RIVER VILLAGE Fully furnished, 2/2 dollhouse. must see. Large double carport. $75,000. (352) 795-6895 Immac. DW 2/2 Cmptr. rm. Scrn. prch. dbi crprt shed. W&D, turn. 55+ pk $39,900 352-628-5977 Over 3,000 Homes and Properties listed at homefront.com -U 2/2 Island C ondo.......................$900 3/2/1 Carport ..............................$850 HOMOSSA 3 or4 Bed,2 BA Ne_.Redu S1,050 32/2 WaterAccess ReducedS1,200 2/1 Duplex ................................$525 2/1/1 New Paint, Carpel......... $675 CHASSAHOWITZKA 2/2 Furnished ........................ $1,000 PINE RIDGE 3/2/2 Pool, Includes pool & lawn Maintenance .......................... $1,600 SUGARMILL WOODS 3/2/2 Pool ...............................$1,800 We HAVE SEAbOALS RE`TA~, CALL FOR LIST Marie E. Hager Broker-Realtor-Property Manager 3279 S. Suncoost Blvd. Homososs FL (352)621-4780 1-800-795-6855 1 Inverness 2/1 duplex near Whispering Pines ...................$475 2/1 duplex in downtown-...$595 2/2 condo in Inverness Landingse..... 3rd.$600 Gorgeous Condo in Laurel Ridge,. 2/2.............$850 3/2 newer home on Stewart Way.. ................. $1000 3/2 home on Liberty. Possible 4'h room.....$1100 Other Areas 3/2 on 3 acres in Floral City........... .................$1000 Pine Ridge 3/2 new home........... ................. $1200 Landmark Realty & Property Management 352-726-9136 645217 Classified Ads from 575 through 660 are sorted by town names to assist you in your search for rental property. House, Cabins@DroDertv manaamentgrouo. com Crystal Palms Apts 1& 2 Bdrm Easy Terms. Crystal River. 564-0882 Large 2/2, family room plus extra Florida room, garage, new appliances, freshly painted, etc, etc. $850. Good area. Call 746-3700 Real Estate Agent 5 BEVERLY HILLS 2/1/1, FIRm, remodeled new carpet & point, $695/mo, 832-444-7796 Janice Holmes-Ray Property Mgmnt. 352-795-0021 We need units furnished & unfurnished 352-795-0021 NATURE COAST BEVERLY HILLS 1/1 CH/A, Fla. rm, Com- plete Long/short lease $650+ (352) 637-3614 BEVERLY HILLS 2/1/1, quiet area, 1st., Ist., sec., $725. mo. 352-795-6525 HOMOSASSA Large 2/1, $200 weekly. clean, 1st., last, security. (352) 628-7862 OZELLO Charming 2/2 cottage on water, appliances, enclosed porch, dock, boat ramp, pool, no pets. $800/month, 1st, sec.dep. Call Scofftt af- ter 4pm, 813-920-6544. YOU'LL THIS 3/2/11/2 on Tamerisk Ave. $875, mo Please Call: (352) 341-3330 For more Info. or visit the web at: citrusyillages BEVERLY HILLS 1-2/1, Carport, commu- nity, pool, $650. mo. 352-613-2238, 613-2239 BEVERLY HILLS 2/1.5/2, New paint, rugs, appl's, windows. $650. + 1st., last., sec. (352) 871-2009 BEVERLY HILLS 2/2/1-202 S Harrison St.pet 200.00 non re- fundable.6 mo. or 1 yr lease. 1st last & owner 865-933-7582 or 865-335-4545. BEVERLY HILLS 2/3/2. complete window coverings, carpet, $900. 1st & Ist Collect, 561-964-5722 BEVERLY HILLS 2BR, C/H/A, W&D, Firm, Carprt. 352-341-8451 BEVERLY HILLS 3/1, clean, carpet, laundry Rm, 382-3525 L CITRUS HILLS 2/2 condos, Furn. privately owned (352) 527-8002 CRYSTAL RIVER 1/1, completely furnish- ed waterfront condo on springfed canal w/boat slip. Seasonal or longterm rental, $1100- $1400 mo. + electric. Includes phone, cable, water, sewer, W&D. (352) 795-3740 INVERNESS Inverness Landings 2/2 eat-in kitchen, enclosed porch. $700/month. 1st, last, sec. dep. 352-341-1847 SUGARMILL WOODS 2/2/1 Villa on Golf Course, Furn. Lawn Serv. Inc. $850, 1st, last & Sec. (352) 422-6030, INVERNESS 2/1, newly painted & carpeted, washer, dryer hookup, no pets/ no smoking. $500 + sec. (352) 637-5598 INVERNESS Brand New Duplexes 2/2/1, beautiful yard, maintained by owner $750. mo. 352-527-9733 FLORAL CITY 1/1 $400 mo. $600 sec. No pets. 352-637-9036 U-Reta CLASSIFIED CITRUS CouN'ry (FL) CHRONICLE 6D FRIDAY, SEPTEMBER 23, 2005 - GM HAS EXTENDED EMPLOYEE 41 DISCOUNT PRICING FOR EVERYONE ctGOO $ Up To 50 . LUNCH SFri,Sat&Sun ' A lani-2pm nev'Y Od~pt *30h 'DOVerbeoffered a@, Less Than Employee Discount Price On Select Models 2005 CADILLAC 2.8L CTS MSRP $31,995 GM EMPLOYEE PRICING LESS VILLAGE SAVINGS Your Price 27y199 STOCK #C50058 Plus tax, title and dealer fees: All factory incentives included. 2005 CADILLAC SRX V6 MSRP $47,285 GM EMPLOYEE PRICING LESS VILLAGE SAVINGS Your Price 38,150 STOCK #C50244 Plus tax, title and dealer fees. All factory incentives included. BREAK( THROUGH 2005 CADILLAC DEVILLE MSRP $46,740 GM EMPLOYEE PRICING LESS VILLAGE SAVINGS Your Price33, 899 STOCK #C50117 Plus tax, title and dealer fees. All factory incentives included. JiTi Z Fi V j t 2005 CADILLAC STS V6 IMSRP $43,610 GM EMPLOYEE PRICING LESS VILLAGE SAVINGS Your Price 38,899 STOCK #C50282 Plus tax, title and dealer fees. All factory incentives included. HOURS: "irr IL L. AG E~ MON..FRI. " -RAM 7:30 PM (352) 628-5100 1-800-852-7248 Service Dept. (352) 628-2100 See our vehicles featured on naturecoastwheels.com OATi.l 96 e-mail us: sales@villagetoyota.com SAT. PM "Vllla gl rio f@p@flnib1i f@f rty i efrpro All s ale prices expire on the Monday evening following publication. Inglis Dwidn ia 8WY f 44 VILLAGE-,nnsimeas Wmcenssa HWY. 98-m Song Soang HiillI Hwy.50 B*%elsi 640901 OPEW- FRIDAY,SEPTEMBER 23, 2005 7D CITRus CouNTY (FL) CHRONICLE C" Ret Hue c= Unfrnishe Cit.Hills Presidential Brand New 3/2/2. $955/mo 344-2796 CITRUS HILLS 3/2/2 Citrus Hills $1200 3/2/2 Laurel Rdg $1300 3a2_Pool, Oaks $1500 3/2 Pool, Kensington $1300; 3/2 Canterbury $1500; 3/2_Laurel Ridge, $1300; 2/2 Bev. Hills $850 All Include lawncare Greenbriar Rentals, Inc. (352) 746-5921 ( CITRUS SPRINGS Brand new 3/2/2, for- mal living & dining rms, great rm, kitchenette. No smoking/pets. $925 mo. + security, credit check. 989-644-6020 CRYSTAL RIVER 3/1 Stilt, outside pets neg. $750+ sec. 746-3073 CRYSTAL RIVER 3/1. Newly remodeled, no pets. $750, 1st & sec (352) 425-0454 INVERNESS 2/1/2, waterfront, Ig. liv. rm., FP, dock, covered boat slip, scrn. porch, new paint & carpet, $895. mo. incl. yard mowing (352) 688-8040 INVERNESS 2/2, No pets, No -nokihg. $690 mo. + sec. (352) 860-2055 INVERNESS 3 bedroom, nice, quiet, clean, avail. immediately $950 mo. 352-613-6262 INVERNESS 3/2/2 on 2 acres, lots. & appl.'s, new paint $925 mo. 352-489-6729 714-623-0432 ON LAKE Inverness, Beautiful 3/2/2, Lrg Oaks, no pets. $850 mo. 908-322-6529 PINE RIDGE 3/21/2/1800 sq.ft., 1 acre, $1,000.mo. + utilities. (352) 527-2441 SUGARMILL WOODS ,-,'20 Lona. or. '-1r Crs. 2100sf under AC, flex. lease, sm. pet ok. $1400. (561) 310-8485 SUGARMILL WOODS SHome & Villa Rentals Call -800-SMW-1980 or S SUGARMILL WOODS New 4/2/2 $1250 also 3/2/2, Pool, $1275 River Links Realty 628-1616/800-488-5184 SUGARMILL WOODS On golf course, 3/2/2, Fresh paint, extra clean, $1250 mo. 352-621-0143 House, Cabins Travel Trailers & RV spots Savail. Short or long term. Excel. cond. on River w/ boat access. Big Oaks River Resort (352) 447-5333 INVERNESS Lakefront Townhouse, 3/2, Scr Rm, Washer/ Dryer; Pool, Boat Dock, Immaculate, $850.mo. 352-726-4062 WITHLACOOCHEE SRiver, 3/2. Avail Oct. 1 SCall904-334-1738 YANKEE TOWN 2/1 River House, W&D, NOQPETS, $650 + 1moo. sec. dep. Wtr. & grbg. Incl. 352-543-9251 HOMOSASSA. Bed/bath, background check, $500 mo. (352) 503-3298 INVERNESS Clean, nice area, priv. bath. Ist & Last wk $130 wk. 637-6297 -a - 3/2/2 Pool Homes SMW Prices Vary Furh. "- E COU "M CRSCUNY ALAN NUSSO BROKER Associate Real Estate Sales Exit Realty Leaders (352) 422-6956 OPEN HOUSE 9/24 & 9/25 12-4PM Re/Max Partners 3 HUECHERA CIR SUGAR MILL WOODS 800-585-4526 ext 7975 * Self Employed No No Income Loans Commercial Loans- Stated Income - Good or Bad Credit Construction Loans Equity Lines of Credit Call for a Free Quote (352) 382-2004 My Loan Service added $2,400.00 to my client's bank account this year If your bank says NO Call me, Kira at 352-795-5626 and ask for Program 99 SOLUTIONS FOR MORTGAGE Compeittive Ratesll Fast Preo-Approvals By Phone. Slow Credlt Ok. *"Purchase/Ref. t- FHA, VA, and Conventional. Down Payment Assistance. Mobile Homes. Call for Detailsl Tim or Candy (352) 563-2661 Lic. Mortgage Lender AT i' i ; t T List with me and get a Free Home Warranty & no transaction fee 352-527-1655 Nature Coast aUlI n11 u y DIAIeI REALTOR 352-613-6136 cblxlerl5@tampa bavorJrcoi Craven Realty, Inc. 352-726-1515 -I 4053 W Alamo Dr. 3/2/2 Open Floor.Plan on acre. Relocating, 1700 sq.ft. AC. $225,000 (352) 249-0850 3YR OLD 3 or 4/2/2 on lac New to market Pool home. Many up- grades with appliances Included, $349,900. (352) 746-5717 352-302-9483 Nature Coast For Sale By Owner, Clean 2/2/1, fam. rm. C/H/A, 7 Mellssa Dr., $107,500. 352-527-7191 HOMES FOR SALE BY OWNER bvownerctrus.com Newly Remodeled 3/2 on 1/3 acre, all appls., $127,900. (352) 746-5969 CITRUS REALTY GROUP 3.9% Listing Full Service/MLS Why Pay More??? No Hidden Fees 20+Yrs, Experience Call & Compare $150+Milllon SOLDIII Please Call for Details, Ustlngs & Home Market Analysis RON& KARNA NEITZ BROKERS/REALTORS CITRUS REALTY GROUP (352)795-0060./212/2+, Ig. encld. heated self cleaning pool, close to tennis court, dock & boat ramp, all appl. many upgrades $264,900. (352) 341-1618 Arbor Lakes, for Sale by Owner, Ig. 3/21/2, over- size gar., din. rm., liv. rm., fam. rm. caged 12x24ft pool, all apple. many extras $264,900. (352) 341-1618 Hampton Square Realty, Inc. Let us give you a helping hand 352-746-1888 1-800-522-1882 Marilyn Booth, GRI 23 years of experience "I LOVE Lecanto Homes' BECAUSE THERE IS NO SUBSTITUTE FOR EXPERIENCE....... Plantation Reality Inc. Lisa VanDeBoe Broker (R)/Owner (352) 422-7925 See all of the listings In Citrus County at realtvlnc.com Becky Wein (352) 422-7176 Free Home Warranty No Transaction Fee 'Personalized Service For All Your Real Estate Needs Nature Coast Bweln.c21 nature.com GEORGE OUELLETTE Exit Realty Leaders SOver 20 years exp. in the housing field *Let my experience work for you, Call me at 586-7041 Office 527-1112 PUBLISHER'S NOTICE: All real estate advertisingmin. this newspaper Is subject to Fair Housing Act which makes It illegal to advertise "any prefereference, limitation or discrimination based on race, color, religion, sex, handi- cap, familial status or national origin, or an intention, toamake eqi l opportunity basis. To complain of discrimination call HUD toll-free at 1-800-669-9777. The toll-free telephone number for the hearing impaired is 1-800-927-9275. 5,' ("Wis.r- i FOR LEASE OR SALE Warehouse & Offices on corner property in Homosasso, Sec. fenced. Lots of parking. Aprox. 3000 sq ft. (352) 628-5700 SPACE FOR LEASE Beverly Hills Medical Park. Ron Whitehead Uc Realtor (352) 628-4211 (2) CBS FINISHED DWELLING UNITS. Currently 4 rentals. 2400 liv. area total, 4BR/4BA CH/A, country setting 1-AC mol $250,000 (352) 726-1909 Brokers welcome 5 ACRES= 7 Lots, 3 doublewides= 4/2. 2 singlewldes. Barn, ponds. $270,000. (352) 795-3019 (352) 212-4737 GOT INCOME? NO DOWN PAYMENT? ZERO DOWN LOANS 1-800-233-9558 x 10051 Recorded Message Get your FREE copy of "Five Easy Steps To Buying a Home" c[fhhmc.com a correspondent lender Over 3,000 Homes and Properties listed at homefront.com 2002 4/2/2 POOL HOME I Great family home, near schools. $218,900. Also lot available next door @ additional cost. (352) 489-9418 2003, NEW 3/2/2 Lg corner lot, cath. ceil- ings, Ig. eat-in kit, scrn. lanal, move in oerfectl. $189,900 (352)465-5576 97-100% Financing to qualified buyers. 4/2/1 w/beautiful land- scaped screened pool '& patio, total sq.ft. 3540, uI reicrr.de':eled $179,0c'0 9210 N Lenox Ter. (352).563-2558 or (352) 422-4824. ". Richard Max Sims 352-527-1655 List with me and get a Free Home Warranty & no transaction fee 352-220-1401 ONrlyC N---a 7.r Nature Coast Steve & Joyce Johnson Realtors Johnson & Johnson Team Call us for all your real estate needs. Investors, ask about tax-deferred exchanges. ERA American Realty and Investments (352) 795-3144 Custom Built House 3/2'/2/3 car detached garage, in ground pool, many extra's $289,000. (352) 212-3613 I -jC= cc Pine Ridge (2) CBS FINISHED DWELLING UNITS. Currently 4 rentals, 2400 liv. area total, 4BR/4BA CH/A, country setting 1-AC mol $250,000 (352) 726-1909 Brokers welcome 2002, 3/2/1, new app.i new carpet,cul-de-sac, clean, $134,900. (352) 564-1764 5219 Tenison St., Highlands, 3/2/2 +fam. rm w/brick FP, spotlessly clean on Ig. corner lot Must sell, $159,900 (352) 726-5292 (727) 492-1442 .acre, 1726 sq. ft., Island kit., Ig. MBR suite, $198,000. Priced to sell! (352) 344-2711. FOR SALE BY OWNER Inverness Highlands West, 2/1, 1431 sq.ft.' under rf. 1087 liv., completely fenced yd. newer AC, $116,000. (352) 461-6973, Cell FOXWOOD 2/2/2 Exc. area. Lg. rms, xtra Ig. Fl. fm. Pool & deck area, new AC, beautifully landscaped, $144,900. 352-726-7486/302-4387 Block home, 2004 sq.ft. under roof. 1200 sq.ft, living, Newly carpeted & painted insidescreen porch,. $140,000 (352) 603-2741 or (352) 461-6973 HIGHLANDS S. 2/2/2 Remodeled, new kit/ baths,$139,900. Call John, Remax 302-4057 JACKIE WATSON -Ugml -jinverness ca Homes I EXIT REALTY LEADERS CITRUS REALTY GROUP 3.9% Listing Full Service/MLS Why Pay More??? No Hidden Fees 20+Yrs. Experience Call & Compare $150+Million SOLDII!! Please Call for Details. Ustings & Home Market Analysis RON & KARNA NEITZ 'BROKERS/REALTORS CITRUS REALTY GROUP (352)795-0060. FREE REPORT What Repairs Should You Make Before You Sell?? Online Email debbie@debbie Or Over The Phone DEBBIE RECTOR Realty One homesnow.com HOME FOR SALE" On Your Lot, $103,900. 3/2/1, w/Laundry Atkinson Construction 352-637-4138 Over 3,000 Homes and Properties listed at homefront.com SEEN THE REST? WORK with the BEST! HOME FOR SALE On Your Lot, $103,900. -3/2/1 w/ Laundry Atkinson Construction 352-637-4138 LIc.# CBC059685 HOMES FOR SALE BY OWNER www. byownercitrus.com SELL YOUR HOME! Place a Cnronlcle Classified ad 6 lines, 30 days $49.50 Call 726-1441 563-5966 Non-Refundable Pirvate Party Only -,me PeS.tilct1ions Maa appl) Carol Scully 352-302-69T2 List with me and get a Free home warranty & no transaction fees 352-302-6912 : ,21. Nature Coast HOMES FOR SALE BY OWNER byownercitrus.com KATHY TOLLE (352) 302-9572, Custom Pantry etc. $274,900 (352) 726-7239 Here To Helpl Visit: waynecormler.com (352) 382-4500 (352) 422-0751 Gate House Realty (2) CBS FINISHED DWELLING UNITS. Currently 4 rentals. 2400 liv. area total, 4BR/4BA CH/A, country setting 1-AC mol $250,000 (352) 726-1909 Brokers welcome $184,900 FLORAL CITY 3/2/2, GR/DR Eat-in-Kit, Grdn. Patio, W/ Fountain, Lanai, Generator wired Great location, Rear pasture view, Adult Community, For Details 352-726-0995. floralcitvlic@aol.com LUXURIOUS SWEETWATER POOL HOME in the ENCLAVE. 2746 sq.ft, in model home condition. On corner lot with many extras, $389,000 (352) 382-3879 VILLA 2/2/2 +Office /Computer Rm. 1650sf under AC, all appll's ECU sys. $182,000 (352) 382-4037 WAYNE CORMIER 0 List with me and get a Free Home Warranty (352) 302-9572 Nature Coast LAURIE B. LATER, P.A. (352) 302-6602 List with me & get a Free Home Warranty & No Transaction Fee' (352) 302-6602 Nature Coast ' I List with me and get a Free Home Warranty & no transaction fees 352-302-2675 Nature Coast Pauline Davis 352-220-1401 Lisl with me and get a Free Home Warranty & No transaction fees 352-613-3699 'Nature Coast CLASSIFIED Vic McDonald (352) 637-6200 : . ... ,:.. S . Realtor My Goal is Satisfied Customers REALTY ONE ' OWstafning Agents Outstanding Resuils (352) 637-6200 We're Selling Citrus!! NO Transaction fees to the Buyer or Seller. Call Today Craven Realty, Inc. (352) 726-1515 Rainbow Springs Desirable Woodlands, 3/2/2, 1+ acre, 1990sq.brlar I-AC mol $250,000 (352) 726-1909 Brokers welcome -M one! $245,900. 352-628-5921 or 352-212-8127 2004 Lexington Home. 3/2/3, pool, scr. lanal, tray Ceilings, tile, well, water softener, many Upgrades Must see, $331,900 (352) 382-3928 BY OWNER, Immaculate 3/2/2 split plan w/family -'JMeadow wHomes 71 Citrus 14:h Home Beverly Hills c= Homes 8D FRIDAYSPTEMBER 23, 2005 -oHms _A= E 312 TOWNHOUSE Furnished. Gated community- Boatslip on Crystal River.Clubhouse, pool, tennis court. $295,000.(352) 564-0376 CITRUS REALTY GROUP 3.9% Listing Full Servlce/MLS 'Why Pay More??? No Hidden Fees 20+Yrs. Experience Call & Compare $150+Mlllion UList with me & Get a Free Home Warranty & No transaction fees 352-634-1861 Nature Coast LET OUR OFFICE GUIDE YOU I Plantation Realty, Inc. (352) 795-0784, Cell 422-7925 Lisa VanDeboe Broker ECep. People. Licensed R.E. Broker S Leading Indep. Real Estate Comp. - Citrus, Marion, Pasco and Hernan- do h- Waterfront, Golf, Investment, Farms & Relocation 9 Excep. People. Except'nal Properties. Corporate Office 352-628-5500 4 proDerties.com Randy Rand/Broker Over 3,000 Homes and & Properties S r \ :-_7..2. Nature Coast RON EGNOT 352-287-9219 Ist Choice Realty YANKEETOWN 2/1 On deep water canal, woodburning fireplace. encd. WE BUY HOUSES AND LOTS Cash....fast closing 727-347-1099 WE BUY HOUSES Any situation including SINKHOLE. Cash, quick closing. 352-596-7448 WE BUY HOUSES Ca$h........Fast r- 352-637-2973 Ihomesold.com /I I ACRES ,500. paved road, N. Reyn- olds Ave., CR Hwy. 44 & 486 (352) 637-9630 1 AC WOODED LOT CITRUS HILLS, $74,900 352-212-7613 Crawford 1 ACRE CITRUS HILLS LOT Clearview Estates $105,000 Call (772) 971-6554 5 ACRES FOR SALE IN HOLDER AREA. Property cleared and partially fenced. $105,000. (352) 302-2638 after 5pm. CITRUS HILLS, 1 acre $74,900; CITRUS HILLS 1/2 acre, $68,900; INVERNESS 1/4 acre + $26,900 Great - American Realty & Investments Inc. 352-637-3800 CITRUS SPRINGS 2 side by side lots, 1 large corner lot. $41K ea. obo (386) 793-3980 CITRUS SPRINGS 3 lots on Primrose, $43,900 each. Call (772) 971-6554 Citrus Springs. Beautiful Corner Lot w/ adj. lot, many new homes In area. Near new school. City water, both lots 100K or 55K each. (239) 593-1335 (239) 591-1287 ml. to public ramp on river, $59,900 Parsley Real Estate, Inc. (352) 726-2628 DUNNELLON 1+ ACRE High/Dry, paved road. Water/Elec. avail. $50K (727) 459-6231 HOMOSASSA 3 acres high & dry close to shopping & river ac- cess 15 minutes to gulf REDUCEDIS 150,000 call 352-286-4482 very motivated to sell INVERNESS Heatherwood, 11/4 ac., 167 x 306 ft, Fenced, quiet near forest, $40,000 (352) 341-1901 KENSINGTON ESTATES Gr 'at ,re c.;1rrer klt ieoii at c. '.00 r0e., Call (954) 629-5516 Pine Ridge 1 acre lot on West Toll Oaks Drive $100,000. (352) 628-1425 PINE RIDGE ._. -a. :'r: O./owner. 2. i :':. l r,e.ff Drive $185,000. 610-756-4033 PINE RIDGE ACRE LOT. Prime wooded corner $135,000. No Realtors. please, (410) 848-8092 RAINBOWS END" .46 acre lot located in Dunnellon, non restrict- ed deed comm., close to two golf courses. $45,000. (352) 494-3551 1 1/4 ACRES, $26,500. paved road, N. Reyn- olds Ave., CR Hwy. 44 & 486 (352) 637-9630 1.22 ACRES in Inverness $49,900. Call Brian, (352) 299-6369 . 4 LOTS, HOMOSASSA Well & septic, Off 490. Nice dry area. (352) 341-0459' CITRUS COUN'IY (FL) CHRONICLE 7 Rivers Golf Course ready to build on, 150 x 150, $100.000, firm (352) 795-0527 Building Lots In Inverness Highlands, River Lakes & Crystal River. From $16,900. Call Ted at (772) 321-5002 Florida Landsource Inc CITRUS SPRINGS LOTS. $33,000 each. Call 352-465-2830 CITRUS SPRINGS Nice lot on sloping street w/newer homes, $36,900. Call Ed Can- dela @ (352) 447-5149 RIVER COAST REALTY CITRUS SPRINGS 20 LOTS FOR SALE 30K-34K each. 407-617-1005 CITRUS-OCALA-PORT CHARLOTTE, OVER- SIZED & /2 AC. Call 888-345-1668 TCHTRE greaffloridalots.com CITY OF INVERNESS New deed restricted development. Beautiful 1/4 acre lots. Paved streets/utilities $50,000 ea. Limited time offer (352) 220-5005 FOXMEADOW ESTATES 1/2 acre lot. 790 N Fox Meadow Terr (Lot 11). $50,000. 352-228-2454 GORGEOUS 1/2 ACRE Lot In Inv. Highlands. Quiet street, large oaks & pines. $49,900 obo (352) 422-6464 INVERNESS HIGHLAND S By owner, 80x120 Excellent location $27,500 (516)445-5558 INVERNESS LOT $18,500 (352) 422-0605 Inverness overlo, C21 Ten- ace 561-329-8491. RIVERHAVEN VILLAGE 85x183 11754 W Fisherman Ln $60,000. (352) 628-7913 SUGARMILL WOODS Lots for Sale By Owner (352) 228-7710 WAYNE CORMIER Here To Help! Visit: waynecormier.com (352) 382-4500 (352) 422-0751 Gate House Realty 1/2 ACRE CANAL LOTS $29,900-$39,900 Great American Realty & Investments Inc. 352-637-3800 CRYSTALRIVER 1994 Merc Outboard 7.5 w/ 9.8 carb. new stator, trigger switch & water pump. Low hrs, mostly fresh water. $700. (352) 564-6847 5HP 4 stroke Honda outboard with tank. Runs great, looks great. $600 firm. (352) 563-5040 PONTOON BOAT TRAILER Scissor Type Single Axle, $650 352-422-6471 SEA DOOS 2000 2-millinium edition SEA DOO GTX's. 1 has depth finder, Trlr incl $7,500/obo (352) 860-0299 Single Jetski Dock $650 Call Usa (352) 422-7925 YAMAHA 2005, FX, HO, comes w/ trailer, life vest & other access. low hrs (14) Must sell $9,400. Nicole 352-464-0631 2000 PRO-LINE 18SU. CC, 130 Johnson, Bimini, Dual Batt,. ElectronIcs, VHF $12,000 795-8014 14' AIRBOAT rod boxes, polymer, c/f prop, 0480 angle Valve Lycoming $10,995.00 (352) 726-5774 21FT WELLCRAFT cuddy cab w/175 Merc, needs work, $500 obo 16FT V-hull boat, new trans. no mtr w/trlr $200 obo (352) 860-0589 after 5p AQUA SPORT 17' CC, alum. I-beam trlr. New Nomex string- ers fiot. Lots of extras. $2400/obo. 795-4959 BANDIT 14ft. Air Boat, 2 dbl,. 350HP, polymer, gear box, everything new, $10,500. w/ out prop $12,500. w/ prop. (352) 341-5900 BAYLINER 1986 16FT Capri, con- vert, top, fish finder, 50HP Merc. Never In salt water, extras, 637-7142 BOWRIDER 18' W/traller, 1989,4.3 V-6, In/out, great on gas, many extras, $8000 In- vested, must sacrifice $5500/obo 352-344-0166 CANOE 16' Old Town Camper Model. Paddles and car roof pads. Great shape, can email pictures. $475.00 352-382-2294 CUSTOM BUILT 15' 6" Flats Boat, many new parts, must sell $6,500. obo (352) 266-8473 Glass Stream 14ft. Boat & Trailer, w 9.9 game fisher motor, plus trolling motor $1,400. (352) 621-5346 or Cell, 302-8886 HANDYMAN SPECIALS 10 PONTOON BOATS 18'-30' Priced From $995.-$8,450. S 2 DECKBOATS I Priced From $1,995.-$2,995. CRYSTAL RIVER | MARINE --- ---. E HONDO Rare Ski Boat, 300 merc, mint cond. 100mph, too many extras, all custom, must see $28,000. invested, make offer (352) 341-5900 HOUSEBOAT 1970, 34', NAUGA-LITE, Fit.ral,3:: '.I n .iFh. 8w .rp H,.3r..I.llI, .l -rir,. A/C,,needs finishing, Handymans dream, $7,900. Take it away. (352) 795-0678, $4500 352-795-7044 JON BOAT 15' -.ji .l;r.u . el ,,at 25.r.p E r.rj. trolling motor, trailer, and Accessories $1500. OBO. (352) 302-9835 JON BOAT 9V, *POLARe BAY BOATS Crystal River Marine 352-795-2597 Kayaks 2- Pungo 120's, all accessories plus helmets excel, cond. $1100. (352) 795-9384 MERCURY MARINE 360 RIB, 11 FT dinghy, 9.9 Mercury engine, boat, motor & trailer, $2,800 (352) 795-4222 POLAR '95, Salt Water Series, 17ft., 75HP Yamaha, bimlni top, fish finder, trailer, clean $7,000. (352) 465-9395 PONTOON BOAT 20' New floor & carpet, no trailer, $1800 OBO Ph: 352-212-9718 or 726-7116 BAYLINER 17FT '88 Capri, 85HP + trailer $1,200 (352) 637-3614 PROSPORT 20', 2002, 90hp Suzuki 4 stroke, approx. 100 hrs, on boat & motor. ,Elec. & trlr. V- clean. $14,500, (352) 527-4224 Shipoke 15' Custom Made, flats boat, 90HP, Inboard jet engine, manatee friendly, magic tilt trailer, pole platform, 60" new trolling motor. $6,500. (352) 489-5472 STARCRAFT 1968, 14FT. 15HP motor, All redone with receipts, as of 8/05. Boat, motor & trailer, $850 obo (352) 860-0892 STINGER 2000, 14'. Fiberglass Johnboat, 25hp Merc., live well troll motor, trl, $2,400. 352-302-6471 STINGRAY 17ft. fiberglass boat w/2003 trailer, 120HP I/O engine, asking $1825 (352) 527-1263 SPECIAL BUY A NEW BOAT AND RECEIVE A FREE FISH FINDER $19900 VALUE 1976 S. Suncoast Blvd. Homosassa, FL 34448 ALLEGRO 1991, 31', class. A, base- ment, 57k mi., Onan gen., rear qn. bd. non smoker, newer tires, $16,500., 352-422-4706 COACHMAN '98, sleeps 8, exc. cond. 5 new tires, Less than 18K mi., $26,500 obo (352) 560-7353 FLEETWOOD 2003 Diesel pusher, $135,000 (352) 746-9102 FLEETWOOD '94 Prowler 5th wheel, 26FT, very good cond., $7,000 obo (352) 476-8315! GULFSTREAM '02, Cavalier excellent condition reduced, $18,000. obo (352) 527-1&36 HOLIDAY 1998, 34' Rambler, w/ all toys, 44k, $38,500. (352) 422-4548 , Search 100's of Local Autqs Online at wheels.com (;iM (J11(1J ,/,,,, COACHMAN 25' w/ CHA, new tires, everything works, $3500. (352) 726-1187/650-2601 COACHMAN '94 Fifth Wheel, 24FT, 1 slide out, light weight, Irg. kitchen w/dinette & couch, sleeps 6 easy. New canopy, $5,900 (352) 422-1026 HUNTERS SPECIAL 23 ft., full sz. bed, full front, couch, refrig., AC, & heat, extra clean $4,995., 352-302-0778 JAYCO 1996,26', good cond. New tires & brakes. Equalizer hitch & extras. $6000. (352) 527-3409 SMOKY BY SUNRAY 28' Bunkhouse '04, w/qu. slips 7, Incl. hitch. Uke new. $13,000/obo (352) 332-2267 MASTER TOW DOLLY 2005 Master Tow dolly used twice. Great shape. Model 77T-14. GVWR 3500 Ibs. $825.00. 527-8376 MOPAR MOTORS 413 Industrial w/tronsm. $400. 360 w/transm + '74 Roadrunner, $200 (352) 628-2769 RACK FOR SMALL TRUCK Steel, 1" sq tube over cab, $100, (352) 564-0690 evenings TOW DOLLY 2002, Like new, under 1,000 miles on It. $650. NICHE RIMS & NEW TIRES, 5 lug, Chrm set of 4, $500/ obo, MUSULL (352) 302-9443 M Boats *.BIG SALE.* CARS. TRUCKS. SUVS CREDITREBUILDERS $500-$1000 DOWN Clean, Safe Autos CONSIGNMENT USA 909 Rt44&US19Airport 564-1212 or 212-3041 BUICK 1995 Roadmaster station wagon. Excellent cond. $3500. (352) 465-3683 BUICK '94, Century, 4 DR, auto, cold AC, 102k, I own, runs perf., needs paint, $1,350. (352) 422-0126 BUICK LACROSSE 2005, MUST SELL DUE TO ILLNESS, low mileage. (352) 264-3765 BUICK RIVIERA 1979, 2 door hardtop, FWD, auto, air, 2nd owner, good shape. $2195, (352) 465-1892 Cadilac 1997 Fully loaded, new tires, g cond. $8900. (352) 344-1482 or 212-8661 Cadillac '98 Deville, 4 dr., Lt. tan, v-good cond., 72K, Ithr. int., new a/c, $7,600, (352) 527-9544 ml., $6,250. (352) 637-1132 CORVETTE 1991, exc. cond. Serious buyers only. $13,500, Rick, 352-560-7413 after 6pm 1993 Thunderbird, V-6, clean, good condition, $1500. (352) 795-2643 FORD '90. Mustang 5.0 car- bolated, many extras $3,200. obo 352-697-1355 FORD CROWN VIC. 1989. Runs good, looks -.. i s cold, ()' 3' obo (352) 860-2207 FORD Must roll 1994 clown Victokria i. d. Good Ii*. I (352) 30'f 390906 . (352) 302-5396 UNDER WARRANTY MERCURY '70, Cougar, good look- ing, fast, dependable, too many new parts to list. $3,700. 352-860-2556 MUSTANG 1965 289 V-8, $2,400 obo (352) 628-2769 PLYMOUTH 1937 Street Rod. 350 eng. Auto trans. AC, PS,. tilt wheel, custom paint with flames. Loaded w/extras. Must see. " $29,995. (352) 726-4374 RihdM 16 * $13,988. Ci.l 1989 Ford 302 Motor w/transmission, runs great, S500. OBO (352) 302-9957 WANTED Clean, Late ModelMOS, CASHMERE LEATHER, 2 TOPS, (352) 949-0094 7FLnc.TGn..-ar- 'MR CIRUSCOUNTe ALAN NUSSO BROKER Associate Real Estate Sales Exit Realty Leaders (362) 422-6956 1994, 11 OK runs well. $900/obo (352) 382-7391 HONDA 2000, Odyssey, 7 pass, full pwr, great shape, 66,500mi, new brakes/ tires, alloid wheels, $13,500. (352) 726-5256 HONDA 1985 for parts, $500 (352) 726-4785 KIA SPECTRA LS 2002, 57k mi. AC, new tires, all power, white, runs excl $5900/obo (352) 489-8098 MERCURY, inci. sunroof. 60,000 mi. Exc. condition. $9700. (352) 795-6886 MUSTANG 1997 GT convertible White/ beige, like new, 27,000 mi. $10,000. (352) 344-0399 or 422-6695 MUSTANG COBRA '97 Turbo, BIk. dr. coat, Ithr, 44k, 5spd, new clutch & alum eng. 18 & 25MPG, 352-560-4279 OLDSMOBILE '85 Cutlass Supr. 2-dr., cust. paint, grt Int./Ext. Gd mi., many new pts, All power. $2,500 obo (352) 220-4621 VALUE- QUALITY* -Extra Clean Autos '99 Lincoln Cont. 1 own. Lea. Gr..$5999. '96 Olds Ciera 1 own. bl. 70K,...$3599. '96 Lincoln Town. Leather, White, 80K.................... $3699. '96 Mer. Grand Marq. 10Owner, blue, 70K.. ,;,..;..:..:1$4999; Swanders Auto Mart 5500 N. Lecanto Blvd. Beverly Hills 527-0440 TOYOTA 1985 Camry, hatch- -back, runs good, $400 (352) 726-4710 (352) 302-4310 TOYOTA CAMRY '02 Solara, silver. Low miles. Like new, eco- nomical 4cyl. $12,950 (352) 795-7028 VOLKSWAGON 1986, Cariola Conny., red, runs good, $2000. OBO (352) 527-3519 '95 Lincoln Town Car Exec. Drk. Green, voLyeather, Nice ..$980 198 Cadillac DeVille Whltew/Grey Leather, Loaded......... .$7,995 '99 Dodge Ram 1500 Ext, P/U 4Dr, Leather, Topper, Loaded... $8975 '02 Isuzu Rodeo SUV 5Or, fPo r,(Extra Clean...............$8,980 MANY MORE IN STOCK ALL CHEVROLET 2003. Silverado, 3rd door, loaded, toolbox, bedliner. 39K Beautiful, $17,500. 352-628-3609/400-3648 CHEVY 1989 S10. V-6, AC, auto. Dependable, Owner going into Military. $800. (352) 563-1518 CHEVY 1996, 1500,5,0, long bed w/ flat cap, 40K, like new, $6,100. (352) 465-2764 CHEVY 2500 LS '00, ext. cab, LWB, 5.7L, V8, auto, AC, Cruise, Tilt CD/Cass. Pewter, $13,500, (352) 422-0154 CHEVY ASTRO 1995 w/ truck mount carpet cleaning system. , good truck, $3,800. (352) 564-7928 FORD 1986 Ranger, longbed 78K miles, 4 cyl, good condition. $1500. (352) 726-9342 FORD 1999, Ranger XL, auto, 6 cycle, A/C, needs engine, $2,200. OBO (352) 628-5700 FORD 2001 F150 XLT. Super cab. 5.3 liter V-8,factory tow pkg. rated 8,400 Ibs, 5th wheel hitch rated 15,000 lbs. 5 disc CD player. Alum tool- box. 46,000 ml. $13,000. (352) 382-7316 FORD '97, F150 XLT, 5.4 liter, 176k mi., excel. cond. w/ topper $5,500. (352) 257-1355 FORD '99 F SIERRA 1987, 350 eng. Cold air, New tires, runs perfect, needs paint. $1500. (352) 344-3183 GMC 1997 extra cab, V-8, 6' bed, 73,000 mi.1 owner, good cond. $7250 firm. (352) 613-5445 GMC 2000, Sonoma SLS, 6 cycle, 3 drs, fully equipt, good cond, $8,500. (352) 637-1174 GMC SONOMA 1999 SLS,61K ml. 5spd. Alloy Wheels, AC, CD player, Fiberglass top. $7400.(352) 465-8233 NISSAN 1987, SE V6, 5spd, cold air, sun roof, $1895. (352) 341-2259 Search 100's of Local Autos Online at wheels.com Clllv 4L N ,,,,- saver, S5,200. (352) 382-3014 897-0923. 1991 FORD RANGER Color: Blaock VIN IFTCR10A4MTA46145 Auction: Oct. 5th, 2005 1993 DODGE VAN Color: Brown VIN # 2B4FK5134JR631204 Auction: Oct. 6th. 2005 1991 FORD RANGER Color: White VIN # 1FTCR10A8MUD54932 Auction: Oct. 6th, 2005 1990 ACURA LEGEND CHEVY '98 Very good cond. well maintained, 93,500 mi. $5400. (352) 527-6639 CHRYSLER LXi '96 Town & Country, 3.8 V-6, all pwr, Ithr, dual rear air, great cond. $3895. (352) 637-3550 Aerostar, runs good, new tires, front end wrecked. $400obo. (352) 795-2518 ml. 4 new tires, TV, VCR, air, CD player. Very good cond. $7000 obo. 352-257-9100 Search 100's of Local Autos Online at wheels.comr (i11pNlI( ,. 885-0923 FCRN Notice to Creditors (Summary Administration) Estate of Dan B. Andersen PUBLIC NOTICE IN THE CIRCUIT COURT FOR CITRUS COUNTY, FLORIDA PROBATE DIVISION File No: 2005-CP-658 Division: Probate IN RE: ESTATE OF DAN B. ANDERSEN Deceased. NOTICE TO CREDITORS (Summary Administration) TO ALL PERSONS HAVING CLAIMS OR DEMANDS AGAINST THE ABOVE ES- TATE: You are hereby notified that an Order of Summary Administration has been DAN B. ANDERSEN, de- ceased, File Number 2005-CP-658, by the Cir- cuit Court for Citrus Coun- ty, Florida. Probate Divi- slon. the address of which Is 110 North Apopka Ave- nue, Inverness, Florida 34450; that the dece- dent's date of death was August 11, 2004; that the total value of the estate Is $23,000.00 and that the names and addresses of those to whom it has been assigned by such or- der are: John Andersen 3428 Valley Woods Drive Verona, Wisconsin 53593 Arthur Andersen 3617 Oakland Avene Ames, Iowa 50014 Anita Moe 7922 RIdgeline N. Austin, Texas 78731 Alice Socha 18048 Gap Drive Spring Grove, Minnesota 55974 Elizabeth Andersen 8801 E, Ogden Lane Floral City, Florida 34436 T.,.i -ri their claims, with thi' Court WITHIN THE TIME i:'-,.r:i SET FORTH IN SECTION 733.702 OF THE FLORIDA PROBATE CODE. ALL CLAIMS AND DE- .MANDS-NOT SO FILED, WILL BE FOREVER BARRED. i NOTWITHSTANDING ANY OTHER APPLICABLE TIME PERIOD, ANY CLAIM FILED TWO (2) YEARS OR MORE AFTER THE DECEDENT'S DATE OF DEATH IS BARRED. The date of first publica- tion of this Notice is. Sep- tember 16, 2005, Person Giving Notice: -s- Elizabeth Andersen 8801 E. Ogden;Lane Floral City, Florida 34436 Attorney for Person Giving Notice: . -s- John A. Nelson, Esquire Florida Bar No. 0727032 PLAYMAKER AND NELSON, P.A. 2218 Highway 44 West Inverness, Florida 34453 Telephone: (352) 726-6129 Published two (2) times In the Citrus County Chroni- cle. September 16 and 23, 2005. 896-0930 FCRN Notice to Creditors Estate of Deborah Jean Holt PUBLIC NOTICE IN THE CIRCUIT COURT FOR CITRUS COUNTY, FLORIDA PROBATE DIVISION File No.: 2005-CP-1251 IN RE: ESTATE OF:. DEBORAH JEAN HOLT, Deceased. NOTICE TO CREDITORS The administration-of the estate of DEBORAH JEAN HOLT, deceased, whose date of death was August 28. 2005, and whose So- cial Security Number is 261-33-6003, is pending in the Circuit Court for Citrus County, Florida, Probate Division, the address of which is 110 North Apopka Avenue, Inver- ness, FL 34450. The names and addresses of the per- sonal representative and that of the personal repre- sent September 23, 2005, Personal Representative: -s- LILLIAN MAE HOLT 2750 N. Bucknell Terrace Hernando, FL 34442, September 23 and 30. 2005. Color: White VIN JH4KA4560LC001466 Auction: Oct. 7th. 2005 UNKNOWN YEAR BASS HUNTER Color: Green MODEL BHECII Auction: Oct. 7th, 2005 1966 NISSAN P/U Color: Green VIN 1N6SDl 1S2TC336910 Auction: Oct. 7th, 2005 1991 GMC SONOMA Color. White VIN # 1GTCS14A1M2558814 Auction: Oct. I lth, 2005 1997 TOYOTA CAMRAY Color: Black VIN 0 4T1BG22K8VU058867 Auction: Oct. 21st. 2005 1999 FORD RANGER Color: Red VIN # SFTYR14V4XPB00673 Auction: Oct. 21st, 2005 1984 CHEVY 2-10 P/U Color: Red VIN = , 1GCCS14BXE8230131 Auction: Oct. 28th, 2005 Published one (1) time in the Citrus County Chroni- cle, September 23. 2005., CLASSIFIED SUBARU OUTBACK LL BEAN EDITION 2002 125,000 mi; Loaded w/leather, AWD, more! $12,200. Call 527-3099. Search 100's of Local Autos Online at wheels.com I, $795. (352) 563-2583 HARLEY DAVIDSON 1/2 Helmet; women's size XS. GlossW black with studs, mint, $75. (352) 628-1092 HARLEY DAVIDSON FLH 1980 5000 ml.l! $4000 (352)422-1466 ml. Leather bags, custom seats, total chrome pkg $5750. 352-382-0029 or 352-382-7233, Iv. msg. KAWASAKI CLASSIC 805 Vulcan, 1998, Lthr bags, custom seats, wind- shield, bkrst. 5700 mi, $3995. 352-382-0029 or 352-382-7233, Iv. msg. MOTOR SCOOTER ULike new. top speed 40 mph, Sporty, $1,000. (352) 621-0537 Search 100's of Local Autos Online at wheels.com YAMAHA New. 2005, Majesty Scooter, 400cc, low mileage, great gas Crnitus COUNTY (FL) CHRONICLE FRIDAY, SI4PIFMBIR 23, 2005 9D ~Y al z 1^J [l Z's UM%! l S i el a I 51' 1 I I [~I I s Ialei :k~I.1Il :4 '1e] 111 '05 Thunderbird #N5C251 s43,395o MSRP EMPLOYEE $38, 23955 PRICE *1, 0oo0 CLEARANCE 1,0.000CASH $37, 239 ssPRICE '05 Freestyle #N5T708 $26,66000 $23,868s5 s1 ,000 $22, 868s5 MSRP EMPLOYEE PRICE CLEARANCE CASH FORD FAMILY PRICE '05 Expedition 4X2 XLT #N5T203 $41 5000 MSRP EMPLOYEE $35,03488 PRICE *2,0 00 8 CLEARANCE $33, O 3488* LYPRICE '05 Crown Victoria #N5C169 $25,4000 MSRP $23,21 265 PRICE g3,0 oo CLEARANCE $20, 21 26 FAMILY PRICE power steering, power brakes, power windows, power locks, NC, cruise control #NP4571- $13 995 *'I MEKRUKY UKGANDU '< MARQUIS LS S- Thiis s a lot of car for the money and it 6.0 liter 8 has leather tool #NP4479 pw. p $139995 ----- C r-Fz I 91 I. CD, All p tB towp W-P-r5U I w '3* M* U -OUw -4A4- ALI JC, ABS brakes, Super crew, V8, auto, air, 344 mi. #NP4550 cruise, dark blue. #NP4522 4,995 $249995 miles, all power. #N5T557B ' $8.995 CREW LARIAT SUPER CREW XLT 103 MERCURY MARAUDER CREW CAB r 8 m. A r la I. ,Lk A I. I il"l |1: h-.l. . cruise, tilt, tint, leather #NP4561 leather & much more. #N07332A #NP4536 $24,995 $19,995 $25,995 '03 GMC SIERRA 1500 all power, tow pkg. #N5T805A $19.995 ,'l rI, n an uJI, i, , ..1 i' ,, ,- ., ." -,, hr , power, 79,832 miles. #N5T763A all pwr, 23,409 mi. #NP4595 $11.995 Si19.995 , ." .,, I 0- rr,- ,,' f j"l mnT 'ual, -,Mr, FM ,.lt+r u, a ,. power, showroom cond #NP4559. tint, A/C, anti-lock brakes #NP460; $21,995 $18,917 01H sud*Ilfrl'L p'II.1 ,,.. 11i1 $11,995 101-7 - ANA .: I 47,420 Miles. White, 4 6 V8, All Power, $18 995 Alloy wheels, Keyless Entry, Power Lumt Seats, Leather Interior, Climate Cont And Much, I Mo * ~ ~. n~a,3, a 1. ~ I - EDGE SUPER CAB $16,995 FRONTIER XE .,1 ., .) ,', ., ii , $17,875 105 FRDm~ rFl.Uoa. ChiA,,0AU~,O 0oio,,Io $219995 SUPER CAB S '' julu ," 1 14 M. I i I:. bedline rand muh ,i re #N T3i. $14,995 '05 FRDrsuCARGO VANI 22i -B a5,0,,4r A md Jri. sNts-I 1 $189995 '05 FORD MUSTANG '04 BUICK LESABRE 2 door coupe, 4.0 V6, 6,512 miles, CUSTOM automatic, A/C, all power. 3.8 Liter 6 cyl fuel inJ, pw, pl, A/C, cruise, #N5T749A lilt, AM/FM CD, alloy wheels. #N5T575A $21 995 $16,995 SMM Bi ~1~1I1 Retail '13,995." 0.995 '04 DODGE DAKOTA '9 FI QUAD CAB E-150 4.7 Liter 8 cyl, auto w/overdve pw, pl NC, 5 4 LiterW ." cruise, tilt, tint, C, towing pkg. #N5T461E wOD, p 2I 1.291 ._Q V8 electronic uel injection, auto Sl. A/C tilt cruise #N5C172M certflfec :J 0 ell ll I AULU, t/U, This is the ot $21 563, 4x4, 6.8 'V #h $1 their pkg. 4.0 Li A pl, 95 3.o leter 0 cyl wheels, keyle $1 FfuDA-Y, Si--rrlzmm--f 23, 20059D CITRUS COUN7Y (FL) CHRONICLE P-II -r ".j i eFow. 10 rel I Ji I I knio I I koilA Ji 11-1 kpi I I'l I N' 41 MODEL 13255 $14,999 2 OR MORE AVAILABLE AT THIS PRICE OR $ PER MONTH MODEL YEAR END CLEARANCE '05 NISSAN XTERRA '05 NISSAN PATHFINDER '05 NISSAN MURANO '05 NISSAN ARMADA MODEL 09215 MODEL 07215 19,999 2 OR MORE AVAILABLE AT THIS PRICE 24,999 2 OR MORE AVAILABLE AT THIS PRICE S26,999 2 OR MORE AVAILABLE AT THIS PRICE S28,999 2 OR MORE AVAILABLE AT THIS PRICE 2005 SENTRA AUTOMATIC A/C P/W P/L CD PRETITLED $9,999 2005 ALTIMA ftCk~~ ~ AUTOMATIC A/C P/W CD PRETITLED $14,999 ME 2005 QUEST V6 AUTOMATIC SKYVIEW PRETITLED $19,999 I I FOUR DOORS MODEL 11515 * V8 AUTOMATIC AIR CONDITIONING $ I 2 OR MORE AVAILABLE AT THIS PRICE MODEL 04165 MODEL 49215 OCALA N I SSAN , TONIGHT 2200 SR 200 OCALA 622-4111 800-342-3008 ALL PRICES GOOD DAY OF AD PLUS TAX TAG & '195 DEALER FEE* W/*1 000 CASH OR TRADE EQUITY 72 MO. 6.75% APR W.A.C. tON REMAINING 2005 MODELS BASED ON MSRP. Bottorlul Ll e IOD FRIDAY. SEPTEMBFR 23, 2005 NO PAYMENTS 'TIL MARCH 1, 2006t I if200 NISESANi TITANI 12005 NISSAN FRONTIER CITRUS COUNTY (FL) CHRONICLE i nus ou ( ) v~vu=rn 2005 LINCOLN TOWN CAR 2005 LINCOLN LS Employee/Family DISCOUNT PRICE $32,209 NEW 2005 GRAND MARQUIS GS Zx13lft Employee/Family DISCOUNT PRICE I17,731 Employee/Family DISCOUNT PRICE $27,300 2005 MERCURY 2005 MERCURY SABLE MONTEREYVAN Employee/Family DISCOUNT PRICE Employee/Family DISCOUNT PRICE 120,077' Employee/Family DISCOUNT PRICE 131,430 / 2005 MERCURY 2005 MERCURY MONTEGO MOUNTAINEER Employee/Family DISCOUNT PRICE Employee/Family DISCOUNT PRICE 121,954 124,701 pF 2002 VILLAGER ESTATE VAN WImte 23k miles. #R2994 $ 16.995 2002 CONTINENTAL 2005 GRAND Siher 74 000 m,les. tlie nen MARQUIS LS R29'6 Siter 16k mi. leather =R2991 s 18,995 $ 18,995 1400.1riirle l. ual,4C &R98 $18.995 CAR Silver. 27,000 miles #X817 $ 18.995 2003 LINCOLN LS CGol. V'. one o ner. 81'9.996A $ 19.995 2003 MOUNTAINEER All i heel dr ve. leather interior R2984 $20,995 SIGNATURE Silver. one oi rner u8578A $21,995 Pearl I% rne. one cnner. loaded c8208A $21,995 2003 AVIATOR 2004 PRESIDENTIAL 2005 TOWN CAR SIGNATUF Green leather, loaded TOWN CAR SEDAN 12 (.000 mles.h, Casnmere n8250A 18.000 mirrles leather #R2962 #X'-'1 S-SOO9 s$7A OO sK7o0c 2004 MERCURY MOUNTAINEER 17k mi leather. V6. 484424 $22,995 2002 FORD T-BIRD Red. 1 .000 m,tes s$0aaOaC 2004 LINCOLN TOWN CAR ntile 15.000 miles 24.995 LINCOULL N-IAVIGAUHII WVriie leather 3rd seat #R2"98 $1o00o0- 2004 LINCOLN TOWN CAR SIGNATURE Silver. 18.000 miles. &X821 $25.995 CAR LIMITED 13k m, moon root uR2-990 $7s 0 0o 2004 LINCOLN LS Coldl ."h8. rmoon root aR2930 $259995 2003 LINCOLN NAVIGATOR ltince loaded #R2983 $so-o.o -~~ w wA UU W= N, ~d1A' & .w'jfiw WM -& w w Mo.Fi.853 3%pER UR SA.8120 12 WHw 96RYTLRIE l 19,057 ---I FruDAY, SEPTEMBFR 23, 2005 IID Cr C NTY FL CHRONIC I - - - -- -- --- - In 2004 MONTEREY PREMIER Gold leafrier. loaded. P-963B s ISP995 IUN; 29th day of September, 2005, at 11:00 A.M., in the Jury Assembly Room In the new addition to the Citrus Coun- ty Courthouse, 110 North Apopka Avenue, Inverness FL, 34450, offer for sale and sell at public outcry to the highest and best bidder for cash, the follow- ing-described property situate In Citrus County, Florida:. pursuant to the Final Judgment entered In a case pending In said Court, the style of which Is Indicated above. WITNESS my hand and official seal of said Court this 9th day of September,- Judy Ramsey Deputy Clerk Published two (2) times In the Citrus County Chronicle, September 16 and 23,2005. ,B&H #223327 874-0923 FCRN Re-Notice of Sale Deutsche Bank, etc. vs. Tina Maddox, et al. PUBLIC NOTICE IN THE CIRCUIT COURT OF THE 5TH JUDICIAL CIRCUIT, IN AND FOR CITRUS COUNTY, FLORIDA CIVIL DIVISION CASE NO,: 2004-CA-4106 DEUTSCHE BANK NATIONAL TRUST COMPANY, AS TRUSTEE OF AMERIQUEST MORTGAGE SECURITIES, INC. ASSET BACKED PASS-THROUGH CERTIFICATES, SERIES 2004-R5 UNDER THE POOLING & SERVICING AGREEMENT DATED AS OF JUNE 1, 2004, WITHOUT RECOURSE, Plaintiff, vs. TINA MADDOX A/K/A TINA J. LEWIS; LEVON MADDOX; JOHN DOE; JANE DOE AS UNKNOWN TENANTS) IN POSSESSION OF THE SUBJECT PROPERTY, Defendants. RE-NOTICE OF FORECLOSURE SALE NOTICE IS HEREBY GIVEN pursuant to a Motion and Or- der Resetting Foreclosure Sale dated the 7th day of September, 2005; and entered In Case No. 2004-CA-4106, of the Circuit Court of the 5TH Judicial Circuit In and for Citrus County, Florida, wherein DEUT- SCHE BANK NATIONAL TRUST COMPANY, AS TRUSTEE OF AMERIQUEST MORTGAGE SECURITIES, INC. ASSET BACKED PASS-THROUGH CERTIFICATES, SERIES 2004-R5 UNDER THE POOLING & LE, .,CifG !Gi.EEMENT DATED AS OF JUNE 1. 2004,. UIiHOui -'ECCJURSE Is the Plaintiff and TINA MADDOX A/K/A TINA J. LEWIS; LEVON MADDOX; JOHN DOE; JANE DOE AS UNKNOWN TEN- ANT(S) IN. POSSESSION OF THE SUBJECT PROPERTY are defendants. I will sell to the highest and best bidder for cash at the ill THE julQ, L,,F.I.1lBL, R o.C.I. in THE tEW ADDITION TO THE iE' Ci CirNuO COutr,,u Curi-IuCiE at the Citrus Co.ur.,y Cou.ir,.:.a. iil .'ERrNELS Fiorrja aT 11!00 am. on the day of 29th day of September. 2005, the -oI- inr.g .e..:rte.a p':pe'rr, a.: :ei ,.nr. Ir. .:o1d Fi- nal Judgment, to wit: SEE ATTACHED EXHIBIT "A".'fhis 8th day of September, 2005. BETTY STRIFLER Clerk of the Circuit Court By: -s- Judy Ramsey Deputy Clerk EXHIBIT "A" LOT '45, OF THE MEADOWS F/K/A DEXTER PARK VILLAS, AN UNRECORDED SUBDIVISION, MORE PARTICULARLY DESCRIBED AS FOLLOWS: COMMENCING AT THE NW CORNER OF THE SE 1/4 OF THE SW 1/4 OF SECTION 24, TOWNSHIP 19 SOUTH, RANGE 17 EAST, CITRUS COUNTY, FLORIDA; GO THENCE S 00 DEG. 32' 52" W AND ALONG THE WEST LINE OF THE AFORESAID SE 1/4, A DISTANCE OF 135'; THENCE S 89 DEG. 21' 42" E, A DISTANCE OF 333.74'; THENCE S 00 DEG. 34' 12" W, A DISTANCE OF 127' TO THE POINT OF BEGINNING; THENCE CONTINUE .S 00 DEG. 34' 12" W, A DISTANCE OF 62'; THENCE N 89 DEG. 21' 42" W, A DIS- TANCE OF 100'; THENCE N 00 DEG. 34' 12" E, A DISTANCE OF 62'; THENCE S 89 DEG. 21' 42" E, A DISTANCE OF 100' TO THE POINT OF BEGINNING. Published two (2) times In the Citrus County Chronicle, September 15 and 23, 2005. 04-07433 877-0923 FCRN Notice of Sale Wells Fargo Bank, N.A., etc. vs. Henry F. Brown, et al. PUBLIC NOTICE IN THE CIRCUIT COURT OF THE 5TH JUDICIAL CIRCUIT, IN AND FOR CITRUS COUNTY, FLORIDA CIVIL DIVISION CASE NO. 2005-CA-411 WELLS FARGO BANK, N.A., SUCCESSOR BY MERGER TO WELLS FARGO BANK MINNESOTA, N.A., AS TRUSTEE F/K/A NORWEST BANK MINNESOTA, N.A., A TRUSTEE FOR THE REGISTERED HOLDERS OF HOME EQUITY LOAN ASSET-BACKED CERTIFICATES, SERIES 2004-1, Plaintiff, vs. HENRY F. BROWN; DEBBIE BROWN; UNKNOWN PERSONS) IN POSSESSION OF THE SUBJECT PROPERTY, Defendants. NOTICE OF FORECLOSURE SALE NOTICE IS HEREBY GIVEN pursuant to a Final Judgment of Foreclosure dated September 1, 2005, and entered In Case No. 2005-CA-411, of the Circuit Court of the 5th Judicial Circuit In and for CITRUS County, Florida. WELLS FARGO BANK, N.A., SUCCESSOR BY MERGER TO WELLS " FARGO BANK MINNESOTA, N.A., AS TRUSTEE F/K/A NORWEST BANK MINNESOTA, N.A., A TRUSTEE FOR THE REGISTERED HOLDERS OF HOME EQUITY LOAN AS- SET-BACKED CERTIFICATES, SERIES 2004-1, Is Plaintiff and HENRY F. BROWN; DEBBIE BROWN; UNKNOWN PER- SON(S) IN POSSESSION OF THE SUBJECT PROPERTY; are defendants, I will sell to the highest and best bidder for cash at THE JURY ASSEMBLY ROOM IN THE NEW ADDI- T11ON TO THE NEW CITRUS COUNTY COURTHOUSE, AT 110 NORTH APOPKA AVENUE, INVERNESS IN CITRUS COUN- TY, FL, at 11:00 a.m., on the 29th day of September, 2005, the following described property as set forth In solid Final Judgment, to wit: LOT 25, BLOCK A, INDIAN WATERS UNIT 1, ACCORDING TO THE PLAT THEREOF RECORDED IN PLAT BOOK 4, PAGE 57 OF THE PUBLIC RECORDS OF CITRUS COUNTY, FLORI- DA., at no cost to you, to provisions of certain assistance, Please contact the Court Admilns- trator at 110 N, Apopka Avenue, Inverness, FL 34450- 4299, Phone No., (352) 637.9883 within 2 working days of your receipt of this notice or pleading; If you are hearing Impaired, call 1-800-955-8771 (TDD); If you are voice impalred,,call 1-800-995-8770 (V) (Via Florida Re- lay Services). Published two (2) times In the Citrus County Chronicle, September 16 and 23, 2005. 04-11618 OCN 894-0930 FCRN Notice of Sale Wachovia Bank, N.A. vs. Jeffrey K. Mangrum, et al. PUBLIC NOTICE IN THE CIRCUIT COURT OF THE 5TH JUDICIAL CIRCUIT, IN AND FOR CITRUS COUNTY, FLORIDA CIVIL DIVISION CASE NO.: 2005-CA-3058 WACHOVIA BANK, N.A., Plaintiff, vs. JEFFREY K. MANGRUM, et al., Defendants, NOTICE OF FORECLOSURE SALE NOTICE IS HEREBY GIVEN pursuant to a Final Judgment of Foreclosure dated the 8th day of September, 2005, and entered in Case No. 2005-CA-3058, of the Circuit Court of the 5TH Judicial Circuit In and for Citrus Coun- ty, Florida, wherein WACHOVIA BANK, N.A. Is the Plain- tiff and JEFFREY K. MANGRUM: KIMBERLY A. MANGRUM; 6th day of October, 2005, the following de- scribed property as set forth In said Final Judgment, to wit: LOT 28, BLOCK 344, INVERNESS HIGHLANDS WEST, AC- CORDING TO THE PLAT THEREOF, AS RECORDED IN PLAT BOOK 5, PAGES 19 THROUGH 33, INCLUSIVE, OF THE PUBLIC RECORDS OF CITRUS COUNTY, FLORIDA. 9th day of September, 2005, BETTY STRIFLER Clerk of the Circuit Court By: -s- Judy Ramsey Deputy Clerk Published two (2) times In the Citrus County Chronicle, September 23 and 30, 2005. 05-04265 878-0923 FCRN Notice of Sale Old Standard Life Ins. Co. vs. Richard J. Plottl,; Defendants, NOTICE OF FORECLOSURE SALE NOTICE IS HEREBY GIVEN pursuant to a Final Judgment of Foreclosure dated September 1, 2005, and entered In Case.No. 2005-CA-1815, of the Circuit Court of the 5th Judicial Circuit In and for CITRUS County, Florida. OLD STANDARD LIFE INSURANCE COMPANY Is Plaintiff and RICHARD J PIOTTI, SR.; DIANNE L PIOTTI; UNKNOWN PERSONS) IN POSSESSION OF THE SUBJECT PROPERTY: are defendants. I will sell to the highest and best bid- der for cash at THE JURY ASSEMBLY ROOM IN THE NEW ADDITION TO THE NEW CITRUS COUNTY COURTHOUSE, AT 110 NORTH APOPKA AVENUE, INVERNESS IN CITRUS COUNTY, FL, at 11:00 a.m., on the 29th day of Septem- ber, 2005, the following described property as set forth In sold Final Judgment, to wit: SEE ATTACHED EXHIBIT "A", al no cod 0 o,: u. io pD.i..1i*i.-; of certain assistance. -re,:e .:or.io.:i Ir. Cour.n iar.lrl.. trator Re- lay Services). EXHIBIT "A" Citrus A portion of Lot 41 of Holiday Acres Unit No. I accord- ing to the plat thereof recorded In Plat Book Ing centerline description. There is a 85 SIES Title # 50149462 ID # 28610928U Sin- glewide mobile home on property described above and a lien In the amount of this mortgage Is being at- tached to the mobile home title(s) thereto and will be satisfied simultaneously with this mortgage when the same has been paid In full. Published two (2) times In the Citrus County Chronicle, September 16 and 23, 2005. 05-11950 OCN 879-0923 FCRN Notice of Foreclosure Sale Wells Fargo Bank, N.A., etc., vs. John Strobaugh, et al. PUBLIC NOTICE IN THE CIRCUIT COURT OF THE 5TH JUDICIAL CIRCUIT, IN AND FOR CITRUS COUNTY, FLORIDA GENERAL JURISDICTION DIVISION CASE NO: 05-CA-2582 WELLS FARGO BANK, NATIONAL ASSOCIATION, ON BEHALF OF THE CERTIFICATEHOLDERS OF SECURITIZED ASSET BACKED RECEIVABLES, LLC FIRST FRANKLIN MORTGAGE LOAN TRUST 2004-FF8 MORTGAGE PASS-THROUGH CERTIFICATES SERIES 2004-FF8, PLAINTIFF vs. JOHN STROBAUGH, IF LIVING, AND IF DEAD, THE UNKNOWN SPOUSE, HEIRS, DEVISEES, GRANTEES, ASSIGNEES, LIENORS, CREDITORS, TRUSTEES AND ALL OTHER PARTIES CLAIMING AN INTEREST BY, THROUGH, UNDER OR AGAINST JOHN STROBAUGH, JOY STROBAUGH, IF LIVING, AND IF DEAD, THE UNKNOWN SPOUSE, HEIRS, DEVISEES, GRANTEES, ASSIGNEES, LIENORS, CREDITORS, TRUSTEES AND ALL OTHER PARTIES CLAIMING AN INTEREST BY, THROUGH, UNDER OR AGAINST JOY STROBAUGH; FIRST FRANKLIN FINANCIAL CORP., A SUBSIDIARY OF NATIONAL CITY BANK OF INDIANA; JOHN DOE AND JANE DOE AS UNKNOWN TENANTS IN POSSESSION, DEFENDANTS) NOTICE OF FORECLOSURE SALE NOTICE IS HEREBY GIVEN pursuant to a Summary Final Judgment of Foreclosure dated September 1, 2005, entered in Clvil Case No. 05-CA-2582 of the Circuit Court of the 5TH Judicial Circuit In and for CITRUS County, Inverness, Florida, I will sell sell to the highest and best bidder for cash at IN THE JURY ASSEMBLY ROOM In the NEW ADDITION at the CITRUS County Courthouse located at 110 N, APOPKA AVENUE In Inverness, Florida, at 11:00 a.m. on the 29th day of September, 2005, the following described property as set forth In said Sum- mary Final Judgment, to-wit: THE NORTH 110 FEET OF LOT 3, BLOCK F, OF CRYSTAL RIV- ER HIGHLANDS, ACCORDING TO THE PLAT THEREOF AS RECORDED IN PLAT BOOK 3, PAGE 145, PUBLIC RECORDS OF CITRUS COUNTY, FLORIDA. Dated this Ist day of September, 2005. BETTY STRIFLER Clerk of the Circuit Court (CIRCUIT COURT SEAL) By: -s- Judy Ramsey Deputy Clerk IN ACCORDANCE WITH THE AMERICANS WITH DISABILI- TIES ACT, persons with disabilities needing a special ac- commodatlon should contact COURT ADMINISTRA- TION, at the CITRi.1 County Courthouie, at NONE, 1-800-955-8771 11-ii or i800988-08770, via Florida Re- lay Service, Published tvw' ,, i f ir in t' ,h' ,=: 'rily Chroniole, September .rdi'J ~1 ,i ', I l/t i..' wr i CLASSIFIED -c - 876-0923 FCRN Notice of Sale Green Tree Servicing, LLC, etc. vs. Paul Clarke Earnheart. et al. PUBLIC NOTICE IN THE CIRCUIT COURT IN AND FOR CITRUS COUNTY, FLORIDA CASE NO.: 2005-CA-2313 Green Tree Servicing LLC, successor service to GreenPoInt Credit, LLC, as authorized servicing agent for BankAmerica Housing Services, a division of Bank of America, FSB, a corporation, Plaintiff, vs. Paul Clarke Eamheart, Lisa Lee Earnheart, IF LIVING, AND IF DECEASED, THEIR UNKNOWN SPOUSES, HEIRS, DEVISEES, GRANTEES, CREDITORS, AND ALL OTHER PARTIES CLAIMING BY, THROUGH, UNDER OR AGAINST THEM; Joseph P. Parrino; JOHN DOE and JANE DOE AND ANY OTHER PERSONS) IN POSSESSION OF THE SUBJECT REAL PROPERTY WHOSE REAL NAMES ARE UNCERTAIN, Defendants. NOTICE OF SALE Notice Is hereby given that, pursuant to an order or a final judgment of foreclosure entered in the above-captioned action, I will sell the property situated In CITRUS County, Florida, describe as: Tract 52, SEVEN RIVERS HEIGHTS 2ND ADDITION, an un- recorded subdivision lying In the NW 1/4 of Section 15, Township 17 South, Range 17 East, CITRUS COUNTY, FLORIDA, being further described as follows: Begin at the NW corner of the NE 1/4 of Sold NW 1/4, thence S 89 degrees 24' 33" E 109.28 feet, thence S 00 degrees 35' 27" W, 569.50 feet, thence N 89 degrees 24' 33" W 200 feet, thence N 00 degrees 35' 27" E 569.50 feet, thence S 89 degrees 24' 33" E 90.72 feet. SUBJECT TO a 100 foot wide Florida Power Easement; AND SUBJECT to a 25 foot wide easement on the South boundary thereof for road right of way. 1997 Fleetwood Chadwick Mobile Home, 28 x 64, Serial Numbers: GAFLT05A28612-CW21 & GAFLT05B25612-CW21. at public sale, to the highest and best bidder for cash, In the Jury Assembly Room of the CITRUS County Court- house, 110 N. Apopka Avenue, Inverness, Florida at 11:00 a.m., on September 29, 2005. DATED this 1st day of September, 2005. Betty Strlfler CLERK OF THE COURT (CIRCUIT COURT SEAL) By: -s- Judy Ramsey As Deputy Clerk AMERICANS WITH DISABILITIES ACT (ADA) NOTICE Individuals with disabilities needing a reasonable ac- commodation to participate In this proceeding should contact the Court Administrator's office, as soon as possible, If hearing Impaired, 1-800-995-8771 (TTD); or 1-800-955-8770 (V),via Florida Relay Service, Published two (2) times in the Citrus County Chronicle, September 16 and 23, 2005. 880-0923 FCRN Notice of Foreclosure Sale Mortgage Electronic Registration Systems, Inc. vs. Richard A. Barnes, Jr., et al. PUBLIC NOTICE IN THE CIRCUIT COURT OF THE 5TH JUDICIAL CIRCUIT, IN AND FOR CITRUS COUNTY, FLORIDA GENERAL JURISDICTION DIVISION CASE NO: 2005-CA-2537 MORTGAGE ELECTRONIC REGISTRATION SYSTEMS, INC., PLAINTIFF vs. RICHARD A. BARNES, JR., IF LIVING, AND IF DEAD, THE UNKNOWN SPOUSE, HEIRS, DEVISEES, GRANTEES, ASSIGNEES, LIENORS, CREDITORS, TRUSTEES AND ALL OTHER PARTIES CLAIMING AN INTEREST BY, THROUGH, UNDER OR AGAINST RICHARD A. BARNES, JR.; STACY BARNES, IF LIVING, AND IF DEAD, THE UNKNOWN SPOUSE, HEIRS, DEVISEES, GRANTEES, ASSIGNEES, ' UENORS, CREDITORS, TRUSTEES AND ALL OTHER PARTIES CLAIMING AN INTEREST BY, THROUGH, UNDER OR AGAINST STACY BARNES: JOHN DOE AND JANE DOE AS UNKNOWN TENANTS IN POSSESSION, DEFENDANTS) NOTICE OF FORECLOSURE SALE NOTICE IS HEREBY GIVEN pursuant to a Summary Final Judgment of Foreclosure dated September 1, 2005, entered In Civil Case No. 2005-CA-2537 of the Circuit Court of the 5TH Judicial Circuit In and for CITRUS' County, INVERNESS, Florida, I will sell to the highest and -best bidder for cash at IN THE JURY ASSEMBLY ROOM IN THE NEW ADDITION at the NEW CITRUS County Cburt- house located at 110 N: APOPKA AVENUE In Inverness, Florida,. at 11:00 a.m. on the 29th day of September, 2005, the following described property as set forth In sald'Summary Final Judgment, to-wit: UNRECORDED LOT 5 OF LOT 41, GREEN ACRES ADDITION NO. 1, AS RECORDED IN PLAT BOOK 5, PAGES 6 AND 7, PUBLIC RECORDS OF CITRUS COUNTY, FLORIDA, BEING MORE PARTICULARLY DESCRIBED AS FOLLOWS: COMMENCE AT THE NE CORNER OF SAID LOT 41, GREEN ACRES ADDITION NO. 1; THENCE S. 00'14'28"W. ALONG THE EAST UNE OF SAID LOT 41, A DISTANCE OF 499.00 FEET TO THE POINT OF BEGINNING; THENCE CONTINUE S. 00-14'28"W., 125.90 FEET TO THE SE CORNER OF SAID LOT 41; THENCE S. 88*49'19"W., 184.94 FEET ALONG THE SOUTH LINE OF SAID LOT 41; THENCE N. 00"14'23"E., 124.46 FEET; THENCE N. 88'22'40"E., 184.99 FEET TO THE POINT OFBEGINNING. SUBJECT TO A 10 FOOT EASEMENT FOR INGRESS AND EGRESS ALONG THE WESTERLY LINE THEREOF.. TOGETHER WITH 1999 SHOREWOOD VIN#S 10L26668U AND 10L26668X. Dated this 1st day of September, 2005. BETTY STRIFLER Clerk of the Circuit Court (CIRCUIT COURT SEAL) By: -s- Judy Rdmsey, September 16 and 23, 2005. 04-42390 (INL.) 881-0923 FCRN,. UEN) NOTICE OF FORECLOSURE SALE NOTICE IS HEREBY GIVEN pursuant to a Summary RFinal Judgment of Foreclosure dated September 1, 2005, entered In Civil Case No. 05-CA-2309 of the Circuit Court of the 5TH Judicial Circuit in and for CITRUS County, Inverness, Rorida. I will sell to the highest and best bidder for cash at Jury Assembly Room In the New Addition at the CITRUS County Courthouse located at 110 North Apopka Avenue In Inverness. Florida, at 11:00 a.m. on the 29th day of September, 2005, the following described property as set forth In sold PUBUC REC- ORDS OF CITRUS COUNTY, FLORIDA. AS AMENDED IN PLAT BOOK 9, PAGE 87-A OF THE PUBUC RECORDS OF CITRUS COUNTY, FLORIDA. Dated this 1st day of September, 2005. BETTY STRIFLER Clerk of the Circuit Court (CIRCUIT COURT SEAL) By: -s- Judy Ramsey Deputy Clerk IN ACCORDANCE WITH THE AMERICANS WITH DISABIU- TIES ACT, persons with disabllitiles needing a special ac- commodatlon should contact COURT ADMINISTRA- TION, at the CITRUS County Courthouse, at NONE, 1-800-955-8771 (TDD) or 1-800-955-8770, via Florida Re- lay Service. Publlihed two (2) times In the Citrus County Chronicle, September 16 and 23, 2005, 05-41954(FTN) CITRUS COUNTY (FL) CHRONICLE 882-0923 FCRN Notice of Sale Under F.S. Ch. 45 Nancy L. Brunswig vs. Amy Jo Kerns, et al. PUBLIC NOTICE IN THE CIRCUIT COURT FOR CITRUS COUNTY, FLORIDA Case No.: 2005-CA-274 Nancy L. Brunswig, Plaintiff, vs. Amy Jo Kems and David E. Kerns, Jr., Defendants. CLERK'S NOTICE OF SALE UNDER F.S. CHAPTER 45 NOTICE IS GIVEN that,. In accordance with the Default Final Judgment of Foreclosure dated September 1, 2005, In the above-styled cause, I will sell to the highest and best bidder for cash at the Jury Assembly Room, at New Citrus County Courthouse in Inverness, FL, at 11:00 A.M., September 29, 2005, the following described property: LOT 1, BLOCK 21, APACHE SHORES UNIT 3, ACCORDING TO PLAT THEREOF AS RECORDED IN PLAT BOOK 4, PAGES 45 AND 46, PUBLIC RECORDS OF CITRUS COUNTY, FLORI- DA; AND THAT PORTION OF LAND LYING SOUTH OF LOT 8, BLOCK 22, AND THAT PORTION LYING NORTH OF LOT 1, BLOCK 21 APACHE SHORES UNIT 3, ACCORDING TO PLAT THERE- OF AS RECORDED IN PLAT BOOK 4, PAGES 45 AND 46, PUBLIC RECORDS OF CITRUS COUNTY, FLORIDA, BEING THAT PORTION OF VACATED PONY EXPRESS WAY. TOGETHER WITH A 1972 GRAYCO MOBILE HOME, TITLE #4792779, VIN ID #13909, DECAL R 381281, DECAL TYPE: REAL PROPERTY. Dated: September 6, 2005. Betty Strifler Clerk of Court By: -s- Judy Ramsey Deputy Clerk Published two (2) times in the Citrus County Chronicle, September 16 and 23, 2005. 898-0923 FCRN PUBLIC NOTICE NOTICE OF PROPOSED RULE DEVELOPMENT WORKSHOP NAME OF AGENCY Southwest Florida Water Management District RULE CHAPTER TITLE: WATER LEVELS AND RATES OF FLOW RULE CHAPTER NO.: 40D-8 PURPOSE AND EFFECT: To amend 40D-8 to Incorporate minimum flows for the middle segment of the Peace River pursuant to Section 373.042, Florida Statutes. SUBJECT AREA TO BE ADDRESSED: Establishment of minimum low, medium and high flows for the middle Peace River. The middle segment of the Peace River Is generally that portion lying between Zolfo Springs and Arcadia. SPECIFIC AUTHORITY: 373.044, 373.113, 373.171, F.S. LAW IMPLEMENTED: 373.036, 373.0361, 373.0395, 373.042, 373.,0421, 373.086, F.S. RULE DEVELOPMENT WORKSHOP WILL BE HELD: DATE: Tuesday, October 11, 2005, beginning at 6:00 p.m. PLACE: Southwest Florida Water Management District's Bartow Service Office, 170 Century Blvd., Bartow, Flori- da 33830-7700 WHAT: Public workshop on proposed minimum flows for the middle Peace River. One or more governing board or basin board members may attend. THE PRELIMINARY TEXT OF THE PROPOSED RULE DEVEL- OPMENT IS NOT AVAILABLE. THE PERSON TO BE CONTACTED REGARDING THE PRO- POSED RULE DEVELOPMENT IS: Martin Kelly, Manager, Ecologic Evaluation Section, 2379 Broad Street, Brooks- vllle, FL 34604-6899, (352) 796-7211, extension 4235. The District does not discriminate on the basis of disabil- Ity. Anyone requiring reasonable accommodation should contact DIanne Lee at (352)796-7211, ext. 4658; TDD only: 1-800-231-6103. NOTICE OF PROPOSED RULE DEVELOPMENT WORKSHOP NAME OF AGENCY Southwest Florida Water Management District RULE CHAPTER TITLE: WATER LEVELS AND RATES OF FLOW RULE CHAPTER NO.: 40D-8 PURPOSE AND EFFECT: To amend 40D-8 to incorporate the next priority lake pursuant to Section 373.042, Florida Statutes. SUBJECT AREA TO BE ADDRESSED: Establishment of minimum lake levels and guidance levels for Lakes Parker and Bonnie In Polk County, Flori- da. SPECIFIC AUTHORITY: 373.044, 373.113,373.171, F.S. LAW IMPLEMENTED: 373.036, 373.0361, 373.0395, 373.042, 373.0421,373.086, F.S. RULE DEVELOPMENT WORKSHOP WILL BE HELD: DATE: Thursday, October 13, 2005, beginning at 6:00 p.m. PLACE: Southwest Florida Water Management District's Bartow Service Office, 170 Century Blvd., Bartow, Flori- da 33830-7700 WHAT: Public workshop on proposed minimum and guidance levels for Lakes Parker and Bonnie In Polk County, Florida. One or more governing board or ba- sin board members may attend, THE PRELIMINARY TEXT OF THE PROPOSED RULE DEVEL- OPMENT IS NOT AVAILABLE. THE PERSON TO BE CONTACTED REGARDING THE PRO- POSED RULE DEVELOPMENT IS: Doug Leeper, Senior En- vironmental Scientist, Resource Conservation and De- velopment Department, 2379 Broad Street, Brooksville, FL 34604-6899, (352) 796-7211, extension 4272. The District does not discriminate on. the basis of disabil- Ity. Anyone requiring reasonable accommodation should contact Dianne Lee at (352)796-7211, ext. 4658; TDD only: 1-800-231-6103. Published one (1) time In the Citrus County Chronicle, September 23,2005. 893-0930 FCRN Notice of Sale Pursuant to Ch. 45 Deutsche Bank National Trust Company, etc. vs. Tammy L Cralg, et al., PUBLIC NOTICE IN THE CIRCUIT COURT FOR CITRUS COUNTY, FLORIDA. CIVIL DIVISION CASE NO. 2005-CA-2218 UCN: 092005CA002218XXXXXX DEUTSCHE BANK NATIONAL TRUST COMPANY, TRUSTEE, ON BEHALF OF THE CERTIFICATEHOLDERS OF MORGAN STANLEY ABS CAPITAL I INC. TRUST 2004-NC2, MORTGAGE PASS-THROUGH CERTIFICATES, SERIES 2004-NC2, Plaintiff, vs. TAMMY L CRAIG, et al., Defendants. NOTICE OF SALE PURSUANT TO CHAPTER 45 NOTICE IS HEREBY GIVEN pursuant to an Order or Sum- mary Final Judgment of Foreclosure dated July 14, 2005 and an Order Resetting Sale dated September 8, 2005, and entered In Case No. 2005-CA-2218 UCN: 092005CA002218XXXXXX of the Circuit Court of the Fifth Judicial Circuit In and for Citrus County, Florida, where- in Deutsche Bank National Trust Company, Trustee, on Behalf of the Certiflcateholders of Morgan Stanley Is Plaintiff and TAMMY L. CRAIG; EUGENE A. CRAIG; Jury Assembly Room In the New Addition to the New Citrus County Courthouse, 110 North Apopka Avenue, Inverness, Florida 34450 at Citrus County, Florida, at 11:00 a.m. on the 6th day of October, 2005, the following described property as set forth In said Order or Final Judgment, to-wit: LOT 23, BLOCK 52, BEVERLY HILLS UNIT 4, ACCORDING TO THE PLAT THEREOF, RECORDED IN PLAT BOOK 5, PAGES 130, 131 AND 132, INCLUSIVE, PUBLIC RECORDS OF CITRUS COUNTY, FLORIDA. If you are a person with a disability who needs any ac- commodation In order to participate In this. proceed- Ing, you are entitled, at no cost to you. to the provision of certain assistance. Please contact the Court at 352-341-6481 within two (2) working days of your re- ceipt of this Notice; If you are hearing or voice impair- ed, call Florida Relay Service (800) 955-8770. DATED at Inverness, Florida, on September 9, 2005. BETTY STRIFLER As Clerk, Circuit Court By: -s- Judy Ramsey As Deputy Clerk Published two (2) times In the Citrus County Chronicle, September 23 and 30, 2005. 884-0923 FCRN Sale 10/6/2005 PUBLIC NOTICE OF SALE NOTICE IS HEREBY GIVEN that the undersigned Intends to sell the personal property described below to en- force a lien Imposed on said property under The Florida Self Storage Facility Act Statutes (Sections 83.801- 83.809). The undersigned will sell at public sale by competitive bidding on Thursday, the 6th day of October, 2005, at 12:30 PM, on the premises where said property has been stored and which are located at Federal Stor- aae. 1227 S. Lecanto Hwv. City of Lecanto, County of Citrus, State of Florida, the following: Name: UnI: Cont : Manny Martin D032 HHG Christine M. Cunningham D040 HHG June M. Oliver C069 HHG Purchases must be paid for at the time of purchase In cash only. All purchased items are sold as Is, where Is. and must be removed at the time of the sale. Sale Is subject to cancellation in the event of settlement be- tween owner and obligated party. Published two (2) times In the Citrus County Chronicle, September 16 and 23, 2005. 895-0930 FCRN Notice of Sale Mortgage Electronic Registration Systems, Inc., etc. vs. MIchele Hurley, et al., NOTICE OF FORECLOSURE SALE NOTICE IS HEREBY GIVEN pursuant to a Final Summary Judgment of Foreclosure dated September 8, 2005, entered Iq Civil Case No.: 2004-CA-3514 of the Circuit Court of the Fifth Judicial Circuit In and for Citrus Coun- ty, Florida, wherein MORTGAGE ELECTRONIC REGISTRA- TION SYSTEMS, INC., as Nominee for Novastar Mort- gage, Inc., Plaintiff, and MICHELE HURLEY, UNKNOWN SPOUSE OF MICHELE HURLEY, RUNNING WOLF CON- SERVATORY, INC., RELAX DEVELOPMENT AND INVEST- MENTS, 6th day of October, 2005, the following described real property as set forth In said Final Septem- ber 12, 2005. BETTY STRIFLER CLERK OF THE COURT (CIRCUIT COURT SEAL) By: -s- Judy Ramsey Deputy Clerk Published two (2) times In the Citrus County Chronicle, September 23 and 30, 2005. 865-0930 FCRN Notice of Action Property New Vista Properties, Inc. vs. Lulda Dalool PUBLIC NOTICE IN THE CIRCUIT COURT OF THE FIFTH JUDICIAL CIRCUIT - IN AND OR CITRUS COUNTY, FLORIDA CIVIL ACTION Case No. 05-CA-2213 NEW VISTA PROPERTIES, INC., a Florida corporation, Plaintiff, vs. LUIDA DALOOL, -a : - Defendant. NOTICE OF ACTION CONSTRUCTIVE SERVICE PROPERTY TO: DEFENDANT, LUIDA DALOOL, IF ALIVE AND IF DEAD, UNKNOWN WIDOWS, WIDOWERS, HEIRS, DEVISEES, GRANTEES, AND ALL OTHER PERSONS CLAIMING BY, THROUGH, UNDER OR AGAINST THEM AND ALL OTHER PARTIES CLAIMING BY, THROUGH, UNDER OR AGAINST THE FOREGOING DEFENDANTS AND ALL PERSONS HAV- ING OR CLAIMING TO HAVE ANY RIGHT, TITLE OR INTER- EST IN THE PROPERTY HEREIN. DESCRIBED, AND ALL OTHERS WHOM IT MAY CONCERN: YOU ARE HEREBY NOTIFIED that an action for specific performance on the following described property In Citrus, County Florida: Lot 18, Block 747, CITRUS SPRINGS, UNIT 14, a Subdlvl- sIon according to the-plat thereof as recorded In Plat Book 6, Pages 110 through 115, of the Public Records of Citrus County, Florida Lot 19, Block 747, CITRUS SPRINGS, UNIT 14, a Subdivi- sion according to the plat thereof as recorded In Plat Book 6, Pages 110 through 115, of the Public Records of Citrus County, Florida Lot 20, Block 747, CITRUS SPRINGS, UNIT 14, a Subdivi- sIon according to the plat thereof as recorded In Plat Book 6, Pages 110 through 115, of the Public Records of Citrus County, Florida Lot 21, Block 747, CITRUS SPRINGS, UNIT 14, a Subdivi- sion according to the plat thereof as recorded In Plat Book 6, Pages 110 through 115, 9, 2005, and file the original with the Clerk of this Court either before service on Plaintiff's at- torney or Immediately.thereafter; otherwise a default will be entered against you for the relief demanded In the Complaint. WITNESS my hand and seal of this Court. September 2, 2005. BETTY STRIFLER Clerk of Court By: M. A. Michel Deputy Clerk Published four (4) times In the Citrus County Chronicle. September 9, 16,23 and 30.2005. 892-1014 FCRN Notice of Action/Quiet Title Brian G. McKenzIe vs. Josephine D. Romano, et aL PUBLIC NOTICE IN THE CIRCUIT COURT OF THE FIFTH JUDICIAL CIRCUIT IN AND FOR CITRUS COUNTY. FLORIDA CASE NUMBER: 2005-CA-3283 BRIAN G. McKENZIE, SPlaintiff. vs. JOSEPHINE D. ROMANO, and If dead, then of the unknown devisees, legatees, grantees, heirs, or claimants otherwise under or against her. Defendants. NOTICE OF ACTION TO: JOSEPHINE D. ROMANO Last Known Address: 7001 10th Avenue Brooklyn, NY 11228-1203 YOU ARE NOTIFIED that an action to quiet title (tax deed) concerning the following property In Citrus County, Rorida: LOTS 51-58, Inclusive, BLOCK 157 of INVERNESS HIGH- LANDS, UNIT 9, according to the plat thereof, as record- ed In Plat Book 100, Page 517, Public Records of Citru October 23, 2005, and file the original with the Clerk of this Court either before service on Plaintiff's at- torney or Immediately thereafter; otherwise a default will be entered against you for the relief demanded In the Complaint. DATED this 16th day of September, 2005, BETTY STRIFLER As Clerk of the Court By: -s- Shelley Sansone Deputy Clerk Published four (4) times In the Citrus County Chronicle, September 23, 30, October 7 and 14, 2005. FRIDAY, SEPTEMBER 23, 2005 13D LITRfUS CUT..~JYA ( .PL) CROICILE 2005 ALL UT SELL-OU COMBINE FAMILY PLAN PRICING WITH ALLNEW FACTORY REBATES & INCENTIVES FOR BEST PRICING ON ALL REMAINING 2005'S IN STOCK! FULL*SIZE LUXURY AND GREAT FUEL ECONOMY r)asiCmoa1 l NEW 2005 LINCOLN TOWN CAR * FULL FRAME * 6 PASSENGER NEW 2005 MERCURY GRAND MARQUIS * REAR WHEEL DRIVE * 5 ***** SAFETY U. III FULL-SIZE COMFORT IN A SMALLER PACKAGE! N, i'I' ALL NEW 2005 MERCURY MONTEGO NEW 2006's A IS--- L.--C '00 MERCURY GRAND MARQUIS VIBRANT WHITE WITH LIGHT GRAPHITE INTERIOR. KEYLESS ENTRY. POWER SEAT, POWER WINDOWS, LOCKS, TILT, CRUISE, WHITEWALL MICHELINS. 41,500 MILES. 3946A s8,750 '03 MERCURY GRAND MARQUIS LSE '03 MERCURY GRAND MARQUIS NEW '05 LOCE. DUAL POWER JUST FRONT BUCKET D IN UPGRADE 110 PACKAGE LOCAL ONEOWNER JUST SEATS WIIH CENTER CONSOLE SHIFTER A ON NEW MERCURY. GOLD ASH COLORS, AMISM/CD. ALLOY WHEELS, KEYLESS EN T REACTION CONTROL AJUt'TABLE PEDALS. KEYLESS AUTO-TEMP CLIMATE CONTROL MERC AIR ENTRY. AUTO ONfOFF HEADLAMPS, MERCURY SUSPENSION. MORE. PA2893 CERTIFIED TOOl 13.000 MILES 91A BUCKET SEATS '15,995 '03 LINCOLN TOWNCAR '03 LINCOLN TOWNCAR ANOTHER LOW MttI,. PREMIER CERTIFIED, S tItRaBCHMMETALLICWETNSTONEFORMALROOF LUXURY TOWN SEDAN Y LIUNCOLN. VIBRANT AND MATCHING LEATHER DUAL POWER SEATS. 17' WHITE WITH BEIGE DUAL POWER LEATHER SPOKE WHEELS. WHITEWALL MICHELNS. CUMATE SEATS. IKEYLESSENTRY.AM C. AUTO ONf CONTROL, POWER TRUNK, KEYLESS ENTRY. HEADLAMPS. POWER TRUNK PULLDOWN & PREMIERCERIIED. 27 700MII.ES.PA29I MORE. 17 ALUMINUM SPOKE WHEELS. DON'T MISS mi PX2909 14,960 MILES PRESIDENTIAL '96 LINCOLN TOWNCAR SIGNATURE BLACK BEAUTY!! POPULAR BODY STYLE. LOW 66,300 MILES. POWER MOONROOF, LEATHER, AND MUCH MORE. 3584A 8.75O AUTOMATIC 6 SPEED TRANSMISSION ARRIVING DAILY! '-'4. PRE-OWNED MERCURY GRAND MARQUIS II cTlnrwi SPECIAL PURCHASE FROM FORD MOTOR COMPANY 2005 FORD TAURUS PAYMENTS FROM 249MONTH 12" SHORTER THAN A GRAND MARQUIS B ~SEE ALL THE NEW * COLORS AND f REFINEMENTS FOR 2006! '99 MERCURY GRAND MARQUIS LS ABSOLUTELY THE MOST GORGEOUS 99 MARQUIS IN TOWNIT ONLY SS.000 LOW MILES. VIBRANT WHITE WITH WHITE LEATHER INTERIOR AND EMERALD GREEN COACH ROOF. LOADED WITH FEATURES. MUST SEE HOW SHARP THIS ONE IS!! PX2878A so on=a lw- d '05 MERCURY GRAND MARQUIS LS COME CHECi OUT THE SAVINGS ON THIS TOPPED UP LUXURY LS. ARIZONA BEIGE WITH PARCHMENT DUAL POWER LEATHER SEATS, AUTO-CLIMATE CONTROL KEFLESS ENTRY, 16 ALUMINUM WIAtES END WHITEWALL MICHEUNS. MERCURY CERTIFIED. PXOAH ROO2917 COACH ROOF WITH NO MONEY DOWN!** * POWER WINDOWS DOOR LOCKS * AM/FM/CD SOUND SYSTEM * POWERFUL, YET ECONOMICAL V6 ENGINE * REMOTE ENTRY FOBS & MORE PX2920 PRE-OWNED LINCOLN TOWNCARS IN STOCK! '04 LINCOLN TOWNCAR AUTUMN RED WITH STONE LEATHER AND MATCHING FORMAL ROOF. DUAL POWER LEATHER SEATS WITH AUTUMN PIPING. SPOKE ALUMINUM WHEELS WITH WHITE WALL MICHENS. KEYLESS ENTRY, AM/FMCD, MORE. LINCOLN PREMIER CERTIFIED. PX2930 14.975 LOW MILES Vw '05 MERCURY GRAND MARQUIS LS EXTRA LOW MILES ON THIS MERCURY CERTIFIED LUXURY LS. LEATHER, KEYLESS ENTRY, AUTO-CLIMATE CONTROL, ANTM.OCK BRAKES, AND MORE. SILVER BIRCH COLORS. PX2906 5.900 MILES '05 LINCOLN TOWNCAR SIGNATURE GORGEOUS CERAMIC WHITE WITH PARCHMENT LEATHER. DUAL POWER SEATS, REVERSE PARK SENSORS, WHITEWALL MICHELINS, 17- ALUMINUM SPOKE WHEELS. LINCOLN PREMIER CERTIFIED. PX2925 1,850 MILES '96 LINCOLN TOWNCAR SIGNATURE ONLY 48,150 EXTRA LOW, PAMPERED MILES ON THIS RARE DIAMOND ANNIVERSARY SIG SERIES. POWER MOONROOF, 16" ALUMINUM WHEELS, KEYLESS ENTRY, DUAL POWER LEATHER SEATS, AND MUCH MORE. 3828A JSCTION NY.NT SPONSIRE FR TYKWL E RROR& DUM TO PUDUCATION DEADLINES SOME UNITS MAY BE SOLD. P ORD C REIC APA4O'dALI OT-ALL JP'PuAITS MA (C 0PLIFY. TAXTA& FEES MUST BE PAID ATDaELIVEY,6%APR FOR72 MONTHS. S '!! II B a r..nwif eim.,....FI rrxa n,, .,,,p %W mn 410 m0assa5 NN6010 MSRP...................................... .....14,89000 You Save....................................... 3,28600 YOU PAY ONLY You Save........................................5,19800 YOU PAY ONLY ReCLRADO SB *Reg Cab #N6343" . MSRP ..........................................21,21500 You Save........................................4,22300 YOU PAY ONLY #N6312 W MSRP .........................................39,80500 , You Save ........................................9,00900 OU PAY ONWL #N6337$- 00 MSRP ........................................ 27,39000 You Save........................................5,77300 $2515r MSRP........................................38,97000 You Save......................................$8,83500 YOU PAY ONLY *On select 2005 makes and models. See dealer for details. Prices & Payments exclude tax, tag, title and dealer fees (299.50) all rebates, customer loyalty & dealer incentives included, expires the following Monday of ad date. Photos for illustration purposes only. SPMI"?ALPURC ( Ch se 'ge Neons GaDOWN PERMONTHWA. From y CavalierMileage m.c 04 CHEVY CAVALIER #8451T '8,9880 1997 HONDA ACCORD Great Buy] #D50748B '8,9880 1999 CHEVY 04 CHEVROLET SUBURBAN LT MALIBU Low miles, leather. #8644A Chevy Classic. #8413 '9,9881 '9,988" I.. mmmm a I 03 MITSUBISHI 02 CHEVY 02 CHEVY CAMARO 02 CHEVY ASTRO OUTLANDER BLAZER T-Tops 35th Anniv. Edition. Affordable, clean, low miles. Roomy, clean. #B50267B 4 Dr, LS, Loaded. #8432T #8456P #N5245A $13,927' $13,995 $13,995 $ 14,123' 03 NISSAN 04 DODGE CARAVAN 05 CHEVY XTERRA Blue, clean, all power. MAUBU Loaded. #N5128P #26020A New body, $AVE. #8551P $15,123 15,7931 $16,595 04 CHEVY 01 GMC 02 CHEVY 05 CHEVROLET 05 CHEVY 04 BUICK 03 CHEVY SILVERAD O 05 CHEVY COLORADO SILVERADO 4X4 YUKON TAHOE LT SILVERADO LS 1500 IMPALA RENDEZVOUS Z71 EXT CAB CREW CAB Red. #J050729A #J050450A 1 owner, great buyl #8536P #25484A Why stop have 2 to choose from Loaded, $AVE. #26031A Must seel #8570P Auto, loaded, fact. warr. #8558F L6,888 '16,9889 '18,988 $22,888 $16,986 $17,891' 21,593 '21,623' -72 months @ 7.9% Selling price $11,588. .tPrices and payments exclude tax, tag, title and dealer fee (299.50)and includes all factory incenties, rebates and customer loyalty. Dealer incentives subject to change. See Dealer for Details. Photos for illustration purposes only. { CHEVROLET CHEVROLET AL 187746927998 LOCAL 1877.692.7998 41515 MY CRYSTAL 637-5050 MY CRYSTAL 5 S. Suneoast Blvd., Homosassa 2209 Hwy. 44 West, Inverness 14D Fl iDfAY SEPTEMHBR 23, 2005 CITRUS COUNTY (FL) CHRONICLE n Tn[ YOU PAY ONLY 2005 CHEVY TAHOE 00 DODGE CARAVAN J6.wsp 10th Annual dCitrus County Sheriff s Safety E xpo September 24 Crystal River Mall - 10 a.m. to 3 p.m. Schedule of Events' 10:00................ Expo Starts 11:30-12:00.......... Captain Eckstein Emergency Management Hurricanes: Before, during, and after 12:00-12:30..........Detective Kanter Scams and Identity Theft Awareness, prevention and response 12:30-12:45...... ... K-9 Demonstration 12:45-1:15............ Detective Seffern Sex Offenders Tracking / monitoring and Sheriff's program overview 1:15-1:30...........K-9 Demonstration 1:30-2:00.............Deputy Farmer Child Lures How to protect children 2:00-2:15...........K-9 Demonstration : 2:15-2:30............Specialist Jakob Crime Prevention Home safety and personal safety presentation 3:00 ................ Expo Ends The Crime Prevention Staff will be at the Sheriff's table throughout the day to answer questions. For more information contact Sgt. Chris Evan at 726-4488. Come meet McG Participants and displays ruff the Crime-fighting Dog. [- 1 .........American Hurricane Specialists [ 12........American Red Cross [1 3........Blind Americans -1 4........Citrus Hearing Impaired Program Services (CHIPS) M 5........Sheriff's Crime Prevention -1] 6........Sherff's Emergency Management -17........Sheriff's Human Resources 1 8........Sheriff's Seniors vs. Crime Program I- 9........Sheriff's Victims Advocates - 10......Sheriffs Bicycle & Pedestrian Safety Program [--11 ......Crystal River Police Department [1 12......United States Coast Guard -114......Nature Coast E.M.S -- 15......Citrus County Fire Rescue [ 16...... Citrus County Fire Prevention [ 17......Community Legal Services of Mid-Florida 1 18......Coastal Hurricane Specialists L1 19......Citrus United Basket (CUB) - 20......Center for Independent Living [ 121......Wachovia - 22......Childhood Development Services [ 23...... Cedar Creek at Kings Bay [1" 24......Lowes 125......Hospice of Citrus County [ 26......Nature Coast Volunteer Center -- 27...... Porter's Locksmithing [-] 28......Sertoma Center [1- 29...... Florida State AARP Office [1-]30......The Home Depot -131......Seven Rivers Nursery -1I 32......Wesley Armitage alarms 7133......Citrus County Chronicle Swwwctfrotcleonhtneb.com Working together we can all prevent crime! I crimeprevention @sheriff citrus.org 1-888-ANY-TI PS I 10th Annual C Iitrus ounty Sheriffs Safety Expo September 24 Crystal River Mall 10 a.m. to 3 p.m. JEFFRE 7J. flVWs The Citrus County Sheriff's Office Crime Prevention Division wants to welcome you to the annual Safety Expo sponsored by the Sheriff's Office and Citrus County S.A.L.T. (Seniors and Law Enforcement Together) Council. Every year October is designated National Crime Prevention Month. It is an opportunity to remind all people in our community how important crime prevention is. We all want a crime-free society and a high quality of life. We have a full day of programs and exhibits geared to make your life safer. I hope that you will come out to this important event. Crime Prevention Mission Statement: The mission of the Crime Prevention Division is to reduce crime through public awareness and education, community partnerships and the utilization of department resources., What is Crime Prevention? Crime Prevention is the act of stopping or preventing a crime before it occurs. For a crime to take place, there must be several elements present. The primary elements are desire and opportunity. Desire is the criminals desire to commit the crime, and opportunity is the availability for the criminal to commit the offense, such as an unlocked door or unsecured property. By taking preventative steps you may reduce your chances of being a victim of crime. Crime Prevention tips to make your home safer... 1. Keep all doors and windows locked. 2. Keep shrubs, bushes and trees trimmed. 3. Use outside lighting (light should be on a timer or photocell). 4. Hate 'your house number on your home but not your name. 5. Secure all outside property such as ladders, equipment. etc. 6. Use an UL appro\ ed monitored alarm system. 7. Keep all \aluables such as jewelry in a hidden location. 8. Use a shredder before throw ing away bills and important papers. 9. Your answering machine should not say that you are not home. , 10. The exterior should offer no place for concealment. N 11. Install peepholes in doors. 12. Utilize solid doors. A Prizes: (MUST HAVE THE VENDOR BOX INITIALED) No need to be present for drawing. Limit one winner per household. * All About Promotions Duffel Bag * Citrus County Sheriff's Office - Vehicle Anti-theft Device * Citrus Memorial Hospital Umbrella (two chances to win) * Fero Funeral Home Golf Umbrella (five chances to win) * Gist RV of Inverness Gift basket * Kmart of Crystal River DVD Player and DVD movie * SunTrust Bank of Beverly Hills Gift basket * Wal-Mart of Inverness $25 gift card Name- Address Phone number for prize entry. Seniors vs. Crime Program The Seniors vs. Crime Program is a joint project of the Citrus County Sheriff's Office and the Florida Attorney Generals Office. It was brought to Citrus County in .2002, and to date the program volunteers have recovered over $500,000 for Citrus County residents and Florida citizens. The programs purpose is to give residents an avenue of complaint if they feel that they have been taken advantage of, scammed, or did not receive what they thought they should have. The main office is located in Beverly Hills at 4093 North Lecanto Hwy. For information or to get the office hours, please call 249-9139. Neighborhood Watch Neighborhood Watch is people watching out for each other. It is taking a vested interest in your community and wanting to maintain a high quality of life. If you are interested in starting a program, please contact the Sheriff's Office. c ., y. s u v 4m \ uww- Working t!!E(I!J14U f we!Mcan EalIE irevent I crime! ww-seifctrsor ciepeenio-hei*ctusog -88ANYTP Free Programs and Services Available: * Residential Security Surveys * Agricultural Security Surveys * Scam Information * Computer Crimes and Security * Auto Theft Prevention * Telemarketing * Disaster Preparation * Neighborhood Watch * Personal Safety * Children's Safety * Gun Safety and Laws * Operation Identification * McGruff Crime-fighting Dog * Pre-Construction Information * Crime Prevention Through Environmental Design Alarm Systems Especially for Business: Commercial Security Surveys Workplace Violence Robbery Disaster / Emergency Planning STAR Program Blast Fax For more information contact Sgt. Chris Evan at 726-4488. IWARNINGI k ,, I wpm FREE Files of Life ON16sw Contact Us | Permissions | Preferences | Technical Aspects | Statistics | Internal | Privacy Policy © 2004 - 2010 University of Florida George A. Smathers Libraries.All rights reserved. Acceptable Use, Copyright, and Disclaimer Statement Last updated October 10, 2010 - - mvs
http://ufdc.ufl.edu/UF00028315/00266
CC-MAIN-2019-09
refinedweb
78,962
78.55
IPv4 vs IPv6: The Road Ahead 334 jeffy124 writes "With the world moving towards having every device under the sun being Internet-connected, is the Internet going to be too large? This article off CNN.com examines this potential situation. They look into the problems of switching networks from IPv4 to IPv6, and the inclusion of inter-operability between the two. Benefits of moving to IPv6 are looked at, but so are the critics of it who point out that if we don't have a problem now, why fix it? While low of technical details, the story points out that not many systems out there currently support IPv6. " More IP address !=more ease (Score:2) Will it give back that huge class A domain that MIT still has? Will my cable modem ISP with IPV6 give me more than 1 IP address so I can turn off NAT and DHCP? probably not. Re:More IP address !=more ease (Score:2) In consequence, there will be no real point in a DNS system, as it exists today. There would be no way a centralized system could keep up with the changes. With IPv6, I suspect you'll find that DNS is replaced with self-identifying systems, using the Anycast protocol. Each machine would then be responsible for knowing what it was called, at that time. (Which sounds reasonable to me!) We haven't seen that, so far, because Anycasting is still too new and few existing IPv6 stacks support it. However, when IPv6 starts getting seriously used, it could become the most important protocol of all. Re:More IP address !=more ease (Score:2) Re:More IP address !=more ease (Score:5, Informative) The theory behind all this is that you can then move a device from one network to another, without ever having to worry about routing problems, IP numbers colliding, or other such mundane trivia. "Permanent" addresses, in this system, don't exist. They're all calculated. How does this work, in practice? Well, let's say that Joe Bloggs is connected to AOL. AOL decides that the backbone provider it uses can get stuffed, and switches. This changes all of AOL's addresses, and therefore Joe Bloggs' address. However, because addresses have a lifetime attached to them, the old address remains active (although forwarded) for a finite length of time, although new connections to the old address are prohibited. Because of this, it makes no sense for some central registry to store AOL's IP number. It can change once every 60 seconds, along with the IP address of everyone/everything connected via it. The only person who can meaningfully store AOL's IP address becomes AOL, itself. Nobody else can possibly know it, with any reliability. Normally, ISPs and large corporations aren't going to flip around like that. But they -can-. The protocol permits it. Because of that, and because uptime is increasingly important, they will then be able to shop for a secondary provider for a backup link, in case the first one dies. In IPv4, a backup link via an alternative provider would be lethal. There would be no way to handle the changes in addressing, unless the entire ISP or company was behind a NAT system with High Availability at the IP level, which causes its own problems. With IPv6, the change-over would take under 5 seconds for the whole of AOL. Nobody would notice the delay, nobody would get disconnected, and the whole setup is much simpler. Not exactly correct (Score:2) You seem to be confused: The point of having a static address is so that one machine can be found by others. You have to have some fixed address in order to describe who it is your connecting to. Imagine the havoc that would pass if area codes in telephone numbers could change on moments notice. Take away the phone book too, since you think dns is uneeded. (Works fine for calling out- since in that case you dont care what your number is. but who are you going to call, exactly?) If there is no way for anyone else to determine what a given servers address is, then there no way anyone else can connect to it. In reality each "entity" be it a megacorp or a measly dialup user, will be given 80 bits worth of routable address. 16 bits of that they can use for subnets. Only the 48 starting bits are really "fixed". The 128 bit addressing scheme is really an attempt to get everyone tons of "static" routable addresses. And There will of course be a name-to address mapping similiar to what DNS does now. The simple reason is that noone is going to type in a huge monster address when they want to hit a web page. Re:Not exactly correct (Score:2) (Of course, this would be extremely easy to spoof, if you weren't also using IPSEC and machine authentication to validate the connection.) This negates any need for a fixed destination. It =does= result in far more peer-to-peer traffic, removes ALL centralized control, and requires Anycasting to be implemented fully on all stacks, but it DOES kill off ICANN, and that can't be a bad thing. Anycasting works by multicasting to all receiving hosts, and then having the first match transmit back. At least, that's the theory. It removes any need for centralized data stores, by using a peer-to-peer search and reply system. Re:Not exactly correct (Score:2) Re:More IP address !=more ease (Score:2) Re:More IP address !=more ease (Score:2, Informative) Further, they anticipated an increasing use of portable devices, such as laptops and hand-helds, which made it important to have Mobile IP a part of the protocol. The result was the complete absence of any notion of static IP addresses. Addresses are assigned at connection time, and last until either they're revoked by the owner, or they time out. Once they reach that point, they are marked as expiring. A new address is then generated. The host machine is required to then notify ALL machines connected to it or that it connects to that the address is changing, and what that new address is. The remote machines then have a certain length of time (it's not long) to change over. During the change-over, if the host has moved, the old IP addresses are forwarded by intermediate routers to the new location. In theory, this means that IPv6 has not just 2^128 addresses, but also a TOTALLY dynamic topology. (Mapping the Internet'll suddenly become a whole lot more interesting! In turn, this means that you can have wireless IP and multiple providers, move from one zone to another, and be guaranteed you'll remain connected. Further, because addressing follows an enforced heirarchy, router tables will NEVER need more than enough addresses to go one layer up or one layer down. For 99.999% of providers, this will mean an entire 512 entries, tops. Compare this with the millions of entries a typical router handles. Forwarding lag will be carved, sliced, diced and roasted. Re:More IP address !=more ease (Score:2) One of the big problems with IPv4 is the difficulty of routing. Given that there's a shortage of IP addresses, we can't let ISPs allocate large blocks, so they have to get several smaller blocks which results in several entries in routing tables. Worse, if an ISP's customer wants its own address allocation that it can take to another ISP or make accessible through multiple ISPs for redundancy, that makes another entry in the routing table. The result is that routing tables are huge and not always well optimised. By making address allocation dynamic, IPv6 makes it possible to optimise address allocations for simplicity of routing. That should result in better routing decisions even as the number of addresses in use increases. Re:More IP address !=more ease (Score:2) - dynamic IPv4 addresses, often used for dialup as you say, and hard to use for web serving - IPv6 allocation of the bottom half of the IPv6 address (last 64 bits I think) - this is basically the MAC address of your Ethernet card (with some provisions to change this for privacy reasons). Not really dynamic unless you want it to change. - IPv6 allocation of the top half of the address - this is derived from your ISP, and it is *very* easy to renumber your whole network (even thousands of machines) when you switch to a different ISP. This is crucial to make sure that the route to your machines doesn't need to be stored in core routing tables in the Internet, avoiding them growing too fast. Also not dynamic unless you want to change providers. The first kind of dynamic allocation goes away completely. The MAC address type allocation is only dynamic if you want to preserve privacy, typically on a client. And the provider part allocation is slowly changing, over a number of days after you switch providers, with plenty of time for DNS servers to react. The upshot of this is that static addresses are very common in IPv6 - you only have to change your address if you switch providers. A couple of points though: - you might want to use a dynamic MAC address for outbound client requests, for privacy reasons, and a static IPv6 address (plus DNS name) for your web server (even on the same host, it's easy to have multiple addresses per interface) - networks with two Internet connections, termed multi-homed, are still a big problem for core routing tables, since they incur one 'exception' route in the core routers. There's some work going on under the term PTOMAINE (a very tortured acronym) that should solve this in the next 5 years or so, 'ietf ptomaine' should find it. Re:More IP address !=more ease (Score:2) If the cost of an IPv6 block dwindles to about ten bucks a year per thousand (pulling numbers out of the air) then I suspect each ISP account would come with 16 or so addresses. And man, would I like that. Ever try playing a DirectPlay game behind a NAT firewall? It's fine with one client and a bunch of blind portforwards, but you're on your own if you have two systems behind it that want to play. (admittedly, that's not IPv4's fault, it's that nobody knows how to read the stream to make an ip_masq_directplay as far as I know) Re:More IP address !=more ease (Score:2) IP addresses per person (Score:2) Re:More IP address !=more ease (Score:2) Re:More IP address !=more ease (Score:3, Insightful) A class A is 1/20,282,409,603,651,670,423,947,251,286,016th of the total IP6 namespace. Why not let them keep it? Yes it will (Score:3, Insightful) entire internet contains at the moment. Re:More IP address !=more ease (Score:2, Interesting) Actually, there is a standard in IPv6 for how to encode an IPv4 address as IPv6 (prepended zeros, not appended). Also, no one needs to replace a NIC. NICs talk Ethernet (typically), not IPv4 or IPv6, and the appropriate protocol is wrapped up in layers before it gets to the NIC. And there is no such thing as a NIC card, or for that matter a PIN number. Sigh. Sorry, its just irritating. Re:More IP address !=more ease (Score:2) Now try not to be such an acronym nazi. (j/k) :) Re:More IP address !=more ease (Score:2) Re:More IP address !=more ease (Score:2) Good summary of the problem (Score:2) Re:Good summary of the problem (Score:2) I certainly don't hope that. I was all for HDTV at first, but since the vendors seem far more concerned with trying to destroy time and space-shifting than actually making a quality product at a reasonable price, I wouldn't mind at all if they went down in flames. Re:Good summary of the problem (Score:2) And you then want this backed up by law? I'm sorry, but if anything is going to be succeeded by anything, making the government do it is not the right way. It's not even their job! Hopefully, what's going to happen is that the backbone providers will see IPv6 as a great technical or strategical boon and they will more or less (through hopefully non-bullying means) convince their customers to switch over. *That* is how progess happens. Remember that "law" and "progress" are seldom used in the same sentence on purpose. Re:you don't get it, do you? (Score:2) Well, I'll take this mainly as a troll. Nevertheless... It appears that you are the one who has not fully grasped the entirety of the situation. I suppose it's not only 100% a matter of rights, but also a matter of ethics. Ever since the advent of VCRs, people have been able to time-shift their viewing in the name of convenience. It's commonplace. As such, most people consider it a fair-use right. Since the government is *supposed* to follow in the interests of the people, it *should* be a right by law. (De facto, I think they call it.) For broadcasters to take that away from us while masquerading the action as an anti-piracy measure is not right, not ethical, and should be (in many people's minds, not just my own) considered illegal. man, first of all, TV is FREE to watch because of advertising As long as we are *forced* to watch the advertisements, TV is not free. The price does not always have to involve money. That aside, I would probably agree to having to watch advertisements if I could time-shift the program. But not if I had a choice. As well, mandatory advertisement-watching disallowal of time-shifting would not be in the best interests of the industry either. (Take Napster for example. Is it any coincedence that CD sales have skyrockted in the last few years? Maybe. But I doubt it.) I currently record Star Trek episodes during the week on my VCR for viewing on the weekend because I'm typically a rather busy person. So, if the government came along and mandated this new HDTV technology that prohibits time-shifting and skipping over advertisements, I am one of many types of TV viewers who would be severely impacted. I would probably not watch Star Trek any more. That means I would not even have the *chance* to view the very commercials that pay them to run the show. And I might note that I do not consider time-shifting as "stealing." By your own admission, you apparently do. Who's the "fucking kid" again? OS support exists (Score:2) Re:OS support exists (Score:2) Re:OS support exists (Score:2) Last Change of this magnitude was Color TV. (Score:5, Interesting) From what I understand, Linux and Windows NT have had IPv6 support for quite some time now. The problem appears to be more subtle than that. The routers are mostly compliant, I wouldn't worry about it. The smooth transition is going to require that everyone on the 'Net start to switch over. Even half-wit Windows-95 AOL-point-and-drool users. Surely, we can release patches to the operating systems. And users can upgrade to new applications programs which aren't crashing when they request a DNS lookup and get something longer than they expect. But you know they won't. As evidence, I submit to you the Code Red worm. You'd have to be living under a rock for the past two months to not know about it. Yet, I still get hit by infected machines. Follow the link on my .sig. I haven't studied or attempted to deploy IPv6, but it will have to be backwards compatible with IPv4. In the 1950s, Europe upgraded their TV system to color. The new PAL and SECAM color standards weren't compatible with their old 405/441-line black and white standards [ausys.se], leaving consumers with far too many confusing choices. Arguably, European TV never recovered. By contrast, RCA came up with an ingenious way of making a color signal ride on top of the existing North American black and white system. Old black and white TV sets were eventually replaced with color, but there was no great format change. You bought a color TV or a black and white set, and you weren't at the mercy of finding out whether or not there was still a black and white station in your area. People transitioned more gently and weren't put off by having their two-year-old oak-cabinet investment turned into a paperweight by moving out of a 405 line service area. IPv6 will have to be deployed in the same way or adoption rates will wane. Re:Last Change of this magnitude was Color TV. (Score:2) 405 line was first introduced in 1936, and temporarily shutdown in 1939. During the war, the european countries were too busy to do anything, but by 1940 the US decided to standardize on 525 lines, not a huge amount above the British 405 lines systems, but enough that in the mid sixties when colour was coming along, NTSC could be built on top of 525 lines, but no acceptable colouring system could be built on top of 405 lines. However, with new TV stations broadcasting only in 625 lines, as soon as PAL came out, you could get monocrome PAL sets. Indeed, monocrome PAL was all that was available for many years. At that time, the tube & the colour decoding was the most expensive part, and by ommitting those, you could make a cheaper set. I doubt if anyone lost any investment in 405 line sets. 405 line was offically obsolete in 1964, when the first 625 line channel (BBC2) was introduced. There was never a 405 line BBC2 signal. Colour was introduced to BBC2 in 1967, but 405 line service continued on until 1985, 49 years of broadcasting. Re:Last Change of this magnitude was Color TV. (Score:2) OK, you have probably had both TV and color TV for a longer time in the US, but the price that you've to pay for that is a slightly lower quality picture with fewer lines and a color signal that is not always perfect. Yes. Admittedly, PAL has more scanning lines. But there's no magic to that. Nearly the same horizontal frequency, with a 50Hz vertical. The bandwidth of the video and RF circuits is nearly the same, so there's really no dramatic improvement in picture quality. On the other hand, NTSC has 525 interlaced scanning lines, 60Hz vertical, a higher frame rate, and almost no perceivable flicker as a result. Point the Big Yagi at Buffalo! (Score:2) Hey my dick is bigger than yours because I shaved off all my pubic hairs Heh. And your girlfriend is a pedophile.even 60Hz isn't acceptable, so now we have tv-sets that digitally enhance the image and give 100Hz ;) True. You don't see features like that in NTSC sets, though - the 60Hz vertical rate of NTSC means that set mfrs concentrate on other things - like 53" projection sets where the scan lines are 1/4" apart. Ugh.IMHO American TV suck, and it suck hard, to many comercials and verry bad picture quality, but mind you that was in 1992 Too many commercials, I agree. But that's not a technical issue. As for the picture quality, were you watching TV on NYC's cablesystem? [grin] A good, clean NTSC signal is very nice. It's nothing compared to a VGA monitor, of course, but neither is PAL. I'm a videophile, I've worked as a broadcast technician, and NTSC's picture quality can be amazingly good.and when is the us going to switch to hdtv ? When Linux conquers the desktop, IIS users keep their webservers patched, and our home 'net connections are fiber optic with IPv6 addresses. Maybe sooner. [sigh] It's the same chicken or egg issue which slows the IPv6 adoption. Here in Canada, we're waiting for the US to take the lead. ER is now simulcast in HDTV, but until I point a big UHF Yagi at Buffalo NY and smuggle a receiver across the border, it does me no good. Who would start the change? (Score:2) How about if AOL made a systemwide change, or ATT, Excite, and MCI all together? Re:Who would start the change? (Score:2) Actually, I believe ARIN [arin.net] (American Registry for Internet Numbers) is in charge of IP (for the USA). I imagine they would be the ones to initiate the change to IPv6. Re:Who would start the change? (Score:2) Re:Who would start the change? (Score:2) Re:Who would start the change? (Score:2) FURTHER, because they were using IPv6 stacks, companies would have an incentive to write IPv6 apps, which would pressure other ISPs into changing over, too. Re:Who would start the change? (Score:3, Insightful) What is needed is ipv6 only services (e.g. mp3 peer2peer filesharing) AND an easy way to get an ipv6 number for your clients/servers that can coexist with your current ipv4 number (i.e. your computer has both an ipv4 and ipv6 number). The easy part is essential because that prevents that people start creating ipv4 gateways to such services (thus removing the need for getting an ipv6 number). There are plenty of ipv6 numbers available so getting and registering one should be made as easy as possible (something like a distributed, global dhcp server that would automatically get you one based on your mac address would come in handy). Come to think of it, why not just automatically convert those mac addresses into ipv6 numbers (mac addresses are supposed to be unique anyway but I'm not entirely sure this is a great idea) As I understand it, ipv6 can be tunneled over existing ipv4 networks, so it shouldn't be a problem if some routers inbetween ipv6 hosts are ipv4 only. This would cause the amount of client pc's with ipv6 numbers to gradually grow. Also since lots of PCs don't have static ipv4 numbers, the amount of servers on ipv6 would also grow. Eventually, there will be a critical mass of ipv6 servers and clients and the switch can be made. Currently there are a lot of p2p applications in development. I imagine, implementing such stuff would be a lot easier using ipv6 with its improved features. Another killerapp could be streaming multimedia (you want to see this great movie, get yourself an ipv6 number now!!). Re:Who would start the change? (Score:3, Interesting) You're thinking about this completely wrong. What was it that made TCP/IP the 800 pound gorilla standard in the first place? The US Government, especially the military, standardized on it. What we need is to get the US Government to start requiring IPv6 in contracts. famous prophecies (Score:5, Insightful) (ahem) "640 kB should be enough for everybody" "I see a worldwide market for 5, maybe 6 computers" and one that I can only assume: "yeah, use 2 digits for the year. Bah, the year 2000 is 20 years away, nobody will be using this stuff then anyways" And besides, if you wait until the problem is upon us, it'll be too late to fix it. Don't forget this famous prophesy (Score:2) -- many many pundits Re:Don't forget this famous prophesy (Score:2) We did. Ever heard of NAP? :-) Re:Don't forget this famous prophesy (Score:2) We didn't. Ever hear of CIDR? So what's this NAP you're babbling about? Re:famous prophecies (Score:2) "I see a worldwide market for 5, maybe 6 computers" "We now know he overestimated by four." -- Clay Shirkey, in a talk on Napster Re:famous prophecies (Score:2) Bill Gates never said this. Its an urban legend. Re:famous prophecies (Score:2) Re:famous prophecies (Score:2) Re:famous prophecies (Score:2) Bill Gates never said that, and the 640K limit was not because of DOS. IBM build the hardware with the various devices occupying memory locations above 640K. The whole machine could only have 1 megabyte of memory, and the devices needed to go somewhere. The 640K limitation is because of the design of the hardware, not anything Microsoft did. Re:Not So Famous... (Score:2) Doesn't seem to strange when you consider how unbelievably complicated and dangerous something like going into space is. If somone has proof (and a fix) to some deadly problem I can see them stopping, otherwise it's all just theoretical mumbo jumbo and we'd still debating launching our first rocket. Even now space shuttle launches are risky, it's only a matter of time before someone else dies in them. Jet fighters won't help us win the war, let's move those R&D funds elsewhere - Adolf Hitler, 1942 Almost certainly true. One of Hitler's problems was his belief in superweapons. Germany spent countless R&D dollars on wasted projects during the war that would have (in the end) been better spent on making Panthers more reliable and simply producing more of them. Jet fighters wouldn't be viable for several years after 1942, even if Hitler decided to spend massive R&D dollars on them. By the way, Germany DID build jet powered planes near the end of the war, but their affect was minimal (the war was already pretty much lost by that point). Mp3? What's that? - RIAA, 1996 Shouldn't that be: MP3? Our existing copyright laws should cover that nicely, but just to be sure, let's go and buy some Congressmen. When it's time for IPv6, (Score:2, Funny) We're living in a wired world, and Windows NT provides the computing tools that we need to do ebusiness, as well as iPlay. Remember, Microsoft Windows NT: it doesn't get any better than this! A problem that was circumvented long ago. (Score:2, Insightful) The original quote (around 1989) was: "My god! At this rate, we'll be out of addresses by [1992]" That obviously hasn't happened now, has it? When ALL of an ISP's web clients can function on a single IP address at port 80 using header redirection, I don't thenk we're going to need the additional address space for a long time. (IP addressing by latitude and longitude, while a cool idea, always seemed to be a solution looking for a problem.) NAT doesn't solve the whole problem. (Score:3, Informative) What it *doesn't* allow is anyone out on the internet to go and connect to the machine behind the NAT, which is kinda essential for anything beyond web-browsing. The internet is not just port 80. Many people treat it as such, and I hope they have fun. But don't delude yourself that you have a full internet connection, because you don't. You've just got a fancy TV with a few more channels. NAT is a stop-gap measure at best. IPv6 is essential for allowing the internet to scale the way you want it to. Think about it: it's not outrageous that MIT and similar institutions have class-A networks - it's outrageous that *you* don't. IPv6 can fix that. Ask your ISP about their plans to upgrade to IPv6 - and what their IP allocation policy will be. If the ISP doesn't intend to give you lots of IPv6 addresses, start looking somewhere else. Dynamic IP allocation sucks in the same way that NAT does. Many of the peer to peer projects nowadays, in order to keep functioning, have to build their own namespace and addressing structures just to work around it. MIT's A-Class (Score:2) For added fun, MIT gave an entire B-class (well, 1/256th of their A-class, not technically a B, but you understand) to each dormitory and each fraternity. MIT groups aren't starving for IPs, which is nice, but the rest of the Internet is. Re:NAT doesn't solve the whole problem. (Score:2) --- Every time a new car is built do they reinvent the wheel? Why should application developers have to do something similar? --- You don't WANT a class A because you can't imagine what kinds of technologies you could use if you and everyone else did have one. Also, Instant messaging doesn't work as well as you say. When people are behind NAT, an intermediary who isn't behind NAT is required. It solves the p2p issue by not being p2p. If you can figure out how to make two machines that are using NAT find each other without an intermediary, and with no advance knowledge held by the NAT devices can you please let the rest of us know how to do it. Re:NAT doesn't solve the whole problem. (Score:2) If you can figure out how to make two machines that are using NAT find each other without an intermediary, and with no advance knowledge held by the NAT devices can you please let the rest of us know how to do it. This has nothing to do with NAT. Say you move from the east coast US to the west coast. Would you rather update the routing tables for the entire country or update a single entry in a dns record? A single IP address with a fancy NAT setup could theoretically handle 32,000 computers each listening on a single port. IPv6 makes things a lot easier, but it is by no means necessary. If I were creating an IP scheme I'd probably just use GPS coordinates. If you need to move the computer, use DNS or some other app level feature, possibly with a tunnel in the mean time. Routing tables become partitions in physical space. For better privacy, the GPS coordinates could be those of your upstream provider, and then some static/dynamic number tacked on to the end. You can already be tracked to your upstream provider, if you want more privacy than that you need to start tunnelling. Re:NAT doesn't solve the whole problem. (Score:2) That's a whole different (unrelated) problem. Of course it makes more sence to change a DNS record, that's how it works now. However, I thought we were talking about devices sharing an address... A single IP address with a fancy NAT setup could theoretically handle 32,000 computers each listening on a single port. A single IP address with each device that's behind it listening on a different port is possible, but unrealistic. First off, you broke one of the rules: with no advance knowledge held by the NAT devices. If the NAT device needs to be programmed with each new device added to the network then the device is screwed in the mass market. Most people aren't going to reprogram their router. Worse, NAT is being implemented by ISPs these days. People's ISPs definatly aren't going go reprogram their router to open a port every time you get a new device. Hell, you'd be lucky if you could get them on the phone in the first place. Then you have the problem of which device get's which port. For most applications, if they don't have a well known port then they're almost useless since you won't be able to find them. The problem could be solved by inventing some kind of automatic port allocation, and linking it to dynamically assigned DNS entrys, but if every router would need to be changed to support that then you might as well just switch to IPv6 which is already implemented and solves more then one problem. Re:NAT doesn't solve the whole problem. (Score:2) That's not an intermediary in the same sense. Once you look up the piece of information you need from DNS you're done with that connection. When you have two IM clients that are behind firewalls, they relay ALL the data through the intermediary. It is impossible for them to connect to each other directly ever. That's a lot different. Are you familiar with SOCKS? The client requests a port to be listened on, and incoming connections to that port are tunnelled through to the client. I'm sure you're aware of what happens when two machines behind the proxy request the same port. If it has to pick a different one, then how are the devices on the outside to know? What if it's this new DNS like server that conflicts? It'll have to be well known by the router or even implemented IN the router then. Now you're changing the router and you might as well go IPv6. Which applications? Once again, if you have a lookup server (similar to a DNS server) acting as an intermediary, this isn't a problem Like I said above, the DNS server isn't an intermediary in the sense that I meant. As for which applications, cat If the user on DSL wants to run a webserver, the user can get a static port forwarded. You still haven't told me who is going to set up these forwards, and who is going to arbitrate them. Not every router would need to be changed, only the router the DSL user is using. Really? So how many DSL routers out there do you think are this intellegent. It's less then 10%. Most ISP's who do NAT do it on the other side of the DSL link. It's way cheaper to buy a nice NAT capable Cisco switch and a bunch of dumb DSL bridges then to give everyone a router. THese ISPs are the same ones who are the roadblock to switching to IPv6, so do you think it's going to be any easier to get them to change to your new NATlike scheme? If the user on DSL wants to run a webserver, the user can get a static port forwarded. Say you do come up with the perfect 'hack' over IPv4 to make IPv6 unessicary. Why would you use the hack when there's this nice elegant new technology that is ready to be dropped into place? Whatever hack is used has to become universal if it is to be built into consumer devices, and that deployment would end up being just as expensive as deploying any other solution... Re:NAT doesn't solve the whole problem. (Score:2) I wonder if I should stop and pick up some milk on the way home. I'll just telnet to my fridge to... Oh wait, the fridge is behind my firewall, and I can't get that information... Having a fridge initiate an order is probably a bad idea, but of course one that someone trying to make some money off of the idea is going to try to get you to like. There are way more bad ideas out there then there are good ones. Being able to find out what's in your fridge while you're, say, at the grocery store seems like a good idea though. So, the ideas that we've thought of that can work with NAT aren't too appealing, but the ideas that don't work with NAT are the ones that are truely interesting. Score 1 for having non translated addresses. It doesn't matter if most of the population can imagine new devices that would use these address. Only the people who invent them need this ability. They will not have this creative freedom without the addresses being there. Not ALL network applications require two-way communication. So by your logic no devices should be able to have communications initiated from either end? Re:NAT doesn't solve the whole problem. (Score:2) Certainly the applications become smarter, because they have to. But at the same time, the hardware must become smarter. In the game world, video cards have all become much more powerful and support a more consistent set of services than they used to, and game developers benefit from this. By the same token, right now developers have to write their way around NAT and proxies etc., but it can't and won't stay that way: the current Internet architecture is seriously limiting and doesn't even provide particularly good security. That's where something like Mono/Passport is a good solution. Who you are is resolvable and reachable from ANYWHERE. You're talking about a higher level of operation - directory services, essentially - that still requires an addressing and routing solution at a lower level. The point is that the current addressing and routing mechanism is already obsolete, most people just don't realize it yet because they don't understand what's under the hood. Re:A problem that was circumvented long ago. (Score:2) 6-BONE? (Score:4, Interesting) Why not run the conversion like the 6bone has [6bone.net]? That is, start off with virtual IPv6 between IPv6 supporting sites over IPv4 links, and gradually shift to native IPv6 where possible as more and more of the intermediate "link" sites convert to IPv6? At some point, you switch over core routers one by one so that they're running virtual IPv4 over IPv6 transport, and switch out the last of the IPv4 hardware as it becomes obsolete. Not that this necessarily provides an incentive for IPv4 users to switch, but IMHO, as a person that's not too knowledgeable about IPv6, I don't see why technically a migration has to be too difficult. Maybe you could make the incentive something like rewarding you with more IPv6 addresses as you move out of IPv4 space - that would definitely move big network operators along, at least. I'm still not sure how to force a more equal global assignment of the dwindling IPv4 address space. It seems like if the IPv4 afficianados aren't careful, China will just switch to IPv6 immediately, and the rest of the world will get dragged along just so we can continue to communicate with that huge percentage of the human race. Re:6-BONE? (Score:2, Insightful) But the Chinese government might not really care about this, since they don't want their people to access the Net anyway, with all the political stuff and all. Re:6-BONE? (Score:2) Re:6-BONE? (Score:2) - 3G mobile phones - IPv6 is mandated by UMTS R5, the 3G technology for GSM network operators - Asian markets - Asia was late to the party in IP, and only got a tiny amount of IPv4 address space. This is why NTT is already running a commercial IPv6 service in the US and Japan. Re:6-BONE? (Score:2) Not that this necessarily provides an incentive for IPv4 users to switch, but IMHO, as a person that's not too knowledgeable about IPv6, I don't see why technically a migration has to be too difficult. The problem with the 6bone is that it pretty much requires a static IP address to connect to, and more importantly, that there are no free service providers (that I know of) which allow you to run it through a firewall. If you want to deploy ipv6 really fast just create a PPTP tunnel and a freenet. With the ability to get a static block of ipv6 addresses which work through a dynamic IPv4 (via PPTP), and IPSec (which is standard on ipv6), you can easily create a freenet-like system. The idea is that each of your fowarded connections go through a separate IPv6 tunnel. Implement something like napster, provide an easy to use installer, and provide the 6bone tunnel, and IPv6 will be deployed in a matter of months. Plus you can probably escape a lawsuit since the only service you're providing is an IPv6 tunnel. Release the napster client part anonymously. Re:6-BONE? (Score:2, Interesting) My upstream ISP (Demon Internet [demon.net]) is a participant in the 6bone network; so I e-mailed their 6bone contact and requested a small allocation of IPv6 addresses with which I could use on my internal network (all Linux; therefore all capable of IPv4). I received no response from them whatsoever after three seperate e-mails. I *want* to switch away from IPv4, but my upstream ISP won't let me, while they are making out to the outside world that they are 'spearheading' the IPv6 revolution by announcing that they are a member of the 6bone. Yes, I have considered applying to other 6bone networks, such as JANET [ja.net] and other UK ISPs, but my upstream ISP would have been ideal for my IPv4IPv6 tunnel (zero routing overheads). Besides, it is a matter of principle. Anybody running a 6bone site reading this care to comment ? - before you say it, yes, I fulfil the criteria for joining the 6bone (according to [6bone.net] anyway). It's time to stop and think. (Score:2) Who has pushed for universal connectivity of most things to the Internet and why do they want it that way? Is the Net reaching a growth limit because of the IP numbers being used for the benefit of the Net and efficiency in the transfer of information, or so New Yuckers can trade stocks on their cellphones? Consider the NASDAQ, which has sold its soul to technological change. It expands its trading capacity every year. The sellers of trading tools anticipate this expansion, and the traders overload the system again every year, driving a further expansion. We can get to longer and longer fingerprints for our digital devices, or we can decide to better allocate IPs. This decision is directly related to our decisions about what we eventually want the Internet to be for. Do we want the Internet to be a marketplace, a teacher, a trainer? I would rather have limited resources allocated to training, skills enrichment, and exposure to art and culture, than to a thousand million Doom-playing boxes and gabby cellphones. Think about it. Which places in a given city get services such as DSL first? Is that the best social choice, for both the city and the Internet? Re:It's time to stop and think. (Score:2, Insightful) Whenever I've thought about IPv6 and its "suggested applications", this is the first thought that's come to mind. The answer is clearly "no, I don't want the entire world to be able to connect to my fridge." But don't you imply that level of connectivity when you assign your fridge an IP address? Not necessarily. What we should see with the switch to IPv6 is a shift of focus from "addresses" to "routes". Let me explain: Right now, particularly in the ISP world, packet destinations are very address-centric; each customer has one or two IP addresses, and if a packet arrives at those addresses, it is delivered to the customer, either directly or through a hub. With the number of IP addresses available in IPv6, it would be silly for an ISP to only give you a few addresses, or even a few hundred addresses. Instead, they will give out entire class B networks, and (here's the key), simply route any packet addressed to that network over the customer's connection. Since you can't just stick several thousand devices on a lan, having a full-featured router in your home will be a requirement to sort out all the incoming packets. Once there's a router in everyone's home, it's trivial to set them up as firewalls so that someone can't hack your fridge from the outside. Sure, your fridge can still initiate a connection to the supermarket and order more milk, and everything works with no NAT hackery, since the fridge has its own IP address within your subnet. Or, you could require authentication when connecting to the fridge from outside, but still be able to address it by its unique IP from anywhere. So, the bottom line is: more IP addresses leads to required home routers, which are trivially set up as firewalls. -- Brett Re:It's time to stop and think. (Score:2) Re:It's time to stop and think. (Score:2) Re:It's time to stop and think. (Score:2) I don't know about you, but I certainly want it. I want a single PDA that can do everything, and that's always connected. I want a big desktop computer that is the frontend for all the real work I'm going to do. I want my fridge connected so I can check what's in there from my PDA when I'm standing in a shop, I want my washing machine connected so I don't need to go home before I would know it's finished, and I want my car connected so I can lookup in maps, and download ogg vorbis files to the stereo. And I'd be happy to pay for it. What I'm worried about are the privacy issues. With all this being logged, things can go wrong. We need laws that says you're not allowed to record a lot of information. Strong privacy laws. And that you own whatever information is recorded about you. As I see it, one of the fundamental pillars of the web is that it is universal. It has to be all. It has to be a marketplace too, but we need to make sure it isn't only a marketplace, because if it becomes, it dies. Now, the web is part of the internet, so the internet must be universal too. Re:It's time to stop and think. (Score:2) I'll have a firewall at the boundary of my house. *Maybe* I'll poke a point-to-point hole so Sears and my fridge can exchange sob stories. Maybe not. The Road Ahead (Score:2) NEVER FEAR CONSUMER UNITS! (Score:2, Funny) Do not fear, Consumer/Citizen #238o47234-9. We have taken care of the threat of the evil hackers. We have applied Purchase::Courts in order to prosecute, convict & incarcerate [wired.com] Evil Hacker Units for crimes we think they'll commit in the future, preventing them from ever happening. We call this "time-shifted law enforcement". Do not fear, Consumer Units. We will prevent Technology::IPV6 from being used to order too much Commodity::Milk. Everything has been rendered extraordinarily safe. Excellent news, Shopper sllort (Score:2) Yours in Consumption, Shopper FreeUser. good, fix DNS too while we are at it (Score:2) quoth the article: great! if we are gonna effectively have two internets anyway, lets have the IPv6-based Net do away with the current DNS monopoly and let anyone register a TLD. .web, .sex, .JoeSchmoe, whatever. Open DNS is the way to go. all someone would have to do is, write a plugin for a browser that lets it seamlessly navigate IPv6 networks. But at the same time, also allow the user to choose from a open list of DNS servers at the same time. YOU choose your root ! as it was intended to be. my apologies to JoeSchmoe for any offense. thpbt :P Quit complaining about it already! (Score:2) someone was being greedy eh? Comeon folks, time to share.. Seriously though, the article does a good job at least trying to cover all the bases even if some of the arguements are weak. We all know that it's a big change and that it's going to take years to make the transistion from 32 bit addressing to 128 bit addressing, but the people saying "why fix it if we dont have a problem?" had better get their heads out of their asses. It's just like standing in the street and saying "why should I buy a car when my horse and wagon works fine?". I agree that some ideas are way over the top (tell me again why my toaster should be networked??) but with computers getting smaller and cheaper the number of networked devices will continue to grow. We need a new system that can handle assigning addresses to them all. It's going to take time, effort and money to switch everything over so get started and quit complaining. Vital IPv6 links (Score:3, Informative) good IPv6 homepage [ipv6.org] IPv6 HOWTO [bieringer.de] IPv6 Standards [sun.com] IPv6 Tutorial (PDF) [itp-journals.com] And the 6bone [6bone.net] NO IPs FOR DEVICES!!! (Score:2) Also, right now the worlds population is about 6 billion, and 4 billion address are possible with IPv4. Based on everybodies estimates on the adoption rate of internet access, we still have a decade before we're screwed. So, take the time to get it right instead of screwing up everything at once. Re:NO IPs FOR DEVICES!!! (Score:2) Besides, since all the dot-com companies have, or are about to go out of business, the IP addresses will just be recycled. Re:NO IPs FOR DEVICES!!! (Score:2) do you an internet connected PC at work? Do you use only one OS, or two OS on one computer? Some people have two computers for that. Do you use any applications that will not work under NAT without a server in the middle. In my opinion, proposing that only individuals need IP addresses, and that they only need one is preposterous. There are more cases than I can think of or list here where a person might require more than one IP address. There is a world outside your box. CyberKnet (the original poster) Re:NO IPs FOR DEVICES!!! (Score:2) FTR, P2P is used (And always has been used) for more than Napster/Clones and IM. Anything that works without going via a server to find the end place is P2P. Some mail clients still deliver mail this way by delivering directly to a domains MX instead of to their local sendmail daemon. Its not some new thing. It's called Virtual hosts, and it works. (Score:2) Why? So that peer-to-peer and servers will work (Score:2) So who would be in favor of that? Just the RIAA, MPAA, SPA (Software Publishers' Association), BSA (Business Software Alliance), and every other organization that believes that elimination of peer-to-peer and residential FTP and web servers would reduce piracy. ISPs would love it because servers on residential connections sometimes use an inordinate amount of bandwidth. Law enforcement would be happy because ISPs would have to process the packets, meaning that they had an easy way to monitor which user connected to which IP addresses. And ISPs could more easily perform content filtering if, say, Adobe's lawyers wrote a letter and said "IP address xxx.xxx.xxx.xxx has a downloadable program that decrypts our e-books. Please assure that your users cannot access that IP address." Embeded Devices Will Be The Hardest To Change... (Score:2) Try explaining to the average AOL user why his new net radio gizmo no longer works. Or why he has to replace his cable modem firewall when it works just fine. And I am not going to even try and think about what IPv6 will look like once Microsoft gets their hands on it... As a class C IPv4 holder that can't get routed. . (Score:2, Interesting) Clueless hype is all that's out there these hot summer days. It's ridiculous. They did concede that IPv6 is inevitable, but they sure spent some time wringing hands over totally irrelevant crap at the same time. I saw that link on CNN earlier in the evening and didn't read it because I knew it would suck and only went back and read it only because I saw the link here on For those of us old enough to go ahead and got busy organizing networks here and there back when ICANN was getting started and you could just ask for net numbers --as I and many others did-- the problem is all too clear. The beauracratic, financial and legal powers that became involved over the years totally twisted the original premise. If you want a frickin' number you get one. If you want a thousand, you get a thousand. They're just numbers. Deal with it. But that's not what it turned into at all. Vast portions of those billions of IPv4 numbers don't go anywhere because network routing is a financial issue closely intertwined with a technical issue that few people outside of open source are familiar with. It's irrelevant though because IPv6 is inevitable and this has already been covered in so many other ways. And, to top it off, dynamic domain names makes it all meta anyway. Yeah, I'm not crying about the way things are by any means but more numbers is such a rational idea. And why stop at IPv6, next step is get rid of this restricive domain naming stuff. They've already started using Chinese characters at some domain registrars. So let's just name domains like long file names so we can use popular phrases! Shit, you don't think there will be a gold rush on that shit? There's a limited set of English phrases. You take that from an English major. Re:As a class C IPv4 holder that can't get routed. (Score:2) ditto more numbers is such a rational idea agreed next step is get rid of this restricive domain naming stuff Well, I think we have been selecting our own domains on the premise that shorter is better. You can't even get a three letter .com domain anymore because they are all taken. Longer is not necessarily better when your customers have to type this.is.my.cool.domain.name.everyone.will.remembe r .com Too much milk? (Score:2) Wow, that kinda puts a new spin on the old too much milk problem from my Operating Systems class in school. Brings back bad memories. (For those of you who don't know/remember this problem, it is an example of resource locking, needed in OS design. I would say all Computer Science/Engineering students take that class, at least the did at my university). Before we start arguing about IPv6... (Score:2) the "looming doom" is based on assumptions (Score:2) Now you might have the reason that you need to run dns,smtp,www,pop3,ftp,etc... on different machines... ok, you still dont need more than 1 Internet IP address. that's what your routing equipment is for, to manage IP addresses. They magically route that request from 127.0.0.1:80 to 10.12.1.2:80 and that 127.0.0.1:21 to 10.12.1.3:21 any shortage is because of slipshod management of the IP space. Re:the "looming doom" is based on assumptions (Score:2) That's obnoxious. Packet mangling (and DHCP) is an ugly hack and breaks many network protocols (IP Telephone, Incoming services, PtP filesharing, etc.) With IPv6 neither technologies are necessary. Do you really think that NAT is the solution for the future?? I believe that the right answer is for every electronic device to have routable addresses and apply packet filtering as appropriate. Then everyone can have their own /48 address space. How do I get an IPV6 address? (Score:2) I want an IPV6 address. I'm going to run my internal home network on IPV6 and run a translator to make my IPV4 addresses translate to internal IPV6 ones. Where do I get a number space? I know the lower 8 bytes are suppose to be a MAC address, but what about the upper 8? Re:How do I get an IPV6 address? (Score:2) Instructions: BSD [kfu.com], Debian [debian.org], Windows [microsoft.com]. The question that seems more important to me... (Score:2) The internet as it stands suffers because it is trust-based and there are all too many willing to abuse that trust. Many untrusting-internet ideas have been flown, and most of them involve more identity checking and awareness of the originators of packets. Would this "new" internet (I hate to use such an overused term but it seems appropriate) - would this "new" internet retain any opportunities for anonymity (and thus more secure freedom of speech), or will it be a case of "let's crack down on anonymity online because anyone who doesn't want the totally benign government to know who he is must be a terrorist or a child molestor! Why do you want to be anonymous, do you have something to HIDE?" A lot can be done towards preventing the latter if the specs for any new internet communications protocols being open or hopefully even GPL'd. Is this likely? -Kasreyn Re:IP6 MLP (Score:2) Or checkout the IPv6 project page [ipv6.org] Offtopic Search (Score:2) Re:Not many systems support it? (Score:2, Informative) Re:I don't get it... (Score:2) slashdot://buzban Re:Seamless Intergration - far from it (Score:2) the switch will piss-off a huge block of users. and that's the price of progress.. Re:Seamless Intergration - far from it (Score:2)
https://slashdot.org/story/01/08/28/1710246/ipv4-vs-ipv6-the-road-ahead
CC-MAIN-2016-40
refinedweb
9,684
72.16
GHC/Using the FFI From HaskellWiki Revision as of 10:53, 12 September 2011 1 Introduction. However, there are other pages that cover other aspects of Haskell's FFI: - An introduction the Haskell FFI - Some complete examples of using the Haskell FFI - Building a Haskell library to be used in a Mac OS X Cocoa project - The FFI cookbook - Interfacing with C: the FFI, Chapter 17 of Real World Haskell by Bryan O'Sullivan, Don Stewart, and John Goerzen. It will guide you through the writing of the bindings to the PCRE library. Very useful and nicely conceived. - Foreign Function Interface addendum to Haskell98 report - Tackling the Awkward Squad A paper by Simon Peyton-Jones which includes discussion of the issues surrounding the design of the FFI 2 Importing C functions that turn out to be CPP macros Some C functions are actually defined by a CPP header file to be a C macro. Suppose you foreign import such a "function", thus: foreign import foo :: Int -> IO Int Then you'll get the right thing if you compile using -fvia-C, provided you cause the right header files to be included. But the native code generator knows nothing of CPP mcros, so it will generate a call to a non-existent C function "foo". In effect, the FFI is defined to interface to the C ABI rather than the C API; it doesn't take account of CPP magic. To work around this you typically need to write yourself a C wrapper function (in C), thus: int foo_wrap(int x) { return foo(x); } This C wrapper lives in a .c file and gets compiled by the C compiler. Then use the Haskell FFI to foreign-import that, rather than calling the C function directly: foreign import "foo_wrap" foo :: Int -> IO Int We have lots of examples scattered about the libraries already. 3 Callbacks into Haskell from foreign code Suppose we have foreign code that takes a function as an argument: callerback.h: #ifndef CALLERBACK_H #define CALLERBACK_H typedef double (d2d)(double); double twice(d2d f, double x); #endif callerback.c: #include "callerback.h" double twice(d2d f, double x) { return f(f(x)); } We can provide a Haskell function as an argument like this: CallBacker.hs: module Main(main) where -- we need CDouble for C's double type; Haskell's Double may be different import Foreign.C.Types(CDouble) -- we need function pointer type and free function import Foreign.Ptr(FunPtr, freeHaskellFunPtr) -- a "wrapper" import gives a factory for converting a Haskell function to a foreign function pointer foreign import ccall "wrapper" wrap :: (CDouble -> CDouble) -> IO (FunPtr (CDouble -> CDouble)) -- import the foreign function as normal foreign import ccall "callerback.h twice" twice :: FunPtr (CDouble -> CDouble) -> CDouble -> IO CDouble -- here's the function to use as a callback square :: CDouble -> CDouble square x = x * x main :: IO () main = do squareW <- wrap square -- make function pointer from the function let x = 4 y <- twice squareW x -- use the foreign function with our callback z <- twice squareW y print y -- see that it worked print z freeHaskellFunPtr squareW -- clean up after ourselves This can be compiled and linked with this Makefile: CallBacker: CallBacker.hs callerback.c callerback.h ghc -O2 -Wall -fffi -o CallBacker CallBacker.hs callerback.c A very simple example, but hopefully enough to see what is going on.; // Ensure that we use C linkage for HsFunPtr #ifdef __cplusplus extern "C"{ #endif typedef void (*HsFunPtr)(void); #ifdef __cplusplus } #endif typedef void *HsPtr; import Control.Monad (when) when (initialized) (f >> duma_run) ) GHC and DLLs 7.1. 7.2. 7.3 and which makes use of 2 Haskell modules Bar and Zap, where Bar imports Zap and is therefore the root module in the sense of GHC user's manual section 8.2.1 all root modules hs_add_root(__stginit_Bar); // do any other initialization here and // return false if there was a problem return HS_BOOL_TRUE; } LEWIS_API void lewis_End(){ hs_exit(); } LEWIS_API HsInt lewis_Test(HsInt(); return 0; } Lewis.h would have to have some appropriate #ifndef to ensure that the Haskell FFI types were defined for external users of the DLL (who wouldn't necessarily have GHC installed and therefore wouldn't have the include files like HsFFI.h etc). 7.4. 8 Using GHC for DLLs in Excel This part illustrates the preceding Beware of dllMain()! section of this document. It extends the information found in the Building and using Win32 DLLs article. For build instructions and base code, refer to this article. 8.1 Excel crash on Exit when using a GHC DLL Calling shutdownHaskell from the dllMain function, as in the given example can cause Excel to crash on exit. As explained in section Beware of DllMain()! of this article, it's safer to call startupHaskell and shutdownHaskell from outside DllMain. 8.2 Updated dllMain.c code Here is an updated dllMain.c code with additional initialization and shutdown functions (tested). #include <windows.h> #include <Rts.h> #define __ADDER_DLL_EXPORT #define ADDER_API _declspec(dllexport) extern void __stginit_Adder(void); static char* args[] = { "ghcDll", NULL }; /* N.B. argv arrays must end with NULL */ BOOL STDCALL DllMain( HANDLE hModule, DWORD ul_reason_for_call, LPVOID lpReserved ){ return TRUE; } ADDER_API BOOL adder_Begin(){ startupHaskell(1, args, __stginit_Adder); return HS_BOOL_TRUE; } ADDER_API void adder_End(){ shutdownHaskell(); } 8.3 VBA code for Dll initialization and shutdown We must call adder_Begin before any call to the DLL exported functions and adder_End before the DLL is unload. Excel VBA provides us with two callback functions that seems appropriate for this: Workbook_Open and Workbook_BeforeClose. Function declaration in Excel is extended to add the two initalization and shutdown functions. I put it in a new module so I can make them public. The code looks like this: Public Declare Function adder Lib "adder.dll" Alias "adder@8" (ByVal x As Long, ByVal y As Long) As Long Public Declare Function adder_Begin Lib "adder.dll" () As Boolean Public Declare Sub adder_End Lib "adder.dll" () The callback functions have to be defined in the ThisWorkbook module and look like this: Private Sub Workbook_BeforeClose(Cancel As Boolean) adder_End End Sub Private Sub Workbook_Open() adder_Begin End Sub 8.4 Known problems If closing Excel is canceled the Workbook_BeforeClose function will be called and haskell will be shutdown leaving the Workbook open but with Haskell down. The application will crash on the next DLL function call. This is easy to reproduce, modify the WorkBook, close it without saving and press Cancel. Change some value to cause a GHC function to be called and Enjoy Excel crashing..
http://www.haskell.org/haskellwiki/index.php?title=GHC/Using_the_FFI&diff=42048&oldid=3675
CC-MAIN-2014-23
refinedweb
1,080
59.84
Blaze.ByteString.Builder Description Blaze.ByteString.Builder is the main module, which you should import as a user of the blaze-builder library. import Blaze.ByteString.Builder It provides you with a type Builder that allows to efficiently construct lazy bytestrings with a large average chunk size. Intuitively, a Builder denotes the construction of a part of a lazy bytestring. Builders can either be created using one of the primitive combinators in Blaze.ByteString.Builder.Write or by using one of the predefined combinators for standard Haskell values (see the exposed modules of this package). Concatenation of builders is done using mappend from the Monoid typeclass. Here is a small example that serializes a list of strings using the UTF-8 encoding. import Blaze.ByteString.Builder.Char.Utf8 strings :: [String] strings = replicate 10000 "Hello there!" The function creates a fromString Builder denoting the UTF-8 encoded argument. Hence, UTF-8 encoding and concatenating all strings can be done follows. concatenation :: Builder concatenation = mconcat $ map fromString strings The function toLazyByteString can be used to execute a Builder and obtain the resulting lazy bytestring. result :: L.ByteString result = toLazyByteString concatenation The result is a lazy bytestring containing 10000 repetitions of the string "Hello there!" encoded using UTF-8. The corresponding 120000 bytes are distributed among three chunks of 32kb and a last chunk of 6kb. A note on history. This serialization library was inspired by the Data.Binary.Builder module. Synopsis - data Builder - module Blaze.ByteString.Builder.Int - module Blaze.ByteString.Builder.Word - module Blaze.ByteString.Builder.ByteString - flush :: Creating builders module Blaze.ByteString.Builder.Int. Executing builders. Writes.
http://hackage.haskell.org/package/blaze-builder-0.2.1.4/docs/Blaze-ByteString-Builder.html
CC-MAIN-2016-44
refinedweb
267
51.75
Red Hat Bugzilla – Bug 529626 CVE-2009-3621 kernel: AF_UNIX: Fix deadlock on connecting to shutdown socket Last modified: 2012-09-05 23:45:12 EDT Quoting from the patch submitted: "...a deadlock bug in UNIX domain socket, which makes able to DoS attack against the local machine by non-root users. ... Why this happens: Error checks between unix_socket_connect() and unix_wait_for_peer() are inconsistent. The former calls the latter to wait until the backlog is processed. Despite the latter returns without doing anything when the socket is shutdown, the former doesn't check the shutdown state and just retries calling the latter forever." How to reproduce: 1. Make a listening AF_UNIX/SOCK_STREAM socket with an abstruct namespace(*), and shutdown(2) it. 2. Repeat connect(2)ing to the listening socket from the other sockets until the connection backlog is full-filled. 3. connect(2) takes the CPU forever. If every core is taken, the system hangs. Reproducer: You will need to add in the missing header files: #include <string.h> #include <stdio.h> #include <sys/un.h> #include <sys/types.h> #include <sys/socket.h> Reproduced this issue on rhel-5 and fedora-11. Thanks Eugene, I just committed the fix Dave Miller acked to the 3 current Fedora branches. regards, Kyle upstream commit:;a=commitdiff;h=77238f2b942b38ab4e7f3aced44084493e4a8675 Created attachment 365339 [details] reproducer $ gcc rep.c -o rep $ for i in {1..XX} ; do ./rep & done # substitute XX for a number of cpus This issue has been addressed in following products: MRG for RHEL-5 Via RHSA-2009:1540 kernel-2.6.30.9-96.fc11 has been submitted as an update for Fedora 11. kernel-2.6.27.38-170.2.113.fc10 has been submitted as an update for Fedora 10. kernel-2.6.30.9-96.fc11 has been pushed to the Fedora 11 stable repository. If problems still persist, please make note of it in this bug report. kernel-2.6.27.38-170.2.113.fc10 has been pushed to the Fedora 10 stable repository. If problems still persist, please make note of it in this bug report. This issue has been addressed in following products: Red Hat Enterprise Linux 4 Via RHSA-2009:1671 This issue has been addressed in following products: Red Hat Enterprise Linux 5 Via RHSA-2009:1670
https://bugzilla.redhat.com/show_bug.cgi?id=529626
CC-MAIN-2016-30
refinedweb
386
59.4
The QXmlStreamReader class provides a fast parser for reading well-formed XML via a simple streaming API. More.... This enum specifies different error cases This enum specifies the different behaviours of readElementText(). This enum was introduced or modified in Qt 4.6. This enum specifies the type of token the reader just read. Constructs a stream reader. See also setDevice() and addData(). Creates a new stream reader that reads from device. See also setDevice() and clear(). Creates a new stream reader that reads from data. See also addData(), clear(), and setDevice(). Creates a new stream reader that reads from data. See also addData(), clear(), and setDevice(). Adds more data for the reader to read. This function does nothing if the reader has a device(). See also readNext() and clear(). Adds more data for the reader to read. This function does nothing if the reader has a device(). See also readNext() and clear().(). Adds a vector of declarations specified by extraNamespaceDeclarations. This function was introduced in Qt 4.4. See also namespaceDeclarations() and addExtraNamespaceDeclaration().(). Returns the attributes of a StartElement. Returns the current character offset, starting with 0. See also lineNumber() and columnNumber(). Removes any device() or data from the reader and resets its internal state to the initial state. See also addData(). Returns the current column number, starting with 0. See also lineNumber() and characterOffset(). Returns the current device associated with the QXmlStreamReader, or 0 if no device has been assigned. See also setDevice(). If the state() is StartDocument, this function returns the encoding string as specified in the XML declaration. Otherwise an empty string is returned. This function was introduced in Qt 4.4. If the state() is StartDocument, this function returns the version string as specified in the XML declaration. Otherwise an empty string is returned. This function was introduced in Qt 4.4. If the state() is DTD, this function returns the DTD's name. Otherwise an empty string is returned. This function was introduced in Qt 4.4. If the state() is DTD, this function returns the DTD's public identifier. Otherwise an empty string is returned. This function was introduced in Qt 4.4. If the state() is DTD, this function returns the DTD's system identifier. Otherwise an empty string is returned. This function was introduced in Qt 4.4. If the state() is DTD, this function returns the DTD's unparsed (external) entity declarations. Otherwise an empty vector is returned. The QXmlStreamEntityDeclarations class is defined to be a QVector of QXmlStreamEntityDeclaration. Returns the entity resolver, or 0 if there is no entity resolver. This function was introduced in Qt 4.4. See also setEntityResolver(). Returns the type of the current error, or NoError if no error occurred. See also errorString() and raiseError(). Returns the error message that was set with raiseError(). See also error(), lineNumber(), columnNumber(), and characterOffset(). Returns true if an error has occurred, otherwise false. See also errorString() and error(). Returns true if the reader reports characters that stem from a CDATA section; otherwise returns false. See also isCharacters() and text(). Returns true if tokenType() equals Characters; otherwise returns false. See also isWhitespace() and isCDATA(). Returns true if tokenType() equals Comment; otherwise returns false. Returns true if tokenType() equals DTD; otherwise returns false. Returns true if tokenType() equals EndDocument; otherwise returns false. Returns true if tokenType() equals EndElement; otherwise returns false. Returns true if tokenType() equals EntityReference; otherwise returns false. Returns true if tokenType() equals ProcessingInstruction; otherwise returns false. Returns true if this document has been declared standalone in the XML declaration; otherwise returns false. If no XML declaration has been parsed, this function returns false. Returns true if tokenType() equals StartDocument; otherwise returns false. Returns true if tokenType() equals StartElement; otherwise returns false. Returns true if the reader reports characters that only consist of white-space; otherwise returns false. See also isCharacters() and text(). Returns the current line number, starting with 1. See also columnNumber() and characterOffset(). Returns the local name of a StartElement, EndElement, or an EntityReference. See also namespaceUri() and qualifiedName(). If the state() is StartElement, this function returns the element's namespace declarations. Otherwise an empty vector is returned. The QXmlStreamNamespaceDeclaration class is defined to be a QVector of QXmlStreamNamespaceDeclaration. See also addExtraNamespaceDeclaration() and addExtraNamespaceDeclarations(). Returns the namespaceUri of a StartElement or EndElement. See also name() and qualifiedName(). If the state() is DTD, this function returns the DTD's notation declarations. Otherwise an empty vector is returned. The QXmlStreamNotationDeclarations class is defined to be a QVector of QXmlStreamNotationDeclaration. Returns the prefix of a StartElement or EndElement. This function was introduced in Qt 4.4. See also name() and qualifiedName(). Returns the data of a ProcessingInstruction. Returns the target of a ProcessingInstruction.(). Raises a custom error with an optional error message. See also error() and errorString().. This function was introduced in Qt 4.6. This function overloads readElementText(). Calling this function is equivalent to calling readElementText(ErrorOnUnexpectedElement).. You can traverse a document by repeatedly calling this function while ensuring that the stream reader is not at the end of the document: QXmlStreamReader xs(&file); while (!xs.atEnd()) { if (xs.readNextStartElement()) std.cout << qPrintable(xs.name().toString()) << std.endl; } This is a convenience function for when you're only concerned with parsing XML elements. The QXmlStream Bookmarks Example makes extensive use of this function. This function was introduced in Qt 4.6. See also readNext(). Sets the current device to device. Setting the device resets the stream to its initial state. See also device() and clear().. Returns the text of Characters, Comment, DTD, or EntityReference. Returns the reader's current token as string. See also tokenType().().
https://doc.bccnsoft.com/docs/PyQt4/qxmlstreamreader.html
CC-MAIN-2022-05
refinedweb
937
54.49
I was recently quoted in a tweet about this and I thought it might be worth a revisit and new discussion. Re Art Direction "This is more than just a trend, it's just a good idea." ~ @chriscoyier Still? And, is AD plugin the best way in 2013? — James Burgos (@JamesBurgos) October 13, 2013 The idea of an "art directed article" is that it is designed specifically for the content of the article. It might share some characteristics from the parent site (it probably should), but lots of design elements change to suit the specific article. Layout, colors, type, backgrounds, images, interactions... all custom just for the article. Here's a simple example on Jason Santa Maria's blog (who has championed this idea): Was this just a trend? I'm going with: yes and no. Yes - I see far less of it these days then in its hayday (2009-2010). I totally jumped on the bandwagon at the time. It was fun, but I didn't stick with it. - There used to be two dedicated "gallery" sites dedicated to the idea: Blogazines and HeartDirected. Both offline. - Some examples have deteriorated over time. For instance this post that is about posts like this. No - The sites doing it have shifted somewhat from individuals to large organizations. - The sites that are doing it these days are taking it to all new levels of impressiveness. See the examples section below. - Good design is good design. If you can design a page that enhances the content, that's a good idea that transcends a trend. How do they hold up over time? Let's see if we can collect some real data. This article lists 20 sites with art-directed posts, with two examples per site. Let's rate how they held up in the four years since 2009. 2013: Art direction only survived on 18/40 articles. Less than half. 2016: Down to 13/40 articles still in good shape. Of course this is a very small sample size and there is nothing to compare it to. It would be interesting to compare against another roundup from 2009 of a totally unrelated topic and see what shape those URL's are in. Did responsive design influence things? 2009 was a bit before responsive web design was "a thing" as we know it today. It's easier to customize a design in a fixed environment than a fluid one. Want the text "Kapow!" lined up right next to Batman's fist in an article about old comics? That's fairly easy to do when you can count on that fist being at the exact same place at all times. But likely you'll need that graphic to shrink and grow to accommodate the screen size. Now you'll have to get tricky with how you position that text. And likely about 50 other little minor adjustments you have to make as the the screen size available goes from tiny to huge. It multiplies an already time-consuming job. Did a focus on performance influence things? Often what happens with art directed articles is: - Serve everything you normally do - Plus more stuff! (e.g. extra images, extra fonts, extra CSS, etc) There is definitely a more-is-worse vibe going on on the web right now. A common theme in art directed articles is adding stuff like interactive maps, scrolling effects, animations, and super large images. All of that stuff is heavy and slow when it comes to web performance. That doesn't mean you can't do it right and progressively enhance, but that's yet-another-difficulty. That may be contributing to less enthusiasm for art-directed posts. How can you plan for the future with your art-directed articles? Websites will change. It's going to happen, so you need to plan for it. The customizations to an article you make now might not make any sense to that same article in a new template. Did you change the background on .article-wrap { } - well maybe that's an <article class="module"> now, so that custom CSS doesn't do anything. The trouble is, redesigns are generally for the better. They accommodate a new advertising structure. They make a non-responsive design responsive. They increase performance. Whatever. We might want to be totally gone with the old design and totally in with the new. Here's some options for various scenarios: - Preserve the article exactly as is. This is how Jason Santa Maria's site works. Posts that were art directed under a certain version of the site get served under that version forever. He's doing it, so clearly it's doable. There are WordPress plugins that change themes with a URL parameter, so I can imagine you could code something that shows a different theme based on a publication date. In talking to some folks from The Verge (and companion sites), they plan to either serve a legacy template specifically for these URL's, or "flatten" the page into a one-off static page. Either way, they design remains forever. - Update the design. It shouldn't be off the table that you just revisit the articles when you redesign and fix them up to work with the redesign. Time permitting, this is probably the best option. - Build them outside the template/theme/CMS from the start. If the article doesn't rely on a template anyway, it won't break when you update that template. - Revert to a normal template. Worst case, just remove all the custom art direction. It's a fairly common approach to just add assets to customize a page anyway, so removing them will hopefully allow the content to drop back to a normal looking article. Hopefully the markup wasn't so customized that it breaks. The lesson here: use namespaced classes that will likely have no future meaning. Whatever you do, don't just nuke the article or redirect it to something unrelated. Because. More Recent Examples New York Times: Snow Fall The Verge: John Wilkes Booth New York Times: Russia Travis Neilson: Fun with jQuery .show() Complex: Danny Brown The Washington Post: Great Falls LA Times: Concrete Risks New York Times: Tomato Can Blues New York Times: The Jockey Daniel Mall: Entertainment Weekly Site Trent Walton: Human Interest Polygon: Watch Dogs Let's check these out in another four years! So what's up? Is it / was it a trend or not? Do you dig it? Have you done it? Is art directing a post the kiss of death for it over time? Can you think of other ways to handle an art directed post over time? Any more interesting examples? And to answer James' question from the tweet up top: I think Dave's fork of the Art Direction Plugin is still the best way to go in WordPress-land, if what you are trying to do is essentially add CSS and JS. Oh and I'm totally mis-using "art direction" here. Sorry about that, but I feel like it's kind of the name that's been applied to this thing. Honestly, I LOVE the idea of them in theory and even have some published on my personal blogs. (with the original intention of doing them many more) but the reality is that they take just WAY too much effort to create on an ongoing basis which I why I think many jumped on the bandwagon but quickly fell away when they realized that a 2 hour blog post became a 20 hour blog post that really didn’t garner much more in terms of traffic. While they are wonderful experiences that I love I wouldn’t read a blog because it was art directed nor would I not read a blog because it is not. And as mentioned I think mobile really through a wrench into things. An art directed post is a ton of work to begin with, making each and every one uniquely responsive is just insane. Yeah, you’ve pretty much hit the nail on the head there. Maintaining a blog with consistent art-directed posts is extremely time consuming. Then when you throw in the ideals of mobile first and RWD…… nah. More effort than it’s worth. I really like some of the stuff that Teehan+Lax has done with their work roundups. I think these kinds of posts should hold up well overtime because it’s a reference to the work you’ve done. Except that their art-directed pages go up to 70MB+ Which is extremely disrespectful to their users. Every link to a Teehan+Lax page should be treated like a PDF link: (WARNING: 70+MB, 100% CPU) I actually like art directed blogs and both Jason’s and Trent’s are the best examples out there IMO. I really enjoy (and appreciate) the time they took to make it that way. This effort makes the reading experience more enjoyable and I’m a sucker for visual stimulation…what can I say. A suggestion when using Dave’s plugin for WordPress… Name your classes and id’s with a prefix. Something like “ art-direction-” or “ ar-“ The reason for this is I’ve gotten myself into trouble naming something I actually have in my main style sheet. Doh! Thanks for the link Chris! It’s important to decide what’s code and what’s content. Custom ‘code’ for art directed articles should really be considered content, and should be saved with the article. Doesn’t solve all (any?) problems, just don’t stick custom CSS/JS/HTML in your main code files. Word I still love the occasional blogazine post. They’re beautiful. For maintainability, I think everything should be packaged with a page that may not be able to get it elsewhere later, so standalone HTML pages are what I’ll be doing. Excellent overview, Chris. I think perhaps art direction is now where RWD was circa 2009: everyone agrees that the idea is sound; what we lack is a rigorous set of techniques that will really enable it to take place in the majority of sites. We barely have the language to discuss art direction on the web, especially in the age of responsive design, much less make it happen with easy, straightforward tools. My impression is that a lot of people are nibbling around the edges of the problem: I know my own contribution definitely falls into that category. From a technical perspective, new CSS proposals, such as Adobe’s Regions and Exclusions, will allow art directors to be able to take their place at the web design table, with the suite of techniques they’re used to from print ready to go. I think it’s likely that we’ll eventually reach a critical mass of tools, techniques, and a maturing visual language that will enable and popularize art direction on the web, but it’s going to take a few more years of development. I still really like the concept and continue to try and add some form of art-direction capabilities where possible… it’s just pulled back to things that are easy for myself or clients to update in their CMSs. It’s actually getting easier to create modular design systems that can be art directed/customized on the front-end using UI libraries and awesome tools like SASS… It’s the back-end that sucks. It’s still incredibly difficult to create an easy-to-use customizable design system in most content management systems. A great layout plugin for a CMS that let’s a user easily choose from a set of pre-designed page modules, with color options, content types, etc. would make a big difference in my world. Pitchfork currently does this with some of their feature articles. They combine it with responsive features and parallax video and images. It’s quite cool. Here’s a better example – Pitchfork Cover Story: MGMT I also was going to mention Pitchfork’s AD posts. The recent Daft Punk cover story was pretty epic. I sort of feel like web design is a bit of spinning plates gig and lately we’ve all been pushing really hard on the RWD plate, the Progressive Enhancement Plate (whether you are a proponent or a detractor it’s in the air) and the Performance Diet plate. Sadly, that’s a lot of plates at the end of the day. Hopefully once those plates are all fully in motion we can start to look at the AD plate again and get it back to full spin. At least for designers private spaces AD is fantastic idea, any zine, serious blog, sectioned resource, should be looking at the benefits… but there are only so many hands to keep those plates in motion. Absolutely agree. The reality is that many people are either solo freelancers or working on small teams pressed for time and budget. Without having the luxury of time, something’s got to give. Hopefully there’ll be some revolutionary tools coming along to make our lives that much simpler, but I sure as hell haven’t got time to create them! The problems that people seem to be associating with “art directed” are all problems due to bad design. You can make well designed art directed posts that are not 70MB in size, progressively enhanced and responsive. Trent Walton does it all the time. It does take more work. But that‘s a complaint some people have about RWD too. Does‘nt mean we should just give up and call it a bad idea. My work just recently did a highly art directed article for a local alt-weekly here in town about a contentious road issue 30-some years in the making. There’s some cool stuff you can do with it but struggling to find the price / benefit sweet spot for both ourselves and our clients. RWD has definitely increased the time it takes to pull off a project of this scale. Project link for the curious: I think it would be time-consuming when you have to design an extra template with different bit of design and then make it compatible to other things like RWD etc. I think that it’s about balance. I’m in the middle of a portfolio site overhaul and we’re looking at something I guess you might call ‘semi-art-directed’ There are constants, but the remaining variables are big enough to give the page its own distinct identity – without having to write crazy amounts of code bloat to get it to work. There is always going to be a place for the art-directed blog, but like all options available to us, it is not always the right solution. That is exactly what I’m currently convincing my team to adopt. All too often ‘art directed’ posts are trying to change everything. I think we should treat customisation in the same way as themes. Most of the layout etc should remain the same, and we should only play with colours, images and fonts. That way, worst case scenario, later they just become the same. And best case scenario, we can sometime reuse the same theme for more articles in the future. In this way, when going through a redesign, it should be easy enough to update all the themes to continue giving them a unique look and feel. Thanks for mentioning my site. Interestingly I’m re-writing from the ground up with HTML5, webfonts, SVG, responsive views etc as it was done so long ago with now outdated technologies. It’s taking a while though! Do you think the fantasy interactive (fi) case studies fall into this category? Theyre definitely custom to their content Art directed articles is an approach I have used on my site, pumpkin-king.com, for many years. Embarrassingly, the two links to my site that you reference in your article return the wrong one these days (they are defaulting to the latest article). This is due to a recent redesign to make the site responsive. As you point out in this article, turning art directed articles and templates into a responsive presentation is a challenge. For my redesign, I used the “update the design” approach and rebuilt each article one by one into new, responsive templates. This was obviously a big project, as I am sure anyone who has done a similar migration can attest to, and I decided to start with a handful of the most current articles (and those which analytics told me were still attracting quality traffic) with the intention of adding the rest over time. This meant that I could get the new site, and the benefits of a responsive redesign, live without being held back by the time needed to add EVERY article. The downside is that some of the older pieces, like the two you reference in this article, will return the wrong content until I can get them added. The way I publish these articles had changed quite a bit since I began using it in 2009. I write much less often than I used to, in large part because of the time it takes to design and develop each article – a task made even more challenging now that the site is responsive. Still, when I decided to redesign the site earlier this year, a point where abandoning this art directed approach would’ve made sense, I decided to stick with it because, even after so many sites that were using this approach have backed away from it, I still find value in publishing article this way. If it was a fad, I hope it comes back. Responsiveness probably did play a roll in smashing this down but if we limit ourselves by imagining what can we do this week we’re going to loose out on great design. I think it’s still a good idea but has it’s place. Out of the millions of bloggers out there most shouldn’t use AD. But looking at the examples from NYT, they used it on ‘major’ articles, not the cat in the tree blog post. Articles that will be referenced, articles that need animation to explain things. I agree that having a blog with only art-directed posts could be very time consuming. But I also think you can find a balance, take a look at the things Vox Media is doing (The Verge, Polygon, SB Nation): not ALL the articles are art-directed, most of them use the same layout, and then you have a couple of features posts that got art designed. Balance. This article inspired me to publish my own thoughts about why I continue using this art directed approach and what has changed for me now that I have moved my articles into a new, responsive design – I can understand the thought behind art directed case studios, even if some seem like more work than the project those case studios are talking about, because the function of those studios is to show off what you can do. But for blog articles it seems too much, I wouldn’t do it, unless the article was something really special. As a web designer I would love art directed articles to become a new trend, it would open a new market for me, and a market that requires a bit of effort and a lot of continuity, but being completely honest, I think they’re not worth the time unless you can afford perfection. Until recently I was the Web Publications Coordinator for TXCPA. We have a lot of great print designers working for us and my original directive was the “Make it look as much like the print as possible.” The coding was fun and I learned a lot of CSS quickly. And I was able to come pretty close to the print, in spite of having to support IE6 and without much CSS3 support (2008-ish). What killed the art direction was not the amount of time it took to code. It was the demise of print (due to budget cuts) and the inability – or lack of interest – on the part of the top print designers to learn to design web pages instead of print pages. At the same time, there was a push by management to move to a cms. Not sure how they felt that would help as it would would require more skilled – and therefore more expensive coders. Wordpress would never support the kind of layouts we did in the past, and while Drupal was better, it still wasn’t conducive to doing layout and design based on content as opposed to which views/regions/nodes you could stick content into. Personally I found it quicker and easier to code everything from scratch. Pages became boring three-column affairs. Now the pendulum is swinging back the other way. We are using Bootstrap/Foundation, making jQuery features easy for those who aren’t javascript experts, and the new challenge is making engaging mobile sites. And management is recognizing that there are opportunities online to integrate graphics, text, video and data visualization in a way you could never do before. And the print designers who have embraced the web as a medium are now the ones working on the high-profile projects. I’ve been doing web work for 20 years (That’s 140 person years right?) and the one thing I’ve learned is that everything old is new again. We are now worried about bandwidth and scaling to different screen resolutions just like we did when most people were on dial-up. Art directed articles have been replaced with sitewide “art directed templates”, where each article follows the same style but is so well-designed, it looks like it was art directed just for that article. I have to straighten it. The main point of the art directed blog is about overriding the default style with some new style rules to get a different look. If we made articles with their individual template that is 100% different, then it is not an art directed article/custom post. It’s just a static web pages that are included in the blog archives. An art directed blog should have their HTML, CSS and JS framework, whatever the risk. I used to have an art directed blog on Tumblr (iamsteve_dot_Tumblr_com — link now dead), where I created a basic theme and then was able to art direct my posts over that. I have since moved over to GitHub () and am still going strong. Each “article” is actually a web page in and of itself. I realize that it is a bit hacky and a cheap skate way of doing things, but it worls for me. I art direct my posts because it is fun. I personally do not like the idea of any template being universally good enough to accomodate all and every of my posts, so I started to create my own webpages,just to be able to publish things the way I think they deserve, rather than using a blogging service of any kind. I am just an amateur in html and css, however, I agree that designing individual pages for individual contributions forces you strongly to select the most important topics. If you spend weeks designing a single webpage, you really must become selective on your subject. My subject, in general, is sound. I am trying to make people aware of that listening to “ordinary” sounds is interesting, as much as it can become very emotional, if you start listening carefuly. So I need to create individual visual presentations for individual acoustic situations, if I want to convince anybody about the individual beauty of sounds. Thank you for your interesting web, Ill try to make use of your professional advices in my amateur work. JL
https://css-tricks.com/art-directed-articles-still-good-idea/
CC-MAIN-2017-39
refinedweb
3,997
70.43
This is a 1.3 app migrated to 1.4 and now is being migrated to 1.11. Will probably need a new manage.py file. Create a dummy project and copy manage.py over your existing manage.py file or diff the two). Rename your settings directory to match the name of your project. In my case the project is portal, settings renamed to portal. This error: django.core.exceptions.ImproperlyConfigured: Creating a ModelForm without either the 'fields' attribute or the 'exclude' attribute is prohibited; form BlahForm needs updating. Change in Django 1.8. See: Quick fix is: fields = '__all__' But you will need to confirm that you want the form to expose all fields. Formtools Removal of django.contrib.formtools: Is now separate package, install with pip: pip install django-formtools Change imports from django.contrib.formtools to formtools. For example: from django.contrib.formtools.preview import FormPreview Becomes: from formtools.preview import FormPreview Models model._meta.get_all_field_names() is gone. See: This is verbatim from the docs: MyModel._meta.get_all_field_names() becomes: from itertools import chain list(set(chain.from_iterable( (field.name, field.attname) if hasattr(field, 'attname') else (field.name,) for field in MyModel._meta.get_fields() # For complete backwards compatibility, you may want to exclude # GenericForeignKey from the results. if not (field.many_to_one and field.related_model is None) ))) This provides a 100% backwards compatible replacement, ensuring that both field names and attribute names ForeignKeys are included, but fields associated with GenericForeignKeys are not. A simpler version would be: [f.name for f in MyModel._meta.get_fields()] While this isn’t 100% backwards compatible, it may be sufficient in many situations. Commands BaseCommand BaseCommand.option_list is gone. See . Arguments See here for how to add arguments: These custom options can be added in the add_arguments() method like this: class Command(BaseCommand): def add_arguments(self, parser): # Positional arguments parser.add_argument(‘poll_id’, nargs=‘+’, type=int) # Named (optional) arguments parser.add_argument( ‘–delete’, action=‘store_true’, dest=‘delete’, default=False, help=‘Delete poll instead of closing it’, ) Move from MySQL to Postgres Bigger or more complex databases may want to do a manual migration where the database is migration using django models. I’ll update this as I have time. 4 thoughts on “Migrate Django 1.4 to 1.11” I am trying to upgrade my django project from 1.5 to 1.11. I have upgraded all the packages. After that I got django.core.exceptions.ImproperlyConfigured: Application labels aren’t unique, duplicates: error. I fixed it by reading django 1.7 release note. Now I am getting ImportError: cannot import name . I am stuck here. Please help. You may have a circular import, or your imports are wrong. Please ask your question on StackoverFlow, and include some code samples. That’s a better place to ask your question as more people will look at it, and you can post code samples which will better help others help you. And post a link to your question! please help me out please help to resolve this
http://timony.com/mickzblog/2017/09/27/migrate-django-1-4-to-1-11/?replytocom=861
CC-MAIN-2019-26
refinedweb
502
54.59
Johannes Landgraf I tried my best to not just write another "why I joined X" blog post. Promise ✌️ With a smile and a heavy heart I decided to leave Target Partners. The leading 🇩🇪 early-stage tech VC that was more family than professional home to me for the last 2.5 years. I once jokingly told Berthold that working together with the investment team rather feels like working together with siblings, uncles and... yeah... grandpas ¯\(ツ)/¯. The level of integrity, brain power and gut intelligence of up to 36 (!) years of Venture Capital (I was minus 9 years old when Waldemar started) I interacted with and absorbed each single day was unparalleled to what I had experienced before. This is something I will never forget and be forever truly grateful for. Even though venture is a great, comforting and intellectually stimulating industry to work in, the entrepreneurial itching never went away. Honestly, it only got stronger when working closely together with entrepreneurs finding product-market fit. It is one thing to tell people what to read (👉 my reading list) and to make intros but it's a whole different story to execute. Taking to heart the football analogy "you can coach your whole life, but you can only play while you are young", I decided to follow the big footsteps of Target Partners' previous associates (Marc, Christian, Raphael and many more) - and switch sides. After my Computer Science studies at UCL, I joined Target Partners in late 2017. One of my first tasks was to make sense of the - often misquoted - umbrella term "Cloud Native" - both on the technical side and as an investment opportunity (.pdf below). This piece of research first introduced me to the Linux Kernel features namespaces and cgroups. Both features power Linux containers and hence the omnipresent container orchestration system Kubernetes (K8s). For all non-technical people out there: it is thanks to Kubernetes that you can binge-watch Last Dance, Tiger King & Dark on Netflix during a pandemic. It is also thanks to Kubernetes that a small group of highly gifted engineers working remotely from Kiel were able to build a fully containerized and automated cloud-based dev environment (👋 Gitpod.io..). Learning about cloud got me hooked and even more interested in everything that happens on the infrastructure side of the OSI-layer. I spent most of my time on developer tools, dev{sec|net|git}ops, infrastructure, developer platforms and open source. I attended almost all relevant European conferences (KubeCon, ContainerDays, Cloud Native Rejects, FOSDEM, All SystemsGo etc) and I was almost always the only venture guy there. Honestly, I never understood why, instead, European early-stage investors visit conferences such as NOAH for Dealflow that all suffer from adverse selection 🤷♂️. During GoDays 2020 my favourite talk by far was by Chris who leads the backend efforts at Gitpod. In his talk he addressed the biggest developer productivity killers in modern, distributed applications: local K8s clusters (Minikube), long build times (Docker) and cumbersome debugging processes. We are not talking minutes, but hours per week here (per developer!) that are lost. There are several companies that try to tackle this problem, but the streamlined setup that the team at Gitpod built to develop Gitpod itself (eat your own dog food ✔️) just blew my mind. This is by far the leanest, most automated and productive dev environment I have seen for developing distributed, microservice-oriented applications (they start coding and debugging on any branch in less than 15 seconds 🤯) ! We call this Dev-Environment-as-Code (DEAC).
https://www.notion.so/Ahoi-Gitpod-io-e2cd4c90263746ce8913204520701221
CC-MAIN-2021-49
refinedweb
591
50.67
Upload code to Arduino Due from Python. piupdue Python package that enables a compiled Ardunio Sketch to be uploaded to an Arduino Due from a RaspberryPI (connected by USB). Based on the Arduino BOSSA C++ source code. Install using: $ pip install pyupdue Sketch file must be saved locally on PI and be of type “.cpp.bin”. Run from cmd line usage: piupdue.py [-h] -f SKETCHFILE [-p PORT] [-l LOGFILE] optional arguments: -h, –help show this help message and exit -f SKETCHFILE, –file SKETCHFILE Sketch file to upload. Including path. (/path/File.cpp.bin) -p PORT, –port PORT Port Due is connected on. Leave blank for auto selection. -l LOGFILE, –log LOGFILE Save output to log file. # Use in Python Program Use the Upload function found in piupdue.py, Ex: import piupdue piupdue.Upload(‘/usr/update/FastSketch.cpp.bin’, ‘/dev/ttyACM1’, ‘/var/log/piupdue.log’) Some background The Arduino Due is a microcontroller board based on the Atmel SAM3X8E ARM Cortex-M3 CPU. It is the first Arduino board based on a 32-bit ARM core microcontroller instead of the more common AVR. The different mcu means the performance is better but also means the booting process is different from the AVR, Ardunio has designed the board such that flashing firmware is easier than what the stock SAM3X has offered, this link explains the booting process and the tricks that Arduiro implemented. The “avrdude” program is used to upload code to the AVR based Arduinos and there are quite a few examples of how to do this from the RaspberryPI. BOSSAC is used by Arduino to upload code to the ARM, it’s the command line variation of BOSSA which is a simple and open source flash programming utility for Atmel’s SAM family of flash-based ARM microcontrollers designed to replace Atmel’s SAM-BA software. I required the ability to upload new code from a RaspberryPI to a Due. I couldn’t find any info on getting BOSSAC to run on the PI so I have written this package in Python to replicate the fucntionality. Download Files Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
https://pypi.org/project/piupdue/
CC-MAIN-2017-51
refinedweb
368
63.39
int hcreate(size_t nel); ENTRY *hsearch(ENTRY item, ACTION action); void hdestroy(void); #define _GNU_SOURCE #include <search.h> int hcreate_r(size_t nel, struct hsearch_data *tab); int *hsearch_r(ENTRY item, ACTION action, ENTRY **ret, struct hsearch_data *tab); void hdestroy_r(struct hsearch_data *tab); First the table must be created with the function hcreate(). The argument nel is an estimate of the maximum number of entries in the table. The function hcreate() may adjust this value upward to improve the performance NULentrant versions that allow the use of more than one table. The last argument used identifies the table. The struct it points to must be zeroed before the first call to hcreate_r(). hsearch() returns NULL if action is ENTER and the hash table is full, or action is FIND and item cannot be found in the hash table. hsearch_r() returns 0 if action is ENTER and the hash table is full, and nonzero otherwise. The glibc implementation will return the following two errors. Individual hash table entries can be added, but not deleted. The following program inserts 24 items in to() { ENTRY e, *ep; int i; /* starting with small table, and letting it grow does not work */ hcreate(30);; }
http://man.linuxmanpages.com/man3/hsearch.3.php
crawl-003
refinedweb
197
62.48
The Switch component is used as an alternative for the Checkbox component. You can switch between enabled or disabled states. import { Switch } from '@nextui-org/react'; You can change the state with checked prop Unusable and un-clickable Switch. Change the size of the entire Switch including padding and border with the size property. You can change the color of the Switch with the property color. You can add a shadow effect with the property shadow. You can change the full style towards a squared Switch with the squared property. You can change the full style towards a bodered Switch with the bordered property. You can disable the animation of the entire Switch with the property animated={false}. NextUI doesn't use any library or icon font by default, with this we give the freedom to use the one you prefer. In the following example we use Boxicons type NormalColors = | 'default' | 'primary' | 'secondary' | 'success' | 'warning' | 'error' | 'gradient'; type NormalSizes = 'xs' | 'sm' | 'md' | 'lg' | 'xl'; interface SwitchEvent { target: SwitchEventTarget; stopPropagation: () => void; preventDefault: () => void; nativeEvent: React.ChangeEvent; } interface SwitchEventTarget { checked: boolean; }
https://nextui.org/docs/components/switch
CC-MAIN-2022-05
refinedweb
179
56.86
Hello there, long time visitor first time poster. I have a problem with the following code... it segfaults as soon as my setFT function is called. I must not be allocating the memory correctly, but what's strange is my temp self-testing code (that **(ptrtwo+5000) = 88 part) actually prints out 88 when I ask it what that particular element is. How is that possible if I haven't allocated that much memory for it? My goal is to create a pointer to a pointer to an array of longs. Initially, the array[0] element should be this "magic number" we have. That's fine. array[1] should be the size of our "flexible table" which is initialized at 0 until the user uses setFT to add elements. The ultimate goal is have this dynamic array of elements that allocates, deallocated, and reallocates necessary memory. I just get seg faults I guess my main question(s) is why am I seg faulting, and if I'm seg faulting, how come I can still put long's into my array?! Any suggestions or thoughts would be greatly appreciated. I'm not sure how clear I have been, but if you need clarification on exactly what the heck I'm talking about, I'll try to do just that. Thank you very much! Code:#include <stdio.h> #include <stdlib.h> #include "FlexTab.h" FlexTab newFT(){ long **ptrone; long *ptrtwo; ptrone = malloc(sizeof(long)); *ptrone = malloc(sizeof(long)); **ptrone = (long)calloc(2, sizeof(long)); ptrtwo = malloc(sizeof(long *)); **(ptrone) = FT_MAGIC; ptrtwo = *ptrone; *(ptrtwo+1) = 0; *(ptrtwo+5000) = 88; //just a tester printf("*(ptrtwo+1) is %ld\n", *(ptrtwo+1)); printf("**ptrone is %ld\n",**ptrone); printf("*ptrtwo is %ld\n",*ptrtwo); printf("Ptrtwo @ element 5000 is %ld\n", *(ptrtwo+5000)); //it works?! return ptrone; } int disposeFT( FlexTab ft ){ free(*ft); free(ft); ft = NULL; return 0; } int setFT( FlexTab ft, const int index, const long item ){ if (index > (**(ft+1)) ){ **ft = (long)realloc(*ft, (2 * sizeof(long)) + (index * sizeof(long)) ); **(ft+1) = index; **(ft+index+2)=item; } else if (index < (**(ft+1)) ){ **(ft+index+2)=item; } return **(ft+1); } int getFT( FlexTab ft, const int index, long *const itemp ){ if (**ft == FT_MAGIC && *ft != NULL && ft != NULL){ *itemp = **(ft + index + 2); return ( (sizeof(ft)) / (sizeof(long)) ); } else if (index >= FT_MAX){ return -2; } return 88; }
http://cboard.cprogramming.com/c-programming/76845-help-allocating-reallocating-memory.html
CC-MAIN-2014-15
refinedweb
391
61.26
Introduction Python is a very powerful programming language with easily understandable syntax which allows you to learn by yourself even you are not coming from a computer science background. Through out the learning journey, you may still make lots mistakes due to the lack of understanding on certain concepts. Learning how to fix these mistakes will further enhance your understanding on the fundamentals as well as the programming skills. In this article, I will be summarizing a few common Python mistakes that many people may have encountered when they started the learning journey and how they can be fixed or avoided. Reload Modules after Modification Have you ever wasted hours to debug and fix an issue and eventually realized you were not debugging on your modified source code? This usually happens to the beginners as they did not realize the entire module was only loaded into memory once when import statement was executed. So if you are modifying some code in separate module and import to your current code, you will have to reload the module to reflect the latest changes. To reload a module, you can use the reload function from the importlib module: from importlib import reload # some module which you have made changes import externallib reload(externallib) Naming Conflict for Global and Local Variables Imagine you have defined a global variable named app_config, and you would like to use it inside the init_config function as per below: app_config = "app.ini" def init_config(): app_config = app_config or "default.ini" print(app_config) You may expect to print out “app.ini” since it’s already defined globally, but surprisedly you would get the “UnboundLocalError” exception due to the variable app_config is referenced before assignment. If you comment out the assignment statement and just print out the variable, you would see the value printed out correctly. So what is going on here? The above exception is due to Python tries to create a variable in local scope whenever there is an assignment expression, and since the local variable and global variable have the same name, the global variable being shadowed in local scope. Thus Python throws an error saying your local variable app_config is used before it’s initialized. To solve this naming conflict, you shall use different name for your global variable and local variables to avoid any confusion, e.g.: app_config = "app.ini" def init_config(): config = app_config or "default.ini" print(config) Checking Falsy Values Examining true or false of a variable in if or while statement sometimes can also go wrong. It’s common for Python beginners to mix None value and other falsy values and eventually write some buggy code. E.g.: assuming you want to check when price is not None and below 5, trigger some selling alert: def selling_alert(price): if price and price < 5: print("selling signal!!!") Everything looks fine, but when you test with price = 0, you would not get any alert: selling_alert(0) # Nothing has been printed out This is due to both None and 0 are evaluated as False by Python, so the printing statement would be skipped although price < 5 is true. In python, empty sequence objects such as “” (empty string), list, set, dict, tuple etc are all evaluated as False, and also zero in any numeric format like 0 and 0.0. So to avoid such issue, you shall be very clear whether your logic need to differentiate the None and other False values and then split the logic if necessary, e.g.: if price is None: print("invalid input") elif price < 5: print("selling signal!!!") Default Value and Variable Binding Default value can be used when you want to make your function parameter optional but still flexible to change. Imagine you need to implement a logging function with an event_time parameter, which you would like to give a default value as current timestamp when it is not given. You can happily write some code as per below: from datetime import datetime def log_event_time(event, event_time=datetime.now()): print(f"log this event - {event} at {event_time}") And you would expect as long as the event_time is not provided during log_event_time function call, it shall log an event with the timestamp when the function is invoked. But if you test it with below: log_event_time("check-in") # log this event - check-in at 2021-02-21 14:00:56.046938 log_event_time("check-out") # log this event - check-out at 2021-02-21 14:00:56.046938 You shall see that all the events were logged with same timestamp. So why the default value for event_time did not work? To answer this question, you shall know the variable binding happens during the function definition time. For the above example, the default value of the event_time was assigned when the function is initially defined. And the same value will be used each time when the function is called. To fix the issue, you can assign a None as default value and check to overwrite the event_time inside your function call when it is None. For instance: def log_event_time(event, event_time=None): event_time = event_time or datetime.now() print(f"log this event - {event} at {event_time}") Similar variable binding mistakes can happens when you implement your lambda functions. For your further reading, you may check my previous post why your lambda function does not work for more examples. Default Value for Mutable Objects Another mistake Python beginners trend to make is to set a default value for a mutable function parameter. For instance, the below user_list parameter in the add_white_list function: def add_white_list(user, user_list=[]): user_list.append(user) return user_list You may expect when user_list is not given, a empty list will be created and then new user will be added into this list and return back. It is working as expected for below: my_list = add_white_list('Jack') # ['Jack'] my_list = add_white_list('Jill', my_list) #['Jack', 'Jill'] But when you want to start with a empty list again, you would see some unexpected result: my_new_list = add_white_list('Joe') # ['Jack', 'Jill', 'Joe'] From the previous variable binding example, we know that the default value for user_list is created only once at the function definition time. And since list is mutable, the changes made to the list object will be referred by the subsequent function calls. To solve this problem, we shall give None as the default value for user_list and use a local variable to create a new list when user_list is not given during the call. e.g.: def add_white_list(user, user_list=None): if user_list is None: user_list = [] user_list.append(user) return user_list Someone may get confused that datetime.now() shall create a Python class instance, which supposed to be mutable also. If you checked Python documentation, you would see the implementation of datetime is actually immutable. Misunderstanding of Python Built-in Functions Python has a lot of powerful built-in functions and some of them look similar by names, and if you do not spend some time to read through the documentation, you may end up using them in the wrong way. For instance, you know built-in sorted function or list sort function both can be used to sort sequence object. But occasionally, you may make below mistake: random_ints = [80, 53, 7, 92, 30, 31, 42, 10, 42, 18] # The sorting is done in-place, and function returns None even_integers_first = random_ints.sort(key=lambda x: x%2) # Sorting is not done in-place, function returns a new list sorted(random_ints) Similarly for reverse and reversed function: # The reversing is done in-place, and function returns None random_ints = random_ints.reverse() # reversing is not done in-place, function returns a new generator reversed(random_ints) And for list append and extend function: crypto = ["BTC", "ETH"] # the new list will be added as 1 element to crypto list crypto.append(["XRP", "BNB"]) print(crypto) #['BTC', 'ETH', ['XRP', 'BNB']] # the new list will be flattened when adding to crypto list crypto.extend(["UNI"]) print(crypto) # ['BTC', 'ETH', ['XRP', 'BNB'], 'UNI'] Modifying Elements While Iterating When iterating a sequence object, you may want to filter out some elements based on certain conditions. For instance, if you want to iterate below list of integers and remove any elements if it is below 5. You probably would write the below code: a = [1, 2, 3, 4, 5, 6, 2] for b in a: if b < 5: a.remove(b) But when checking the output of the list a, you would see the result is not as per you expected: print(a) # [4, 5, 6, 2] This is because the for statement will evaluate the expression and create a generator for iterating the elements. Since we are deleting elements from the original list, it will also change the state of the generator, and then further cause the unexpected result. To fix this issue, you can make use of the list comprehension as per below if your filter condition is not complex: [b for b in a if b >= 5] Or if you wish, you can use the the filterfalse together with the lambda function: from itertools import filterfalse list(filterfalse(lambda x: x < 5, a)) Re-iterate An Exhausted Generator Many Python learners started writing code without understanding the difference between generator and iterator. This would cause the error that re-iterating an exhausted generator. For instance the below generator, you can print out the values in a list: some_gen = (i for i in range(10)) print(list(some_gen)) # [0, 1, 2, 3, 4, 5, 6, 7, 8, 9] And sometimes you may forget you have already iterated the generator once, and when you try to execute the below: for x in some_gen: print(x) You would not be able to see anything printed out. To fix this issue, you shall save your result into a list first if you’re not dealing with a lot of data, or you can use the tee function from itertools module to create multiple copies of the generator so that you can iterate multiple times: from itertools import tee # create 3 copies of generators from the original iterable x, y, z = tee(some_gen, n=3) Conclusion In this article, we have reviewed through some common Python mistakes that you may encounter when you start writing Python codes. There are definitely more mistakes you probably would make if you simply jump into the coding without understanding of the fundamentals. But as the old saying, no pain no gain, ultimately you will get there when you drill down all the mistakes and clear all the roadblocks.
https://www.codeforests.com/category/resources/page/2/
CC-MAIN-2022-21
refinedweb
1,754
54.36
Quoting Nick Andrew (nick@nick-andrew.net):> Rewrite the help descriptions for clarity, accuracy and consistency.> > Kernel config options affected:> > - NAMESPACES> - UTS_NS> - IPC_NS> - USER_NS> - PID_NS> > Signed-off-by: Nick Andrew <nick@nick-andrew.net>> ---> Try #3.> > --- a/init/Kconfig 2008-02-20 09:34:48.000000000 +1100> +++ b/init/Kconfig 2008-02-22 09:01:09.000000000 +1100> @@ -414,31 +414,71 @@ config NAMESPACES> bool .> + Select various namespace options.> +> + Namespaces allow different kernel objects (such as processes> + or sockets) to have the same ID in different namespaces.> + Identifiers like process IDs, which historically were globally> + unique, will now be unique only within each PID namespace.> + Each task can refer only to PIDs within the same namespace> + as the task itself.> +> + Namespaces are used by container systems (i.e. vservers)> + to provide isolation between the containers.> +> + This option does not affect any kernel code directly; it merely> + allows you to select namespace options below.> +> + Answer Y if you will be using a container system, and you> + will probably want to enable all the namespace options> + below.> > config UTS_NS> bool "UTS namespace"> depends on NAMESPACES> help> - In this namespace tasks see different info provided with the> - uname() system call> + Enable support for multiple UTS system attributes.> +> + Each UTS namespace provides an individual view of the> + information returned by the uname() system call including> + hostname, kernel version and domain name.> +> + This is used by container systems (e.g. vservers) so that> + each container has its own hostname and other attributes.> + Tasks in the container are placed in the UTS namespace> + corresponding to the container.Hi Nick,this paragraph reads a little weird... really what happens is thateach forked task is in the same UTS namespace as its parent, unlessit was cloned with CLONE_NEWUTS or has done unshare(CLONE_NEWUTS),in which case it receives a copy.> +> + Answer Y if you will be using a container system.> > config IPC_NS> bool "IPC namespace"> depends on NAMESPACES && SYSVIPC> help> - In this namespace tasks work with IPC ids which correspond to> - different IPC objects in different namespaces> + Enable support for namespace-specific IPC IDs.> +> + IPC IDs will be unique only within each IPC namespace.> +> + This is used by container systems (e.g. vservers).> + Tasks in the container are placed in the IPC namespace> + corresponding to the container.Same as with UTS, except that upon CLONE_NEWIPC the task receives ablank new ipc namespace, not a copy of the original.> + Answer Y if you will be using a container system.> > config USER_NS> bool "User namespace (EXPERIMENTAL)"> depends on NAMESPACES && EXPERIMENTAL> help> - This allows containers, i.e. vservers, to use user namespaces> - to provide different user info for different servers.> + Enable experimental support for user namespaces.> +> + This is a function used by container-based virtualisation systems> + (e.g. vservers). User namespaces are intended to ensure that> + processes with the same uid which are in different containers are> + isolated from each other.> +> + Currently user namespaces provide separate accounting, while> + isolation must be provided using SELinux or a custom security> + module.> +> If unsure, say N.> > config PID_NS> @@ -446,12 +486,16 @@ config PID_NS> default n> depends on NAMESPACES && EXPERIMENTAL> help> - Suport process id namespaces. This allows having multiple> - process with the same pid as long as they are in different> - pid namespaces. This is a building block of containers.> + Enable experimental support for hierarchical process id namespaces.> > - Unless you want to work with an experimental feature> - say N here.> + This is a function used by container-based virtualisation> + systems (e.g. vservers). Each process will have a distinct> + Process ID in each PID namespace which the process is in.> + Processes in the container are placed in the PID namespace> + corresponding to the container, and cannot see or affect> + processes in any parent PID namespace.A cloned process inherits the pid namespace hierarchy from itsparent. If it was cloned with CLONE_NEWPID, the hierarchy istopped with one additional newly created pid namespace. Thisis the only pid namespace in which the new process will be ableto see processes, while it will be visible in all namespaces inits pidns hierarchy.A pid namespace cannot be unshared.> +> + If unsure, say N.> > config BLK_DEV_INITRD> bool "Initial RAM filesystem and RAM disk (initramfs/initrd) support"
http://lkml.org/lkml/2008/2/22/457
CC-MAIN-2014-15
refinedweb
695
58.28
This package provides debug information for package 389-ds. Debug information is useful when developing applications that use this package or when debugging this package. 1.4.1.2 1.4.0.3 1.3.4.5 Latest updates OpenSUSE Tumbleweed debug/oss: Updated from 1.4.1.2~git0.9a126614a-1.1 to 1.4.1.2~git0.9a126614a-1.4 Jun 19 - fix permissions handling (boo#1120189) OpenSUSE Leap 15.0 debug debug/oss: Version 1.4.0.3-lp151.4.1 introduced Apr 10 - fix permissions handling (boo#1120189) OpenSUSE Tumbleweed debug/oss: Updated from 1.4.1.1~git0.af9bb7206-2.1 to 1.4.1.2~git0.9a126614a-1.1 Apr 09 - fix permissions handling (boo#1120189) OpenSUSE Leap 15.1 debug/oss: Version 1.4.0.3-lp151.3.2 removed Mar 22 OpenSUSE Tumbleweed debug/oss: Updated from 1.4.1.1~git0.af9bb7206-1.1 to 1.4.1.1~git0.af9bb7206-2.1 Mar 19 - Remove a pair of %if..%endif guards that do not affect the build. OpenSUSE Tumbleweed debug/oss: Version 1.4.1.1~git0.af9bb7206-1.1 introduced Feb 26 - OpenSUSE Leap 15.1 debug/oss: Version 1.4.0.3-lp151.3.2 introduced Jan 23 - Explicitly generate dirsrv sysconfig file as it is necessary for SLES 15 (bsc#1081324). OpenSUSE Leap 42.3 debug/update/oss: Version 1.3.4.5-8.1 introduced Jan 18 - debug/oss: Version 1.4.0.3-lp150.2.2 introduced Jan 17 - Explicitly generate dirsrv sysconfig file as it is necessary for SLES 15 (bsc#1081324). OpenSUSE Leap 42.3 debug/oss: Version 1.3.4.5-6.13 introduced Jan 17 - Update to new upstream release 1.3.4.5 - Various bugs are fixed
https://reposcope.com/package/389-ds-debuginfo
CC-MAIN-2019-30
refinedweb
297
56.01
40. Re: Photoshop saving issue (FILES TOO LARGE)Rome_Gio Dec 17, 2016 4:49 AM (in response to davescm) Then what was the point to making the export function? I can see save for web doing this as 72 ppi is standard for screens, but not export as functionality Save as will alter the titling on the artboard if saving a file with no layers... Adding extra time that the export function was supposed to help by allowing changing of image size to export to a particular dimension.... What is happening lately Adobe? 41. Re: Photoshop saving issue (FILES TOO LARGE)D Fosse Dec 17, 2016 6:02 AM (in response to Rome_Gio) giovani1059 wrote: IT IS A PHOTOSHOP ISSUE!!!!!! You can stop shouting, giovani. This is by design, it is not an "issue". - Export and Save For Web do not export at 72 ppi. They strip resolution metadata altogether from the file. The file in fact does not have a ppi at all when exported - not 72, not 96, not 300, nothing. The 72 figure appears when the file is reopened into Photoshop, and a default value of 72 is assigned, because it has to assign something. Other applications have different defaults. This is done because Export is intended for screen viewing only - web, phones, tablets. On screen, ppi is a completely meaningless figure. It only applies to printing on paper. If that's what you're doing - don't Export. Save As. 42. Re: Photoshop saving issue (FILES TOO LARGE)Mike Arrowsmith Dec 30, 2016 10:00 AM (in response to kylet17468902) I've been having a similar problem using Image Processor in CC2017 to create thumbnails constrained to a maximum of 180 pixels in the largest dimension. Some files processed as expected and resulted in files of 20KB or so, whilst others were saving at 4MB. I eventually resolved it by disabling the 'Include ICC profile' option so that seems to be where the problem lies, in my case at least. I tested this further by doing a 'Save as' of the original file without the embedded colour profile and halved the resulting filesize. Hope this is useful to someone else who's been tearing their hair out over this. 43. Re: Photoshop saving issue (FILES TOO LARGE)D Fosse Dec 30, 2016 11:30 AM (in response to Mike Arrowsmith) Mike Arrowsmith wrote: I eventually resolved it by disabling the 'Include ICC profile' option so that seems to be where the problem lies An icc profile is only 3 kB, so that simply can't be, unless the profile is massively corrupt. It is never a good idea to strip the profile. It is known that file history metadata sometimes can balloon a file to enormous sizes (several MB). I rather think that's it. Try Export or Save For Web with metadata set to "none" or "copyright". That should strip out all those megabytes. 44. Re: Photoshop saving issue (FILES TOO LARGE)Test Screen Name Dec 30, 2016 11:31 AM (in response to kylet17468902) A profile need not be just 3 kB. A CMYK profile is typically multiple megabytes. 45. Re: Photoshop saving issue (FILES TOO LARGE)Mike Arrowsmith Dec 30, 2016 11:53 AM (in response to D Fosse) Well, it it simply *can be*. Whether or not it's a corrupt profile I don't know, nor would I know how to tell, but this definitely resolves it for me. Screenshot attached of image processor results: .jpg is with included ICC profile _1.jpg is without ICC profile _2.jpg is with ICC profile, but with 'convert profile to sRGB' selected. 46. Re: Photoshop saving issue (FILES TOO LARGE)Earth Oliver Dec 30, 2016 11:59 AM (in response to Test Screen Name) 47. Re: Photoshop saving issue (FILES TOO LARGE)starstruck80 Feb 6, 2017 5:19 AM (in response to kylet17468902) i have the same problem. i'm working in CS6 and the problem only surfaced when working with cc files i had to open. save for web does the job correctly, but it's impossible to create a correctly (file-)sized jpg through the "save as" process. -with/without colour profile: no effect -changing the file's size or resolution - no effect -pasting the file's art into an new file - no effect -converting to another colour mode - no effect can anyone at adobe fix this please? 48. Re: Photoshop saving issue (FILES TOO LARGE)gener7 Feb 6, 2017 5:33 AM (in response to starstruck80) Using File > Export> Save for Web, set Metadata to "None" or "Copyright", save the file, and tell me if you get a reasonable size. 49. Re: Photoshop saving issue (FILES TOO LARGE)ndeliso Feb 9, 2017 5:59 AM (in response to kylet17468902) This problem just showed up in my photoshop CS6 as well. Up until a week ago, files were saved at a reasonable size. For three years, there has been no change in my process, no change in my hardware, no change in my software. Suddenly, even a white background 4x5 inch photo with nothing other than black text on it comes in at over 6MB. I don't understand how a bug could "suddenly develop" when there have been no changes in anything on my end. I ran MacAfee and this does not appear to be the result of a virus. I'm in CS6,version 13.0.1. Any suggestions on resolving the actual problem, rather than creating a whole new process of saving as a PNG, opening, then resaving as a JPG (which did actually work) for all of my many, many pictures that I process each week? 50. Re: Photoshop saving issue (FILES TOO LARGE)tedt72583949 Feb 24, 2017 8:36 AM (in response to kylet17468902) Hey guys, just got this bug and yes saving without metadata worked as a quick fix. Honestly have no idea how Adobe manages to put 5MB of metadata into a file. Seriously, try turning down quality to 0 for a jpeg, still 5mb. 51. Re: Photoshop saving issue (FILES TOO LARGE)D Fosse Feb 24, 2017 9:23 AM (in response to tedt72583949) tedt72583949 wrote Honestly have no idea how Adobe manages to put 5MB of metadata into a file. This issue has been looked into by engineers here in the forum a couple of times. In all instances it turned out to be what they called "ancestors metadata" - IOW a record of the file origin and history. The metadata isn't put there by Adobe, but users. 52. Re: Photoshop saving issue (FILES TOO LARGE)Rami Hoballah Mar 1, 2017 11:34 PM (in response to kylet17468902) 53. Re: Photoshop saving issue (FILES TOO LARGE)D Fosse Mar 2, 2017 4:44 AM (in response to Rami Hoballah) wrote Same problem here with Adobe Photoshop CC 2014 And same cause and same solution. See above. Now, I have no opinion as to why this history metadata is included, or whether it should be included, but that's the way it is. 54. Re: Photoshop saving issue (FILES TOO LARGE)ShanesAdobe May 26, 2017 11:29 PM (in response to davescm) I'm having the EXACT same issue except the file sizes are FAR huger. Consider the following screenshots to illustrate: 1. Saving a simple red block image 1080 pixels high by 801 wide. Scratch size in Photoshop shows 2.48M 2. Choosing JPG with compression of 9/high suggests a file of 19M (but saves at 15.7M)? WHY? 3. To try and avoid the saving issue -- I've tried: Select all > Copy Flattened > Paste to NEW using clipboard -- and then Save As... and still 19M suggested /15.7M Actual size. WHY? It's a red block from a new file with no metadata...?! 4. Using "export to web" exports the simple image to 11K This is a bug and we need to know how to fix it. As evident here -- enough users are having the issue -- and since we are paying for this software, and this is effecting our productivity having to use annoying work-arounds, it should be resolved. Especially since we're now forced into a subscription model where our software is meant to be continually updated. Please help. This is not user error. It's a bug. It's slowing down users productivity, is a massive pain, and it's unacceptable. 55. Re: Photoshop saving issue (FILES TOO LARGE)davescm May 27, 2017 2:41 AM (in response to ShanesAdobe) There has been no bug found so far in this thread. If you read back through it there were two issues. The first was metadata (which can get huge). If you are creating a new document from scratch then this is unlikely to be your issue. The second was a broken (and very large) color profile. What color profile is attached to your document and have you tried saving without the profile to see if that is your issue? I tried the exact document size here (as 8 bit RGB in the Adobe RGB color space) . With the same jpeg settings I get : Dave 56. Re: Photoshop saving issue (FILES TOO LARGE)Stephen_A_Marsh May 27, 2017 6:14 AM (in response to ShanesAdobe) There will be a difference between the metadata in the “save as” files vs. “save for web” or “export”. Compare the 15mb files to the 11kb file – is there a photoshop:DocumentAncestors metadata entry when exploring via File > File Info > Raw Data? You could always share the files via DropBox or similar for others to explore. 57. Re: Photoshop saving issue (FILES TOO LARGE)Korrektorr May 27, 2017 6:21 AM (in response to ShanesAdobe) This is not a bug but a very annoying thing. Find a "history log" in preferences and disable it. You can also run this JSX script to remove metadata from a file that already exists For others viewing this thread in may 2017 - is there any easy way to remove metadata from the document or probably even prevent it to load in any documents? I'm working with few designers that have this stuff enabled for some reason (I use their templates or psds) and I hate so much to doublecheck every saved image or use export functions instead of saving It is very annoying, really 58. Re: Photoshop saving issue (FILES TOO LARGE)Stephen_A_Marsh May 28, 2017 11:32 PM (in response to Korrektorr) Until Adobe offer a direct feature to disable this feature, end users have to use workarounds… (1) Offhand, you could setup the script to remove DocumentAncestors metadata to be automatically run via the Script Events Manager when a document OPEN, SAVE or EXPORT event is used. (2) I might be able to hack something together in Adobe Bridge from other scripts, which is a better choice than opening up images into Photoshop. Edit: This is proving to be not so easy! (3) Another option is to use the CLI driven ExifTool on already saved files, which is great if you have files that use lossy compression: Mac OS: exiftool -r -overwrite_original -XMP-photoshop:DocumentAncestors= '/Users/currentusername/Documents/Top Level Folder' Windows OS: exiftool -r -overwrite_original -XMP-photoshop:DocumentAncestors= "C:\Users\Currentuser\Documents\Top Level Folder" Note (this could take some time, target lower level folders and work one folder at a time if there are many files): All readable/writable file types in the top level folder and any sub level folders/files in the nominated file path would have their Photoshop XMP DocumentAncestors metadata removed, overwriting the original file/s. Ensure that you have backups of the data first, or remove the -overwrite_original command. Use at your own risk. A technically better approach may be to introduce a conditional processing step, so that only files that contain DocumentAncestor metadata are processed (this could take some time, target lower level folders and work one folder at a time if there are many files): Mac OS: exiftool -r -overwrite_original -if '$XMP-photoshop:DocumentAncestors =~ /.*/' -XMP-photoshop:DocumentAncestors= '/Users/currentusername/Documents/Top Level Folder' Windows OS: exiftool -r -overwrite_original -if "$XMP-photoshop:DocumentAncestors =~ /.*/" -XMP-photoshop:DocumentAncestors= "C:\Users\Currentuser\Documents\Top Level Folder" Mac users can set slightly modified versions of these commands into an Automator task that can be accessed via a simple contextual right click on files/folders, or any of the other possible processing methods available (drag-n-drop to application, watched folders, scheduled via Calendar etc). Windows users can set slightly modified versions of these commands in a drag-n-drop .exe or use scheduled tasks to run the commands from a .bat or .cmd file etc. 59. Re: Photoshop saving issue (FILES TOO LARGE)Stephen_A_Marsh May 31, 2017 6:39 AM (in response to Stephen_A_Marsh) OK, I figured out the Bridge script! However I don’t understand why Bridge requires a 2 step process! All this time I thought that the code was bad, when it was “working fine”. Step 1: Run the Bridge script to remove DocumentAncestors metadata (the file size does not change, when it “should”) Step 2: Apply a secondary metadata change in Bridge, such as adding/removing a temporary keyword, or rotating clockwise and then rotating back counterclockwise again to “force the image to reset” The second step for whatever reason will force the file to update and take into account the removal of the DocumentAncestors metadata and then applies the file size reduction! The code: // // #target bridge // let EntendScript know what app the script is for clearDocumentAncestors = {};// create an object clearDocumentAncestors.execute = function(){// create a method for that object var sels = app.document.selections;// store the array of selected files for (var i = 0; i < sels.length; i++){//loop though that array var md = sels[i].synchronousMetadata;// get the metadata for the file md.namespace = "";// set the namespace md.DocumentAncestors = " ";//set the porperty } } // this script only works in bridge if (BridgeTalk.appName == "bridge"){ //creage the munuItem var menu = MenuElement.create( "command", "Clear DocumentAncestors in metadata", "at the end of Tools"); menu.onSelect = clearDocumentAncestors.execute; } 60. Re: Photoshop saving issue (FILES TOO LARGE)daryljimenea Jun 1, 2017 2:29 PM (in response to kylet17468902) Hello, I am having the same problem, I am running Mac OS Sierra 10.12.4 and Photoshop CC 17.0.0 Release on a . Every time I save the JPEG it doesn't go down below 3mb file size event if I set the quality to 0. I usually do batch process from bridge, It ends up having huge image sizes after export to jpeg. I've already everything, restarting photoshop, bridge, restarting computer etc. 61. Re: Photoshop saving issue (FILES TOO LARGE)Stephen_A_Marsh Jun 1, 2017 2:53 PM (in response to daryljimenea) So apart from trying all of the things that don't work, have you tried the posted solutions that do work? 62. Re: Photoshop saving issue (FILES TOO LARGE)kcroy2011 Jun 1, 2017 4:59 PM (in response to Stephen_A_Marsh) This is still marked as "not answered", so maybe just a helpful pointer to the best solution would be nice. Here is one: jpg file size during "save as" 63. Re: Photoshop saving issue (FILES TOO LARGE)Stephen_A_Marsh Jun 1, 2017 6:02 PM (in response to kcroy2011) My two previous posts #58 and #59 in this topic offer solutions: And then there is this one too: 64. Re: Photoshop saving issue (FILES TOO LARGE)nikdel5 Jun 14, 2017 7:54 AM (in response to kylet17468902) I am having the same issue and it just started happening about a month ago. We're using the latest version available on Creative Cloud. What we're doing is taking a JPG file, setting it up for print (normally at 200ppi for black and white newsprint) and saving it out as a JPG or PSD to be embedded into an InDesign file. Normally these small ads would be ~1MB, but we've started incurring a lot of bloating in these JPG or PSD files suddenly over the last few months. We've reinstalled, reset preferences to no avail. This issue generally only happens on one install running on a MacBook Pro (2.3 GHz Intel Core i7, 16GB RAM) Here is a link to download two example files to demonstrate the issue: Dropbox - Photoshop Troubleshooting 65. Re: Photoshop saving issue (FILES TOO LARGE)Stephen_A_Marsh Jun 14, 2017 2:32 PM (in response to nikdel5) Yes, it’s DocumentAncestors metadata again (around 15mb of bloat), this Bridge search isolated your images as matching this criteria (as does using File > File Info): Again, my previous posts #58 and #59 in this topic offer solutions to this issue. I recommend setting up the Photoshop script in Script Events Manager on all computers and also installing the Bridge script to put out spot fires where needed. Direct links to the script source code: Re: Inflated JPG File Size - Photoshop Document:Ancestors Metadata Bridge Script to Remove Photoshop DocumentAncestors Metadata Keep in mind that a simple export/save for web can also strip metadata, which should be used for “web” images, however sometimes users need to send out hi-res data or CMYK etc, so export/save for web is not always suitable and then these Photoshop or Bridge scripts will be necessary if the files are bloated. 66. Re: Photoshop saving issue (FILES TOO LARGE)Stephen_A_Marsh Jul 13, 2017 1:08 AM (in response to Stephen_A_Marsh)2 people found this helpful I have documented all known solutions at my blog (please let me know if I need to add any further solutions or info): Prepression: Metadata Bloat – photoshop:DocumentAncestors 67. Re: Photoshop saving issue (FILES TOO LARGE)deanp78121107 Aug 7, 2017 7:42 AM (in response to kylet17468902) Did the file you were working on originate from the web as a resource? I worked on a PSD file for a mobile phone, when I save the file as a TIFF it was 26MB. I thought this was wrong, so saved it so it was 1cm wide. When I checked the file is was still 26MB. Which clearly means there is meta data or something in the bloating it. So, to resolve the problem, I saved as a TIFF again. The file was 26MB. I opened it in the excellent Graphic Converter. I literally just did a save as, saved over the TIFF and when I checked the file it was 2.8MB as I had expected. Basically, you have data in there, that no matter what yo do stays connected to the file. 68. Re: Photoshop saving issue (FILES TOO LARGE)deanp78121107 Aug 7, 2017 7:58 AM (in response to kylet17468902) I was correct in saying its additional data. The following link will describe how to remove the bloated data: Prepression: Metadata Bloat – photoshop:DocumentAncestors 69. Re: Photoshop saving issue (FILES TOO LARGE)derrickwills Nov 7, 2017 8:30 PM (in response to kylet17468902)2 people found this helpful The problem is a Corrupted/Bloated Meta Data File. SOLUTION: - CREATE a NEW DOCUMENT using same dimensions and dpi - DRAG Layers from old document to new document - DELETE corrupted Document - WORK AS NORMAL That should be an easy work around. 70. Re: Photoshop saving issue (FILES TOO LARGE)Stephen_A_Marsh Nov 7, 2017 9:20 PM (in response to derrickwills) Hi derrickwills– one needs to double check the actual metadata before assuming corruption. If the excessive file size is due to DocumentAncestors metadata and not due to corruption, creating a new blank file and dragging over the layer will carry over the bloat and will not reduce file size. P.S. Rather than dragging, using the Apply Image command to “stamp” data between documents does not carry over any embedded DocumentAncestors metadata. 71. Re: Photoshop saving issue (FILES TOO LARGE)derrickwills Nov 7, 2017 10:11 PM (in response to Stephen_A_Marsh) Maybe not a Meta Data file but something is corrupted and bloated. I just know it worked for me having the same issue. 72. Re: Photoshop saving issue (FILES TOO LARGE)leo.zuo Feb 6, 2018 3:50 AM (in response to derrickwills) I had this problem a few times as well. And I've also discovered this approach suggested by derrickwills, to create a new document, and duplicate all layers to the new document. Currently, this workaround works fine for me. But I really hope Adobe will fix this issue. It's been two years since the OP brings this up and still not fixed as of today, in the latest Photoshop CC. It's really FRUSTRATING! As you can see in this screenshot: after the file has been corrupted, I deleted all layers, then resized it down to 100*140px. Still saved as a 10MB JPEG file. Under preferences, history log is disabled (not checked). I don't know why am I getting the photoshop:DocumentAncestors metadata entry in my files. 73. Re: Photoshop saving issue (FILES TOO LARGE)Stephen_A_Marsh Feb 6, 2018 4:51 PM (in response to leo.zuo) Under preferences, history log is disabled (not checked). I don't know why am I getting the photoshop:DocumentAncestors metadata entry in my files. History log settings do not have any bearing on photoshop:DocumentAncestors metadata. This metadata is added as a record of copy/paste or placed document ID entries. Prepression: Metadata Bloat – photoshop:DocumentAncestors 74. Re: Photoshop saving issue (FILES TOO LARGE)rickburress Jun 12, 2018 6:49 PM (in response to kylet17468902)1 person found this helpful This just happened to us on Mac OS Sierra and Photoshop cc2017. A file reporting in the lower left corner it was 144mb, flattened, no extra layers or channels, 8-bit, RGB, ACTUALLY saved as a 956mb file to the Hard drive. The only workaround was to create a new file of the same dimensions and drag and drop the Background layer to the new document. Only then did it save as 144mb. 75. Re: Photoshop saving issue (FILES TOO LARGE)essig-peppard Jun 25, 2018 2:24 PM (in response to kylet17468902) This just started with me yesterday! The only thing I can think of is I'm collaborating with another artist on a gig - he's working on a Mac and sent me a PSD he was working on so I could wrap up (unknown version of photoshop on his end but I'm running at the latest version). Now, any asset originating from his PSD saves as a 118.8MB JPEG (regardless of changes in DPI or composition dimensions). The JPEG file size/quality slider results in only a single MB difference between 0 and 10 on the slider. This applies to even to any flattened images that originated from content in his PSD. 76. Re: Photoshop saving issue (FILES TOO LARGE)D Fosse Jun 25, 2018 2:37 PM (in response to essig-peppard)1 person found this helpful essig-peppard wrote The only thing I can think of This has been explained several times over, if you scroll up a bit and read a few of the latest posts, like #73 by Stephen A Marsh. Use Save For Web or Export to strip the metadata. 77. Re: Photoshop saving issue (FILES TOO LARGE)essig-peppard Jun 25, 2018 3:21 PM (in response to D Fosse) Thanks! It looks like his file is experiencing the bloated metadata problem and it's carrying over into any visuals I use from his PSD. Unfortunately, I'm not a programmer and I'm a bit too close to the finish line on this gig to run the metadata removal script without knowing exactly how it would affect my own work/files. Looks like I'll have to look into it once I'm wrapped. 78. Re: Photoshop saving issue (FILES TOO LARGE)Stephen_A_Marsh Jun 25, 2018 3:53 PM (in response to essig-peppard) Multiple solutions are covered here: Prepression: Metadata Bloat – photoshop:DocumentAncestors To install scripts: Prepression: Downloading and Installing Adobe Scripts 79. Re: Photoshop saving issue (FILES TOO LARGE)andynickless Jun 27, 2018 12:11 PM (in response to Stephen_A_Marsh) I've been having this problem recently. A 1280 x 720 6.2MB tiff image was 4.1MB when saved as a jpeg (Quality 1). After much tearing of hair, deleting Photoshop CS6 Preferences and eventually reinstalling the application, it turned out the problem was happening because I'd previously edited the image with the Picktorial application before exporting it as a tiff. When I opened a completely fresh version of the image in CS6, the resulting jpeg was tiny.
https://forums.adobe.com/message/10466256
CC-MAIN-2018-51
refinedweb
4,101
59.84
Varld's Popover and Tooltip Library .Simple Tooltip and Popover Components with React Simple Tooltip and Popover components made by Varld 💖 # yarn yarn add @varld/popover # npm npm install --save @varld/popover import { Tooltip } from '@varld/popover'; let Component = () => { return ( <Tooltip content="I am a tooltip"> <button>I have a tooltip</button> </Tooltip> ) } import { Popover } from '@varld/popover'; let Component = () => { return ( <Popover popover={({ visible, open, close }) => { return ( <div> I am a popover and i am {visible ? 'visible' : 'not visible'} and {open ? 'open' : 'not open'} <button onClick={() => close()}> Close me </button> </div> ) }}> <button>I have a popover</button> </Popover> ) } The popover prop gets passed an object with three values (open, visible and close) and must return a ReactElement. The open value is true when the popover is fully visible or animating. The visible value is true when the popover is fully visible. The close value is a function, which you can call to close the popover. Author: varld. This article will walk you through the concepts you would need to know to step into the world of widely used ReactJS.
https://morioh.com/p/8376270a28c6
CC-MAIN-2021-10
refinedweb
179
66.98
The NetCDF-flattener package Project description netcdf-flattener Flatten netCDF files while preserving references as described in the CF Conventions 1.8, chapter 2.7. Usage The flattener takes as input and output NetCDF Dataset objects, which the user can create or open from ".nc" files using the netCDF4 API. To flatten the Dataset named "input_dataset" into a Dataset named "output_dataset", use the following command. In most cases, "output_dataset" will be an empty Dataset. import netcdf_flattener netcdf_flattener.flatten(input_dataset, output_dataset) By default, the flattener is in strict mode and returns an exception if a an internal reference from a variable attribute to a dimension or variable could not be resolved. To use the lax mode that continues the flattening process with warning, specify the lax_mode parameter: netcdf_flattener.flatten(input_dataset, output_dataset, lax_mode=True) For copying variables that would otherwise be larger than the available memory, the copy_slices parameter allows to specify slices to be used when copying the variable. They are specified per variable in a dictionary. The slicing shape is either None for using a default slice value, or a custom slicing shape in the form of a tuple of the same dimension as the variable. If a variable from the Dataset is not contained in the dict, it will not be sliced and copied normally. Slice shapes should be small enough to fit in memory, but not too small larges loops on small slice can degrade performances drastically. Typically, slices of size in the order of 10^6 to 10^8 are suitable. netcdf_flattener.flatten(input_dataset, output_dataset, copy_slices={"/grp1/var1": (1000,1000,500,), "/grp1/var3": None}) Limitations When a CF coordinate variable in the input dataset is in a different group to its corresponding dimension, the same variable in the output flattened dataset will no longer be a CF coordinate variable, as its name will be prefixed with a different group identifier than its dimension. In such cases, it is up to the user to apply the proximal and lateral search alogrithms, in conjunction with the mappings defined in the flattener_name_mapping_variables and flattener_name_mapping_dimensions global attributes, to find which netCDF variables are acting as CF coordinate variables in the flattened dataset. For example, if an input dataset has dimension lat in the root group and coordinate variable lat(lat) in group /grp1, then the flattened dataset will contain dimension lat and variable grp1__lat(lat), both in its root group. In this case, the flattener_name_mapping_variables global attribute of the flattened dataset will contain the mapping "grp1__lat: /grp1/lat" and the flattener_name_mapping_dimensions global attribute will contain the mapping "lat: /lat". Deployment From PyPi netCDF-flattener is in installable with pip, for example: pip install netcdf-flattener From source Install the build dependencies: python3 -m pip install --upgrade pip setuptools wheel Download the source code from and compile the wheel file, by running the following command from the repository root: python3 setup.py bdist_wheel Install the wheel file using pip: python3 -m pip install dist/netcdf_flattener-*.whl Support Questions and issues should be raised at the issue tracker in the canonical source code repository: Automated testing Dependencies Running the tests requires having the NetCDF4 libraries installed (ncdump and ncgen applications are required). You can install them either using your package manager, or build them from the source. On CentOS: sudo yum install netcdf Install Pytest: python3 -m pip install pytest All other dependencies are managed by pip and use OSI-approved licenses. Run the tests Run Pytest from the root of the repository: python3 -m pytest Documentation A Sphinx project is provided to generate the HTML documentation from the code. Install Sphinx: python3 -m pip install sphinx From the "doc" folder, build the documentation: cd doc sphinx-build -b html . build The entry point to the documentation is the doc/build/index.html file. License This code is under Apache 2.0 License. See LICENSE for the full license text. Authors Project details Release history Release notifications | RSS feed Download files Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
https://pypi.org/project/netcdf-flattener/1.0.1b3/
CC-MAIN-2022-33
refinedweb
677
50.36
We are about to switch to a new forum software. Until then we have removed the registration on this forum. So, I've been searching around the web about this, and I found some solutions, but seems like none worked (reinstall Processing, move the sketch folder somewhere else, and I've seen the Minim library, but I would prefer to use processing.sound). I actually got it working yesterday, but today it's saying again: Target VM failed to initialize. So, pretty much I can recreate this with the code below. import processing.sound.*; WhiteNoise noise; void setup() { size(800, 600); background(255); noise = new WhiteNoise(this); noise.play(); } Here's the log, if it helps.
https://forum.processing.org/two/discussion/19991/can-t-run-the-sketch-with-processing-sound
CC-MAIN-2019-43
refinedweb
116
73.07
NAME sync, syncfs - commit buffer cache to disk SYNOPSIS #include <unistd.h> void sync(void); void syncfs(int fd); Feature Test Macro Requirements for glibc (see feature_test_macros(7)): sync(): _BSD_SOURCE || _XOPEN_SOURCE >= 500 || _XOPEN_SOURCE && _XOPEN_SOURCE_EXTENDED syncfs(): _GNU_SOURCE DESCRIPTION sync() causes all buffered modifications to file metadata and data to be written to the underlying file systems. syncfs() is like sync(), but synchronizes just the file system. CONFORMING TO sync(): SVr4, 4.3BSD, POSIX.1-2001. syncfs() is Linux-specific. NOTES Since glibc 2.2.2 the Linux prototype for sync().35 of the Linux man-pages project. A description of the project, and information about reporting bugs, can be found at.
http://manpages.ubuntu.com/manpages/precise/en/man2/syncfs.2.html
CC-MAIN-2014-41
refinedweb
110
60.41
TheSmokie 241 Posted August 8, 2019 Share Posted August 8, 2019 Hello, i got the idea from someone else and thought it would be a good idea to release the source code for people who wish to log there fightclass / plugins to be able to help find bugs faster and help people fix problems with there product. enjoy Class.cs using System; using System.IO; using robotManager.Helpful; public class Main : wManager.Plugin.IPlugin { public void Initialize() { Log("Hello, welcome to pornhub."); } public void Dispose() { } public void Settings() { } private void Log(String lines) { System.IO.Directory.CreateDirectory(@"Plugins\FileName\logs\"); string logpath = Path.Combine(Environment.CurrentDirectory, @"Plugins\FileName\logs\", "Logger" + DateTime.Now + ".txt"); try { System.IO.StreamWriter file = new System.IO.StreamWriter(logpath, true); file.WriteLine(lines + "\n"); file.Close(); } catch (Exception e) { Logging.Write("[Logger] Error logging" + e); } } } Kamogli 1 Quote Link to comment Share on other sites More sharing options... Recommended Posts Join the conversation You can post now and register later. If you have an account, sign in now to post with your account.
https://wrobot.eu/forums/topic/11559-release-simple-log-format/
CC-MAIN-2022-40
refinedweb
177
53.58
Wing Tips: Extending Wing with Python (Part 2 of 4) In this issue of Wing Tips we continue to look at how to extend Wing's functionality, by setting up a project that can be used to develop and debug extension scripts written for (and with) Wing, just as you would work with any other Python code. If you haven't already read it, you may want to check out Part 1 of this series, where we introduced Wing's scripting framework and set up auto-completion for the scripting API. Creating a Scripting Project To debug extension scripts written for Wing, you will need to set up a new project that is configured so that Wing can debug itself. The manual steps for doing this are documented in Debugging Extension Scripts. However, let's use an extension script to do this automatically. Copy the following Python code and paste it into a new file in Wing, using the File > New menu item: import sys import os import collections import wingapi def new_scripting_project(): """Create a new Wing project that is set up for developing and debugging scripts using the current instance of Wing""" app = wingapi.gApplication def setup_project(): # Set the Python Executable to the Python that runs Wing proj = app.GetProject() proj.SetPythonExecutable(None, sys.executable) if not __debug__: from proj.attribs import kPyRunArgs app.fSingletons.fFileAttribMgr.SetValue(kPyRunArgs, None, ('custom', '-u -O')) # Add Wing's installation directory to the project proj.AddDirectory(app.GetWingHome()) # Set main debug file to Wing's entry point wingpy = os.path.join(app.GetWingHome(), 'bootstrap', 'wing.py') proj.SetMainDebugFile(wingpy) # Setup the environment for auto-completion on the API and some additional # values needed only on macOS; use OrderedDict because later envs depend # on earlier ones env = collections.OrderedDict() env['PYTHONPATH'] = os.path.join(app.GetWingHome(), 'src') if sys.platform == 'darwin': runtime_dir = os.path.join(app.GetWingHome(), 'bin', '__os__', 'osx') files = os.listdir(runtime_dir) for fn in files: if fn.startswith('runtime-qt'): qt_ver = fn[len('runtime-'):] break env.update(collections.OrderedDict([ ('RUNTIMES', runtime_dir), ('QTVERSION', qt_ver), ('QTRUNTIME', '${RUNTIMES}/runtime-${QTVERSION}'), ('SCIRUNTIME', '${RUNTIMES}/runtime-scintillaedit-${QTVERSION}'), ('DYLD_LIBRARY_PATH', '${QTRUNTIME}/lib:${SCIRUNTIME}/lib'), ('DYLD_FRAMEWORK_PATH', '${DYLD_LIBRARY_PATH}'), ])) app.GetProject().SetEnvironment(None, 'startup', env) # Create a new project; this prompts the user to save any unsaved files first # and only calls the completion callback if they don't cancel app.NewProject(setup_project) new_scripting_project.contexts = [wingapi.kContextNewMenu('Scripts')] Save this to a file named utils.py or any other name ending in .py in the scripts directory that is located inside Wing's Settings Directory, as listed in Wing's About box. Then select Reload All Scripts from the Edit menu to get Wing to discover the new script file. Once that's done, Wing monitors the file and will reload it automatically if you edit it and save changes to disk. You can now create your project with New scripting project from the Scripting menu that should appear in the menu bar: This prompts to save any edited files before closing the current project, and then creates and configures the new project. Debugging Extension Scripts Now you're ready to develop and debug extension scripts with Wing. Try this now by appending the following to the script file that you created in the previous section: import wingapi def hello_world(): wingapi.gApplication.ShowMessageDialog("Hello", "Hello world!") hello_world.contexts = [wingapi.kContextNewMenu("Scripts")] Save this to disk and then set a breakpoint on the third line, on the call to ShowMessageDialog. Next, uncheck the Projects > Auto-reopen Last Project preference so that the debugged copy of Wing opens the default project and not your already-open scripting project: Then select Start/Continue from the Debug menu to start up a copy of Wing running under its own debugger. This copy of Wing should also contain a Scripts menu in its menu bar, with an item Hello world: Select that and you will reach the breakpoint you set in the outer instance of Wing (the one you started debug from): You will see and can navigate the entire stack, but Wing will not be able to show source files for most of its internals. If you need to see the source code of Wing itself, you will have to obtain the source code as described in Advanced Scripting. That's it for now! In the next Wing Tip we'll look look at how extension scripts can collect arguments from the user. Share this article:
https://wingware.com/hints/scripting-2
CC-MAIN-2019-35
refinedweb
741
53.41
Introduction Separation of Concerns is the in thing these days, and with the introduction of RESTful architecture, it has been a cakewalk; however, new developers often face the dilemma of choosing their weapons. The frameworks, and the suite of tools they will use to develop their next killer application. Not long ago, I was one of them, and then I came across this excellent talk by Eran Hammer from WalmartLabs, and decided that Hapi.js was the way to go. The problem with Hapi.js is that it is simple and complicated at the same time. Honestly, I find it cleaner and easier than Express.js, and you will see why I say that once we're done with this segment. Our goal Everyone hates a tutorial which just contains some incoherent code, and expects you to follow along. And hence, we will actually make something; by the end of this series, we will have a fully functional application to add pictures of cute cats. (Really, this is the kind of application I want to work on.) Since covering everything in one long post will be anything but smart (and because we love a "modular apporach"), I have broken this tutorial in 2 parts. In sequence, following will be the outline: - Part 1 - a gentle introduction to Hapi.js; we set up the environment and all the dependencies; simple Hello World; - Part 2 - creating a fully blown RESTful API using Hapi.js [Update] The second part is finished and up at [](this link). After deployment, we will have a fully functional and consumable API with all the goodies. So, what are we waiting for for? Let's get started. What is Hapi.js? Hapi (pronounced "happy") is a web framework for building web applications, APIs and services. It's extremely simple to get started with, and extremely powerful at the same time. The problem arises when you have to write perfomant, maintable code. Let's Start With that said, let's dive straight in. But before we get to coding, let me explain what our development environment will look like. I am a fan of ES6, and really, I can't write code in the old ES5 syntax. I will show you a really quick way to get started with ES6 without the transpiling part. That's great: it means that you don't have to run gulp build:development everytime you make a change. We'll use Babel for on-the-fly transpilation of the ES6 code. I say on the fly simply because there is no direct output; if you're familiar with CoffeeScript's require hook, it'll be just like that. If you are not, then don't worry because this is really, really simple. Directory Structure For starting out, we'll have a fairly simple directory structure with just one src folder, and all of the program files will reside in that folder. In the root folder, we'll have all other build toolchain files. Start by finding the directory of your choice, and point your terminal to it. I love the command line, so I do: mkdir getting-started-with-hapi-js-part-1 && cd $_ mkdir src touch .babelrc .gitignore .jshintrc src/server.js Notice the $_. This means, use the last argument of the last command. So, this will turn to cd getting-started-with-hapi-js-part-1 An interesting shorthand. Let's examine the dotfiles I have created: .gitignore-- tell Git what all to ignore; .babelrc-- tell the BabelJS transpiler which presets and/or plugins to use; .jshintrc-- tell our linter (JSHint) what all we expect from it. With that done, execute npm init in the root directory. Fill in all the details; it should look something like the following: { "name": "getting-started-with-hapi-js-part-1", "version": "1.0.0", "description": "Getting started with Hapi.js -- Part 1", "main": "index.js", "scripts": { "test": "echo \"Error: no test specified\" && exit 1" }, "repository": { "type": "git", "url": "git+" }, "author": "Shreyansh Pandey", "license": "MIT", "bugs": { "url": "" }, "homepage": "" } Oh, before I forget, all of the code is available at the GitHub repository. Now, open your favourite text editor in the root directory. Your directory structure should look something like the following: Perfect. Now, let's install the dependencies. We'll go with the real basics which are required to spin up a simple Hello World along with some decoration to that. Right now, we'll just install babel-core, babel-preset-es2015, and hapi. For those that don't know, Babel is a transpiler that helps us convert ES6 JS code to ES5 code. Run npm install --save babel-core babel-preset-es2015 hapi in the root directory, and wait for the dependencies to finish installing. Till then, let's prepare our .babelrc, .gitignore, and our .jshintrc files. The configuration here is really simple, but you can always tweak it to your requirement. In the .babelrc file, we need to tell Babel we that are using the es-2015 preset. A preset is a set of transformations which something should go through so that it's converted to something else. Here, for example, the es-2015 preset includes all the transforms to convert the fancy ES6 functions to their respective ES5 equivalant. Add the following to the .babelrc file: { "presets": [ "es2015" ] } Yeah, really! That's it. In the .gitignore file, we want to exclude the node_modules folder, so adding node_modules to that file will do the job. Lastly, .jshintrc needs to know just one thing: we're using ES2015. For that, add the following snippet to the file: { "esnext": true } And that's it. We're done with our initial configuration. Now let's write some code. Bootstrapping for ES6 Lastly, we need to create a bootstrap.js file which will require the babel-core's registering module, and the main module from our code: in this case server.js. And, we'll also create a very simple shortcut in the package.json file so that we can just run npm start to fire up our Hapi.js project. Start by creating a bootstrap.js file in the root folder, and add the following two lines: require( 'babel-core/register' ); require( './src/server' ); The first line calls for the babel register module, which then loads the server module. This helps Babel in transpiling on the fly. Simple, eh? Getting Lazy with package.json Node has a concept of scripts; you can define them in the scripts section of the package.json file. Modify the existing scripts section to look something like this: ... "scripts": { "test": "echo \"Error: no test specified\" && exit 1", "start": "node bootstrap.js" }, ... Now, run npm start in the command line, and your output should resemble something like below: > getting-started-with-hapi-js-part-1@1.0.0 start /Users/labsvisual/Documents/Scotchio-Articles/getting-started-with-hapi-js-part-1 > node bootstrap.js Nothing happened? Well, that's because we don't have any code, don't worry. However, if there is some error, be sure to check and see if you have followed all the steps outlines here. Introduction to the Terms Before we get Hapi-specific, let's have a look at the terms the framework throws at us. Don't worry, there are only three main terms. server-- the root object which contains everything about the web application; connection-- an instance of a connection, usually a hostand a portwhere the requests will come to; route-- a URI within a connection telling the server which function to execute when; Create a Simple Hello World server Alright, now we come to the best part: creating the actual server. In this part, we'll only create a few example routes to see what all Hapi has to offer; we'll modify this in the next parts and soon, it'll start looking like our application. So, start by importing Hapi into the server.js file: import Hapi from 'hapi'; Perfect. Now, we'll create a new server instance, and attach a new connection to it. Add the following bit to create a new server instance: const server = new Hapi.Server(); server.connection( { port: 8080 }); Now, I have skipped the host field because that's a known bug. I can't find a link right now, but I will update the post once I find the official link to the bug. Cool! Now, run your server by typing npm start from the command line. And yet again, there is no output. That's because we haven't yet started the server, nor have we defined a route. Let's define a simple hello route: server.route({ method: 'GET', path: '/hello', handler: ( request, reply ) => { reply( 'Hello World!' ); } }); The block here is self-explanatory, apart from maybe the handler. The handler is the function which is executed when the specific path is hit. So, in this case, the anonymous function will be executed if the user visits the path /hello. The request parameter represents the entire request: it has the query strings, the URL parameters, and the payload (if it's a POST/PUT request; we'll see this later). The reply object helps in sending a reply back to the client. Here, we're just sending back a simple Hello World! reply. Nothing special. Lastly, let's write the code to start the server. server.start(err => { if (err) { // Fancy error handling here console.error( 'Error was handled!' ); console.error( err ); } console.log( `Server started at ${ server.info.uri }` ); }); The server.info property contains an object which contains the following information: - created - the time the server instance was created; - started - the time the server instance was started; - host - the hostname of the machine; - port - the port to which the server the server is listening ; - protocol - the protocol on which the server is operating; - id - a unique ID of the server instance; - uri - the complete URI of the current server instance; - address - the address the server is bound to Now, run npm start; the console will say something like Server started at If that's the case, then point your browser to localhost:8080/hello and hit enter. You'll see a page something like the following: If you see errors like the following: Error was handled! {[Error: listen EADDRINUSE 0.0.0.0:8080] code: 'EADDRINUSE', errno: 'EADDRINUSE', syscall: 'listen', address: '0.0.0.0', port: 8080 } It means that some application is using port 8080, try a different port and your application should work flawlessly. You can play around with it, but when you are done, hit Ctrl + C to exit out of the server. Conclusion I guess that got your feet wet, and you are excited to try out this exciting framework. In the upcoming tutorials, we'll have a look at all the goodies in the request object; try out different request verbs, and use Paw to test our URLs. If you get stuck, be sure to check the API documentation; they have some really good explanations there.
https://scotch.io/tutorials/getting-started-with-hapi-js
CC-MAIN-2017-26
refinedweb
1,840
65.52
IOSACAL is the radiocarbon calibration software from the IOSA project. It's written in Python and it's open source. This demo is based on the current version (0.3). The documentation is at. An interactive session with IOSACal in Jupyter Notebook is the best way to get familiar with the software and create beautiful reports that are also self-explaining. Reproducible science! This is the standard import needed to start working with IOSACal and Jupyter Notebook: from iosacal import R, combine, iplot %matplotlib inline If you are going to define labels in languages different from English, please do this: from __future__ import unicode_literals Now define three radiocarbon determinations and combine them: rs = [R(3320, 65, 'LTL-32131'), R(3320,65,'LTL-123414'), R(3325,55,'LRS-8384')] cr = combine(rs) print(cr) RadiocarbonSample( Combined from LTL-32131, LTL-123414, LRS-8384 with test statistic 0.005 : 3322 ± 35 ) Now that we have a combined age, calibrate it using the IntCal13 curve: calcr = cr.calibrate('intcal13') The calibrated date can be plotted as normal: iplot(calcr) rs = [R(7729, 80, "P-1365"), R(7661, 99, "P-1375"), R(7579, 86, "P-827"), R(7572, 92, "P-772"), R(7538, 89, "P-778"), R(7505, 93, "P-769")] multiple = [r.calibrate('intcal13') for r in rs] It's also possible to change Matplotlib settings without need to edit the underlying source code: import matplotlib.pyplot as plt plt.style.use('ggplot') And create the resulting plot: iplot(multiple) Any plot can be saved directly to a file on disk, if needed: iplot(multiple, output="Catalhöyük East level VI A.pdf") This was a quick tour of IOSACal used interactively in Jupyter. Thank you!
http://nbviewer.jupyter.org/urls/gitlab.com/iosa/iosacal/snippets/18122/raw
CC-MAIN-2018-13
refinedweb
282
51.48
I have a client that wants the documentTitle field to be blank for certain PDFs. If I go to File > File Info (in CS5.5) and delete the Document Title and export a PDF, everything is fine. However, if a Document Title is already set and I try to remove it with JavaScript, it doesn't work: doc.metadataPreferences.documentTitle = ""; where doc is my document object. If I set it to any other string it works. I tried setting it to a space: doc.metadataPreferences.documentTitle = " "; but that doesn't work either. Any workarounds would be appreciated. Thank you very much. Rick Quatro Hey Rick, Try setting property directly to XMP: doc.metadataPreferences.setProperty("", "title", ""); Hope that helps. -- Marijan (tomaxxi) Hi Marijan, This works great! Thank you very much for the quick response. But I have a question: what is the significance of the namespace? How did you know what to use for this? Thanks. Rick Let's say I did a lot of research about a year ago about XMP and it's structure Take a look at "Raw Data" tab inside "File Info" to find namespaces. For more info about my research, take a look here: Hope that helps. -- Marijan (tomaxxi)
https://forums.adobe.com/thread/894991
CC-MAIN-2018-05
refinedweb
203
77.53
+++ This bug was initially created as a clone of Bug #1356263 +++ See bug 1356263 comment #3: Uses of nsILocaleService in C-C: From bug 1356263 comment 4: > You seem to only have one use of this in StringBundle.js. You should switch to Services.locale.getAppLocaleAsLangTag. > You seem to really only have one use of this in navigator.js - you should switch it to mozIOSPreferences systemLocale attribute. Aryx, would like to take this? Jorg, this is becoming a bit more urgent as with the 57 window opening, I'd like to start working on bug 1356263. It seems to me after a brief search, that Tb has no uses of the APIs left (the webspeech is also m-c, and I'll remove it in the patch in bug 1356263). Can you confirm that it's ok for me to start working on removing nsILocaleService, nsLocaleService, nsILocale and nsLocale? (In reply to :aceman from comment #1) > From bug 1356263 comment 4: > > > You seem to only have one use of this in StringBundle.js. You should switch > to Services.locale.getAppLocaleAsLangTag. mailnews/base/util/StringBundle.js is unnecessary to use nsILocaleService. Services.strings.createBundle has only 1 parameter. (In reply to Zibi Braniecki [:gandalf][:zibi] from comment #2) > Can you confirm that it's ok for me to start working on removing > nsILocaleService, nsLocaleService, nsILocale and nsLocale? Sure, go for it, I'm here to fix things if they break in TB. Created attachment 8893707 [details] [diff] [review] 1357822-nsILocaleService.patch Bug 1356263 is on autoland, so we need to hurry. FRG, I'm not going to do the SM part here: > FRG, I'm not going to do the SM part here: Thanks for the heads up. Need to take care of some other things too. Keeping the needinfo to not forget this one. Bug 1356263 had landed and it's causing C++ bustage in nsMsgDBView.h: static nsDateFormatSelector m_dateFormatDefault; static nsDateFormatSelector m_dateFormatThisWeek; static nsDateFormatSelector m_dateFormatToday; I'll look into it. nsDateFormatSelector is still there, it just moved here in bug 1313625: Comment on attachment 8893707 [details] [diff] [review] 1357822-nsILocaleService.patch Review of attachment 8893707 [details] [diff] [review]: ----------------------------------------------------------------- Thanks. OK, all we need to do is add mozilla:: Patch coming. Created attachment 8893955 [details] [diff] [review] 1357822-nsILocaleService.patch (v2) Sorry for lumping to ports into the same bug. This compiles so far. Pushed by mozilla@jorgk.com: Port bug 1356263: remove nsILocaleService/use of getApplicationLocale(); Port bug 1313625: add namespace to date/time format. r=aceman Second and third bustage of the day, times are getting tough :-( Sorry to hear that Jorg! It may come as a consolation to you that this is probably the end of Locale related changes for quite a while! We have the new API ready and complete with all features and old APIs removed. :) Thank you so much for your help with getting it working for Tb and Sm! ... and FF, you forgot: Bug 1383463, bug 1351427, bug 1355465. One personal comment: Why doesn't anyone fix bug 1355977? That's ten lines at most and it's ugly. Jorg: I didn't! I just meant in this bug for the removal of the old APIs. You've helped a lot during the whole process. Thank you:) > Why doesn't anyone fix bug 1355977? That's ten lines at most and it's ugly. Lower priority than other things I guess.
https://bugzilla.mozilla.org/show_bug.cgi?id=1357822
CC-MAIN-2017-47
refinedweb
568
67.25
Over a month ago I did a presentation on LINQ and promised a few people I’d share the code from the session. Better late than never, eh? We warmed up by building our own filtering operator to use in a query. The operator takes an Expression<Predicate<T>>, which we need to compile before we invoking the predicate inside. public static class MyExtensions { public static IEnumerable<T> Where<T>( this IEnumerable<T> sequence, Expression<Predicate<T>> filter) { foreach (T item in sequence) { if (filter.Compile()(item)) { yield return item; } } } } The following query uses our custom Where operator: IEnumerable<Employee> employees = new List<Employee>() { new Employee() { ID= 1, Name="Scott" }, new Employee() { ID =2, Name="Paul" } }; Employee scott = employees.Where(e => e.Name == "Scott").First(); Of course, if we are just going to compile and invoke the expression there is little advantage to using an Expression<T>, but it generally turns into an “a-ha!” moment when you show someone the difference between an Expression<Predicate<T>> and a plain Predicate<T>. Try it yourself in a debugger. We also wrote a LINQ version of “Hello, World!” that reads text files from a temp directory (a.txt would contain “Hello,”, while b.txt would contain “World!”. A good demonstration of map-filter-reduce with C# 3.0. var message = Directory.GetFiles(@"c:\temp\") .Where(fname => fname.EndsWith(".txt")) .Select(fname => File.ReadAllText(fname)) .Aggregate( new StringBuilder(), (sb, s) => sb.Append(s).Append(" "), sb => sb.ToString() ); Console.WriteLine(message); Moving into NDepend territory, we also wrote a query to find the namespaces with the most types (for referenced assemblies only): var groups = Assembly.GetExecutingAssembly() .GetReferencedAssemblies() .Select(aname => Assembly.Load(aname)) .SelectMany(asm => asm.GetExportedTypes()) .GroupBy(t => t.Namespace) .OrderByDescending(g => g.Count()) .Take(10); foreach (var group in groups) { Console.WriteLine("{0} {1}", group.Key, group.Count()); foreach (var type in group) { Console.WriteLine("\t" + type.Name); } } And finally, some LINQ to XML code that creates an XML document out of all the executing processes on the machine: XNamespace ns = ""; XNamespace ext = ""; XDocument doc = new XDocument( new XElement(ns + "Processes", new XAttribute(XNamespace.Xmlns + "ext", ext), from p in Process.GetProcesses() select new XElement(ns + "Process", new XAttribute("Name", p.ProcessName), new XAttribute(ext + "PID", p.Id)))); Followed by a query for the processes ID of any mspaint instances: var query = (from e in doc.Descendants(ns + "Process") where (string)e.Attribute("Name") == "mspaint" select (string)e.Attribute(ext + "PID")); More on LINQ to come… Is there other consideration? foreach (T item in sequence) { if (filter.Compile()(item)) Actually be: Predicte pred = filter.Compile(); foreach (T item in sequence) { if (pred(item)) There's no really sense in recompiling it every time... Good point - I did show both techniques. The one advantage to casting is when dealing with optional attributes. Casting will yield a null string reference while .Value will throw an exception. I was doing some work with reflection today and started off by looping through a load of PropertyInfos. Then I remembered this blog post and trimmed it all down to one line. Great post Scott, thanks very much.
http://odetocode.com/blogs/scott/archive/2008/09/02/stupid-linq-tricks.aspx
CC-MAIN-2014-52
refinedweb
520
51.65
Red Hat Bugzilla – Bug 766959 Memory leak in agent; likely use of native code Last modified: 2013-09-01 15:18:46 EDT Description of problem: Memory leaks over time with RHQ agent loaded. Java heap shows very little memory consumed, most seems to be non-Java memory, i.e. native code leaking. See: From Top: PID USER PR NI VIRT RES SHR S %CPU %MEM 15 0 11.0g 10g 13m S 0.0 33.0 26:03.99 java That's 11g of memory usage. jhat and the like show quite a lot less in the JVM itself. Here is a histogram: num #instances #bytes class name 1: 39295 5184840 <constMethodKlass> 2: 39295 4725784 <methodKlass> 3: 4091 4414496 <constantPoolKlass> 4: 43604 3832328 [C 5: 64747 3511200 <symbolKlass> 6: 4712 3101592 [I 7: 4091 2994248 <instanceKlassKlass> 8: 3706 2709792 <constantPoolCacheKlass> 9: 23291 2499224 [Ljava.lang.Object; 10: 12682 2042320 [Ljava.util.HashMap$Entry; $ Here is the inventory for this particular host: host.com Aliases File Apache HTTP Servers Bundle Handler - Ant Bundle Handler - File Template Cobblers CPUs Cron File Systems GRUB Hosts File Network Adapters Postfix Servers RHQ Agent Samba Servers SnmpTrapds SSHDs Sudoers Version-Release number of selected component (if applicable): Agent version 4.1 (updated from 4.0.) Also present in 4.0. Linux vg61l01ad-opsdev002.apple.com 2.6.18-238.19.1.0.1.el5 #1 SMP Fri Jul 15 04:42:13 EDT 2011 x86_64 x86_64 x86_64 GNU/Linux Red Hat Enterprise Linux Server release 5.6 (Tikanga) How reproducible: Every time, every system we have. Steps to Reproduce: 1. Install agent 2. Import all resources 3. Wait a few days. Actual results: Memory usage increases slowly over time (maybe 1GB per few days?) Expected results: No leaks ;-) Additional info: Hardware info: $ free -m total used free shared buffers cached Mem: 32183 26323 5860 0 642 12349 -/+ buffers/cache: 13331 18852 Swap: 18047 14 18033 CPU: 8 of these vendor_id : GenuineIntel cpu family : 6 model : 26 model name : Intel(R) Xeon(R) CPU E5506 @ 2.13GHz stepping : 5 cpu MHz : 2133.469 cache size : 4096 KB root@vg61l01ad-opsdev002 # lspci -tv -[0000:00]-+-00.0 Intel Corporation 5520 I/O Hub to ESI Port +-01.0-[03]----00.0 Hewlett-Packard Company Smart Array G6 controllers +-08.0-[02]--+-00.0 Broadcom Corporation NetXtreme II BCM5709 Gigabit Ethernet | \-00.1 Broadcom Corporation NetXtreme II BCM5709 Gigabit Ethernet +-1d.0 Intel Corporation 82801JI (ICH10 Family) USB UHCI Controller #1 +-1d.1 Intel Corporation 82801JI (ICH10 Family) USB UHCI Controller #2 +-1d.2 Intel Corporation 82801JI (ICH10 Family) USB UHCI Controller #3 +-1d.3 Intel Corporation 82801JI (ICH10 Family) USB UHCI Controller #6 +-1d.7 Intel Corporation 82801JI (ICH10 Family) USB2 EHCI Controller #1 +-1e.0-[01]--+-03.0 ATI Technologies Inc ES1000 | +-04.0 Compaq Computer Corporation Integrated Lights Out Controller | +-04.2 Compaq Computer Corporation Integrated Lights Out Processor | +-04.4 Hewlett-Packard Company Proliant iLO2/iLO3 virtual USB controller | \-04.6 Hewlett-Packard Company Proliant iLO2 virtual UART +-1f.0 Intel Corporation 82801JIB (ICH10) LPC Interface Controller \-1f.2 Intel Corporation 82801JI (ICH10 Family) 4 port SATA IDE Controller #1 Elias, this indeed looks like it might be a problem with augeas as mentioned on the forum pages. Could you check if augeas library is installed system-wide and what version it is? On RHEL/Fedora, do something like: yum info augeas-libs Installed Packages Name : augeas-libs Arch : x86_64 Version : 0.7.4 Release : 1.el5 Size : 950 k Repo : installed Summary : Libraries for augeas URL : License : LGPLv2+ Description: The libraries for augeas. Available Packages Name : augeas-libs Arch : i386 Version : 0.9.0 Release : 1.el5 Size : 338 k Repo : epel-5 Summary : Libraries for augeas URL : License : LGPLv2+ Description: The libraries for augeas. Name : augeas-libs Arch : x86_64 Version : 0.9.0 Release : 1.el5 Size : 340 k Repo : epel-5 Summary : Libraries for augeas URL : License : LGPLv2+ Description: The libraries for augeas. Yes, looks so... So maybe I need to update? What's the version to use? Ok, that I hope explains it. While the RHQ agent bundles the augeas libraries (in version 0.9.0), it uses the system-wide augeas in preference if it is available. augeas 0.7.4 has a known memory leak (I think) so I'd recommend to a) upgrade the system-wide augeas to 0.9.0 or (if that is not possible) to start the agent with modified LD_LIBRARY_PATH that would point to the bundled augeas location before the standard paths: LD_LIBRARY_PATH=$RHQ_AGENT_HOME/lib/augeas/lib64:"$LD_LIBRARY_PATH" bin/rhq-agent.sh I'll keep an eye on things and verify that it isn't leaking memory. I am still seeing a leak, even though Augeas was updated to 0.90 system-wide. Contrary to what you claim, the wrapper seems to always boot with the shipped version of Augeas, as it prepends LD_LIBRARY_PATH no matter what... # ---------------------------------------------------------------------- # Prepare LD_LIBRARY_PATH to include libraries shipped with the agent # ---------------------------------------------------------------------- if [ "x$_LINUX" != "x" ]; then if [ "x$LD_LIBRARY_PATH" = "x" ]; then if [ "x$_X86_64" != "x" ]; then LD_LIBRARY_PATH="${RHQ_AGENT_HOME}/lib/augeas/lib64" else LD_LIBRARY_PATH="${RHQ_AGENT_HOME}/lib/augeas/lib" fi else if [ "x$_X86_64" != "x" ]; then LD_LIBRARY_PATH="${RHQ_AGENT_HOME}/lib/augeas/lib64:${LD_LIBRARY_PATH}" else LD_LIBRARY_PATH="${RHQ_AGENT_HOME}/lib/augeas/lib:${LD_LIBRARY_PATH}" fi fi export LD_LIBRARY_PATH debug_msg "LD_LIBRARY_PATH: $LD_LIBRARY_PATH" fi In any case, what I have system-wide (0.90) matches the agent's included copy. $ rpm --query --file /usr/lib/libaugeas.so.0.14.0 augeas-libs-0.9.0-1.el5 $ diff /usr/lib/libaugeas.so.0.14.0 /usr/local/rhq-agentlib/augeas/lib/libaugeas.so ; echo $? 0 I'm seeing a growth of about 20GB of memory over 14 days. I'm guessing there must be a leak someplace else. What can I look at? ok, this is bad.. Not sure what's leaking and where so I would like to ask you to do the following steps to get to the bottom of this: 1) checkout and build the augeas leak detector that I put together which is located in rhq-project-samples/agent/debug-tools/augeas-leak-detector 2) Follow the directions in the README.txt there to run the agent with the detector. 3) Grab the agent log for the time the agent was running with the detector + the augeas-leak-detection-results.txt which should be generated in the RHQ_AGENT_HOME after you stop the instrumented agent and attach both files to this BZ. Created attachment 551692 [details] result of leak detection I ran the agent for about 4 hours. I still see the memory usage increase, but nothing in the report seems suspicious. Could it be something in another native library? Well, there are a couple of leaked references, but I'd agree with you that those probably don't contribute to the continuous increase of the memory usage, since these references are created on resource component startup and are stored in instance fields of the components - the components live for the lifetime of agent so they shouldn't be contributing to the increase of the leak unless there is some more "hidden" leak inside the augeas library itself (which has not been reported as of yet). The only other native library we use is sigar but that has been stable for a long time so I somehow doubt the leak is going to be there - but of course I can't rule that out - you can turn off the usage of sigar when you disable the native system in the agent. On the agent prompt: setconfig rhq.agent.disable-native-system=true or if you have your agent inventoried, you can check the "Disable Native System" property in the Connection Settings of the agent resource. Unfortunately, I was still not able to reproduce this locally so I will have to ask you for some more testing: 1) Does disabling the agent's native system help? 2) How does the leak change when you disable the augeas-based plugins?: Aliases, Apache HTTP Server, Cobbler, Cron, Hosts, Postfix, Samba, Sudo Access 4) If the leak disappears when you disable the above, you should enable them one by one to see which ones of them leak. FYI, the cause for leaks detected by the augeas leak detector is most probably bug 773031. At the same time I think we're dealing with something more than just that here. 1) Native system disabled: Memory still leaked. 2) I disabled those but it still leaked. Once I ALSO disabled "OpenSSH,GRUB,Iptables" the memory use seems to be stable but I will check overnight. (I suspected there were more than what you listed, so I grepped around for Augeus in the source tree.) So, I suspect one of those three plugins, though there could be more than one that leaks. What seems likeliest? I'll report tomorrow. Seems that GRUB is suspect, and perhaps others, but at least enabling GRUB has created a leak. (It is hard to observe.) Few questions: 1) How often is loadResourceConfiguration() called? I don't know the call flow, but it appears "augeas" is never closed: public class GrubComponent implements ResourceComponent, ConfigurationFacet { public Configuration loadResourceConfiguration() throws Exception { Configuration pluginConfiguration = resourceContext.getPluginConfiguration(); return loadResourceConfiguration(pluginConfiguration); } public Configuration loadResourceConfiguration(Configuration pluginConfiguration) throws Exception { // Gather data necessary to create the Augeas hook ... Augeas augeas = new Augeas(rootPath, lensesPath, Augeas.NONE); The same issue (no "close") appears in sshd/src/main/java/org/rhq/plugins/sshd/OpenSSHDComponent.java also rhq/modules/plugins (plugingen) $ git grep -E "new +Augeas\\(" apache/src/main/java/org/rhq/plugins/apache/ApacheServerComponent.java: ag = new Augeas(); apache/src/test/java/org/rhq/plugins/apache/ApacheAugeasTest.java: Augeas ag = new Augeas(); augeas/src/main/java/org/rhq/augeas/AugeasProxy.java: augeas = new Augeas(config.getRootPath(), config.getLoadPath(), config.getMode()); augeas/src/main/java/org/rhq/plugins/augeas/AugeasConfigurationComponent.java: augeas = new Augeas(this.augeasRootPath, augeasLoadPath, Augeas.NO_MODL_AUTOLOAD); augeas/src/main/java/org/rhq/plugins/augeas/helper/AugeasRawConfigHelper.java: Augeas aug = new Augeas(rootPath, loadPath, Augeas.NO_MODL_AUTOLOAD); grub/src/main/java/org/rhq/plugins/grub/GrubComponent.java: Augeas augeas = new Augeas(rootPath, lensesPath, Augeas.NONE); sshd/src/main/java/org/rhq/plugins/sshd/OpenSSHDComponent.java: Augeas augeas = new Augeas(rootPath, lensesPath, Augeas.NONE); I have a proposed patch but will test and need approval before submission. My plugin fixes seem to have worked. Memory usage does grow for about 24 hours and remains steady at about 300MB with perhaps slow growth over time, but much better than before. So the fixes required are for 'grub' and 'sshd' plugins only. Will there be a JON 3.0 patch for this? If so, is there an ETA? If the issue affects the grub and sshd plug-ins, there will be no patch for JON 3.0 as these plug-ins are not included with the product. Created attachment 561689 [details] Patch based on commit 1174064a0372d31199d75939b64d36eaa2232d02 Approved by employer Thanks, Elias! I only changed one minor thing - in SSHD plugin I changed the getConfig() method to throw an Exception, just to minimize the diff. master:;a=commitdiff;h=ff54dedcfdefb994c8390d6f68393134b3842e8e Author: Elias Ross <elias_ross@apple.com> Date: Thu Jan 12 21:51:51 2012 -0800 [BZ 766959] fix possible memory leak in plugins Bulk closing of BZs that have no target version set, but which are ON_QA for more than a year and thus are in production for a long time.
https://bugzilla.redhat.com/show_bug.cgi?id=766959
CC-MAIN-2017-13
refinedweb
1,903
58.28
XMonad.Doc.Extending Contents - The xmonad-contrib library - Extending xmonad Description: Synopsis The xmonad-contrib. - XMonad.Actions.Commands: Allows.Actions sendMessageth.Actions. Configurations Hooks In the XMonad.Hooks namespace you can find modules exporting hooks. Hooks are actions that xmonad performs when certain events occur. The two most important hooks are: for more information on customizing manageHook. logHook: this hook is called when the stack of windows managed by xmonad has been changed, by calling the windowsfunction. For instance XMonad.Hooks.DynamicLog will produce a string (whose format can be configured) to be printed to the standard output. This can be used to display some information about the xmonad state in a status bar. See XMonad.Doc.Extending for more information.. - XMonad.Hooks.DynamicLog: for use with logHook; send information about xmonad's state to standard output, suitable for putting in a status bar of some sort. See XMonad.Doc.Extending. - XMonad.Hookstype, or XMonad.Layout.LayoutCombinators. Layouts can be also modified with layout modifiers. A general interface for writing layout modifiers is implemented in XMonad.Layout.LayoutModifier. For more information on using those modules for customizing your layoutHook see XMonad.Doc.Extending. - XMonad.Layout.Accordion:H2 = H2Hlayout,:package to be installed..AppLauncher: A module for launch applicationes that receive parameters in the command line. The launcher call a prompt to get the parameters. - XMonad.Prompt.AppendFile:! - XMonad.Prompt.DirExec: A directory file executables prompt for XMonad. This might be useful if you don't want to have scripts in your PATH environment variable (same executable names, different behavior) - otherwise you might want to use XMonad.Prompt.Shell instead - but you want to have easy access to these executables through the xmonad's prompt. -does) - Usually a prompt is called by some key binding. See XMonad.Doc.Extending, which includes examples of adding some prompts. Utilities.Cursor: configure the default cursor/pointer glyph. - XMonad.Util.CustomKeys: configure key bindings (see XMonad.Doc.Extending). - ppExtrasfieldflag outside of core. - XMonad.Util.Run: This modules provides several commands to run an external process. It is composed of functions formerly defined in XMonad.Util.Dmenu (by Spencer Janssen), XMonad.Util.Dzen (by glasser@mit.edu) and XMonad.Util.RunInXTerm (by Andrea Rossato). -and putSelectionare adaptations of Hxsel.hs and Hxput.hs from the XMonad-utils - XMonad.Util.XUtils: A module for painting on the screen Extending xmonad Since the xmonad.hs file is just another Haskell module, you may import and use any Haskell code or libraries you wish, such as extensions from the xmonad-contrib library, or other code you write yourself. Editing key bindings Editing key bindings means changing the keys field of the XConfig record used by xmonad. For example, you could write: import XMonad main = xmonad $ defaultConfig { keys = myKeys } and provide an appropriate definition of myKeys, such as: myKeysad For a list of the names of particular keys (such as xK_F12, and so on), see Usually, rather than completely redefining the key bindings, as we did above, we want to simply add some new bindings and/or remove existing ones. Adding key bindings Adding key bindings can be done in different ways. See the end of this section for the easiest ways. The type signature of keys is: keys :: XConfig Layout -> M.Map (ButtonMask,KeySym) (X ()) In order to add new key bindings, you need to first create an appropriate Map from a list of key bindings using fromList. This Map of new key bindings then needs to be joined to a Map of existing bindings using union. Since we are going to need some of the functions of the Data.Map module, before starting we must first import this modules: import qualified Data.Map as M For instance, if you have defined some additional key bindings like these: myKeys keys field of the configuration: main = xmonad $ defaultConfig { keys = newKeys } Alternatively, the <+> operator can be used which in this usage does exactly the same as the explicit usage, Removing key bindings requires modifying the Map which stores the key bindings. This can be done with difference or with delete. For example, suppose you want to get rid of mod-q and mod-shift-q (you just want to leave xmonad running forever). To do this you need to define newKeys as a difference between the default map and the map of the key bindings you want to remove. Like so: newKeys x = keys defaultConfig x `M.difference` keysToRemove x keysToRemove :: XConfig Layout -> M.Map (KeyMask, KeySym) (X ()) keysToRemove x = M.fromList [ ((modm , xK_q ), return ()) , ((modm .|. delete to remove them. In that case we would write something like: newKeys x = foldr M.delete (keys defaultConfig x) (keysToRemove x) keysToRemove :: XConfig Layout -> [(KeyMask, KeySym)] keysToRemove x = [ (modm , xK_q ) , (modm .|. shiftMask, xK_q ) ] Another even simpler possibility is the use of some of the utilities provided by the xmonad-contrib library. Look, for instance, at removeKeys, k), windows $ f i) | (i, k) <- zip (workspaces x) [xK_1 .. xK_9] , (f, m) <- [(W.greedyView, 0), (W.shift, shiftMask .|. controlMask)] ] You can achieve the same result using the XMonad.Util.CustomKeys module; take a look at the customKeys function in particular. NOTE: modm is defined as the modMask you defined (or left as the default) in your config. additionalMouseBindings and removeMouseBindings functions from the XMonad.Util.EZConfig module. Editing the layout hook When you start an application that opens a new window, when you change the focused window, or move it to another workspace, or change that workspace's layout, xmonad will use the: |||. Suppose we want a list with the Full, tabbedTheme ||| Accordion Now, all we need to do is change the layoutHook field of the noBorders layout modifier, from the XMonad.Layout.NoBorders module (which must be imported): mylayoutHook = noBorders (Full ||| tabbed shrinkText defaultTheme ||| Accordion) If we want only the tabbed layout without borders, then we may write: mylayoutHook = Full ||| noBorders (tabbed shrinkText defaultTheme) |||Theme) ||| Accordion main = xmonad $ defaultConfig { layoutHook = mylayoutHook } That's it! Editing the manage hook The manageHook is a very powerful tool for customizing the behavior of xmonad with regard to new windows. Whenever a new window is created, xmonad calls the manageHook, which can thus be used to perform certain actions on the new window, such as placing it in a specific workspace, ignoring it, or placing it in the float layer. The default manageHook causes xmonad to float MPlayer and Gimp, and to ignore gnome-panel, desktop_window, kicker, and kdesktop. The XMonad.ManageHook module provides some simple combinators that can be used to alter the manageHook by replacing or adding to the default actions. Let's start by analyzing the default manageHook, defined in XMonad.Config: manageHook :: ManageHook manageHook = composeAll [ className =? "MPlayer" --> doFloat , className =? "Gimp" --> doFloat , resource =? "desktop_window" --> doIgnore , resource =? "kdesktop" --> doIgnore ] composeAll can be used to compose a list of different ManageHooks. In this example we have a list of ManageHooks formed by the following commands: the Mplayer's and the Gimp's windows, whose className are, respectively "Mplayer" and "Gimp", are to be placed in the float layer with the doFloat function; the windows whose resource names are respectively "desktop_window" and kdesktop" are to be ignored with the doIgnore function. This is another example of composeAll to compose a list of different ManageHooks. The first one will put RealPlayer on the float layer, the second one will put the xpdf windows in the workspace named "doc", with doF and shift functions, and the third one will put all firefox windows on the workspace called web. Then we use the <+> combinator to compose myManageHook with the default manageHook to form newManageHook. Each ManageHook has the form: property =? match --> action Where property can be: title: the window's title resource: the resource name className: the resource class name.: doFloat: to place the window in the float layer; doIgnore: to ignore the window; doF: to execute a function with the window as argument. For example, suppose we want to add a manageHook to float RealPlayer, which usually has a resource name of "realplay.bin". First we need to import XMonad.ManageHook: import XMonad.ManageHook Then we create our own manageHook: myManageHook = resource =? "realplay.bin" --> doFloat We can now use the <+> combinator to add our manageHook to the default one: newManageHook = myManageHook <+> manageHook defaultConfig (Of course, if we wanted to completely replace the default manageHook, this step would not be necessary.) Now, all we need to do is change the manageHook field of the XConfig record, like so: main = xmonad defaultConfig { ..., manageHook = newManageHook, ... } And we are done. Obviously, we may wish to add more then one manageHook. In this case we can use a list of hooks, compose them all with. The log hook and external status bars When the stack of the windows managed by xmonad changes for any reason, xmonad will call logHook doesn't produce anything. To enable it you need first to import XMonad.Hooks.DynamicLog: import XMonad.Hooks.DynamicLog Then you just need to update the logHook field of the!
http://xmonad.org/xmonad-docs/xmonad-contrib/XMonad-Doc-Extending.html
CC-MAIN-2015-35
refinedweb
1,492
57.06
Initialize variables in class methods. Initialization of fields (data members) of the class. Ways to initialize data members of the class This topic demonstrates how to initialize the internal members of the class data in the Java programming language. Contents - 1. The concept of initializing variables in Java methods - 2. What are the ways of initializing data members of the class? - 3. Initialization of data fields of the class. What is the initialization by default of data fields of the class? - 4. What default values are assigned to the class fields for different types? - 5. What value initializes a reference variable of a class object? - 6. Explicit initialization. How is realized an explicit initialization by initial values of data members of class? - 7. How is realized an explicit initialization of data members of a class that are variable-references to a class - 8. Explicit initialization by calling methods. How is the value of a class data member initialized by a method call? - 9. What is the order of initialization when declaring variables? What is the value of the initialization order when declaring variables? Examples - 10. How is the initialization done using the constructor? - 11. How is it possible to initialize the members of the class data using the initialization section { }? Example - 12. What is done first: the initialization section or the constructor? - Related topics Search other websites: 1. The concept of initializing variables in Java methods Initializing a variable means an explicit (or implicit) setting of a variable value. In the Java programming language, the variables declared in the method must be initialized before they are used. If in the body of some class method, try use the declared but not initialized variable, the compiler will generate an error. For example. In the following code snippet, an attempt is made to use the variable t, which is declared but not initialized static void SomeMethod() { int t; int x; x = 6; x = x + t + 2; // error: the variable t not initialized } In this case, an error message will occurs: The local variable t may not have been initialized To correct the situation, you need to assign a value to the variable t before using it. 2. What are the ways of initializing data members of the class? In Java, you can initialize a variable if it is a member of the class. There are four ways to initialize members of the class data: - initialization by default (implicit initialization); - explicit initialization with initial values (constant values); - explicit initialization using class methods; - initialization using class constructors. 3. Initialization of data fields of the class. What is the initialization by default of data fields of the class? If the variable is a data member of the class, this variable is initialized with the default value, when it is declared. That is, if there is a class in which internal variables are declared (class fields) class SomeClass { int d; double x; // ... } these variables (d, x) will be initialized with the default value. In the above code, the default variable will be assigned the following values d = 0.0 x = 0 It does not matter which access identifier is used for the variable (private, protected, public) in the class. 4. What default values are assigned to the class fields for different types? When you declare a variable in a class, this variable is set to the default values. The following are the default values that are assigned to variables of different types int => 0 boolean => false double => 0.0 float => 0.0 char => ' ' - zero-character long => 0 byte => 0 A character variable of type char is assigned a null character, which is displayed as a space character. 5. What value initializes a reference variable of a class object? If the class declares a reference variable to an object of a certain class, then by default, the value of this reference is null. The following code fragment demonstrates this. // some class public class InnerClass { // ... } // class in which an object of the InnerClass class is declared public class MyClass { // ... public static InnerClass obj; // obj = null; - by default // ... } In the above example, the variable obj is a reference to the InnerClass class. In other words, obj is an object of the InnerClass class. Because, the memory for obj is not already allocated, the default value of obj = null. 6. Explicit initialization. How is realized an explicit initialization by initial values of data members of class? Explicit initialization means setting the initial (necessary) value of the variable when it is declared in the class. For example. The MyClass class implements the initialization of variables of different types with initial values. public class CTrain01 { // explicit initialization of initial values of variables int d = 25; // explicit initialization of a variable d of type int with a value 25 float y = 3.885f; public double x = -129.48; boolean b = true; char c = 'Z'; long l = 0xF3309FA; // ... } 7. How is realized an explicit initialization of data members of a class that are variable-references to a class If a data member of the class has a reference variable to some class (a class object), then it is initialized in the standard way with the new operator: class InnerClass { // ... } class MyClass { // ... // explicit initialization of variable obj in class MyClass InnerClass obj = new InnerClass(); // ... } In the MyClass class, the obj reference variable must be initialized with the ‘new’ operator before it can be used. If you try to use an uninitialized variable, which is a reference to the class, an exception will occur. 8. Explicit initialization by calling methods. How is the value of a class data member initialized by a method call? Members of the class data can be initialized by calling some method. For example. Let the class CRadius be given. In the CRadius class, data members len, area, volume are initialized by calling the Length(), Area(), Volume() methods. These methods calculate, respectively, the circumference, the area of the circle, and the volume of the sphere of radius r, which is the input parameter of the methods. double Length(double r) { return 2*Pi*r; } double Area(double r) { return Pi*r*r; } double Volume(double r) { return 4.0/3.0*Pi*r*r*r; } public static void main(String[] args) { // demonstration of initialization using CRadius class methods CRadius r1 = new CRadius(); // there is an explicit initialization of the data members of the object r1 double l, a, v; l = r1.len; // l = 6.283 a = r1.area; // a = 3.1415 v = r1.volume; // v = 4.1886666666 } } 9. What is the order of initialization when declaring variables? What is the value of the initialization order when declaring variables? Examples In a class, variables are initialized first. Initialization of variables occurs even before the class constructor is called. The order of initialization of variables is determined by the order of their declaration in the class (see Example 1). After the variables are initialized, the constructor is called. In this case, declaration and initialization of variables can be implemented anywhere in the class (see example 2). As can be seen from the program code in section 8, the variables are declared in a strictly defined sequence, in which the value of the initializing variables and methods (to the right of the assignment operation) was determined at the time of initialization. Example 1. Let the class CInitOrderClass be specified, in which the value of the next data member is initialized by the value of the previous member of the data or method. // the class demonstrates the correct initialization order public class CInitOrderClass { int t1 = 5; int t2 = SomeMethod(); // t2 = 100; int t3 = t2; // t3 = 100 int t4 = t1 + t3; // t4 = 5 + 100 = 105 int t5 = SomeMethod() + t4; // t5 = 205 // method that is used when initializing int SomeMethod() { return 100; } public static void main(String[] args) { // use of a CInitOrderClass object CInitOrderClass obj = new CInitOrderClass(); int d; d = obj.t1; // d = 5 d = obj.t2; // d = 100 d = obj.t3; // d = 100 d = obj.t4; // d = 105 d = obj.t5; // d = 205 } } If you change the order of declaration and initialization in the class, an error may occur. For example, if the declaration of variable t4 is placed at the very top of the declarations of members of the class data: public class CInitOrderClass { int t4 = t1 + t3; // t4 = ??? - here an error, variables t1, t3 have not yet been declared int t1 = 5; int t2 = SomeMethod(); // t2 = 100; int t3 = t2; // t3 = 100 int t5 = SomeMethod() + t4; // t5 = 205 // ... } then there will be a compilation error Cannot reference a field before it is defined This is logical, since the variable declaration is viewed from top to bottom (from the beginning to the end). At the time the variable t4 is declared, the variables t1 and t3 that take part in the initialization are not yet declared. This is the cause of the error. This does not apply to the method of the SomeMethod() class, which can be used when initializing anywhere in the class. Example 2. This example demonstrates a rule in which any internal class variable (class data member) is initialized first, even before calling the constructor. Let the class COrderInit be given, in which the three variables a, b, c are initialized using the InitMethod() method and using the COrderInit() constructor. // the class demonstrates the initialization order public class COrderInit { int a = InitMethod("a = "); // Initializing the variable a using the method // initializing variables with a constructor COrderInit() { a = b = c = 0; System.out.println("Constructor COrderInit()."); } int c = InitMethod("c = "); // initializing variable c // method of initializing variables int InitMethod(String s) { System.out.println(s + "InitMethod()."); return 100; } int b = InitMethod("b = "); // initialization of varible b public static void main(String[] args) { COrderInit obj = new COrderInit(); } } As you can see from the above code, the class contains the main() function, in which an object of the COrderInit class is created. The method of the InitMethod() class gets the string s as the input parameter. This line displays an initialization string with the name of the corresponding variable. As a result of executing this code, the following result will be output: a = InitMethod(). c = InitMethod(). b = InitMethod(). Constructor COrderInit(). The result shows that the initialization of the variables a, c, b occurs first. The order of initialization of variables is determined by the order of their declaration in the class. After that, the constructor is called. 10. How is the initialization done using the constructor? The initialization of data members of a class using the constructor is described in more detail in the topic: - Constructors. Parameterized constructors. The keyword ‘this’. Garbage collection. The finalize() method. Examples 11. How is it possible to initialize the members of the class data using the initialization section { }? Example Members of class can be initialized in one section, as shown in the example. public class CDataInit { int a, b, c, d; // Initialization using the initialization section {} { a = 1; b = 2; c = 3; d = 4; } public static void main(String[] args) { CDataInit obj = new CDataInit(); int t; t = obj.a; // t = 1 t = obj.b; // t = 2 t = obj.c; // t = 3 t = obj.d; // t = 4 } } 12. What is done first: the initialization section or the constructor? The initialization section is executed first and then the class constructor. Related topics - Initialization of static data members. Static block. Arrays initialization - Constructors. Parameterized constructors. The keyword ‘this’. Garbage collection. The finalize()method. Examples - Default constructor. Calling class constructors from others constructors
https://www.bestprog.net/en/2018/09/14/initialize-variables-in-class-methods-initialization-of-fields-data-members-of-the-class-ways-to-initialize-data-members-of-the-class/
CC-MAIN-2022-27
refinedweb
1,909
55.74
You can subscribe to this list here. Showing 1 results of 1 Hi Fern, Yes, this is a bug, but a well known one, unfortunately. We're not far from having it fixed for good. See [1]. The problem is that we statically partition virtual address space and your large arrays are larger than the address space allocated to the LOS (large object space), although not larger than the total available memory. If you need a solution immediately, you can do one of two things: a) apply the most recent patch at [1] (this requires that you be working at or near the svn head), or b) as a clumsy hack, modify PLOS_FRAC in org.mmtk.plan.Plan to a (much larger value) [2]. This is the constant that determines how much of the available address space is made available to the PLOS (large object space for primitive (non-reference) types). I'm hoping that I'll have time to square this issue away toward the end of next week. So if you can wait that long, the bug should be fixed in svn (but of course I can't promise). Cheers, --Steve [1] [2] public static final float PLOS_FRAC = (float) 0.07; On 01/09/2007, at 9:13 AM, Fern Moon wrote: > I just ran a benchmark on rvm, but there are out of memory errors. > I am sure the error is not caused by stack or heap size settings. > > The Test.java program is simple: > > import java.io.*; > import java.util.*; > > public class Test > { > > public static void main(String argv[]) > { > > double[] data = new double[10000 * 1000]; > double[] data1 = new double[10000 * 1000]; > > }} > > > > I run it by rvm (heap size 500M -- 800M ) > rvm -Xms1040M -Xmx1040M -X:gc:variableSizeHeap=true -X:verbose - > X:verboseBoot=1 -X:gc:verbose=3 Test 1 > It will produce errors. > ..... > reserved = 91 MB (23416 pgs) total = 1040 > MB (266240 pgs) > Collection time: 19.83 ms > Live ratio 0.08 > GCLoad 0.98 > Heap adjustment factor is 1.00 > [POLL] plos: Triggering collection > Exception in thread "main": java.lang.OutOfMemoryError > at Test.main(Test.java:20) > JikesRVM: exit 113 > > But if I run it by sun java > java -Xms1040M -Xmx1040M Test 1 > It will produce right result. > > > Thanks for your help > > Fern > ---------------------------------------------------------------------- > --- >@... >
http://sourceforge.net/p/jikesrvm/mailman/jikesrvm-researchers/?viewmonth=200709&viewday=1
CC-MAIN-2015-06
refinedweb
377
72.66
Context: I have a rather large project which is a social media back end. We use MondoDB (w/ mongoose) and Express in JS. The question that I have is: Is it necessary to continue wrapping every route in try/catch blocks to ensure responses? Currently almost all (some need to return more specifc errors) of our routes look like this: router.get('/path/to/route', async (req, res, next) => { try { // function of route } catch (err) { res.status(500).send({ status: false }) } } I suspect there may be something anti-pattern about the continual use of try/ catch blocks or the use of async functions for every route. My idea was to simple make a standard error handler that sends the 500 response, but then I believe that try/ catch would still be necessary to use next(err) Overall: try/ catchblocks be continually used? If anyone has the time to response, thank you so much. You shouldn't try/catch on every route. You can use middleware to catch handle all errors and respond with the appropriate status code. A short example is: app.use(function (err, req, res, next) { console.error(err.stack) res.status(500).send({ status: false }) }) You can read more about error handling in Express here I suggest creating a errorHandler.js file in your project with these contents. class ErrorHandler extends Error { constructor(statusCode, message) { super(); this.statusCode = statusCode; this.message = message; } } const handleError = (err, res) => { const { statusCode, message } = err; res.status(statusCode).json({ status: "error", statusCode, message }); }; module.exports = { ErrorHandler, handleError } Then in your api.index.js you register a middleware, after importing the exported members of your errorHandler.js file, like so. import {handleError} from errorHandler.js; app.use((err, req, res, next) => { handleError(err, res); }); then each time you want to handle a potential error, import the ErrorHandler class from the ErrorHandler.js file, and then simply use this signature import {ErrorHandler} from errorHandler.js; if(somethingWentAwry){ throw new ErrorHandler(400, "something went really awry") } Since the handleError function, and its use as a middle-ware in api.index.js doesn't handle next, the chain ends when you throw an error. The solution is inspired by Chinedu Orie's post here: I'm trying to develop a service that listens for Twitch subscribe events (through its API) and gifts chests to the user that subscribedTwitch allows me to get an auth token for the user and get a new one everytime it expires, so that part is covered
https://cmsdk.com/node-js/how-to-handle-errors-in-async-express.html
CC-MAIN-2021-04
refinedweb
415
57.57
Components and supplies Apps and online services About this project DeBae, our friendly office superhero, usually takes care of the trash at Bolt IoT. It's his responsibility to throw out the trash into the local cans for garbage collection once our main bin fills up. Except... he usually doesn't check our trash can often enough. What he does check quite often is his Whatsapp, Facebook timeline and SMS's. Hence we, the developers at Bolt IoT, decided to come up with the Trash Talker system. It's essentially a setup which uses the popular Ultrasonic Sensor (HC-SR04), the Bolt Wi-Fi module, and an Arduino Uno to measure how much of the trash can has filled up. Once above a threshold, it sends an SMS to DeBae to check the trashcan and hence help save the olfactory systems of the entire company.Hardware Setup The HC-SR04 Ultrasonic Sensor is at the center of the Trash Talker. You can check out how it works with the Arduino in this nicely explained blog post by Dejan Nedelkovski. The Fritzing breadboard diagram is as follows:Software Setup Usually, interfacing the Ultrasonic sensor is kind of non-trivial, in that one needs to use it in the manner of the functioning as explained in the blog by Dejan linked in above. However, Erick Simoes' Ultrasonic library (available from the Arduino Library Manager) greatly simplifies things by abstracting away the core implementation. Check it out on GitHub to see the basic Hardware connections as well as an explanation of the basic structure and usage of the library. The Arduino Code linked in below measures the distance using the Ultrasonic sensor and thereafter sends it to the Bolt Wi-Fi module over serial communication. A Python Script (running on a server or your PC, for instance) queries the Bolt Cloud for this distance value using the Bolt Python Library, which in turn is based on the Bolt open APIs for Serial Read. The Python script then checks if the distance is less than a preset threshold (basically if the last banana peel is too high in the trash pile). In case the bin is full, an SMS alert is sent out using the Twillio SMS service. That's it! Have a go at this project and in case you like our friendly little Trash Talker, check us out on Indiegogo, back us, and spread the word! We have exclusive discounts for developers and the first batch of Bolts ships out in February 2018. Code Trash Check DistanceArduino /* * Ultrasonic Simple * Prints the distance read by an ultrasonic sensor in * centimeters. They are supported to four pins ultrasound * sensors (liek HC-SC04) and three pins (like PING))) * and Seeed Studio sesores). * * The circuit: * * Module HR-SC04 (four pins) or PING))) (and other with * three pins), attached to digital pins as follows: * --------------------- --------------------- * | HC-SC04 | Arduino | | 3 pins | Arduino | * --------------------- --------------------- * | Vcc | 5V | | Vcc | 5V | * | Trig | 12 | OR | SIG | 13 | * | Echo | 13 | | Gnd | GND | * | Gnd | GND | --------------------- * --------------------- * Note: You need not obligatorily use the pins defined above * * By default, the distance returned by the distanceRead() * method is in centimeters, to get the distance in inches, * pass INC as a parameter. * Example: ultrasonic.distanceRead(INC) * * created 3 Apr 2014 * by Erick Simões (github: @ErickSimoes | twitter: @AloErickSimoes) * modified 23 Jan 2017 * by Erick Simões (github: @ErickSimoes | twitter: @AloErickSimoes) * modified 03 Mar 2017 * by Erick Simões (github: @ErickSimoes | twitter: @AloErickSimoes) * * This example code is released into the MIT License. */ #include <Ultrasonic.h> /* * Pass as a parameter the trigger and echo pin, respectively, * or only the signal pin (for sensors 3 pins), like: * Ultrasonic ultrasonic(13); */ Ultrasonic ultrasonic(12, 13); void setup() { Serial.begin(9600); } void loop() { Serial.println(ultrasonic.distanceRead()); delay(1000); } Trash AlertPython from boltiot import Bolt, Sms #Import Sms and Bolt class from boltiot library import json, time garbage_full_limit = 5 # the distance between device and garbage in dustbin in cm API_KEY = "your Bolt Cloud api key" DEVICE_ID = "your device id" # Credentials required to send SMS SID = 'your twilio sid' AUTH_TOKEN = 'your twilio auth token' FROM_NUMBER = 'This is the no. generated by Twilio. You can find this on your Twilio Dashboard' TO_NUMBER = 'This is your number. Make sure you are adding country code in the beginning' mybolt = Bolt(API_KEY, DEVICE_ID) #Create object to fetch data sms = Sms(SID, AUTH_TOKEN, TO_NUMBER, FROM_NUMBER) #Create object to send SMS response = mybolt.serialRead('10') print response while True: response = mybolt.serialRead('10') #Fetching the value from Arduino data = json.loads(response) garbage_value = data['value'].rstrip() print "Garbage level is", garbage_value if int(garbage_value) < garbage_full_limit: response = sms.send_sms('Hello DeBae, I am full- Trash Talker') time.sleep(200) Schematics Team Bolt IoT Developers U.P. Region Mayank Joneja - 2 projects - 31 followers Rahul Singh - 2 projects - 63 followers Published onDecember 28, 2017 Members who respect this project you might like
https://create.arduino.cc/projecthub/bolt-iot-developers-u-p-region/trash-talker-using-bolt-iot-f2af5e
CC-MAIN-2021-10
refinedweb
804
57.81
Just because Stimulus.js is designed to work with HTML over the wire doesn’t mean it can’t use JSON APIs when the need arises. In fact, it can perform just like Vue.js in pulling JSON from an API and placing the results on your page. Here is a tutorial that loads commit messages from Github, and renders them in a list. There is no templating library used, since ES6 strings in Javascript are very succinct and will cleanly concatenate strings. The HTML The wrapper div houses the controller, and has the commit message url. There is a set of radio buttons to load commits for different branches, just like in the Vue.js example. The current branch text is changed when a radio button is selected, and the commits are loaded and inserted into the commits.commits target. <div data- <h1>Latest Rails Commits</h1> <input data-master</label> <input data- <label for="5-2-stable">5-2-stable</label> <input data- <label for="5-2-stable">5-1-stable</label> <p>rails/rails@<span data-</span></p> <ul data- </ul> </div> The Controller The controller will be responsible for loading the commits for a branch, generating the HTML, and then inserting them into the commits <ul>. The controller also loads the commits for the master branch when it is connected to the dom. Selecting a branch calls the selectBranch() method, which then loads the commits. The loadBranch() function fetches the commits from Github’s API and then converts the data to a JSON object. The HTML is generated from the commitTemplate() function, which is just concatenates the string for a single commit object. There are two other helper functions, truncate() and formatDate(), which come from the Vue.js example. import { Controller } from "stimulus" export default class extends Controller { static targets = ["option", "branch", "commits"] connect() { this.optionTargets.forEach((el, i) => { if (el.checked) { this.loadBranch(el.value) } }); } selectBranch(event) { this.loadBranch(event.srcElement.value); } loadBranch(branch) { this.branchTarget.innerHTML = branch; this.commitsTarget.innerHTML = `<li>Loading comits for ${branch}</li>` var${ commit.sha.slice(0, 7) }</a> - <span class="message">${ truncate(commit.commit.message) }</span><br> by <span class="author"><a :${ commit.commit.author.name }</a></span> at <span class="date">${ formatDate( commit.commit.author.date ) }</span> </li>`; } function truncate (v) { var newline = v.indexOf('\n') return newline > 0 ? v.slice(0, newline) : v } function formatDate(v) { return v.replace(/T|Z/g, ' ') } Templating With Stimulus Without the need for a third party templating library, you can wrap your string concatenation code inside a function, and then pass the data you want in the template as an object. This works really well with JSON, since everything is already an object, and is no more difficult than importing a library, parsing a template, and binding values from an object. With multiline strings, enclosed by a “ pair and the ${} concatenation, your html can still look crisp. And wrapping it into a function will keep your main logic clean. Stimulus loves JSON Your Stimulus controllers can add some JSON API functionality, especially when it’s from a service that doesn’t have HTML. No need to rewrite your Rails app into a single, full page web app. You can sprinkle on a little Stimulus, and use any data source. Want To Learn More? Try out some more of my Stimulus.js Tutorials. One Comment
https://johnbeatty.co/2019/01/30/loading-and-templating-json-responses-in-stimulus-js/
CC-MAIN-2019-35
refinedweb
563
57.87
A utility for crawling historical and Real-time Quotes data of China stocks Project description - easy to use as most of the data returned are pandas DataFrame objects - can be easily saved as csv, excel or json files - can be inserted into MySQL or Mongodb Target Users - financial market analyst of China - learners of financial data analysis with pandas/NumPy - people who are interested in China financial data Installation pip install tushare Upgrade pip install tushare –upgrade Quick Start import tushare as ts ts.get_hist_data('600848') return: open high close low volume p_change ma5 date 2012-01-11 6.880 7.380 7.060 6.880 14129.96 2.62 7.060 2012-01-12 7.050 7.100 6.980 6.900 7895.19 -1.13 7.020 2012-01-13 6.950 7.000 6.700 6.690 6611.87 -4.01 6.913 2012-01-16 6.680 6.750 6.510 6.480 2941.63 -2.84 6.813 2012-01-17 6.660 6.880 6.860 6.460 8642.57 5.38 6.822 2012-01-18 7.000 7.300 6.890 6.880 13075.40 0.44 6.788 2012-01-19 6.690 6.950 6.890 6.680 6117.32 0.00 6.770 2012-01-20 6.870 7.080 7.010 6.870 6813.09 1.74 6.832 Project details Release history Release notifications Download files Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
https://pypi.org/project/tushare/
CC-MAIN-2018-43
refinedweb
258
71.65
Ross Gardler wrote: > Cameron McCormack wrote: > >Gav: > > > >>Ok, will take another look, but initially I assumed you wanted to use > >>DTDs as you declared them in your code, this is why it is failing as > >>It can not find the specified DTD. > > > >Right, OK. I just declared them because, from looking at the sample > >sitemap.xmap file, I gathered that was the way you had to do it. > > The sourcetype resolver can only work if you define the type of > document. To do this you have to use DTD's. No that is not true. There are other ways. See which refers to One does not need a DTD to use the SourceTypeAction, for example can use a namespace instead. > You could work without DTD's but you would have to place your home grown > files in a specific directory so that you can match on location rather > than type. > > If you did this you would have to turn validation off (see > forrest.properties) > > see below for more... > > >OK, forget I mentioned DTDs. :-) > > > >There must be some way I can tell Cocoon/Forrest, via the sitemap.xmap > >file, that when a file called status.xml is requested, it should be > >passed transformed with a particular XSLT file into a document-v20 > >document, and from there, converted into either HTML or PDF, as would > >normally be done. Cocoon is quite complicated, though, and I haven't > >yet got my head around it. (Nor do I quite understand the relationship > >between Forrest and Cocoon...) > > (you don't mention which version of Forrest you are working with, the > below is 0.7, in 0.8-dev this will still work but you should realy use > the locationmap to resolve source locations). > > <map:match > <map:generate > <map:transform > <map:serialize > </map:match> > > Gavin points to some examples in forrest, but these all use the > sourceresolver, and requrie a DTD. Not necessarily, see above. > I really would recomend using a DTD it makes things much more flexible > and will prevent time hunting errors in your source files. But the > choice is yorus. I agree with that. But one does not need to use DTDs. Use a specific namespace on the source documents, as above, then use a RELAX NG grammar to do validation. That can be done as a separate task outside of Forrest. Alternatively Forrest provides Jing, so one could have an Ant task to do RNG validation. Alternatively Forrest provides validation pipelines with the Cocoon Validation block in Forrest-0.8-dev. See and search for "validation". -David
http://mail-archives.apache.org/mod_mbox/forrest-user/200605.mbox/%3C20060515012301.GC4935@igg.indexgeo.com.au%3E
CC-MAIN-2015-06
refinedweb
425
75.2
ALM-9 Failed to Restart Containerized Application Description This alarm is reported when a pod fails to start containerized applications. Pod: In Kubernetes, pods are the smallest unit of creation, scheduling, and deployment. A pod is a group of relatively tightly coupled containers. Pods are always co-located and run in a shared application context. Containers within a pod share a namespace, IP address, port space, and volume. Attribute Parameters Impact on the System Related functions may be unavailable. System Actions The pod keeps restarting. Possible Causes The container startup command configured for the pod is incorrect. As a result, the containers cannot run properly. Procedure - Obtain the name of the pod that fails to be started. - Use a browser to log in to the FusionStage OM zone console. - Log in to ManageOne Maintenance Portal. - Login address: for accessing the homepage of ManageOne Maintenance Portal:31943, for example,. - The default username is admin, and the default password is Huawei12#$. - On the O&M Maps page, click the FusionStage link under Quick Links to go to the FusionStage OM zone console. - Choose Application Operations > Application Operations from the main menu. - In the navigation pane on the left, choose Alarm Center > Alarm List and query the alarm by setting query criteria. - Click to expand the alarm information. Record the values of name and namespace in Location Info, that is, podname and namespace. - Use PuTTY to log in to the manage_lb1_ip node. The default username is paas, and the default password is QAZ2wsx@123!. - Run the following command and enter the password of the root user to switch to the root user: su - root Default password: QAZ2wsx@123! - Run the following command to obtain the IP address of the node on which the pod runs: kubectl get pod podname -n namespace -oyaml | grep -i hostip: In the preceding command, podname is the instance name obtained in 1, and namespace is the namespace obtained in 1. Log in to the node using SSH. - Search for the error information based on the pod name and correct the container startup configuration. - Run the following commands to view the kubelet log: cd /var/paas/sys/log/kubernetes/ vi kubelet.log Press the / key, enter the name of the pod, and then press Enter for search. If the following content in bold is displayed, the container startup command fails to be executed: I0113 14:19:29.497459 70092 docker_manager.go:2703] checking backoff for container "container1" in pod "nginx-run-1869532261-29px2" I0113 14:19:29.497620 70092 docker_manager.go:2717] Back-off 20s restarting failed container=container1 pod=nginx-run-1869532261-29px2_testns(b01b9e9c-f829-11e7-aa58-286ed488d1d4) E0113 14:19:29.497673 70092 pod_workers.go:226] Error syncing pod nginx-run-1869532261-29px2-b01b9e9c-f829-11e7-aa58-286ed488d1d4, skipping: failed to "StartContainer" for "container1" with CrashLoopBackOff: "Back-off 20s restarting failed container=container1 pod=nginx-run-1869532261-29px2_testns(b01b9e9c-f829-11e7-aa58-286ed488d1d4) - Run the following command to query the container ID: docker ps -a - Run the following command to check the specific error information: docker logs containerID containerID is the container ID obtained in 5.b.The following information in bold indicates that the startup script does not exist: # docker logs 128acfd300c8 container_linux.go:247: starting container process caused "exec: \"bash /tmp/test.sh\": stat bash /tmp/test.sh: no such file or directory" - Correct the container startup command based on error information, delete and deploy the application again, and then check whether the alarm is cleared. In the case of the above error, you need to specify the correct directory for the startup script or put the startup script in the directory. - Contact technical support for assistance. Alarm Clearing This alarm is automatically cleared after the fault is rectified. Related Information None
https://support.huawei.com/enterprise/en/doc/EDOC1100062365/5fb51853/alm-9-failed-to-restart-containerized-application
CC-MAIN-2019-51
refinedweb
627
57.98
[ ] Matteo Bertozzi commented on HBASE-11598: ----------------------------------------- {quote}I think just doing r+w is a good start – the question is my ind from a user pov is how would the admin commands be for specifying r-only and w-only throttles? Do the would we have to add yet more admin commands for "types"/"whats" to the throttle command?{quote} from the java api, nothing will change since there is a ThrottleType. on the ruby side you have tons of possible way of doing that.. new "read/write" flag and so on. {quote}From a user's point of view would it make sense to say throttle_table or throttle_namespace as opposed to throttle 'table' or throttle 'namespace'? (currently it would seem you would need throttle 'tableReads' and throttle 'tableWrites' as as new types etc.. ){quote} as above, you have tons of possible way of doing that. I didn't want to add 100 new commands just to set a flag. but I'm open to any suggestion. {quote}I didn't see quotaScope in the admin commands code so I'm wondering how that would fit in from a users's point of view. Where would it go wrt to the current ruby commands you are proposing to add?{quote} yeah, at the moment there is only QuotaScope.MACHINE because we don't have a good notification system to do the aggregation/notification. but again is a flag "throttle ... {QUOTA_SCOPE => CLUSTER}" {quote}1: Let's say you the rs can handled a total of 10MB/s of throughput (the available capacity). User 'jon' is restricted to 1mb/s. This is not a reservation of 1MB/s throughput for jon – jon gets to use 1mb/s and then gets an exception despite there being 9MB of capacity remaiing..{quote} At the moment this is what the patch is doing. {quote}2: Let's say you the rs can handled a total of 10MB/s of throughput (the available capacity). There are many users – u001-u100 each restricted to 1mb/s. This is not a reservation for 1MB/s throughput for each user – each user would be fighting for a chunk of the 10MB/s capacity.{quote} The first problem that we have today is that we don't know the "available capacity", we can guess it after a while with some stats available and that's why the ThrottleRequest in Master.proto has a "float share" field that can be used instead of the "uint limit". so in the future you may be able to specify 25% of the available quota/capacity/whatever... > Add simple rpc throttling > ------------------------- > > Key: HBASE-11598 > URL: > Project: HBase > Issue Type: New Feature > Reporter: Matteo Bertozzi > Assignee: Matteo Bertozzi > Priority: Minor > Fix For: 1.0.0, 2.0.0 > > > Add a simple version of rpc throttling. > (by simple I mean something that requires less changes as possible to the core) > The idea is to add a hbase:quota table to store the user/table quota information. > Add a couple of API on the client like throttleUser() and throttleTable() > and on the server side before executing the request we check the quota, if not an exception is thrown. > The quota will be per-machine. There will be a flag "QuotaScope" that will be used in the future to specify the quota at "cluster level" instead of per machine. (A limit of 100req/min means that each machine can execute 100req/min with a scope per-machine). > This will be the first cut, simple solution that requires verify few changes to the core. > Later on we can make the client aware of the ThrottlingException and deal with it in a smarter way. > Also we need to change a bit the RPC code to be able to yield the operation if the quota will be > available not to far in the future, and avoid going back to the client for "few seconds". > REVIEW BOARD: -- This message was sent by Atlassian JIRA (v6.2#6252)
http://mail-archives.apache.org/mod_mbox/hbase-issues/201407.mbox/%3CJIRA.12730184.1406549809165.89356.1406837561155@arcas%3E
CC-MAIN-2017-47
refinedweb
664
71.14
Memo Take and organize notes like text messages. Linear regression is applied to cases in which two variables are related. The main idea is when you are given a set of data points, your task is to find a line that best fit the data points. There are many ways to solve this, and the most effective way of finding the line of best fit is the least-squares method. Some examples can be applied to finding the relationship between the age and height of a child, high school GPA and college GPA of students, describing the relationship between shoe size and hand size. The simple linear regression is modeled as y = mx + b. Our input or predictor is denoted as x, y is our output or response, m is our slope and b is our y intercept One of the many ways of finding the line of best fit is by least-squares method. This formula can be modeled by the function below: def line_of_best_fit(x,y): xm = mean(x) ym = mean(y) a = 0 b = 0 for i in range(len(x)): a += (x[i] - xm) * (y[i] * ym) b += (x[i] - xm)**2 m = a / b y = ym - (m * xm) return (m,y) This function would return the slope and the y intercept respectively. Linear regression can help us logically interpret the relationship of your data, predict the output given some input, or find the probability of an output to occur. As an example, let's look at the following linear model: y = 0.46x - 3.63 This model describes the relationship between the weight of the brain and body of a mammal species in kilograms. In this formula, x will represent the weight of the body and y will represent the weight of the brain. From this model, we can interpret that on average, the weight of the brain will increase by 0.46% for every kilogram of the body. From this same model, we can also predict the weight of the mammals brain by the weight of the mammals body. From this model, we can also find the probability for a mammal to have a brain that weighs some value y if the mammals body weight is some value x The residual variance describes the variability in the model. In other words, it tells us how much of the observation is spread from the line of best fit. A higher residual variance, the data is much more spread while a smaller residual variance are closer to the line of best fit. To calculate the residual variance, we first have to calculate the error sum of squares. The model is represented in this function sse = 0 for i in range(len(data)): y = data[i][0] x = data[i][1] sse += (y -(m * x + b))**2 # To estimate the residual variance: r = sse / (n - 2) The coefficient of determination describes how much of the data influences the line of best fit. We can calculate this by first calculating the total sums of squares and the error sum of squares. sst = 0 mean_of_y = mean(Y) for y in Y sst +=(y - mean_of_y)**2 # To calculate the coefficient of determination r**2 = 1 - (sse / sst) A coefficient of determination that is close to 1 means that the points all lie close to the regression line. These are some of the few applications of linear regression. You can try to practice finding the line of best fit using some of the datasets from this website here
https://articlesbycyril.com/statistics/simple-linear-regression.html
CC-MAIN-2019-43
refinedweb
587
64.75
My Journey I constantly ask myself, how do I maintain a high quality codebase? Well, the obvious answer is simple — to maintain a good coding standard. What’s not so simple, however, is what should be part of this standard and how I enforce this standard. I didn’t have a good answer. I tried my best to come up with my own standard, and I tried to enforce this standard in code reviews. But it wasn’t enough. My “standard” was constantly changing and things kept on slipping past code reviews. This all changed when I learned about ESLint. ESLint ESLint is Javascript’s linter. It works by analyzing your code and warning you if any configured rules are violated. These rules can detect suspicious or concerning coding quality or formatting issues. It’s similar to Google Doc’s or Microsoft Word’s spelling and grammar checking — essentially an automatic proofreader for your code! This is exactly what I needed. I can create a coding standard from ESLint’s vast collection of rules and have ESLint enforce them. So it turns out, I was already using ESLint — just not in a way that was effective. Create React App ships with a native ESLint configuration but is extremely basic. I needed to update this configuration so that my automatic proofreader could make me a better developer. Setup To start, ESLint provides a handy setup tool. Run npx eslint --init, and you will be asked a series of questions that will help ESLint create your initial setup. How would you like to use ESLint? To check syntax only, To check syntax and find problems, or to check syntax, find problems, and enforce code style. I recommend selecting check syntax, find problems, and enforce code style to get the most out of ESLint. What type of modules does your project use? JavaScript modules (import/export), CommonJS (require/exports), or none of these. Which framework does your project use? React, Vue.js, or none of these. Does your project use TypeScript? Yes or no. Where does your code run? Browser, Node, or both. These would depend on your codebase. How would you like to define a style for your project? Use a popular style guide, or answer questions about your style, or inspect your JavaScript file(s). I recommend using a popular style guide. This will allow you to take advantage of a style guide that took experts thousands of hours to build. And you get it for free! Which style guide do you want to follow? Airbnb, Standard, or Google. I highly recommend using Airbnb. From what I’ve seen, it’s the most popular style guide and I consider it the de facto standard in the Javascript community. What format do you want your config file to be in? JavaScript, YAML or JSON. This is up to you but remember — we’re Javascript developers! Once the questionnaire is done, ESLint will install all the necessary dependencies and create your base configuration in .eslintrc.js. Configuration Now that we have a base configuration, let’s understand what it does. The three main parts are rules, plugins, and extensions. Rules Rules, defined in the rules section of the configuration, determine what the ESLint proofreader looks for in your code. ESLint provides hundreds of these rules that help maintain code quality. These rules can either be set to off, warn or error. off will do nothing, warn will log the error, and error will log the error and return a 1 exit code so integrations such as continuous integrations will fail. module.exports = { rules: { 'no-underscore-dangle': 'off', 'no-console': 'warn', 'no-empty': 'error', }, } Some rules also allow you to customize a rule with addition configuration options so you don’t have to turn the entire rule off. module.exports = { rules: { 'no-empty': ['error', { allowEmptyCatch: true }], }, } Plugins But there are a lot more rules than that. ESLint also provides plugins, defined in the plugins section of the configuration, to allow third-parties to develop rules themselves. Most established frameworks such as React, Jest, and Testing Library, take advantage of this and expand upon ESLint’s native rules. In fact, I usually evaluate a framework’s maturity by checking whether they have their own ESLint rules! module.exports = { plugins: ['react'], rules: { 'react/no-deprecated': 'error', }, }; Extensions All told, there are easily thousands of ESLint rules. How could you possibly decide which rules to enable without spending weeks and weeks to understand them all? You don’t — extensions, defined in the extends section of the configuration, handle that for you. Extensions such as Airbnb’s ESLint Configuration, something that the ESLint setup tool provides if you selected Airbnb’s style guide, have enabled hundreds of rules; rules that will also be enabled for you if you use their extension. Here are a few notable ESLint configurations from common Javascript frameworks: airbnb — Airbnb’s ESLint configuration for it’s Javascript style guide plugin:react-hooks/recommended— Recommended ESLint configuration for React Hooks plugin:react/recommended — Recommended ESLint configuration for React plugin:react-redux/recommended— Recommended ESLint configuration for React Redux plugin:jest/recommended — Recommended ESLint configuration for Jest plugin:testing-library/react — Recommended ESLint configuration for React Testing Library Overriding + Disabling A side effect of using extensions is that you may not like all of their rules. Fortunately, you can customize or turn off these rules in the rules section. module.exports = { extends: ['airbnb', 'plugin:react/recommended'], rules: { 'no-empty': ['error', { allowEmptyCatch: true }], 'react/jsx-filename-extension': [ 'error', { extensions: ['.js', '.jsx'] } ], }, }; Even if you like a rule, sometimes you encounter a situation where you want to temporarily disable it. You can accomplish this using comments. /_ eslint-disable _/: Disables ESLint for all lines below /_ eslint-disable-line _/: Disables ESLint for the current line /_ eslint-disable-next-line _/: Disables ESLint for the next line You can also specify (comma separated) rules after the disable comment to specifically disable those rules instead of disabling all. import React from 'react'; import PropTypes from 'prop-types'; */* eslint-disable */* import ReactDom from 'react-dom'; */* eslint-enable */* */* eslint-disable-line arrow-body-style */* const App = () => { return <h1>ESLint Demo</h1>; }; App.propTypes = { */* eslint-disable-next-line react/no-unused-prop-types, react-redux/no-unused-prop-types */* unused: PropTypes.string.isRequired, }; export default App; Of course, if you find yourself disabling the same rule over and over again, you may want to consider permanently disabling it. Running Now that we have the desired configuration, it’s finally time to run ESLint. To do this, add the following to your package.json. { "scripts": { "lint": "eslint . ", "lint:fix": "eslint . --fix", }, } npm run lint will run ESLint and any errors and warnings will be printed to the console. Fix and repeat. npm run lint:fix will run ESLint as well but will also try and automatically fix any violated rules. Any rules that can’t be automatically fixed will be printed to the console. Final Thoughts Now, you should be up and running with ESLint. The next step is to fix any violations— I had to deal with over 30,000 errors myself! But I consider this well worth it in the long run. ESLint monitors and guides me to create and maintain a high quality codebase so I don’t have to obsess over the little details. Instead, I can focus that obsession into creating a better product.
https://plainenglish.io/blog/eslint-a-proofreader-for-your-code
CC-MAIN-2022-40
refinedweb
1,238
56.96
Details Description Found a tricky bug when (un-)marshalling arrays. public class Dim1 { private int[] values; public Dim1() { this.values = new int[2]; } //getters + setters for 'values' } If you marshal an instance of Dim1 and unmarshal it again, 'Dim1.values' has now four and not two values. I included a junit test-case that demonstrates the problem. Activity Test case highlighting the problem with the constructor code. Actually, please ignore my last comment. It's completely wrong .. . Just looked at the test case again, and I think that you have got the wrong expectations. Here's why: Castor will add to your array, and that's it. If it has been initialized already. If the array would not have been initialized already, Castor would initialize it (to an array of 0 length). But in this case, the array has been initialized only. As such, there's no way for Castor to derive that you are trying to pre-initialize an array. From Castor's point of view, there's an property of type array, and it has been initialized already (is not null). Does this make sense ? Hi Werner, when I noticed the described behavior I was just unsure how to feel about that...I know maybe it's a very theorical issue because I think it's not very common to initialize an array in a no-arg-constructor (?, not sure about that but I think this is just like the no-arg constructor of java.util.ArrayList works). It just didn't seem 'right' to me that the state of the instance changed by marshalling and unmarshalling again. From a users point of view I would expect that all non-transient and non-static fields are exactly the same after going through this process. Am I wrong here? Do you know if there is a particular reason why castor adds the newly created array and not simply overrides the reference? Hi Martin, I agree that the observed behaviour during a full round-trip does not feel right, but I guess one has to clearly distinguish between various things here: - object instantitation - object initialization - adding artefacts to such objects as a result of unmarshalling. As already said, if your POJO does not e.g. create the int[] instance, Castor will do so by using reflection and eventually calling newInstance(). But if the object instance already is in place, Castor will use it as it is to add objects to the array in your case. To clarify my argumen(s) even further, how would Castor be able to distinguish between an int[] initialized with default values (as in your case) and any values (2, 4) ? Personally, I do not think it should be able to do so. When it comes to your last question, Castor uses whatever is there. If there's an object instance of either an array or e.g. a LinkedList, it will use it and e.g. call the add() methid on the LinkedList. If there isn't such an instance, it will create it. In other words, either leave it up to Castor or control it yourself. But once you control it, that's it. Martin, any thoughts on my last question ? I'm sorry Werner but it still feels wrong to me to add something as a result of unmarshalling. I would instead expect castor to override the preinitialized array. Can't figure out the sense of the add-behavior in a scenario where I have the array populated with default values. If I remove the initialization of the array from the constructor just to adapt the behavior of the unmarshaller I'm ending up with having to initialize the array for myself each time I create an instance of the class. Give me a hint if I'm wrong but isn't my constructor supposed to initialize my private fields? Martin, it looks like this is a side-effect of your constructor code. Once I removed the initialization of the array to the test method, everythings's fine.
http://jira.codehaus.org/browse/CASTOR-2921?attachmentOrder=desc
CC-MAIN-2015-18
refinedweb
675
73.68
.Drawing.Rectangle.GetHashCode() implmenentation is wrong. Running the code snippet below returns the same hash code for all rectangles. Running the same in a Windows Forms application returns a different result for each rectangle. for (int i = 0; i < 100; i++) { System.Drawing.Rectangle rect = new System.Drawing.Rectangle(i, i, i, i); int hash = rect.GetHashCode(); System.Diagnostics.Debug.WriteLine(rect, "rect "); System.Diagnostics.Debug.WriteLine(hash, "hash"); } Found the implementation in Xamarin.Android is this: public override int GetHashCode() { return ((this.height + this.width) ^ (this.x + this.y)); } The same in the Mono Framework (): public override int GetHashCode () { return (height + width) ^ x + y; } So this is both a Mono base classes and Xamarin.Android problem. Please do not copy and paste Microsoft proprietary code into bugzilla. github.com/Microsoft/referencesource and related is fine. reference source.microsoft.com is NOT. You must not rely on the GetHashCode() implementation, as the implementation can change over time. Having different values from .NET is not a bug. > the .NET Framework does not guarantee the default implementation of the GetHashCode > method, and the value this method returns may differ between .NET Framework versions > and platforms... > The hash code itself is not guaranteed to be stable. Hash codes for identical strings > can differ across versions of the .NET Framework and across platforms... The existing Rectangle.GetHashCode() implementation may not be ideal (increased risk of hash collision), but it is by no means "wrong" or buggy. YOU MUST NOT RELY ON THE GetHashCode() IMPLEMENTATION. We do not RELY on the GetHashCode implementation, we USE the GetHashCode implementation. Presumably if the GetHashCode was not fit for use, it would not be present in the API. The Xamarin implementation is not fit for use. The .NET framework code IS fit for use. This is clearly problematic, and we request that the issue be reviewed as soon as possible. Thank you. > The Xamarin implementation is not fit for use. Please elaborate on how the current implementation is not fit for use, as I'm an idiot who cannot fathom how it's not fit for use. Jonathan, my apologize if I posted code that could not be pasted here. I obtained it using Reflector on the System.Drawing.dll assembly. As far as the use of GetHashCode() is concerned, we store object instances into a dictionary for performance purposes. Doing so we improve performance not having to create identical object instances. Each object instance is identified in the dictionary with a custom hash code (generated using GetHashCode() among other operations) calculated from each property that the instantiated object uses. As you suggested, current implementation has a high rate of hash collision, making our code not producing the expected output. Same code base works perfectly in Windows Forms applications but fails in Xamarin platforms. That's the reason why we think GetHashCode() is not fit for use. If I'm not wrong, the aim of GetHashCode() is providing the functionality I just described: If you need more information don't hesitate to let me know. From the MSDN documentation here: "A hash code is a numeric value that is used to insert and identify an object in a hash-based collection such as the Dictionary<TKey, TValue> class, the Hashtable class, or a type derived from the DictionaryBase class." However, this is not possible with Xamarin's implementation of Rectangle.GetHashCode() because it generates identical hashcodes for different instance objects. Running the code the OP specifies, you will see that a good number of the instance objects, despite having different values for their properties, return identical hashcodes. Given that identical key values cannot be used in a Dictionary<TKey, TValue> instance, for example, this means that different instances of Rectangle with different values for their properties cannot be added to it. By definition, then, the implementation is unfit for this specified use. > we store object instances into a dictionary for performance purposes. > Doing so we improve performance not having to create identical object instances. I don't know what this means. Presumably you're using a Dictionary<TKey, TValue>. What is TKey? Rectangle? > current implementation has a high rate of hash > collision, making our code not producing the expected output. This likewise doesn't make sense: hash collision within Dictionary<TKey, TValue> would merely result in slower runtime behavior. It would NOT result in "code not producing the expected output". For example: $ csharp -r:System.Drawing: csharp> using System.Drawing; csharp> new Rectangle (1, 1, 1, 1).GetHashCode(); 0 csharp> new Rectangle (4, 4, 4, 4).GetHashCode(); 0 Note hash code collisions. csharp> var d = new Dictionary<Rectangle, string>(); csharp> d[new Rectangle (1, 1, 1, 1)] = "1"; csharp> d[new Rectangle (4, 4, 4, 4)] = "4"; We add two entries to a Dictionary<Rectangle, string>, with the aforementioned Rectangle values which produce hash collisions. csharp> d[new Rectangle (1, 1, 1,1 )]; "1" csharp> d[new Rectangle (4, 4, 4, 4)]; "4" Observe that the hash collisions DO NOT MATTER. We're still able to retrieve the correct value for a given key; we're not getting unexpected and incorrect output. GetHashCode() producing collisions is *solely* a performance problem, and at that it's an indeterministic performance problem. (How big is this dictionary? Does profiling actually suggest that it's a problem?) > it generates identical hashcodes for different instance objects There is no way to avoid this behavior. Avoiding collisions is IMPOSSIBLE. object.GetHashCode() returns an Int32. It may thus contain, at most, 2**32 values. Meanwhile, consider System.String. It can contain FAR MORE than 2**32 values. The same is true for any type that contains int fields. Consider: struct Point { public int x, y; } How many possible Point values are there? There's a set of Point values for which x varies from int.MinValue to int.MaxValue and y is 0 -- 2**32 values, same as int -- and a separate set of Point values for which x is 0 and y varies from int.MinValue to int.MaxValue -- *another* 2**32 values, same as int -- then there's every other possible combination. Note that the set of possible Point values far larger than what can be held in an Int32. So what *must* happen? There *must* be the potential for collisions, and the Dictionary/etc. container needs to cope with them appropriately. See also the Pigeonhole Principle: In the case of Dictionary<TKey, TValue>, this is done by using the hash code to lookup an appropriate "bucket", then checking each key in the bucket with object.Equals() to see if it's an actual match. Okay, you don't see it as a problem. It remains curious that, for identical client code, Microsoft's implementation of Rectangle.GetHashCode does not give any collision problems whereas Xamarin's does. As you state, it is not an insurmountable problem to work around. @chris, may I point out the Remarks section here - - and especially the Caution box. Note the second bullet. This is what Jon is trying to explain. Also consider the paragraph above the Caution box as well as the two bullet points. Consider another point as well - storing a value type in a dictionary will *not* increase performance. Each time you assign a value to the key and each time you extract the stored value you will have a copy performed. It will most probably hurt performance (and memory use) instead of improving it. Neither Mono nor Microsoft implementations of GetHashCode are bad or wrong - they are different which is in line with the documentation. Can the Mono version be improved? Yes. Will it fix your problem? No. Will the Microsoft implementation (pasting code for which makes it harder to implement the new version of the method btw) always produce the desired results for you? No, there's no guarantee whatsoever for this. @Marek, thanks. One point though - hashing instance objects where such objects are repeatedly reused does have demonstrable performance benefits in our case. So far, the only trouble we have experienced are with the Xamarin implementations of the GetHashCode method. Pure coincidence? Maybe. We wanted to avoid bucketing given that the objects we hash exist within a small range of possible values, and I'm sure bucketing would have a negative impact on the performance of our hashing technique. We will try it and see, although I am still unconvinced by the explanations we have been given as to why the code @Narcís posted produces identical hash codes for Xamarin but not for Microsoft. @chris - there is no "reuse" with value types - you constantly copy them in their entirety. Instead of bucketing you can use your own implementation of GetHashCode () (a simple extension method will do the trick) even using the code you retrieved from Microsoft's System.Drawing. As for why the codes are different? Because they're *implementation dependent* - it's how it is designed and it is perfectly fine for them to differ. It's precisely the same kind of situation as with the C 'char' type. It is up to compiler implementation to treat it as signed or unsigned - some compilers have one, some another. And it doesn't make neither of them bad or wrong. It's documented so it's up to the developer to make *proper* use of the type (if you want to be sure that your variable is signed char then you type it as 'signed char'). The same applies to GetHashCode () - what you're doing is against the documented behavior and is, let me be blunt, incorrect. @Marek "reuse" here a simile to describe the process by which classes are instantiated as instances and these instances are "reused" rather than being instantiated again in the code. That these instances are actually copied rather than "reused"? Fine; from what I understand of .NET architecture, this copying is virtually instantaneous. And yes, our hashing process does use our own implementations of GetHashCode(), although we do use the Framework type GetHashCode() method as part of the seed in some cases. I understand that the implementation is different, but when I said I was unconvinced by this explanation I meant that I was looking for an explanation that explains why the difference in implementation causes this effect. No, what we are doing is in accordance with the documentation. It is not incorrect. Can it be bettered? Yes, it can, and it will be. > we store object instances into a dictionary for performance purposes. > Doing so we improve performance not having to create identical object instances. I'm still wondering what this looks like at a code level. That could go a long way to explaining why the expected output isn't produced, unless the expected output *is* the value of Rectangle.GetHashCode()... @Jonathan It is a very standard implementation of hashing following MSDN documentation. What was unexpected was the return value of the Xamarin Rectangle.GetHashValue which we were using as a seed value of a hashing function. This unexpectedness is perfectly reflected in the OP code, where the Xamarin Rectangle.GetHashValue returns identical values for different instance objects with different field values. As far as I can see, we have been given no coherent explanation for this behaviour other than the fact that the implementation is different, a fact the OP posted in his first comment which was subsequently deleted. Still, not to worry. I'm very confident we'll be able to make the necessary compensatory changes to our routines, thank you. Created attachment 11386 [details] 2 screenshots showing the problem. Here are two screenshots that show the implications Xamarin's Rectangle.GetHashCode implementation has. NoCache.png shows what we'd expect to get, a regular gradient across the entire area. WrongHashCode.png shows what the result of GetHashCode, unpredictable gradients filling in the area. Such gradients are created using. Among other parameters, this is defined by a rectangle (x0, y0, x1 & y1). Rectangle's hash code is part of the custom hash code we calculate to store LinearGradient instances into a dictonary and not having to create unnecessary instances (Xamarin Profiler showed us that was more time consuming). Inconsistent hash codes render Xamarin implementation of Rectangle.GetHashCode useless for us. We have been able to circumvent that problem using Microsoft's implementation in our custom hash code calculation. > Rectangle's hash code is part of the custom hash code we calculate to store > LinearGradient instances into a dictonary and not having to create unnecessary > instances What is your data structure? What is the key into your Dictionary? As far as I can tell, what you're doing is similar to this: var d = new Dictionary<int, LinearGradient> (); var r = new Rectangle (...); d [r.GetHashCode()] = new LinearGradient (...); i.e. using the result of Rectangle.GetHashCode() as the dictionary key. Assuming the above is the case, *that's the bug*: The implementation of GetHashCode() can change at any time, for any reason. Hash codes do *not* uniquely identify a value; they *can't* (see Comment #9). The screenshots you provided show a problem. They do not indicate that the problem lies solely in the GetHashCode() implementation. Yes, we use custom hash codes as dictionary keys as you mentioned. However, those dictionaries are cleaned and recreated at each execution, they are only valid at run-time and not stored at any data structure. Therefore, any change in the implementation of GetHashCode() will be reflected accordingly into all object instances stored in the dictionary. This works flawlessly in Windows Forms applications. We encountered problems with hash code calculated in Xamarin/Mono platform.
https://xamarin.github.io/bugzilla-archives/30/30538/bug.html
CC-MAIN-2019-43
refinedweb
2,265
57.98
This action might not be possible to undo. Are you sure you want to continue? 0 The Snort Project December 2, . . . . . . . . . . . . . . . . . . . . . . . .1 2. . . . . .2. . . . . . . . . . . .9. . . . . . 2. . . . . .9 Frag3 . . . . . . . . . . . . . 2 Configuring Snort 2. . . . . . . . . . . . . . . . .3 1. . . . . . . . . . . . . . . . 2. . . . . . . . . . . . .1 1. . . . . . . . . . . . . . . . . . . . . . . . . . . .2. . . . . . . . . . . . . . . . . . . . . .4 2. . . . . . . . . . . . . . . 100 Event Processing . SSH . Preprocessors . . . . . . . . . . . . . . . . . 106 2. . . . . . . . . . . . . . . . . . . . .9. .3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 106 Preprocessor Profiling . Obfuscating IP Address Printouts . . . . . . . . . . . .2. . . Reverting to original behavior . . . FTP/Telnet Preprocessor .1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTTP Inspect . . . . 2. . . . . . . .2. .4 1. . . . .9. . . . . . . . . . . . . . . . . . . . . . . . . . .2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .10 DNS . . . . Config . . . . . . .1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .5 Performance Profiling . . . . . . . . 105 2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 100 2. . . . .1 2. . . . . . . . . . . . .2 2. . . . . . . . . . . . . . . . . . . . . 102 Event Suppression . . . . . . . . . Specifying Multiple-Instance Identifiers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .12 ARP Spoof Preprocessor . . . . . . .3. . . .4. . . . . . . . . . .2 2. .3 2. .13 DCE/RPC 2 Preprocessor . . . . . . . . . . . . . . . . . . 2. . . . . . . . . . . . . . . . . . . . . . 2. . . . . . . . .15 Normalizer . . . . . . . . . . . . . . . . . .7 2. . . . .5. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1 2. . . . . . . . . . .2. . . . . . . .2. . . . . . . . . . . .2. . .2 Rule Profiling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4. . . . . . . .11 SSL/TLS . . .2. Stream5 . . . . . . . . . . . . . . . . .1 Includes . . . . . 101 Event Filtering . . . . . . . . . . . . .5.1. . . . . . . . . . . . . . . . . . .2 Format . . . . . . . . . . . . . . . . . . . . . .5 Running Snort as a Daemon . . . . . . . . . . .3 2. . Running in Rule Stub Creation Mode . . . . . . . . .3 2. . . . . . . . . . . . . . . . . . .1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 104 Event Logging . . . . .8 2. . . . . .1 2. . . . . . . . . .2. . . . . . . . . . . . . . . . . Variables . . . .6 2. . . . . . . . . . . . . . . . . . . . . . . . . .1 2. . . . . . . . . . . . . . . . . . . . . . . 2. . . . . RPC Decode . . .2. . . . 23 23 24 24 24 25 26 26 26 26 29 37 38 41 45 51 51 55 66 69 75 77 77 79 80 93 96 99 99 1. . . . . .2. . . . . . .14 Sensitive Data Preprocessor . . . . . . .5 2. . . . . . .3 Decoder and Preprocessor Rules . . . . . . . .9. . . . . .2 2. . . . . . .4 Configuring . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4 Rate Filtering .2 1. . . . . . . . . . . . . . . . . . .4. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2 2. . . 2. . . . . . . . . . . . . . . . . . . . . . . . .9. . . . . . . . .2. . . . . . . . . . . . Performance Monitor . . . . . . . . . 2. . . SMTP Preprocessor . . . . . . . . . .10 More Information . . . . . . . . . . sfPortscan . . . . Snort Modes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2. . . 108 3 . . . . . . . . . . . . 2. . . . . . . . 2. . . . . . . . . . . . . . . .2 Configure Sniping . . . . . . . . . . . . . . 121 2. . . . . . . . . . .6. . . .7 2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 116 log tcpdump . . . . . . . . . .11 Active Response . . . . . . . . . . . . . .3 Enabling support . . . . . . .6. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .11. . 126 2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 129 2. . . . . . . . . . .6. 114 alert fast . . . . . . . . . . . 130 2. . . . . . . . . . . . . . . . . . . . 110 Output Modules . . . . . . . . . . . .11 log null .13 Log Limits . . . . . . . . . . . . . .11. . . . . .9. . . . . . . . . . . . . . .6. . . . . . . . . 128 2. . . . . . 134 4 . . . . . . . . . . . . . . . . . . . . . . . . .1 Creating Multiple Configurations . . . . . . . . . . . . . . . . . .10. . . . . . . . . . . . . . 121 2. . . . . . . . . . . . . . . . . 116 alert unixsock . . . . . . 120 2. . . . . . . . . . . .11. . . .4 React . .10 alert prelude . . . . . . . . . . . . .12 alert aruba action . .10 Multiple Configurations . . . . . . . . . . . . . . . . . . .8 Configuration Format . . . . . . . .2 2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 126 Directives . 132 2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1 2. . . . . . . . . . . . .11. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .6. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1 2. . . . . . . . . . . . 115 alert full . . . . . . . .8. . . . . . . . . . . . . . . . . . . . . . . . . . . . . .5. . . . . . . . . . . . . . . . . . . . . .5 2. . . . . . . .9. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2. . . . . . . . . . . . . . . . . . . . . . . . . . 118 unified . . . . . . . . . . . . . . . . . .8 2. . . . . . . . . . . .6. . . . . . . . . 132 2. . . . . . . . . . . . . . . .1 Enabling Active Response . . . . . . . . . . . . . . . . . . . . . . .6. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .8. . . . . . . . . . . . . . . . . . . 122 Attribute Table File Format . . . . . . . . . . 131 2. . . . . . . . . . . . . . . . . . .6. . . . . . . . . .5 Rule Actions . .7. . . . . .11. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .6 Packet Performance Monitoring (PPM) . 120 2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 127 Non-reloadable configuration options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 129 2. . . . . . . . . . . . . . . . . . .2 Configuration Specific Elements . . . . . . . . . 122 2. . . 113 2. . . . . 133 2. . . . . . . . . . . . 127 2.1 2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4 2. . . . . . . . . . . . . . . . .7. .3 2. . . . . . . . . . . . . . . . . . 125 Dynamic Modules . . . . . . 123 Attribute Table Example . . . . . 122 2.3 Flexresp . . . . . .2 2. . . . . . . . . .2 2. . . . . . . . . . .3 2. . . . . . . . . . . 126 2. . . . . . . . . . . . . . . . . 117 csv . . . . . . .10. . . . . . . . . . . . . . . . . . .9 alert syslog . . . . . . . . . . . . . . . . . .3 How Configuration is applied? . . . . . . . .6. .6. . . . . . . . . . . . . .7 Host Attribute Table . . 127 Reloading a configuration . . . . . . . . . . . . . .9. . . . . . . . . . . . . 119 unified 2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .6. . . . . . . . . 132 2. 116 database . . . . . . . . . . . . . . .3 2. . . . . . . . . . . . . . . . . . . . . . . . . . . . .1 2. . . . . . . .7. .10. . . . . . . . . . .6. . . . . . . . . .6. . . . . . . . .6 2. . . . . . . .2 Format . . . 131 2. . . . . . . . .9 Reloading a Snort Configuration . . . . . . . . . . . . . . . . . . .2 3. . . . . . . . . . . . . . . . . . . .10 http raw cookie . . . . . . . .11 http header . . . . . . . . .4. . . . . . . . . . . . . . .1 3. . .5. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 150 3. . . . . . . . . . . . . . . . . . . . . . . . .5. . . . . . . . .2. . . . . . . . . . . . .5. . . . . . .3 Writing Snort Rules 3. . . . . .15 http raw uri . . . . . . . . . . . . . . . . . . . . . . 150 3. . . . 135 Rules Headers . . .8 3. . . . . . . . . . . . . . . . . . . . . . . .5. . . . . . . . .5. . . . . . . . . . . . . . . . . . . . . . 148 3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4 Rule Options . . . . . . . . . . . . . . . . . . . . . .1 3. . . . . . . . . . . .5. . . . . . . . . 137 The Direction Operator . . . . . 145 depth . . . . . . 144 3. . . . . .4 3. . .2. . . . . . . . . . . . . .4. . . . 146 offset . . . . . .14 http uri . . . . . . . . . . . .5. .5 3. . . . . . . . . . . . . . . . . . . 143 General Rule Quick Reference . . . . . . . . . . . . . . . 149 3. . . . . . . . . . . . . . . . . . . . . . . . . .2. . . . . . . . . . . . .5. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .6 3.2. . . . . 139 3. .13 http method . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3 3. . . . . . . . . . . . . . . . . . . .4. . . . . . . . . . . .4. . . . . . . . . . . .4 3. . 146 distance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 143 3. . . . . . . .5. . . . . . . . . . . . . . . . . . .2 3.5. . 152 5 . . . . . . . . . . . . . .6 Rule Actions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 146 within . . . . . . . . . . . . . . . . . . . . . . . . . . .4. . . . . . . . . .3 3. . . . . . . . . . . . . . 139 gid . . . . . . . .4.17 http stat msg . . . . . . 136 IP Addresses . . . . . . . . . . . . . . . . . . .7 3.4. . . . . . . . . . . . . . . . . . . . . . . . . . . . .5. . . . . . . . . . . . . . . . . . . . . . . . . 135 3. . . . . .5. . . . . . . . . . . . . 138 3. . . . . . . . . . . . .9 content .5. 149 3. . . . . . . . . . . . . . . . . .18 http encode . 150 3. . . 141 priority . . . . . .2. . . . . . . . . .4. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 135 Protocols . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 151 3. . . . . . . . . . . . .7 3. . . . . . . . . . . . . 144 nocase . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1 3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 148 3. . . . . . . . . . .5. . . . . . . . . . . . . . . . . . . . . .5.4. . . . . . . . . . . . . . . . . . . . . . .5. . . . . . . . . . . . . .12 http raw header . . . . . . . . . . . . . . . . 147 http client body . . 139 reference . . . . . . . . . . . . . . . . . 137 Activate/Dynamic Rules . .2 135 The Basics .1 3. .8 3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 142 metadata . . . . . . . . . . . . . .5. . . . . .5 Payload Detection Rule Options . . . . . . . . . . . . . . . . . . . 145 rawbytes . . . .6 3. . . . . . . . . . . . . . . .4 3. . . . . . . . . . . . . . . . 147 http cookie . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .9 msg . . . . . . . . .5. . . . . . . . . . . . . . . . . . . . . . . . . . . 140 rev . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3 3. . . . . . . . . . . 136 Port Numbers . . . . . . . . . . . . . .5 3. . 138 General Rule Options . . . . . . . . . . . . .16 http stat code . . . . . . . . . . . . . . . . . . . . . .2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 140 sid . . . . . . . . . . . . . . . . . . 151 3. . . . . . .3 3. . .2 3. . . . . . . . . .5 3. . . . . . . . . . . . . . . . . . 141 classtype . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .24 file data . . . . . . . . . . . . . . .21 urilen . . . .6. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .6. . . . . . . . .6 Non-Payload Detection Rule Options . . . . . . . . . . . . . . . . 169 3. . . . . . . . . . . . . . . . . . . . . . . . . .5. . . . . .5. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .5. . . . . . . . . . . . . . . . . . . . . . . . . 164 3. . . . . .5. . . . . . . . 159 3. . . . . . . . . . . . . . . . . 161 3. . . . . . . . . .5. . . . . . 164 3. . . . . . . . . . . . . .9 fragoffset . . . . . . .18 rpc . . . . . . . . . . . . . . . . . . . . . .3. . . . . . . . . . . . 169 3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .31 asn1 . . . . . . . .6. . . . . . . . 166 dsize . . . . . . . . . . . . . . . . . . . . 161 3. . . . . . . . . . . . . . . . . . . . . . . . . . . . 163 3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 165 id . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .14 itype . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 163 3. . . . . . . . . . . . . . . .6 3. . . . . 170 3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .26 base64 data . . . . . . . . . . . 166 ipopts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2 3. . . . 170 3. . . . . . . 158 3. .37 ssl state . . . . .5. . . . . . . . . . . . 170 3.28 byte jump . . . . . . .6. . . . . . . . . .5. . . . . . . . . . .5. . .38 Payload Detection Quick Reference . . . . . . . . . . . . . . . . . . . . .6. .25 base64 decode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 171 6 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 165 tos . . . . . . . . . . . . . . . . . .6. . . . .6. .5.33 dce iface . . . . . . . . . . . . . . . 164 ttl . . . . . . . .6. . . . . . . . . . . . . . . . . . .36 ssl version . . . . . .5. . . . . . . . . . . . . . . . . . . . . . . .5. . .6. . . . . . .6. . . . . . . . . . . . . . . 168 3. . . . . . . . . . . . . . . . . . . . . 164 3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 171 3. . . . . .20 uricontent . . . . . . . . . . . . . . .5. . . . . 154 3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .6.19 fast pattern . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .32 cvs . . . 153 3. . . . . . . . . . . . . . . . . . . . . . . . .5. . . . 164 3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .27 byte test . . . . . . .3 3. . . . . . . . . . . . . . . . . . . .4 3. . . . . . . . .5. . .7 3. . . . . . . . . . . . . . . . . . . . . . . . . . . .6. . . . . . . . . . . . . . . . . . . . . 163 3. . . . . . . . . . . . . .5. . . . . . . .5 3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . .35 dce stub data .5. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .16 icmp id . . 168 3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 164 3. . . . . . . . . . . . . . . . . . . . . . . . .6. . . . . . . . . . . . . . . . .22 isdataat . .6. . . . . 157 3. . . . . . . . . . . . . . . . . .5. . . . . . . . . . . . .6. . . . . . . . . . . . .10 flowbits . . . . . . . 162 3. . . . . . . . . . . . . . . . . . . . . . . . . .8 3. . . . . . . . 155 3. . . . . 166 fragbits . . .5. . .29 byte extract . . . . . . . . . . . . . . . . . . . . .15 icode . .13 window . . . . . . . . . .17 icmp seq . . . . . . . . . . . . . . . . . . . 164 3. . . . .30 ftpbounce . . . . . . . . . . 156 3. . . . . . . .12 ack . 167 flow . . . . . . . . . 159 3. . .5. . . . . . . . . . . . . . . . . . . . . . . . .6. . . . . . . . . . . . . . . . . . . . . .34 dce opnum . . . . . . . . .23 pcre .1 3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 155 3. . .6. . . . . . . . 167 flags . . . . . . . . . . . . . . .5. . . . . . .11 seq . . . . . . . . 169 3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .6. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .5 3. . . . .21 stream reassemble . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4 3. . . . . . . . .3 4.7. . . . . . . . . . . . . . . . . .9 Rule Thresholds . . . . . . . . . . . . . . . . . . . . . . .4 3. .1. . . . . . . . . . . . . . . . . . . . . . . . . . 177 3. . . .7. . Not the Exploit . .1. . . . 175 activated by . . . . . . . . . . . . . . . . .1 3. . . . . . . . . . . . . . . . . 175 3. . . . . . . . . . . . . . . . . . . . . . . . .10 detection filter . . . . . . . . . . . . . . . . . . . . .9. . . . . . . . . . . . .3. . . . . . . . . . . . . . . . . . . . . .6. . . . . . . . . . . . . .2 Preprocessor Example . . . . . . . . . . . . .7. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 176 3. . . . . . . . . . . . .8 3. . . . . . . .7. 175 3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .7. . . . . . . . 190 Rules . . . . . . . . . . . . . . . . . . . . . . . . . .7. . . . . . . . . . . . 177 Catch the Oddities of the Protocol in the Rule . . .7. . . . .23 Non-Payload Detection Quick Reference .2 Required Functions . . . . . . . . . . . . . . . . . . . . . . . . . . . 183 4. .1 4. .6. . . . . . . . . . . . . . . . .5 DynamicPluginMeta . . . . . . . . . . . . . . . . . . . . . . . . . . 192 7 . . . . . . . . . . . . . . . . .3 Examples . . . . . .3. . 173 session . . . . . . . . . . . . . . . . .9. . . . . . . . 178 Testing Numerical Values . . . . . . . . . . . . . . . . . . . . . 173 resp . . . . . . . . . . . . . . . . . . . . . .9 logto . . . . . . . . . . . . . . . . . . 182 DynamicEngineData . . . 182 DynamicPreprocessorData . 188 4. 189 Rules . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .6 3. . . . . .6. . . . . . . . . . 173 3. . . . . . . . . . . . . . . . . . . . . . . . . . 172 3. . . . . . . . . . . . . . . . . . . 174 activates . . .9. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4 4. . . . . . . . . . . . . . . . . .7. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 171 3. . . . .2 3. . . . . . . . . . . . . . . . . . . . . . .2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1 4. . . . . . . . . . 171 3. . . . . . . . . .1. . . . . . . . . . . . . . . . .8 3. . . . . . . . . . . . . . . . . . . . . . . . .3 3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .7 3. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 174 react . . . . . . . . . . .1. . . . . . . . . . . . . . . . . . .6. . . . . . . . . . . .2 3. . . . . . . . .2 4. . . . . . . . . . . . . . . 189 Detection Engine . . . . . .1. . . . . 177 Optimizing Rules . . . . . . . . . . . . . . . .20 sameip . . . . . 172 3.3. . . . 176 Writing Good Rules . . . . . . . . . . . . . . . . . . . . . . . . . . .1 4. . . . . . . . . .9. . . . .22 stream size . . . . . . . . .7 Post-Detection Rule Options . . . . . . . .11 Post-Detection Quick Reference . . . . . . . .19 ip proto . . . . . . . . .2. . . . . . . . .6. . . . . . . . . . . . 173 3. . . . . . .2 4. . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3 3. . . . . . .7. . . . 190 4. .1 3. . . . . . . . . . . 183 SFSnortPacket . . . . . . . . . . . . . . . . . . . . . . . . . . . .5 4 Content Matching . . . . . . .1 Data Structures . . . . . . . . . . . . . . . 182 4. . . . . . . . . . . . . . . 179 182 Dynamic Modules 4. . 183 Dynamic Rules . . . . . . . . . . . . 175 replace .7. . . . . . . . . . . . . . . . . . . .7. . . . . . . . . . . . . . . . . . . . 174 tag . . . . . . . . . .2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3 Preprocessors . . . 177 Catch the Vulnerability. . . . . . . . . . . . . . . . 190 4. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .9. . . . . . . . . . . . . . . . . . . . . . . . . . 175 count . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1 5. . . . . . . . . . . . . . . . . .2. . . . . . . . . . 195 5. 196 8 . . .2. . .3 The Snort Team . . . . . . . . . . . . . . . . 195 5. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 195 Detection Plugins . . . . . . . . . . . . . . . . . . . . .2 5. . . . . . . . . . . . . . . . . .2. . .2 195 Submitting Patches . . . . . .1 5. . . . . . 195 Output Plugins . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .5 Snort Development 5. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 195 Snort Data Flow . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3 Preprocessors . 1. If you want an even more descriptive display. If you want to see the application data in transit. try the following: . • Network Intrusion Detection System (NIDS) mode. nothing else. Before we proceed. Snort can be configured to run in three modes: • Sniffer mode.org> and now is maintained by the Snort Team. let’s start with the basics. • Packet Logger mode. the most complex and configurable configuration. which logs the packets to disk. there are a few basic concepts you should understand about Snort.org>. If you would like to submit patches for this document. try this: ./snort -v This command will run Snort and just show the IP and TCP/UDP/ICMP headers. Small documentation updates are the easiest way to help out the Snort Project.2 Sniffer Mode First. sniffer mode).1 Getting Started Snort really isn’t very hard to use. This file aims to make using Snort easier for new users. which simply reads the packets off of the network and displays them for you in a continuous stream on the console (screen). which allows Snort to analyze network traffic for matches against a user-defined rule set and performs several actions based upon what it sees.tex. If you just want to print out the TCP/IP packet headers to the screen (i. 1. It was then maintained by Brian Caswell <bmc@snort./snort -vd This instructs Snort to display the packet data as well as the headers.. drop us a line and we will update A it.e. but there are a lot of command line options to play with. do this: 9 . and it’s not always obvious which ones go together well. you can find the latest version of the documentation in LTEX format in the Snort CVS repository at /doc/snort_manual. showing the data link layer headers. /log./snort -dev -l . you can try something like this: 10 .0/24 This rule tells Snort that you want to print out the data link and TCP/IP headers as well as application data into the directory . but if you want to record the packets to the disk.1. Additionally./snort -l . Packets from any tcpdump formatted file can be processed through Snort in any of its run modes./log -h 192.. you need to tell Snort which network is the home network: . and you want to log the packets relative to the 192. When Snort runs in this mode. If you’re on a high speed network or you want to log the packets into a more compact form for later analysis. which puts it into playback mode. you should consider logging in binary mode./snort -d -v -e and it would do the same thing. Snort can also read the packets back by using the -r switch. In order to log relative to the home network. All incoming packets will be recorded into subdirectories of the log directory./log Of course. if you wanted to run a binary log file through Snort in sniffer mode to dump the packets to the screen.. Once the packets have been logged to the binary file. this assumes you have a directory named log in the current directory. you need to specify a logging directory and Snort will automatically know to go into packet logger mode: .1./log -b Note the command line changes here. they are logged to a directory Note that if with a name based on the higher of the two port numbers or. all of these commands are pretty cool. don’t. For example.3 Packet Logger Mode OK. Binary mode logs the packets in tcpdump format to a single binary file in the logging directory: .168. with the directory names being based on the address of the remote (non-192. in the case of a tie. Snort will exit with an error message. it collects every packet it sees and places it in a directory hierarchy based upon the IP address of one of the hosts in the datagram. these switches may be divided up or smashed together in any combination. which eliminates the need to tell it how to format the output directory structure. The last command could also be typed out as: . ! △NOTE both the source and destination hosts are on the home network. you can read the packets back out of the file with any sniffer that supports the tcpdump binary format (such as tcpdump or Ethereal).168.) 1.168. If you just specify a plain -l switch.0 class C network./snort -dev -l ./snort -vde (As an aside. the source address. you may notice that Snort sometimes uses the address of the remote computer as the directory in which it places packets and sometimes it uses the local host address.1) host. Writes the alert in a simple format with a timestamp. 11 . fast.4 Network Intrusion Detection System Mode To enable Network Intrusion Detection System (NIDS) mode so that you don’t record every single packet sent down the wire.conf where snort. console.1. it will default to /var/log/snort. read the Snort and tcpdump man pages. simply specify a BPF filter at the command line and Snort will only see the ICMP packets in the file: . The screen is a slow place to write data to. Full alert mode./snort -dvr packet. . The default logging and alerting mechanisms are to log in decoded ASCII format and use full alerts. It’s also not necessary to record the data link headers for most applications. Generates “cmg style” alerts./snort -dev -l . cmg. socket.conf This will configure Snort to run in its most basic NIDS form. if you only wanted to see the ICMP packets from the log file.conf file to each packet to decide if an action based upon the rule type in the file should be taken.0/24 -c snort. If you don’t specify an output directory for the program. 1. Sends “fast-style” alerts to the console (screen). One thing to note about the last command line is that if Snort is going to be used in a long term way as an IDS.0/24 -l .168. These options are: Option -A fast -A full -A -A -A -A unsock none console cmg Description Fast alert mode. syslog. try this: . logging packets that trigger rules specified in the snort. as well as two logging facilities. The full alert mechanism prints out the alert message in addition to the full packet headers.168. This will apply the rules configured in the snort. This is the default alert mode and will be used automatically if you do not specify a mode. Six of these modes are accessed with the -A command line switch.log You can manipulate the data in the file in a number of ways through Snort’s packet logging and intrusion detection modes./snort -dv -r packet. alert message. source and destination IPs/ports. There are several other alert output modes available at the command line./log -h 192.4.. the -v switch should be left off the command line for the sake of speed. as well as with the BPF interface that’s available from the command line. For example. There are seven alert modes available at the command line: full.conf is the name of your snort configuration file.conf in plain ASCII to disk using a hierarchical directory structure (just like packet logger mode)./snort -d -h 192. so you can usually omit the -e switch.1. and packets can be dropped while writing to the display. Sends alerts to a UNIX socket that another program can listen on./log -c snort. 1. Turns off alerting. and none.1 NIDS Mode Output Options There are a number of ways to configure the output of Snort in NIDS mode.log icmp For more info on how to use the BPF interface. Alert modes are somewhat more complex. too. For output modes available through the configuration file. such as writing to a database. In this case. please read etc/generators in the Snort source.1. For example.168.2 Understanding Standard Alert Output When Snort generates an alert message. Rule-based SIDs are written directly into the rules with the sid option. we know that this event came from the “decode” (116) component of Snort. To disable packet logging altogether. The second number is the Snort ID (sometimes referred to as Signature ID).conf -A fast -h 192. but still somewhat fast.Packets can be logged to their default decoded ASCII format or to a binary log file via the -b command line switch.conf -l . as each rendition of the rule should increment this number with the rev option. For a list of GIDs. please see etc/gen-msg. use the output plugin directives in snort.conf.1 for more details on configuring syslog output. This allows Snort to log alerts in a binary form as fast as possible while another program performs the slow actions. If you want to configure other facilities for syslog output. try using binary logging with the “fast” output mechanism.6.6. This will log packets in tcpdump format and produce minimal alerts. 1.conf 12 . you need to use unified logging and a unified log reader such as barnyard. See Section 2. use the following command line to log to the default facility in /var/log/snort and send alerts to a fast alert file: . If you want a text file that’s easily parsed.4. use the following command line to log to default (decoded ASCII) facility and send alerts to syslog: .map. The third number is the revision ID. For a list of preprocessor SIDs. this tells the user what component of Snort generated this alert. For example: . ! △NOTE Command line logging options override any output options specified in the configuration file. use the -s switch.168./snort -b -A fast -c snort. To send alerts to syslog.4.0/24 -s As another example.3 High Performance Configuration If you want Snort to go fast (like keep up with a 1000 Mbps connection)./snort -c snort.0/24 1. it will usually look like the following: [**] [116:56:1] (snort_decoder): T/TCP Detected [**] The first number is the Generator ID.1. In this case. This allows debugging of configuration issues quickly via the command line. 56 represents a T/TCP event. This number is primarily used when writing signatures./snort -c snort. The default facilities for the syslog alerting mechanism are LOG AUTHPRIV and LOG ALERT. see Section 2./log -h 192. use the -N command line switch. only the events for the first action based on rules ordering are processed. ! △NOTE Pass rules are special cases here. in which case you can change the default ordering to allow Alert rules to be applied before Pass rules. then the Drop rules. please refer to the --alert-before-pass option. For more information. for packet I/O. etc. ! △NOTE Sometimes an errant pass rule could cause alerts to not show up.4. The Pass rules are applied first.5 Packet Acquisition Snort 2. • --alert-before-pass option forces alert rules to take affect in favor of a pass rule. Several command line options are available to change the order in which rule actions are taken.1 Configuration Assuming that you did not disable static modules or change the default DAQ type. you can select and configure the DAQ when Snort is invoked as follows: . rather then the normal action. you can run Snort just as you always did for file readback or sniffing an interface. The DAQ replaces direct calls to PCAP functions with an abstraction layer that facilitates operation on a variety of hardware and software interfaces without requiring changes to Snort. However. . regardless of the use of --process-all-events. • --process-all-events option causes Snort to process every event associated with a packet.9 introduces the DAQ. It is possible to select the DAQ type and mode when invoking Snort to perform PCAP readback or inline operation. The sdrop rules are not loaded.1.4 Changing Alert Order The default way in which Snort applies its rules to packets may not be appropriate for all installations. 1.5. Log rules are applied. while taking the actions based on the rules ordering. Without this option (default case). • --treat-drop-as-alert causes drop and reject rules and any associated alerts to be logged as alerts. or Data Acquisition library. 1. in that the event processing is terminated when a pass rule is encountered. then the Alert rules and finally. This allows use of an inline policy with passive/IDS mode. the maximum size is 32768. but -Q and any other DAQ mode will cause a fatal error at start-up. by using a shared memory ring buffer. Instead of the normal mechanism of copying the packets from kernel memory into userland memory. it will operate as it always did using this module. Phil Woods (cpw@lanl. These are equivalent: . mode. enabling the ring buffer is done via setting the environment variable PCAP FRAMES. This applies to static and dynamic versions of the same library./snort --daq pcap --daq-var buffer_size=<#bytes> Note that the pcap DAQ does not count filtered packets. If the mode is not set explicitly. You may include as many variables and directories as needed by repeating the arg / config. and attributes of each. MMAPed pcap On Linux. -Q and –daq-mode inline are allowed.5. The shared memory ring buffer libpcap can be downloaded from his website at. as this appears to be the maximum number of iovecs the kernel can handle. version. PCAP FRAMES is the size of the ring buffer. a modified version of libpcap is available that implements a shared memory ring buffer. if snort is run w/o any DAQ arguments. According to Phil. libpcap will automatically use the most frames possible./snort --daq pcap --daq-mode read-file -r <file> You can specify the buffer size pcap uses with: . . On Ethernet.gov/cpw/. the command line overrides the conf. and if that hasn’t been set. variable. 14 . and directory may be specified either via the command line or in the conf file.<mode> ::= read-file | passive | inline <var> ::= arbitrary <name>=<value> passed to DAQ <dir> ::= path where to look for DAQ module so’s The DAQ type. if configured in both places. 1. This feature is not available in the conf. Also. DAQ type may be specified at most once in the conf and once on the command line./snort --daq pcap --daq-mode passive -i <device> . Once Snort linked against the shared memory libpcap.lanl. This change speeds up Snort by limiting the number of times the packet is copied before Snort gets to perform its detection upon it. the most recent version is selected.gov) is the current maintainer of the libpcap implementation of the shared memory ring buffer.2 PCAP pcap is the default DAQ. -r will force it to read-file. for a total of around 52 Mbytes of memory for the ring buffer alone. libpcap is able to queue packets into a shared buffer that Snort is able to read directly./snort [--daq-list <dir>] The above command searches the specified directory for DAQ modules and prints type. Note that if Snort finds multiple versions of a given library. By using PCAP FRAMES=max. this ends up being 1530 bytes per frame./snort -i <device> . since there is no conflict./snort -r <file> . -Q will force it to inline. and if that hasn’t been set. the mode defaults to passive. 1. The number of frames is 128 MB / 1518 = 84733.5.5 MB.4 NFQ NFQ is the new and improved way to process iptables packets: . where each member of a pair is separated by a single colon and each pair is separated by a double colon like this: eth0:eth1 or this: eth0:eth1::eth2:eth3 By default. here’s why. 5. 15 . Assuming the default packet memory with a snaplen of 1518. you must set device to one or more interface pairs. You can change this with: --daq-var buffer_size_mb=<#MB> Note that the total allocated is actually higher.65535.. 3. the afpacket DAQ allocates 128MB for packet memory. default is 0 Notes on iptables are given below. 1.. default is IP injection <proto> ::= ip4 | ip6 | ip*. The smallest block size that can fit at least one frame is 4 KB = 4096 bytes @ 2 frames per block. 2.65535. etc. 4.. The frame size is 1518 (snaplen) + the size of the AFPacket header (66 bytes) = 1584 bytes. Actual memory allocated is 42366 * 4 KB = 165. default is 0 <qlen> ::= 0.3 AFPACKET afpacket functions similar to the memory mapped pcap DAQ but no external library is required: . we need 84733 / 2 = 42366 blocks. As a result. the numbers break down like this: 1. default is ip4 <qid> ::= 0.5. 9 versions built with this: .5.9 Snort like injection and normalization./snort -r <pcap> --daq dump By default a file named inline-out./snort -J <port#> Instead. start Snort like this: ./snort --daq dump --daq-var file=<name> dump uses the pcap daq for packet acquisition.65535./snort --daq ipfw [--daq-var port=<port>] <port> ::= 1. you will probably want to have the pcap DAQ acquire in another mode like this: . default is 8000 * IPFW only supports ip4 traffic. 1.6 IPFW IPFW is available for BSD systems.7 Dump The dump DAQ allows you to test the various inline mode features available in 2.9 versions built with this: ..5.1./configure --enable-inline / -DGIDS Start the IPQ DAQ as follows: ./snort -i <device> -Q --daq dump --daq-var load-mode=passive 16 ./snort --daq ipq \ [--daq-var device=<dev>] \ [--daq-var proto=<proto>] \ <dev> ::= ip | eth0. 1./snort -i <device> --daq dump ./snort -r <pcap> -Q --daq dump --daq-var load-mode=read-file . It therefore does not count filtered packets. Note that the dump DAQ inline mode is not an actual inline mode.5. It replaces the inline version available in pre-2. You can optionally specify a different name. It replaces the inline version available in pre-2. .pcap will be created containing all packets that passed through or were generated by snort. . etc. default is IP injection <proto> ::= ip4 | ip6.5 IPQ IPQ is the old way to process iptables packets. Furthermore. default is ip4 Notes on iptables are given below./configure --enable-ipfw / -DGIDS -DIPFW This command line argument is no longer supported: . Reset to use no filter when getting pcaps from file or directory. This can be useful for testing and debugging Snort. Note. A space separated list of pcaps to read. Added for completeness.e.2 Examples Read a single pcap $ snort -r foo.6. A directory to recurse to look for pcaps. Same as -r. Can specify path to pcap or directory to recurse to get pcaps. however. 1.. This filter will apply to any --pcap-file or --pcap-dir arguments following.6 Reading Pcaps Instead of having Snort listen on an interface. Print a line saying what pcap is currently being read. --pcap-no-filter --pcap-reset --pcap-show 1. reset snort to post-configuration state before reading next pcap. without this option. 1. Shell style filter to apply when getting pcaps from file or directory. • Ignore packets that caused Snort to allow a flow to pass w/o inspection by this instance of Snort.5. eg due to a block rule. • Allow packets Snort analyzed and did not take action on.6.1. Option -r <file> --pcap-single=<file> --pcap-file=<file> --pcap-list="<list>" --pcap-dir=<dir> --pcap-filter=<filter> Description Read a single pcap. Snort will read and analyze the packets as if they came off the wire. The default. Sorted in ASCII order.pcap $ snort --pcap-single=foo. If reading multiple pcaps. is not to reset state. eg TCP resets. i. • Blacklist packets that caused Snort to block a flow from passing.8 Statistics Changes The Packet Wire Totals and Action Stats sections of Snort’s output include additional fields: • Filtered count of packets filtered out and not handed to Snort for analysis.1 Command line arguments Any of the below can be specified multiple times on the command line (-r included) and in addition to other Snort command line options. • Injected packets Snort generated and sent.pcap 17 . • Whitelist packets that caused Snort to allow a flow to pass w/o inspection by any analysis program. The action stats show ”blocked” packets instead of ”dropped” packets to avoid confusion between dropped packets (those Snort didn’t actually see) and blocked packets (those Snort did not allow to pass). you can give it a packet capture to read. that specifying --pcap-reset and --pcap-show multiple times has the same effect as specifying them once. • Block packets Snort did not forward. File that contains a list of pcaps to read. pcap”.txt foo1. $ snort --pcap-filter="*.txt $ snort --pcap-filter="*. then no filter will be applied to the files found under /home/foo/pcaps.pcap foo2.Read pcaps from a file $ cat foo.pcap foo2.pcap.pcap" This will read foo1.txt foo1.pcap”.txt \ > --pcap-filter="*. $ snort --pcap-filter="*. so all files found under /home/foo/pcaps will be included.pcap" --pcap-file=foo.pcap --pcap-file=foo.pcap /home/foo/pcaps $ snort --pcap-filter="*. 18 .pcap and foo3.cap” will cause the first filter to be forgotten and then applied to the directory /home/foo/pcaps.cap” will be included from that directory. any file ending in ”.pcap --pcap-file=foo.txt. foo2.pcap” will only be applied to the pcaps in the file ”foo.pcap" --pcap-dir=/home/foo/pcaps The above will only include files that match the shell pattern ”*.cap" --pcap-dir=/home/foo/pcaps2 In this example. so all files found under /home/foo/pcaps will be included.pcap and all files under /home/foo/pcaps.pcap /home/foo/pcaps $ snort --pcap-file=foo.txt \ > --pcap-no-filter --pcap-dir=/home/foo/pcaps In this example. in other words.cap" --pcap-dir=/home/foo/pcaps In the above. The addition of the second filter ”*.txt.txt” (and any directories that are recursed in that file). then no filter will be applied to the files found under /home/foo/pcaps. $ snort --pcap-filter="*. the first filter will be applied to foo. the first filter ”*. Using filters $ cat foo.pcap foo3.cap” will be applied to files found under /home/foo/pcaps2. Read pcaps under a directory $ snort --pcap-dir="/home/foo/pcaps" This will include all of the files under /home/foo/pcaps.txt \ > --pcap-no-filter --pcap-dir=/home/foo/pcaps \ > --pcap-filter="*.pcap foo2.txt This will read foo1.pcap --pcap-file=foo. Read pcaps from a command line list $ snort --pcap-list="foo1.pcap. foo2. Note that Snort will not try to determine whether the files under that directory are really pcap files or not. then the filter ”*.pcap. so only files ending in ”. the first filter will be applied to foo. It includes total seconds and packets as well as packet processing rates. and only shown when non-zero. Snort ran for 0 days 0 hours 2 minutes 55 seconds Pkts/min: 1858011 Pkts/sec: 21234 =============================================================================== 1. minutes. Many of these are self-explanatory. The others are summarized below. If you are reading pcaps. • Outstanding indicates how many packets are buffered awaiting processing. For each pcap.856509 seconds Snort processed 3716022 packets. Snort will be reset to a post-configuration state.000%) 19 . 1. it will be like Snort is seeing traffic for the first time. etc. The rates are based on whole seconds.7 Basic Output Snort does a lot of work and outputs some useful statistics when it is done. the totals are for all pcaps combined. but after each pcap is read. Example: =============================================================================== Packet I/O Totals: Received: 3716022 Analyzed: 3716022 (100. 1. just the basics. unless you use –pcap-reset.2 Packet I/O Totals This section shows basic packet acquisition and injection peg counts obtained from the DAQ. • Injected packets are the result of active response which can be configured for inline or passive modes. • Filtered packets are not shown for pcap DAQs. meaning all buffers will be flushed..1 Timing Statistics This section provides basic timing statistics. This does not include all possible output data. The way this is counted varies per DAQ so the DAQ documentation should be consulted for more info.Resetting state $ snort --pcap-dir=/home/foo/pcaps --pcap-reset The above example will read all of the files under /home/foo/pcaps.7. statistics reset. in which case it is shown per pcap.7. etc. 817%) 20 .103%) ICMP: 38860 ( 1.000%) IP4/IP6: 0 ( 0.000%) GRE Loop: 0 ( 0.000%) GRE VLAN: 0 ( 0.000%) VLAN: 0 ( 0.000%) GRE IP6: 0 ( 0.000%) IP4/IP4: 0 ( 0.000%) EAPOL: 0 ( 0.511%) Teredo: 18 ( 0. • Disc counts are discards due to basic encoding integrity flaws that prevents Snort from decoding the packet.000%) GRE: 202 ( 0.000%) Injected: 0 =============================================================================== 1.7.000%) GRE PPTP: 202 ( 0.000%) ARP: 104840 ( 2.000%) MPLS: 0 ( 0.511%) IP6: 1781159 ( 47.044%) UDP6: 140446 ( 3.850%) IP6 Ext: 1787327 ( 48.005%) GRE ARP: 0 ( 0.884%) Frag: 3839 (. session timeout.000%) GRE IPX: 0 ( 0.166%) Frag6: 3839 ( 0.000%) GRE IP6 Ext: 0 ( 0.000%) IP6/IP4: 0 ( 0.000%) IP4: 1782394 ( 47.773%) TCP6: 1619633 ( 43. • S5 G 1/2 is the number of client/server sessions stream5 flushed due to cache limit.103%) ICMP6: 1650 ( 0. Example: =============================================================================== Breakdown by protocol (includes rebuilt packets): Eth: 3722347 (100.016%) IP6 Opts: 6168 ( 0.000%) Outstanding: 0 ( 0.000%) IP6/IP6: 0 ( 0.000%) GRE IP4: 0 ( 0.005%) GRE Eth: 0 ( 0.044%) UDP: 137162 ( 3. • Other includes packets that contained an encapsulation that Snort doesn’t decode.685%) TCP: 1619621 ( 43.Dropped: 0 ( 0. session reset.000%) ICMP-IP: 0 ( 0.000%) Filtered: 0 ( 0. • Log Limit counts events were not alerted due to the config event queue: • Event Limit counts events not alerted due to event filter limits. This can only happen in inline mode with a compatible DAQ. If not. • Block = packets Snort did not forward.7. snort will block each packet and this count will be higher.555%) Bad Chk Sum: 32135 ( 0. max queue events max queue • Queue Limit counts events couldn’t be stored in the event queue due to the config event queue: setting. • Replace = packets Snort modified. This information is only output in IDS mode (when snort is run with the -c <conf> option). ”Block” is used instead of ”Drop” to avoid confusion between dropped packets (those Snort didn’t actually see) and blocked packets (those Snort did not allow to pass).863%) Bad TTL: 0 ( 0. this is done by the DAQ or by Snort on subsequent packets. This is the case when a block TCP rule fires.000%) All Discard: 1385 ( 0. and block actions processed as determined by the rule actions. If the DAQ supports this in hardware.037%) Other: 57876 ( 1. Limits arise due to real world constraints on processing time and available memory. Like blacklist. eg due to a block rule. and reject actions. The default is 3. 21 . no further packets will be seen by Snort for that session.IPX: 60 ( 0. Verdicts are rendered by Snort on each packet: • Allow = packets Snort analyzed and did not take action on. Limits. due to normalization or replace rules. Like blacklist. this is done by the DAQ or by Snort on subsequent packets.000%) TCP Disc: 0 ( 0. log setting.044%) Total: 3722347 =============================================================================== 1. The default is 8. alert. • Alerts is the number of activate.037%) ICMP Disc: 0 ( 0.000%) S5 G 1: 1494 ( 0. • Whitelist = packets that caused Snort to allow a flow to pass w/o inspection by any analysis program. for example.000%) Eth Disc: 0 ( 0.000%) IP6 Disc: 0 ( 0. The default is 5.4 Actions. These indicate potential actions that did not happen: • Match Limit counts rule matches were not processed due to the config detection: setting.040%) S5 G 2: 1654 ( 0. Here block includes block. • Blacklist = packets that caused Snort to block a flow from passing. drop. • Ignore = packets that caused Snort to allow a flow to pass w/o inspection by this instance of Snort. and Verdicts Action and verdict counts show what Snort did with the packets it analyzed.000%) IP4 Disc: 0 ( 0.002%) Eth Loop: 0 ( 0.000%) UDP Disc: 1385 ( 0. one still needs to use the configuration option: $ . an extra configuration option is necessary: $ .8. Scenarios such as Eth IPv4 GRE IPv4 GRE IPv4 TCP Payload or Eth IPv4 IPv6 IPv4 TCP Payload will not be handled and will generate a decoder alert.g.000%) =============================================================================== 1.000%) Logged: 0 ( 0.1 Multiple Encapsulations Snort will not decode more than one encapsulation.000%) Blacklist: 0 ( 0.000%) Match Limit: 0 Queue Limit: 0 Log Limit: 0 Event Limit: 0 Verdicts: Allow: 3716022 (100. IP in IP and PPTP.000%) Whitelist: 0 ( 0. only the encapsulated part of the packet is logged./configure --enable-gre To enable IPv6 support./configure --enable-ipv6 1. 1.2 Logging Currently.000%) Passed: 0 ( 0. Eth IP1 GRE IP2 TCP Payload gets logged as Eth IP2 TCP Payload 22 .000%) Block: 0 ( 0.000%) Replace: 0 ( 0.000%) Ignore: 0 ( 0.8. e.8 Tunneling Protocol Support Snort supports decoding of GRE. To enable support.Example: =============================================================================== Action Stats: Alerts: 0 ( 0. /usr/local/bin/snort -c /usr/local/etc/snort. the daemon creates a PID file in the log directory. the --pid-path command line switch causes Snort to write the PID file in the directory specified.9 Miscellaneous 1.9.1 Running Snort as a Daemon If you want to run Snort as a daemon. you might need to use the –dump-dynamic-rules option. is not currently supported on architectures that require word alignment such as SPARC. Use the --nolock-pidfile switch to not lock the PID file. Additionally. Please notice that if you want to be able to restart Snort by sending a SIGHUP signal to the daemon. The PID file will be locked so that other snort processes cannot start. which utilizes GRE and PPP.and Eth IP1 IP2 TCP Payload gets logged as Eth IP2 TCP Payload ! △NOTE Decoding of PPTP. Snort PID File When Snort is run as a daemon . the --create-pidfile switch can be used to force creation of a PID file even when not running in daemon mode.168. you can the add -D switch to any combination described in the previous sections. you must specify the full path to the Snort binary when you start it. 1.2 Running in Rule Stub Creation Mode If you need to dump the shared object rules stub to a directory.1. 1.0/24 \ -l /var/log/snortlogs -c /usr/local/etc/snort.9.6. In Snort 2. The path can be relative or absolute. for example: /usr/local/bin/snort -d -h 192. 23 .conf -s -D Relative paths are not supported due to security concerns. These rule stub files are used in conjunction with the shared object rules.conf \ --dump-dynamic-rules=/tmp This path can also be configured in the snort. 1.4 Specifying Multiple-Instance Identifiers In Snort v2.168.conf: config dump-dynamic-rules-path: /tmp/sorules In the above mentioned scenario the dump path is set to /tmp/sorules.conf \ --dump-dynamic-rules snort.1. You can also combine the -O switch with the -h switch to only obfuscate the IP addresses of hosts on the home network.5 Snort Modes Snort can operate in three different modes namely tap (passive). and inline-test. inline. This option can be used when running multiple instances of snort. obfuscating only the addresses from the 192.. Snort policies can be configured in these three modes too.168.9. it acts as an IPS allowing drop rules to trigger. Snort can be configured to run in inline-test mode using the command line option (–enable-inline-test) or using the snort config option policy mode as follows: 24 . you might want to use the -O switch. Each Snort instance will use the value specified to generate unique event IDs.9.3 Obfuscating IP Address Printouts If you need to post packet logs to public mailing lists. Snort can be configured to passive mode using the snort config option policy mode as follows: config policy_mode:tap • Inline-Test Inline-Test mode simulates the inline mode of snort. Drop rules are not loaded (without –treat-drop-as-alert). or on the same CPU but a different interface. This is useful if you don’t care who sees the address of the attacking host.9. For example. This switch obfuscates your IP addresses in packet printouts. Users can specify either a decimal value (-G 1) or hex value preceded by 0x (-G 0x11). The drop rules will be loaded and will be triggered as a Wdrop (Would Drop) alert. the -G command line option was added that specifies an instance identifier for the event logs.0/24 1./snort -d -v -r snort. This is also supported via a long option --logid.0/24 class C network: ./usr/local/bin/snort -c /usr/local/etc/snort. you could use the following command to read the packets from a log file and dump them to the screen. Explanation of Modes • Inline When Snort is in Inline mode. it acts as a IDS. allowing evaluation of inline behavior without affecting traffic. 1.log -O -h 192.4. either on different CPUs.. The Snort manual page and the output of snort -? or snort --help contain information that can help you get Snort running in several different modes. 25 .net provide informative announcements as well as a venue for community discussion and support. so you may have to type snort -\? instead of snort -? for a list of Snort command line options.10 More Information Chapter 2 contains much information about many configuration options available in the configuration file.com/?l=snort-users at snort-users@lists.theaimsgroup.snort. The Snort web page (. ! △NOTE In many shells.snort --enable-inline-test config policy_mode:inline_test ! △NOTE Please note –enable-inline-test cannot be used in conjunction with -Q. a backslash (\) is needed to escape the ?.org) and the Snort Users mailing list:. so sit back with a beverage of your choosing and read the documentation and mailing list archives. There’s a lot to Snort.sourceforge. 0/24.1.1. ipvar. msg:"SYN packet". 2.0/24] alert tcp any any -> $MY_NET $MY_PORTS (flags:S. use a regular ’var’.1.2 for more information on defining and using variables in Snort config files. reading the contents of the named file and adding the contents in the place where the include statement appears in the file.conf indicated on the Snort command line. Without IPv6 support.1024:1050] ipvar MY_NET [192.1.10.1.rule 26 . See Section 2.168.) include $RULE_PATH/example.Chapter 2 Configuring Snort 2. It works much like an #include from the C programming language. Note: ’ipvar’s These are simple substitution variables set with the var.1. 2.80. Note that there Included files will substitute any predefined variable values into their own variable references.1 Format include <include file path/name> ! △NOTE is no semicolon at the end of this line.2 Variables Three types of variables may be defined in Snort: • var • portvar • ipvar ! △NOTE are only enabled with IPv6 support.1 Includes The include keyword allows other snort config files to be included within the snort. or portvar keywords as follows: var RULES_PATH rules/ portvar MY_PORTS [22. 3]] The order of the elements in the list does not matter. each element in a list was logically OR’ed together.1.2. IP variables should be specified using ’ipvar’ instead of ’var’.0/8.1. negated IP ranges that are more general than non-negated IP ranges are not allowed.1.3.1.1. See below for some valid examples if IP variables and IP lists.2 and 2. sid:1. [1.2.1.2.3]] alert tcp $EXAMPLE any -> any any (msg:"Example". Negation is handled differently compared with Snort versions 2. Valid port ranges are from 0 to 65535.1.2. and CIDR blocks may be negated with ’!’.![2. with the exception of IPs 2.1.2. The element ’any’ can be used to match all IPs.!1.) Different use of !any: ipvar EXAMPLE !any alert tcp $EXAMPLE any -> any any (msg:"Example". but ’!any’ is not allowed. IP lists.!1.) Logical contradictions: ipvar EXAMPLE [1.1.1. The following example list will match the IP 1. in a list.0/24.2.2. Previously. ’any’ will specify any ports.255.2.2.1.1.1. but it will be deprecated in a future release. Lists of ports must be enclosed in brackets and port ranges may be specified with a ’:’.2.1] Nonsensical negations: ipvar EXAMPLE [1.0/16] Port Variables and Port Lists Portlists supports the declaration and lookup of ports and the representation of lists and ranges of ports.1. Also.) The following examples demonstrate some invalid uses of IP variables and IP lists. Also.2.888:900] 27 . such as in: [10:50.2.sid:3.2. or any combination of the three.2.2.2.IP Variables and IP Lists IPs may be specified individually.x and earlier.![2. IPs.0. as a CIDR block.1.0/24.2. or lists may all be negated with ’!’.1.2. ranges. IP lists now OR non-negated elements and AND the result with the OR’ed negated elements.0.2.1.2. Variables. ipvar EXAMPLE [1.0.2.!1.2. Use of !any: ipvar EXAMPLE any alert tcp !$EXAMPLE any -> any any (msg:"Example". although ’!any’ is not allowed.) alert tcp [1.2.0/24.0 to 2. If IPv6 support is enabled.7.0/24] any -> any any (msg:"Example".sid:3.2.2. Using ’var’ for an IP variable is still allowed for backward compatibility.sid:2.1.2.1 and IP from 2. provided the variable name either ends with ’ PORT’ or begins with ’PORT ’. For backwards compatibility. These can be used with the variable modifier operators ? and -. sid:2. The following examples demonstrate several valid usages of both port variables and port lists.) alert tcp any $PORT_EXAMPLE2 -> any any (msg:"Example". sid:3.100:200] alert tcp any $EXAMPLE1 -> any $EXAMPLE2_PORT (msg:"Example". as described in the following table: 28 . sid:1.!80] Ports out of range: portvar EXAMPLE7 [65536] Incorrect declaration and use of a port variable: var EXAMPLE8 80 alert tcp any $EXAMPLE8 -> any any (msg:"Example".9999:20000] (msg:"Example".Port variables should be specified using ’portvar’. The use of ’var’ to declare a port variable will be deprecated in a future release.91:95. sid:5. You can define meta-variables using the $ operator.) Variable Modifiers Rule variable names can be modified in several ways.) Port variable used as an IP: alert tcp $EXAMPLE1 any -> any any (msg:"Example". sid:4.) Several invalid examples of port variables and port lists are demonstrated below: Use of !any: portvar EXAMPLE5 !any var EXAMPLE5 !any Logical contradictions: portvar EXAMPLE6 [80. portvar EXAMPLE1 80 var EXAMPLE2_PORT [80:90] var PORT_EXAMPLE2 [1] portvar EXAMPLE3 any portvar EXAMPLE4 [!70:90] portvar EXAMPLE5 [80. a ’var’ can still be used to declare a port variable.) alert tcp any 90 -> any [100:1000. They should be renamed instead: Invalid redefinition: var pvar 80 portvar pvar 90 2. types can not be mixed.0/24 log tcp any any -> $(MY_NET:?MY_NET is undefined!) 23 Limitations When embedding variables. variables can not be redefined if they were previously defined as a different type.1. Here is an example of advanced variable usage in action: ipvar MY_NET 192.168.90] Likewise. Replaces the contents of the variable var with “default” if var is undefined. but old-style variables (with the ’var’ keyword) can not be embedded inside a ’portvar’. Replaces with the contents of variable var or prints out the error message and exits. Valid embedded variable: portvar pvar1 80 portvar pvar2 [$pvar1. Format config <directive> [: <value>] 29 .90] Invalid embedded variable: var pvar1 80 portvar pvar2 [$pvar1. port variables can be defined in terms of other port variables. For instance. Replaces with the contents of variable var.1. If Snort was configured to enable decoder and preprocessor rules. Decodes Layer2 headers (snort -e). Default (with or without directive) is enabled. udp. noudp. Types of packets to calculate checksums. Values: none. noicmp. Global configuration directive to enable or disable the loading of rules into the detection engine. See Section 3. notcp. Forks as a daemon (snort -D). udp. See the DAQ distro README for possible DAQ modes or list DAQ capabilities for a brief summary). Chroots to specified dir (snort -t). tcp. icmp or all (only applicable in inline mode and for packets checked per checksum mode config option). You can also preceed this option with extra DAQ directory options to look in multiple directories. Sets the alerts output file. Specifies the maximum number of nodes to track when doing ASN1 decoding. Not all DAQs support modes. this option will cause Snort to revert back to it’s original behavior of alerting if the decoder or preprocessor generates an event. The selected DAQ will be the one with the latest version. ip. Select the DAQ mode: passive. noip.2 for a list of classifications.31 for more information and examples. Values: none.5. Snort just passes this information down to the DAQ. notcp. This can be repeated. See the DAQ distro README for possible DAQ variables. Specify disabled to disable loading rules. See Table 3. Types of packets to drop if invalid checksums. Selects the type of DAQ to instantiate. inline. You can optionally specify a directory to include any dynamic DAQs from that directory. Set a DAQ specific variable. Specifies BPF filters (snort -F). The DAQ with the highest version of the given type is selected if there are multiple of the same type (this includes any built-in DAQs). noicmp. or read-file. noudp. Tell Snort where to look for available dynamic DAQ modules. tcp. 30 . ip. icmp or all. Tell Snort to dump basic DAQ capabilities and exit. noip. Intel CPM library (must have compiled Snort with location of libraries to enable this) – No queue search methods .config detection: <method>] [search-method Select type of fast pattern matcher algorithm to use.Aho-Corasick Full with ANYANY port group evaluated separately (low memory. moderate performance) ∗ ac-sparsebands .Aho-Corasick Standard (high memory. Note this is shorthand for search-method ac.Aho-Corasick Full (high memory.Matches are queued until the fast pattern matcher is finished with the payload. ∗ ac-nq . moderate performance) ∗ ac-split . high performance) ∗ acs . best performance).Aho-Corasick Sparse (high memory. best performance). high performance) ∗ lowmem and lowmem-q . high performance). This is the default search method if none is specified. split-any-any ∗ intel-cpm .Low Memory Keyword Trie (low memory.Aho-Corasick Binary NFA (low memory. This was found to generally increase performance through fewer cache misses (evaluating each rule would generally blow away the fast pattern matcher state in the cache). ∗ ac and ac-q .Aho-Corasick Banded (high memory.Low Memory Keyword Trie (low memory. ∗ ac-bnfa and ac-bnfa-q . moderate performance) 31 .Aho-Corasick SparseBanded (high memory.The ”nq” option specifies that matches should not be queued and evaluated as they are found. moderate performance) ∗ ac-banded .Aho-Corasick Full (high memory. moderate performance) – Other search methods (the above are considered superior to these) ∗ ac-std . ∗ ac-bnfa-nq . • search-method <method> – Queued match search methods . ∗ lowmem-nq . high performance). then evaluated.Aho-Corasick Binary NFA (low memory. some fail-state resolution will be attempted. • search-optimize – Optimizes fast pattern memory when used with search-method ac or ac-split by dynamically determining the size of a state based on the total number of states. Default is to not set a maximum pattern length. • split-any-any – A memory/performance tradeoff. But doing so may require two port group evaluations per packet . Of note is that the lower memory footprint can also increase performance through fewer cache misses. Useful when there are very long contents being used and truncating the pattern won’t diminish the uniqueness of the patterns..e. Patterns longer than this length will be truncated to this length before inserting into the pattern matcher. 32 . By default. potentially increasing performance.config detection: [split-any-any] [search-optimize] [max-pattern-len <int>] Other options that affect fast pattern matching. Note that this may cause more false positive rule evaluations. Default is not to split the ANY-ANY port group. however CPU cache can play a part in performance so a smaller memory footprint of the fast pattern matcher can potentially increase performance. rules that will be evaluated because a fast pattern was matched.one for the specific port group and one for the ANY-ANY port group. but eventually fail. Not putting the ANY-ANY port rule group into every other port group can significantly reduce the memory footprint of the fast pattern matchers if there are many ANYANY port rules. ANYANY port rules are added to every non ANY-ANY port group so that only one port group rule evaluation needs to be done per packet. i. Default is not to optimize. thus potentially reducing performance. • max-pattern-len <integer> – This is a memory optimization that specifies the maximum length of a pattern that will be put in the fast pattern matcher. Default is 1024. 33 . Not recommended. Default is 5 events.. Default is to inspect stream inserts. • max queue events <integer> – Specifies the maximum number of events to queue per packet. config detection: [debug] Options for detection engine debugging. • debug-print-rule-group-build-details – Prints port group information during port group compilation. Turns off alerts generated by T/TCP options. Dumps raw packet starting at link layer (snort -X). [debug-print-fast-pattern] [bleedover-warnings-enabled] • debug-print-nocontent-rule-tests – Prints port group information during packet evaluation. config disable decode alerts config disable inline init failopen Turns off the alerts generated by the decode phase of Snort. Only useful if Snort was configured with –enable-inline-init-failopen.-groups-compiled – Prints compiled port group information. Turns off alerts generated by T/TCP options. Turns on character dumps (snort -C). • debug-print-fast-pattern – For each rule with fast pattern content. Enables the dropping of bad packets identified by decoder (only applicable in inline mode). • bleedover-warnings-enabled – Prints a warning if the number of source or destination ports used in a rule exceed the bleedover-port-limit forcing the rule to be moved into the ANY-ANY port group. Disables failopen thread that allows inline traffic to pass while Snort is starting up. 34 . prints information about the content being used for the fast pattern matcher. config enable decode oversized alerts Enable alerting on packets that have headers containing length fields for which the value is greater than the length of the packet. [debug-print-nocontent-rule-tests] [debug-print-rule-group-build-details] • debug [debug-print-rule-groups-uncompiled] – Prints fast pattern information for a particular port [debug-print-rule-groups-compiled] group. (snort --disable-inline-init-failopen) Disables IP option length validation alerts. Turns off alerts generated by experimental TCP options. Dumps application layer (snort -d). • debug-print-rule-groups-uncompiled – Prints uncompiled port group information. Disables option length validation alerts. Snort’s packet decoder only decodes Teredo (IPv6 over UDP over IPv4) traffic on UDP port 3544. The default is 1024 bits and maximum is 2096. config flowbits size: config ignore ports: <port-list> config interface: <num-bits> <proto> <iface> 35 . this configuration option should not be turned on. (only applicable in inline mode). You can use the following options: • max queue <integer> (max events supported) • log <integer> (number of events to log) • order events [priority|content length] (how to order events within the queue) See Section 2. When this option is off and MPLS multicast traffic is detected. Enables the dropping of bad packets with bad/truncated IP options (only applicable in inline mode). it is off. (only applicable in inline mode). However. This option makes Snort decode Teredo traffic on all UDP ports.4 for more information and examples. Default is 1048576 bytes (1 megabyte). enable decode oversized alerts must also be enabled for this to be effective (only applicable in inline mode). Enables the dropping of bad packets with experimental TCP option. This option is needed when the network allows MPLS multicast traffic. followed by a list of ports. there could be situations where two private networks share the same IP space and different MPLS labels are used to differentiate traffic from the two VPNs. this configuration option should be turned on. Enables the dropping of bad packets with obsolete TCP option. Enables the dropping of bad packets with bad/truncated TCP option (only applicable in inline mode). In a normal situation. Specifies ports to ignore (useful for ignoring noisy NFS traffic). Enables support for overlapping IP addresses in an MPLS network. Enables support for MPLS multicast. IP. Enables the dropping of bad packets with T/TCP option.4. By default. In such a situation. Specifies conditions about Snort’s event queue. it is off. Sets the network interface (snort -i). (only applicable in inline mode). Specify the protocol (TCP. Enables the dropping of bad packets with T/TCP option. where there are no overlapping IP addresses. UDP. By default. Port ranges are supported. Snort will generate an alert. or ICMP). Set global memcap in bytes for thresholding. Specifies the maximum number of flowbit tags that can be used within a rule set. (only applicable in inline mode). Print statistics on preprocessor performance. Obfuscates IP Addresses (snort -O). The default MPLS payload type is ipv4 Disables promiscuous mode (snort -p). 36 . up to the PCRE library compiled limit (around 10 million). Sets a Snort-wide MPLS payload type.before Snort has had a chance to load a previous configuration. which means that there is no limit on label chain length. Default is on) • bad ipv6 frag alert on|off (Specify whether or not to alert. it will limit the number of nested repeats within a pattern. For example. In addition to ipv4.). an error is logged and the remainder of the hosts are ignored. Sets a Snort-wide limit on the number of MPLS headers a packet can have. See Section 2. Disables pcre pattern matching. This option is used to avoid race conditions when modifying and loading a configuration within a short time span . up to the PCRE library compiled limit (around 10 million). Note: Alerts will still occur. ipv6 and ethernet are also valid options.5. Sets a Snort-wide minimum ttl to ignore all traffic. max frag sessions <max-track>] The following options can be used: • bsd icmp frag alert on|off (Specify whether or not to alert.5. (snort -N). Disables logging. binding version must be in any file configured with config binding. Print statistics on rule performance.config ipv6 frag: [bsd icmp frag alert on|off] [. Restricts the amount of backtracking a given PCRE option.7). Base version should be a string in all configuration files including included ones. Its default value is -1. This option is only supported with a Host Attribute Table (see section 2. frag timeout <secs>] [. Restricts the amount of stack used by a given PCRE option. The default is 10000. Minimum value is 32 and the maximum is 524288 (512k). This option is only useful if the value is less than the pcre match limit Exits after N packets (snort -n). See Section 2. bad ipv6 frag alert on|off] [. If the number of hosts in the attribute table exceeds this value. Changes the order that rules are evaluated. eg: pass alert log activation. A value of 0 results in no PCRE evaluation. Supply versioning information to configuration files. A value of 0 results in no PCRE evaluation.2 for more details. A value of -1 allows for unlimited PCRE. The snort default value is 1500. Sets a limit on the maximum number of hosts to read from the attribute table. A value of -1 allows for unlimited PCRE. In addition. The snort default value is 1500.1 for more details. Specifies a pcap file to use (instead of reading from network). inline or inline test. Default is 1048576 bytes (1 megabyte). (This is deprecated.5 on using the tag option when writing rules for more details. Preprocessor code is run before the detection 37 . See Section 3.config quiet config read bin file: config reference: <pcap> <ref> config reference net <cidr> config response: [attempts <count>] [. Set global memcap in bytes for so rules that dynamically allocate memory for storing session data in the stream preprocessor. That may occur after other configuration settings that result in output to console or syslog.conf is parsed. Default is 0. Default is 3600 (1 hour). Maximum value is the maximum value an unsigned 32 bit integer can hold which is 4294967295 or 4GB. Sets assurance mode for stream (stream is established). Sets the policy mode to either passive. They allow the functionality of Snort to be extended by allowing users and programmers to drop modular plugins into Snort fairly easily. Setting this option to a value of 0 will disable the packet limit. Set the number of strafing attempts per injected response and/or the device.). Uses verbose logging to STDOUT (snort -v). Sets UID to <id> (snort -u). Uses UTC instead of local time for timestamps (snort -U). the obfuscated net will be used if the packet contains an IP address in the reference net. When a metric other than packets is used in a tag option in a rule. Adds a new reference system to Snort. same effect as -P <snaplen> or --snaplen <snaplen> options. Set global memcap in bytes for thresholding. The default value when this option is not configured is 256 packets. this option sets the maximum number of packets to be tagged regardless of the amount defined by the other metric. Sets umask when running (snort -m). Use config event filter instead.com/?id= For IP obfuscation. same effect as -r <tf> option. Set the snaplength of packet. from which to send responses. Shows year in timestamps (snort -y).5 of Snort.7. NOTE: The command line switch -q takes effect immediately after processing the command line parameters. The are intended for passive mode. These options may appear in any order but must be comma separated. such as eth0. 2. eg: myref. whereas using config quiet in snort.conf takes effect when the configuration line in snort. A value of 0 disables the memcap. Changes GID to specified GID (snort -g). Note this option is only available if Snort was built to use time stats with --enable-timestats.2 Preprocessors Preprocessors were introduced in version 1. Also used to determine how to set up the logging directory structure for the session post detection rule option and ASCII output plugin an attempt is made to name the log directories after the IP address that is not in the reference net.) Set the amount of time in seconds between logging time stats. pdf. but only one global configuration. Target-based analysis is a relatively new concept in network-based intrusion detection. Target-based host modeling anti-evasion techniques.icir. Unfortunately. When IP stacks are written for different operating systems. it is possible to evade the IDS. For an IDS this is a big problem. The frag2 preprocessor used splay trees extensively for managing the data structures associated with defragmenting packets. There are at least two preprocessor directives required to activate frag3. As I like to say..snort.. This is where the idea for “target-based IDS” came from. We can also present the IDS with topology information to avoid TTL-based evasions and a variety of other issues.2. but that’s a topic for another day. Faster execution than frag2 with less complex data management. heavily fragmented environments the nature of the splay trees worked against the system and actually hindered performance. check out the famous Ptacek & Newsham paper at is called. For more detail on this issue and how it affects IDS. Once we have this information we can start to really change the game for these complex modeling problems.1 Frag3 The frag3 preprocessor is a target-based IP defragmentation module for Snort.. Frag 3 Configuration Frag3 configuration is somewhat more complex than frag2. if the attacker has more information about the targets on a network than the IDS does. Frag3 is intended as a replacement for the frag2 defragmentation module and was designed with the following goals: 1. There can be an arbitrary number of engines defined at startup with their own configuration. Preprocessors are loaded and configured using the preprocessor keyword. a global configuration directive and an engine instantiation. Check it out at. there are ambiguities in the way that the RFCs define some of the edge conditions that may occur and when this happens different people implement certain aspects of their IP stacks differently. Frag3 was implemented to showcase and prototype a target-based module within Snort to test this idea.org/vern/papers/activemap-oak03. they are usually implemented by people who read the RFCs and then write their interpretation of what the RFC outlines into code. Global Configuration 38 . 2. In an environment where the attacker can determine what style of IP defragmentation is being used on a particular target. but after the packet has been decoded. The format of the preprocessor directive in the Snort config file is: preprocessor <name>: <options> 2. IP List to bind this engine to. – disabled . bsd. Default value is all. – timeout <seconds> . – memcap <bytes> .Detect fragment anomalies. – max frags <number> . Anyone who develops more mappings and would like to add to this list please feel free to send us an email! 39 . The Paxson Active Mapping paper introduced the terminology frag3 is using to describe policy types. Use preallocated fragment nodes (faster in some situations). Default is 4MB.Maximum simultaneous fragments to track. last.Memory cap for self preservation. bsdright. if detect anomalies is also configured. Fragments in the engine for longer than this period will be automatically dropped. the minimum is ”0”. This is an optional parameter. – min fragment length <number> . – prealloc frags <number> . The accepted range for this option is 1 .255. The known mappings are as follows. Default is 8192. This is an optional parameter. Default is 60 seconds.Timeout for fragments. and prealloc frags are applied when specified with the configuration. Available types are first. detect anomalies option must be configured for this option to take effect. – detect anomalies . When the preprocessor is disabled only the options memcap.Alternate memory management mode.• Preprocessor name: frag3 global • Available options: NOTE: Global configuration options are comma separated. – policy <type> .Select a target-based defragmentation mode.Limits the number of overlapping fragments per packet. – bind to <ip list> . prealloc memcap. – min ttl <value> . linux.Minimum acceptable TTL value for a fragment packet. Fragments smaller than or equal to this limit are considered malicious and an event is raised.Option to turn off the preprocessor. The default is ”0” (unlimited). This engine will only run for packets with destination addresses contained within the IP List.Defines smallest fragment size (payload size) that should be considered valid. – overlap limit <number> . Default type is bsd. Engine Configuration • Preprocessor name: frag3 engine • Available options: NOTE: Engine configuration options are space separated. Default is 1. This config option takes values equal to or greater than zero. detect anomalies option must be configured for this option to take effect. The default is ”0” (unlimited). By default this option is turned off. 8 Tru64 Unix V5.4 (RedHat 7.4 Linux 2.0/24 policy first.V5 OSF1 V3.7-10 Linux 2.3 IRIX64 6.2 IRIX 6.2smp Linux 2.0.5F IRIX 6.2. Packets that don’t fall within the address requirements of the first two engines automatically fall through to the third one.1 OS/2 (version unknown) OSF1 V3.5.10.5.0.5.Platform AIX 2 AIX 4.9-31SGI 1.8.47. first and last policies assigned.5.0A. The first two engines are bound to specific IP address ranges and the last one applies to all other traffic. detect_anomalies 40 .1.16-3 Linux 2.0.5.9.16.0.19-6.168.00 IRIX 4.0/24.20 HP-UX 11.2.2.10 Linux 2.6.14-5.10smp Linux 2.2.3) MacOS (version unknown) NCD Thin Clients OpenBSD (version unknown) OpenBSD (version unknown) OpenVMS 7.1.2.5.4.3 8.172.1 SunOS 4.1-7.4 SunOS 5.7.0 Linux 2.2 OSF1 V4.1.1.4.3 Cisco IOS FreeBSD HP JetDirect (printer) HP-UX B.0/24] policy last. bind_to [10. Stream5 Global Configuration Global settings for the Stream5 preprocessor.2 Stream5 The Stream5 preprocessor is a target-based TCP reassembly module for Snort. UDP sessions are established as the result of a series of UDP packets from two end points via the same set of ports. \ [memcap <number bytes>]. data received outside the TCP window. With Stream5. \ [track_udp <yes|no>]. \ [prune_log_max <bytes>]. Read the documentation in the doc/signatures directory with filenames that begin with “123-” for information on the different event types. like Frag3. etc) that can later be used by rules. The methods for handling overlapping data. etc. Anomaly Detection TCP protocol anomalies. Stream API Stream5 fully supports the Stream API. [max_udp <number>]. FIN and Reset sequence numbers. the rule ’flow’ and ’flowbits’ keywords are usable with TCP as well as UDP traffic. [max_icmp <number>]. Transport Protocols TCP sessions are identified via the classic TCP ”connection”. For example. and update the identifying information about the session (application protocol.Frag 3 Alert Output Frag3 is capable of detecting eight different types of anomalies.2. introduces target-based actions for handling of overlapping data and other TCP anomalies. Its event output is packet-based so it will work with all output modes of Snort. \ [flush_on_alert]. [disabled] 41 . Target-Based Stream5. etc). ICMP messages are tracked for the purposes of checking for unreachable and service unavailable messages. [show_rebuilt_packets]. a few operating systems allow data in TCP SYN packets. which effectively terminate a TCP or UDP session. identify sessions that may be ignored (large data transfers. Data on SYN. other protocol normalizers/preprocessors to dynamically configure reassembly behavior as required by the application layer protocol. TCP Timestamps. [max_tcp <number>]. \ [track_icmp <yes|no>]. Some of these anomalies are detected on a per-target basis. preprocessor stream5_global: \ [track_tcp <yes|no>]. It is capable of tracking sessions for both TCP and UDP. and the policies supported by Stream5 are the results of extensive research with many target operating systems. etc are configured via the detect anomalies option to the TCP configuration. 2. such as data on SYN packets. while others do not. direction. Session timeout. \ [overlap_limit <number>]. Track sessions for UDP. [max_window <number>]. Memcap for TCP packet storage. maximum is ”1048576”. [use_static_footprint_sizes]. [max_queued_segs <number segs>]. Backwards compatibility. One default policy must be specified. \ [timeout <number secs>]. Stream5 TCP Configuration Provides a means on a per IP address target to configure TCP policy. maximum is ”1048576”. The default is set to off. This can have multiple occurrences. By default this option is turned off. minimum can be either ”0” (disabled) or if not disabled the minimum is ”1024” and maximum is ”1073741824”. \ [require_3whs [<number secs>]]. preprocessor stream5_tcp: \ [bind_to <ip_addr>]. [flush_factor <number segs>] Option bind to <ip addr> timeout <num seconds> Description IP address or network for this policy. [detect_anomalies]. The default is set to any. The default is ”30”. The default is ”yes”. minimum is ”1”. \ [dont_store_large_packets]. 42 . max udp and max icmp are applied when specified with the configuration. Maximum simultaneous ICMP sessions tracked. \ [ports <client|server|both> <all|number [number]*>]. [policy <policy_id>]. \ [check_session_hijacking]. and that policy is not bound to an IP address or network. Flush a TCP stream when an alert is generated on that stream. The default is ”131072”. Track sessions for ICMP. The default is set to off. The default is ”65536”. the minimum is ”1”. minimum is ”1”. [dont_reassemble_async]. minimum is ”1”. The default is ”8388608” (8MB). Maximum simultaneous TCP sessions tracked. The default is ”1048576” (1MB). When the preprocessor is disabled only the options memcap. maximum is ”1048576”. The default is ”yes”. maximum is ”1073741824” (1GB). \ [protocol <client|server|both> <all|service name [service name]*>]. The default is ”no”. Print/display packet after rebuilt (for debugging). minimum is ”32768” (32KB). Print a message when a session terminates that was consuming more than the specified number of bytes. max tcp. per policy that is bound to an IP address or network. Option to disable the stream5 tracking. \ [max_queued_bytes <bytes>]. The default is ”262144”. and the maximum is ”86400” (approximately 1 day). Maximum simultaneous UDP sessions tracked. \ [ignore_any_rules]. Detect and alert on TCP protocol anomalies. and a maximum of ”1073741824” (1GB).x and newer linux Linux 2. the minimum is ”0”. and the maximum is ”255”. Establish sessions only on completion of a SYN/SYN-ACK/ACK handshake. and the maximum is ”1073725440” (65535 left shift 14). the minimum is ”0”. 43 . The default is set to off. The default is set to off. The default is set to off. The default is set to queue packets.x and newer. Check for TCP session hijacking. Windows XP. The default is set to off. Default is ”1048576” (1MB).3 and newer Limits the number of overlapping packets per session. Using this option may result in missed attacks. Use static values for determining when to build a reassembled packet to allow for repeatable tests. A value of ”0” means unlimited. there are no checks performed.policy <policy id> overlap limit <number> max window <number> require 3whs [<number seconds>] detect anomalies check session hijacking use static footprint sizes dont store large packets dont reassemble async max queued bytes <bytes> The Operating System policy for the target OS. last Favor first overlapped segment. The policy id can be one of the following: Policy Name Operating Systems. Maximum TCP window allowed. This option should not be used production environments. The optional number of seconds specifies a startup timeout. Don’t queue packets for reassembly if traffic has not been seen in both directions. The default is set to off. so using a value near the maximum is discouraged. Limit the number of bytes queued for reassembly on a given TCP session to bytes. NetBSD 2. and the maximum is ”86400” (approximately 1 day).4 and newer old-linux Linux 2. That is the highest possible TCP window per RFCs. with a non-zero minimum of ”1024”. If an ethernet layer is not part of the protocol stack received by Snort. OpenBSD 3. The default is ”0” (don’t consider existing sessions established).x and newer. The default is ”0” (unlimited).2 and earlier windows Windows 2000. This option is intended to prevent a DoS against Stream5 by an attacker using an abnormally large window. the minimum is ”0”. Performance improvement to not queue large packets in reassembly buffer. The default is ”0” (unlimited).. Windows 95/98/ME win2003 Windows 2003 Server vista Windows Vista solaris Solaris 9.x and newer hpux HPUX 11 and newer hpux10 HPUX 10 irix IRIX 6 and newer macos MacOS 10. first Favor first overlapped segment. bsd FresBSD 4. This allows a grace period for existing sessions to be considered established during that interval immediately after Snort is started. A message is written to console/syslog when this limit is enforced. 3) or others specific to the network. Specify the client. ! NOTE △no options are specified for a given TCP policy.7). or byte test options. Rules that have flow or flowbits will never be ignored. server. Since there is no target based binding.max queued segs <num> ports <client|server|both> <all|number(s)> protocol <client|server|both> <all|service name(s)> ignore any rules flush factor Limit the number of segments queued for reassembly on a given TCP session. The default is ”off”. PCRE. there should be only one occurrence of the UDP configuration. or byte test options. only those with content. If only a bind to option is If used with no other options that TCP policy uses all of the default values. including any of the internal defaults (see 2. The default is ”2621”. This can appear more than once in a given config. a UDP rule will be ignored except when there is another port specific rule With the ignore that may be applied to the traffic. preprocessor stream5_udp: [timeout <number secs>]. The default settings are ports client 21 23 25 42 53 80 110 111 135 136 137 139 143 445 513 514 1433 1521 2401 3306. if a UDP rule specifies destination port 53. For example. Specify the client. that is the default TCP policy. The default is ”off”. derived based on an average size of 400 bytes. and the maximum is ”86400” (approximately 1 day). or both and list of ports in which to perform reassembly. the minimum is ”1”. A message is written to console/syslog when this limit is enforced. This can appear more than once in a given config. Don’t process any -> any (ports) rules for UDP that attempt to match payload if there are no port specific rules for the src or destination port. PCRE. Using this does not affect rules that look at protocol headers. and a maximum of ”1073741824” (1GB). Using this does not affect rules that look at protocol headers. The service names can be any of those used in the host attribute table (see 2. [ignore_any_rules] Option timeout <num seconds> ignore any rules Description Session timeout. but NOT to any other source or destination port. or both and list of services in which to perform reassembly.7. A value of ”0” means unlimited. Stream5 UDP Configuration Configuration for UDP session tracking. The drop in size often indicates an end of request or response. This is a performance improvement and may result in missed attacks. The minimum port allowed is ”1” and the maximum allowed is ”65535”. This is a performance improvement and may result in missed attacks. Rules that have flow or flowbits will never be ignored. This option can be used only in default policy. server. A list of rule SIDs affected by this option are printed at Snort’s startup. only those with content. The default is ”30”. Don’t process any -> any (ports) rules for TCP that attempt to match payload if there are no port specific rules for the src or destination port. the ’ignored’ any -> any rule will be applied to traffic to/from port 53. Useful in ips mode to flush upon seeing a drop in segment size after N segments of non-decreasing size. The default settings are ports client ftp telnet smtp nameserver dns http pop3 sunrpc dcerpc netbios-ssn imap login shell mssql oracle cvs mysql. ! △NOTE any rules option. 44 . with a non-zero minimum of ”2”. 1. most queries sent by the attacker will be negative (meaning that the service ports are closed). and the maximum is ”86400” (approximately 1 day). one for Windows and one for Linux.3 sfPortscan The sfPortscan module. track_tcp yes. The default is ”30”. and rarer still are multiple negative responses within a given amount of time. the ignore any rules option will be disabled in this case. This configuration maps two network segments to different OS policies. track_udp yes.1. With the ignore the ignore any rules option is effectively pointless. an attacker determines what types of network protocols or services a host supports. if a UDP rule that uses any -> any ports includes either flow or flowbits. developed by Sourcefire. this phase would not be necessary. In the nature of legitimate network communications. otherwise. use_static_footprint_sizes preprocessor stream5_udp: \ ignore_any_rules 2. Since there is no target based binding.2. It is not ICMP is currently turned on by default. Example Configurations 1. track_icmp no preprocessor stream5_tcp: \ policy first. policy windows stream5_tcp: bind_to 10.1. policy linux stream5_tcp: policy solaris 2.! △NOTE any rules option.0/24. This example configuration is the default configuration in snort.0/24. 45 . ! △NOTE untested. Because of the potential impact of disabling a flowbits rule. the minimum is ”1”. negative responses from hosts are rare. This phase assumes the attacking host has no prior knowledge of what protocols or services are supported by the target. is designed to detect the first phase in a network attack: Reconnaissance. This is the traditional place where a portscan takes place. Our primary objective in detecting portscans is to detect and track these negative responses. preprocessor stream5_global: \ max_tcp 8192. in minimal code form and is NOT ready for use in production networks. preprocessor preprocessor preprocessor preprocessor stream5_global: track_tcp yes stream5_tcp: bind_to 192. with all other traffic going to the default policy of Solaris. Stream5 ICMP Configuration Configuration for ICMP session tracking. As the attacker has no beforehand knowledge of its intended target.168.conf and can be used for repeatable tests of stream reassembly in readback mode. there should be only one occurrence of the ICMP configuration. preprocessor stream5_icmp: [timeout <number secs>] Option timeout <num seconds> Description Session timeout. In the Reconnaissance phase. sfPortscan alerts on the following filtered portscans and portsweeps: 46 . This tactic helps hide the true identity of the attacker. One host scans a single port on multiple hosts. Distributed portscans occur when multiple hosts query one host for open services. if an attacker The characteristics portsweeps a web farm for port 80.. if not all. This usually occurs when a new exploit comes out and the attacker is looking for a specific service. This is used to evade an IDS and obfuscate command and control hosts. so we track this type of scan through the scanned Negative queries host. of the current portscanning techniques. Nmap encompasses many. sfPortscan alerts for the following types of portsweeps: • TCP Portsweep • UDP Portsweep • IP Portsweep • ICMP Portsweep These alerts are for one→many portsweeps. ! △NOTE of a portsweep scan may not result in many negative responses. only the attacker has a spoofed source address inter-mixed with the real scanning address. sfPortscan will currently alert for the following types of Nmap scans: • TCP Portscan • UDP Portscan • IP Portscan These alerts are for one→one portscans. one host scans multiple ports on another host. sfPortscan was designed to be able to detect the different types of scans Nmap can produce. which are the traditional types of scans. we will most likely not see many negative responses.One of the most common portscanning tools in use today is Nmap. since most hosts have relatively few services available. sfPortscan alerts for the following types of distributed portscans: • TCP Distributed Portscan • UDP Distributed Portscan • IP Distributed Portscan These are many→one portscans. ! △NOTE will be distributed among scanning hosts. For example. Most of the port queries will be negative. but tags based on the original scan alert. sfPortscan Configuration Use of the Stream5 preprocessor is required for sfPortscan. Open port events are not individual alerts.2.2. sfPortscan only generates one alert for each host pair in question during the time window (more on windows below). Active hosts.conf. such as NATs. You should enable the Stream preprocessor in your snort. It’s also a good indicator of whether the alert is just a very active legitimate host. proto <protocol> Available options: • TCP • UDP • IGMP • ip proto • all 2. A filtered alert may go off before responses from the remote hosts are received. Stream gives portscan direction in the case of connectionless protocols like ICMP and UDP. On TCP scan alerts. On TCP sweep alerts however. as described in Section 2. can trigger these alerts because they can send out many connection attempts within a very small amount of time. The parameters you can use to configure the portscan module are: 1. sfPortscan will only track open ports after the alert has been triggered. scan type <scan type> Available options: • portscan • portsweep • decoy portscan 47 . sfPortscan will also display any open ports that were scanned. so the user may need to deploy the use of Ignore directives to properly tune this directive. watch ip <ip1|ip2/cidr[ [port|port2-port3]]> Defines which IPs. • medium . this can lead to false alerts. 5. disabled This optional keyword is allowed with any policy to avoid packet processing. 6. especially under heavy load with dropped packets. Any valid configuration may have ”disabled” added to it. which is why the option is off by default. 9.. IP address using CIDR notation. However. especially under heavy load with dropped packets. and because of the nature of error responses.“Medium” alerts track connection counts. which is necessary to detect ACK scans. detect ack scans This option will include sessions picked up in midstream by the stream module. • high . networks. A ”High” setting will catch some slow scans because of the continuous monitoring. after which this window is reset. This most definitely will require the user to tune sfPortscan. 7. logfile <file> This option will output portscan events to the file specified. This option disables the preprocessor. This setting may false positive on active hosts (NATs. proxies.“Low” alerts are only generated on error packets sent from the target host. If file does not contain a leading slash. and so will generate filtered scan alerts. this setting should see very few false positives. The parameter is the same format as that of watch ip. 10. but is very sensitive to active hosts. The other options are parsed but not used. include midstream This option will include sessions picked up in midstream by Stream5. and specific ports on those hosts to watch. Optionally. IPs or networks not falling into this range are ignored if this option is used. ignore scanned <ip1|ip2/cidr[ [port|port2-port3]]> Ignores the destination of scan alerts. this file will be placed in the Snort config dir. However. which is why the option is off by default.• distributed portscan • all 3. this setting will never trigger a Filtered Scan alert because of a lack of error responses. This can lead to false 48 . When the preprocessor is disabled only the memcap option is applied when specified with the configuration. 4. The parameter is the same format as that of watch ip. This setting is based on a static time window of 60 seconds. etc). 8. sense level <level> Available options: • low . DNS caches. The list is a comma separated list of IP addresses. ignore scanners <ip1|ip2/cidr[ [port|port2-port3]]> Ignores the source of scan alerts. and port range.169.5 (portscan) TCP Filtered Portscan Priority Count: 0 Connection Count: 200 IP Count: 2 Scanner IP Range: 192. one or more additional tagged packet(s) will be appended: Time: 09/08-15:07:31.168.200 bytes.169.169. The size tends to be around 100 . Open port alerts differ from the other portscan alerts.169. The payload and payload size of the packet are equal to the length of the additional portscan information that is logged. because open port alerts utilize the tagged packet output system. The open port information is stored in the IP payload and contains the port that is open. The characteristics of the packet are: Src/Dst MAC Addr == MACDAD IP Protocol == 255 IP TTL == 0 Other than that. then the user won’t see open port alerts. the packet looks like the IP portion of the packet that caused the portscan alert to be generated. the more bad responses have been received. IP count. The sfPortscan alert output was designed to work with unified packet logging. Log File Output Log file output is displayed in the following format. port count. snort generates a pseudo-packet and uses the payload portion to store the additional portscan information of priority count.603881 event_ref: 2 192.5 (portscan) Open Port Open Port: 38458 1.3:192. IP range. The higher the priority count. unreachables).4 Port/Proto Count: 200 Port/Proto Range: 20:47557 If there are open ports on the target.168. This includes any IP options. This means that if an output system that doesn’t print tagged packets is used.603880 event_id: 2 192.3 -> 192. connection count. and explained further below: Time: 09/08-15:07:31. so it is possible to extend favorite Snort GUIs to display portscan alerts and the additional information in the IP payload using the above packet characteristics.168.168.169. 49 . Event id/Event ref These fields are used to link an alert with the corresponding Open Port tagged packet 2. Priority Count Priority Count keeps track of bad responses (resets.3 -> 192.168.168. etc. Most of the false positives that sfPortscan may generate are of the filtered scan alert type. the analyst will know which to ignore it as. If the host is generating portscan alerts (and is the host that is being scanned). DNS cache servers. Make use of the Priority Count. We use this count (along with IP Count) to determine the difference between one-to-one portscans and one-to-one decoys. 4. Connection Count Connection Count lists how many connections are active on the hosts (src or dst). we hope to automate much of this analysis in assigning a scope level and confidence level. this ratio should be high. ignore scanners. The ignore scanners and ignore scanned options come into play in weeding out legitimate hosts that are very active on your network. Tuning sfPortscan The most important aspect in detecting portscans is tuning the detection engine for your network(s). indicating that the scanning host connected to few ports but on many hosts. Port Count / IP Count: This ratio indicates an estimated average of ports connected to per IP. and is more of an estimate for others. but be aware when first tuning sfPortscan for these IPs. Port Count Port Count keeps track of the last port contacted and increments this number when that changes. this ratio should be low. Depending on the type of alert that the host generates. 50 . If no watch ip is defined. For active hosts this number will be high regardless. IP Range. The portscan alert details are vital in determining the scope of a portscan and also the confidence of the portscan. add it to the ignore scanners list or use a lower sensitivity level. IP Count IP Count keeps track of the last IP to contact a host. For portscans. this ratio should be low. but for now the user must manually do this. sfPortscan may not generate false positives for these types of hosts. The following is a list of ratios to estimate and the associated values that indicate a legitimate scan and not a false positive. sfPortscan will watch all network traffic. So be much more suspicious of filtered portscans. When determining false positives.3. Whether or not a portscan was filtered is determined here. IP Count. For portsweeps. It’s important to correctly set these options. add it to the ignore scanned option. and nfs servers. If the host continually generates these types of alerts. then add it to the ignore scanners option. In the future. Many times this just indicates that a host was very active during the time period in question. 6. Connection Count. If the host is generating portsweep events. the higher the better. the alert type is very important. Some of the most common examples are NAT IPs. This is accurate for connection-based protocols. Here are some tuning tips: 1. 3. this is a low number. The watch ip option is easy to understand. and ignore scanned options. Use the watch ip. For portscans. syslog servers. Portsweep (one-to-many) scans display the scanned IP range. and Port Range to determine false positives. Scanned/Scanner IP Range This field changes depending on the type of alert. For one-to-one scans. The analyst should set this option to the list of CIDR blocks and IPs that they want to watch. Port Count. High connection count and low priority count would indicate filtered (no response received from target). 5. The easiest way to determine false positives is through simple ratio estimations. Portscans (one-to-one) display the scanner IP. Filtered scan alerts are much more prone to false positives. Connection Count / IP Count: This ratio indicates an estimated average of connections per IP. and one-to-one scans may appear as a distributed scan. 2. For portsweeps. and increments the count if the next IP is different. this ratio should be high and indicates that the scanned host’s ports were connected to by fewer IPs. It does this by normalizing the packet into the packet buffer.5 Performance Monitor This preprocessor measures Snort’s real-time and theoretical maximum performance. it should have an output mode enabled. Don’t alert when the sum of fragmented records exceeds one packet. but it’s also important that the portscan detection engine generate alerts that the analyst will find informative. Whenever this preprocessor is turned on. The low sensitivity level only generates alerts based on error responses. If none of these other tuning techniques work or the analyst doesn’t have the time for tuning. lower the sensitivity level.] 51 . Don’t alert when a single fragment record exceeds the size of one packet. If stream5 is enabled. 4.Connection Count / Port Count: This ratio indicates an estimated average of connections per port. This indicates that there were many connections to the same port. Snort’s real-time statistics are processed. it runs against traffic on ports 111 and 32771. For portsweeps. 2.4 RPC Decode The rpc decode preprocessor normalizes RPC multiple fragmented records into a single un-fragmented record. The Priority Count play an important role in tuning because the higher the priority count the more likely it is a real portscan or portsweep (unless the host is firewalled). The reason that Priority Count is not included. For portscans. You get the best protection the higher the sensitivity level. lower the sensitivity level. This indicates that each connection was to a different port. this ratio should be high.2. it will only process client-side traffic. Format preprocessor rpc_decode: \ <ports> [ alert_fragments ] \ [no_alert_multiple_requests] \ [no_alert_large_fragments] \ [no_alert_incomplete] Option alert fragments no alert multiple requests no alert large fragments no alert incomplete Description Alert on any fragmented RPC record. either “console” which prints statistics to the console window or “file” with a file name. Don’t alert when there are multiple records in one packet. The low sensitivity level does not catch filtered scans. is because the priority count is included in the connection count and the above comparisons take that into consideration. 2.2. These responses indicate a portscan and the alerts generated by the low sensitivity level are highly accurate and require the least tuning. this ratio should be low. If all else fails. where statistics get printed to the specified file name. By default. By default. since these are more prone to false positives.) 52 .: 53 . This value is in bytes and the default value is 52428800 (50MB).Prints out statistics about the type of traffic and protocol distributions that Snort is seeing. adding a content rule option to those rules can decrease the number of times they need to be evaluated and improve performance. • flow-ip-file . By default. followed by YYYY-MM-DD. Rules without content are not filtered via the fast pattern matcher and are always evaluated.Collects IP traffic distribution statistics based on host pairs. By default. Before the file exceeds this size. generic contents are more likely to be selected for evaluation than those with longer. This boosts performance. This is only valid for uniprocessor machines. Once the cap has been reached. This prints out statistics as to the number of rules that were evaluated and didn’t match (non-qualified events) vs.Turns on event reporting. • max file size .Defines which type of drop statistics are kept by the operating system.x. reset is used.Prints statistics at the console. Snort will log a distinctive line to this file with a timestamp to all readers to easily identify gaps in the stats caused by Snort not running. the table will start to prune the statistics for the least recently seen host pairs to free memory. the number of rules that were evaluated and matched (qualified events). The minimum is 4096 bytes and the maximum is 2147483648 bytes (2GB). are included.• flow .Prints statistics in a comma-delimited format to the file that is specified. The default is the same as the maximum. For each pair of hosts for which IP traffic has been seen. • flow-ip-memcap . • atexitonly . • accumulate or reset . • events . 54 . more unique contents. Not all statistics are output to this file. since many operating systems don’t keep accurate kernel statistics for multiple CPUs. so if possible. You may also use snortfile which will output into your defined Snort log directory. This option can produce large amounts of output.. All of the statistics mentioned above.Dump stats for entire life of Snort.Turns on the theoretical maximum performance that Snort calculates given the processor speed and current performance.Defines the maximum size of the comma-delimited file. • flow-ip . • time .Adjusts the number of packets to process before checking for the time sample.Sets the memory cap on the hash table used to store IP traffic statistics for host pairs.Prints the flow IP statistics in a comma-delimited format to the file that is specified. • file . Both of these directives can be overridden on the command line with the -Z or --perfmon-file options. • console . it will be rolled into a new date stamped file of the format YYYY-MM-DD.Represents the number of seconds between intervals. this is 10000. where x will be incremented each time the comma delimited file is rolled over. • pktcnt . Rules with short. since checking the time sample reduces Snort’s performance. as well as the IP addresses of the host pairs in human-readable format. At startup.. • max . Given a data buffer. but there are limitations in analyzing the protocol. HTTP Inspect will decode the buffer. Within HTTP Inspect. It is called unicode.2. and will be fooled if packets are not reassembled.6 HTTP Inspect HTTP Inspect is a generic HTTP decoder for user applications. The map file can reside in the same directory as snort. 55 . Users can configure individual HTTP servers with a variety of options.Examples preprocessor perfmonitor: \ time 30 events flow file stats.conf or be specified via a fully-qualified path to the map file.c. The current version of HTTP Inspect only handles stateless processing.csv pktcnt 1000 2. find HTTP fields. Configuration 1. HTTP Inspect works on both client requests and server responses. which should allow the user to emulate any type of web server. iis unicode map <map filename> [codemap <integer>] This is the global iis unicode map file.snort.profile max console pktcnt 10000 preprocessor perfmonitor: \ time 300 file /var/tmp/snortstat pktcnt 10000 preprocessor perfmonitor: \ time 30 flow-ip flow-ip-file flow-ip-stats. there are two areas of configuration: global and server. and normalize the fields. Global Configuration The global configuration deals with configuration options that determine the global functioning of HTTP Inspect. HTTP Inspect has a very “rich” user configuration. The iis unicode map file is a Unicode codepoint map which tells HTTP Inspect which codepage to use when decoding Unicode characters.org/dl/contrib/. For US servers. This means that HTTP Inspect looks for HTTP fields on a packet-by-packet basis. you’ll get an error if you try otherwise. The iis unicode map is a required configuration parameter. Future versions will have a stateful processing mode which will hook into various reassembly modules. A Microsoft US Unicode codepoint map is provided in the Snort source etc directory by default.map and should be used if no other codepoint map is available. A tool is supplied with Snort to generate custom Unicode maps--ms unicode generator. The following example gives the generic global configuration format: Format preprocessor http_inspect: \ global \ iis_unicode_map <map_filename> \ codemap <integer> \ [detect_anomalous_servers] \ [proxy_alert] \ [max_gzip_mem <num>] \ [compress_depth <num>] [decompress_depth <num>] \ disabled You can only have a single global configuration. which is available at. the codemap is usually 1252. This works fine when there is another module handling the reassembly. In the future. This option is turned off by default. By configuring HTTP Inspect servers and enabling allow proxy use. Please note that if users aren’t required to configure web proxy use. ”compress depth” and ”decompress depth” options are applied when specified with the configuration. Example Global Configuration preprocessor http_inspect: \ global iis_unicode_map unicode. we want to limit this to specific networks so it’s more useful. So. max gzip mem This option determines (in bytes) the maximum amount of memory the HTTP Inspect preprocessor will use for decompression. but for right now. This value can be set from 3276 bytes to 100MB. please only use this feature with traditional proxy environments. proxy alert This enables global alerting on HTTP server proxy usage. This option disables the preprocessor. 3. this inspects all network traffic. 6. Other options are parsed but not used. The default value for this option is 838860. disabled This optional keyword is allowed with any policy to avoid packet processing. detect anomalous servers This global configuration option enables generic HTTP server traffic inspection on non-HTTP configured ports. Most of your web servers will most likely end up using the default configuration. max gzip session = max gzip mem /(decompress depth + compress depth) 7. 2. Any valid configuration may have ”disabled” added to it. 56 . decompress depth <integer> This option specifies the maximum amount of decompressed data to obtain from the compressed packet payload. The default for this option is 2920. you will only receive proxy use alerts for web users that aren’t using the configured proxies or are using a rogue proxy server. then you may get a lot of proxy alerts. When the preprocessor is disabled only the ”max gzip mem”. ! △NOTE It is suggested to set this value such that the max gzip session calculated as follows is at least 1. This value can be set from 1 to 65535. individual servers can reference their own IIS Unicode map. This option along with compress depth and decompress depth determines the gzip sessions that will be decompressed at any given instant. Blind firewall proxies don’t count. 5. 4. Don’t turn this on if you don’t have a default server configuration that encompasses all of the HTTP server ports that your users might access. and alerts if HTTP traffic is seen. This value can be set from 1 to 65535. The default for this option is 1460. compress depth <integer> This option specifies the maximum amount of packet payload to decompress.! △NOTE Remember that this configuration is for the global IIS Unicode map. 1. the only difference being that multiple IPs can be specified via a space separated list. %u encoding. Apache also accepts tabs as whitespace. HTTP normalization will still occur. There is a limit of 40 IP addresses or CIDR notations per http inspect server line. 57 . In other words. and rules based on HTTP traffic will still trigger. Example IP Configuration preprocessor http_inspect_server: \ server 10. This differs from the iis profile by only accepting UTF-8 standard Unicode encoding and not accepting backslashes as legitimate slashes. so it’s disabled by default. regardless of the HTTP server. profile apache sets the configuration options described in Table 2.0 and IIS 5. So that means we use IIS Unicode codemaps for each server. We alert on the more serious forms of evasions. 1-D. The ‘yes/no’ argument does not specify whether the configuration option itself is on or off. profile iis sets the configuration options described in Table 2. 1-B.2. apache. There are five profiles available: all. apache The apache profile is used for Apache web servers. double decoding. iis4 0. iis5 0 In IIS 4. This is a great profile for detecting all types of attacks. and iis4 0. This argument specifies whether the user wants the configuration option to generate an HTTP Inspect alert or not. iis5 0. 1-C.2. etc. 1. backslashes. profile all sets the configuration options described in Table 2.1 10. except they will alert by default if a URL has a double encoding.1 and beyond. Double decode is not supported in IIS 5. iis The iis profile mimics IIS servers. like IIS does.5.1. iis.1.1 profile all ports { 80 } Configuration by Multiple IP Addresses This format is very similar to “Configuration by IP Address”. only the alerting functionality. the only difference being that specific IPs can be configured. Example Multiple IP Configuration preprocessor http_inspect_server: \ server { 10. Profiles allow the user to easily configure the preprocessor for a certain type of server.0.4. These two profiles are identical to iis. 1-A. all The all profile is meant to normalize the URI using most of the common tricks available.1.0/24 } profile all ports { 80 } Server Configuration Options Important: Some configuration options have an argument of ‘yes’ or ‘no’. but are not required for proper operation. profile <all|apache|iis|iis5 0|iis4 0> Users can configure HTTP Inspect by using pre-defined HTTP server profiles.3.Example Default Configuration preprocessor http_inspect_server: \ server default profile all ports { 80 } Configuration by IP Address This format is very similar to “default”. there was a double decoding vulnerability. bare-byte encoding. whether set to ‘yes’ or ’no’. alert off multiple slash on. default. Profiles must be specified as the first server option and cannot be combined with any other options except: • ports • iis unicode map • allow proxy use • server flow depth • client flow depth • post depth • no alerts • inspect uri only • oversize dir length • normalize headers • normalize cookies • normalize utf • max header length • max headers • extended response inspection • enable cookie • inspect gzip • unlimited decompress • enable xff • http methods These options must be specified after the profile option. Example preprocessor http_inspect_server: \ server 1. alert on %u decoding on. alert on iis unicode codepoints on. alert on iis backslash on. header length not checked max headers 0. number of headers not checked 1-E. no profile The default options used by HTTP Inspect do not use a profile and are described in Table 2. alert off double decoding on. alert on non strict URL parsing on tab uri delimiter is set max header length 0. alert off webroot on.Table 2. alert on bare byte decoding on. alert off directory normalization on.6.1. alert off iis delimiter on. alert off apache whitespace.1 profile all ports { 80 3128 } 58 . For US servers. alert on apache whitespace on. Decompression is done across packets. The different fields of a HTTP response such as status code. So the decompression will end when either the ’compress depth’ or ’decompress depth’ is reached or when the compressed data ends.. HTTPS traffic is encrypted and cannot be decoded with HTTP Inspect. By default the cookie inspection and extraction will be turned off. use the SSL preprocessor. >]} This is how the user configures which ports to decode on the HTTP server. Executing this program generates a Unicode map for the system that it was run on. the state of the last decompressed packet is used to decompressed the data of the next packet. alert off webroot on. Also the amount of decompressed data that will be inspected depends on the ’server flow depth’ configured. cookie (when enable cookie is configured) and body are extracted and saved into buffers.4: Options for the apache Profile Option Setting server flow depth 300 client flow depth 300 post depth 0 chunk encoding alert on chunks larger than 500000 bytes ASCII decoding on. you run this program on that server and use that Unicode map in this configuration. http stat msg and http cookie. alert on utf 8 encoding on. So. 3. However. ! △NOTE When this option is turned on. one should use the http modifiers with content such as http header. to get the specific Unicode mappings for an IIS web server. headers. the user needs to specify the file that contains the IIS Unicode map and also specify the Unicode map to use. You can select the correct code page by looking at the available code pages that the ms unicode generator outputs. enable cookie This options turns on the cookie extraction from HTTP requests and HTTP response. this is usually 1252. When using this option. alert off multiple slash on. 5. alert off non strict url parsing on tab uri delimiter is set max header length 0. the decompressed data from different packets are not combined while inspecting). You should select the config option ”extended response inspection” before configuring this option. But the decompressed data are individually inspected.. extended response inspection This enables the extended HTTP response inspection.snort. To search for patterns in the header of the response. (i.c. alert off directory normalization on. The default http response inspection does not inspect the various fields of a HTTP response. if the HTTP response packet has a body then any content pattern matches ( without http modifiers ) will search the response body ((decompressed in case of gzip) and not the entire packet payload. number of headers not checked 2. status message. it’s the ANSI code page. By turning this option the HTTP response will be thoroughly inspected. iis unicode map <map filename> codemap <integer> The IIS Unicode map is generated by the program ms unicode generator.org web site at. ports {<port> [<port>< . But the ms unicode generator program tells you which codemap to use for you server. To ignore HTTPS traffic.Table 2. When the compressed data is spanned across multiple packets. This program is located on the Snort. Different rule options are provided to inspect these buffers. header length not checked max headers 0. 59 .e.org/dl/contrib/ directory. inspect gzip This option specifies the HTTP inspect module to uncompress the compressed data(gzip/deflate) in HTTP response. 6. http stat code. 4. To ensure unlimited decompression. alert off webroot on. alert on bare byte decoding on. alert on %u decoding on. alert on double decoding on. or the content that is likely to be in the first hundred or so bytes of non-header data. It is suggested to set the server flow depth to its maximum value. enable xff This option enables Snort to parse and log the original client IP present in the X-Forwarded-For or True-ClientIP HTTP request headers along with the generated events. When extended response inspection is turned on. alert off iis delimiter on. it is suggested to set the ’compress depth’ and ’decompress depth’ to its maximum values. alert on iis backslash on. alert on non strict URL parsing on max header length 0. number of headers not checked ! △NOTE To enable compression of HTTP server off directory normalization on. Snort rules are targeted at HTTP server response traffic and when used with a small flow depth value may cause false negatives. This tool is present in the tools/u2spewfoo directory of snort source tree. When the extended response inspection is 60 . 9. This value can be set from -1 to 65535. Most of these rules target either the HTTP header. Snort should be configured with the –enable-zlib flag. unlimited decompress This option enables the user to decompress unlimited gzip data (across multiple packets). alert on iis unicode codepoints on. it is applied to the HTTP response body (decompressed data when inspect gzip is turned on) and not the HTTP headers. Unlike client flow depth this option is applied per TCP session. but your mileage may vary. ! △NOTE The original client IP from XFF/True-Client-IP in unified2 logs can be viewed using the tool u2spewfoo. 8. This option can be used to balance the needs of IDS performance and level of inspection of HTTP server response data. header length not checked max headers 0. server flow depth <integer> This specifies the amount of server response payload to inspect. Headers are usually under 300 bytes long.Table 2. When extended response inspection is turned off the server flow depth is applied to the entire HTTP response (including headers). The decompression in a single packet is still limited by the ’compress depth’ and ’decompress depth’. A value of -1 causes Snort to ignore all server side traffic for ports defined in ports when extended response inspection is turned off. The XFF/True-Client-IP Original client IP address is logged only with unified2 output and is not logged with console (-A cmg) output. alert off multiple slash on.Decompression will stop when the compressed data ends or when a out of sequence packet is received. 7. post depth <integer> This specifies the amount of data to inspect in a client post message. a value of 0 61 . number of headers not checked turned on. If less than flow depth bytes are in the payload of the HTTP response packets in a given session. the entire payload will be inspected. Values above 0 tell Snort the number of bytes to inspect of the server response (excluding the HTTP headers when extended response inspection is turned on) in a given HTTP session. The default value for server flow depth is 300. a value of 0 causes Snort to inspect all HTTP server payloads defined in ”ports” (note that this will likely slow down IDS performance). alert off apache whitespace on. It primarily eliminates Snort from inspecting larger HTTP Cookies that appear at the end of many client request Headers. which will be deprecated in a future release. a value of 0 causes Snort to inspect all HTTP client side traffic defined in ”ports” (note that this will likely slow down IDS performance). Note that the 65535 byte maximum flow depth applies to stream reassembled packets as well. alert off utf 8 encoding on. alert off non strict URL parsing on max header length 0. alert on iis backslash on. This value can be set from -1 to 1460. It is suggested to set the client flow depth to its maximum value. 10. It is not a session based flow depth. Rules that are meant to inspect data in the payload of the HTTP response packets in a session beyond 65535 bytes will be ineffective unless flow depth is set to 0. Note that the 1460 byte maximum flow depth applies to stream reassembled packets as well. alert off multiple slash on. If more than flow depth bytes are in the payload of the first packet only flow depth bytes of the payload will be inspected. header length not checked max headers 0. client flow depth <integer> This specifies the amount of raw client request payload to inspect. A value of -1 causes Snort to ignore all client side traffic for ports defined in ”ports.Table 2. The value can be set from -1 to 65495. Inversely.” Inversely. Only packets payloads starting with ’HTTP’ will be considered as the first packet of a server response. It has a default value of 300. It is suggested to set the server flow depth to its maximum value. alert off directory normalization on. The default value is -1. value of -1 causes Snort to ignore the HTTP response body data and not the HTTP headers. the entire payload will be inspected. alert off webroot on. Inversely.6: Default HTTP Inspect Options Option Setting port 80 server flow depth 300 client flow depth 300 post depth -1 chunk encoding alert on chunks larger than 500000 bytes ASCII decoding on. A value of -1 causes Snort to ignore all the data in the post message. If more than flow depth bytes are in the payload of the HTTP response packet in a session only flow depth bytes of the payload will be inspected for that session. If less than flow depth bytes are in the TCP payload (HTTP request) of the first packet. alert off iis delimiter on. ! △NOTE server flow depth is the same as the old flow depth option. 11. Values above 0 tell Snort the number of bytes to inspect in the first packet of the client request. Rules that are meant to inspect data in the payload of the first packet of a client request beyond 1460 bytes will be ineffective unless flow depth is set to 0. Unlike server flow depth this value is applied to the first packet of the HTTP request. When iis unicode is enabled. doing decodes in each one. this option will not work. 15. When base36 is enabled. How this works is that IIS does two passes through the request URI. utf 8 <yes|no> The utf-8 decode option tells HTTP Inspect to decode standard UTF-8 Unicode sequences that are in the URI. Don’t use the %u option. This increases the performance by inspecting only specified bytes in the post message. %u002e = . The iis unicode option handles the mapping of non-ASCII codepoints that the IIS server accepts and decodes normal UTF-8 requests. How the %u encoding scheme works is as follows: the encoding scheme is started by a %u followed by 4 characters. 18. this 62 . iis unicode <yes|no> The iis unicode option turns on the Unicode codepoint mapping.a %2f = /. because we are not aware of any legitimate clients that use this encoding. Bare byte encoding allows the user to emulate an IIS server and interpret non-standard encodings correctly. because base36 won’t work. The xxxx is a hex-encoded value that correlates to an IIS Unicode codepoint. 19.. bare byte <yes|no> Bare byte encoding is an IIS trick that uses non-ASCII characters as valid values when decoding UTF-8 values. and then UTF-8 is decoded in the second stage. You should alert on the iis unicode option. bare byte. You should alert on %u encodings. 14. The alert on this decoding should be enabled. If there is no iis unicode map option specified with the server config. the default codemap is used. We leave out utf-8 because I think how this works is that the % encoded utf-8 is decoded to the Unicode byte in the first pass. like %uxxxx. and %u. In the first pass. This is not in the HTTP standard. iis unicode uses the default codemap. a. In the second pass. 13. base36 <yes|no> This is an option to decode base36 encoded chars. because it is seen mainly in attacks and evasion attempts. double decode <yes|no> The double decode option is once again IIS-specific and emulates IIS functionality. because there are no legitimate clients that encode UTF-8 this way since it is non-standard. This abides by the Unicode standard and only uses % encoding. An ASCII character is encoded like %u002f = /. bare byte. This option is based on info from:. 12. etc. ASCII encoding is also enabled to enforce correct behavior. Anyway. but this will be prone to false positives as legitimate web clients use this type of encoding.yk. If no iis unicode map is specified before or after this option. This value can most definitely be ASCII. so it is recommended that you disable HTTP Inspect alerting for this option. ascii <yes|no> The ascii decode option tells us whether to decode encoded ASCII chars. You have to use the base36 option with the utf 8 option.or. make sure you have this option turned on. So it is most likely someone trying to be covert. ASCII and UTF-8 decoding are also enabled to enforce correct decoding..rim. ASCII decoding is also enabled to enforce correct functioning. It is normal to see ASCII encoding usage in URLs. 17. the following encodings are done: ASCII.patch. u encode <yes|no> This option emulates the IIS %u encoding scheme. As for alerting.causes Snort to inspect all the client post message.jp/˜shikap/patch/spp_http_decode. 16. This option is turned off by default and is not supported with any of the profiles. you must enable also enable utf 8 yes. so for any Apache servers. When utf 8 is enabled. and %u. If %u encoding is enabled.k. Apache uses this standard. To alert on UTF-8 decoding. it seems that all types of iis encoding is done: utf-8 unicode. you may be interested in knowing when you have a UTF-8 encoded URI. ASCII. extended ascii uri This option enables the support for extended ASCII codes in the HTTP request URI. as all non-ASCII values have to be encoded with a %. etc. %2e = . Alerts on this option may be interesting. a user may not want to see null bytes in the request URI and we can alert on that. we always take this as standard since the most popular web servers accept it.. so ASCII is also enabled to enforce correct decoding. specify yes. then configure with a yes../bar gets normalized to: /foo/bar If you want to configure an alert. 24. pipeline requests are not decoded and analyzed per HTTP protocol field. but Apache takes this non-standard delimiter was well. This is again an IIS emulation. This alert may give false positives. chunk length <non-zero positive integer> This option is an anomaly detector for abnormally large chunk sizes. and is a performance enhancement if needed. directory <yes|no> This option normalizes directory traversals and self-referential directories. It’s flexible. 21. Please use this option with care. apache whitespace <yes|no> This option deals with the non-RFC standard of using tab for a space delimiter. 26. This picks up the Apache chunk encoding exploits. but may also be false positive prone. no pipeline req This option turns HTTP pipeline decoding off. Since this is common. multi slash <yes|no> This option normalizes multiple slashes in a row. By default./bar gets normalized to: /foo/bar The directory: /foo/.is really complex and adds tons of different encodings for one character. since some web sites refer to files using directory traversals. 20. It is only inspected with the generic pattern matching. 63 . so be careful. and may also alert on HTTP tunneling that uses chunk encoding. otherwise. so something like: “foo/////////bar” get normalized to “foo/bar.. but when this option is enabled. so if the emulated web server is Apache. otherwise. 25. When double decode is enabled. use no.” 23. pipeline requests are inspected for attacks.” If you want an alert when multiple slashes are seen. non rfc char {<byte> [<byte . enable this option. alert on all ‘/’ or something like that. specify no. But you can still get an alert on this option. For instance. 22.>]} This option lets users receive an alert if certain non-RFC chars are used in a request URI. because you could configure it to say. So a request URI of “/foo\bar” gets normalized to “/foo/bar. 27. The directory: /foo/fake\_dir/. iis delimiter <yes|no> This started out being IIS-specific. Apache uses this. iis backslash <yes|no> Normalizes backslashes to slashes. like whisker -i 4. The non strict option assumes the URI is between the first and second space even if there is no valid HTTP identifier after the second space. a tab in the URI should be treated as any other character. This means that no alert will be generated if the proxy alert global keyword has been used. which is associated with certain web attacks. If the proxy alert keyword is not enabled. To enable. This is obvious since the URI is only inspected with uricontent rules. IIS does not. if we have the following rule set: alert tcp any any -> any 80 ( msg:"content". non strict This option turns on non-strict URI parsing for the broken way in which Apache servers will decode a URI. inspect uri only This is a performance optimization. When enabled. then this option does nothing. Whether this option is on or not. then there is nothing to inspect. because it doesn’t alert on directory traversals that stay within the web server directory structure. 35. The integer is the maximum length allowed for an HTTP client request header field. and if there are none available. Apache accepts tab as a delimiter. The allow proxy use keyword is just a way to suppress unauthorized proxy use for an authorized server. 29. This should limit the alerts to IDS evasion type attacks. webroot <yes|no> This option generates an alert when a directory traversal traverses past the web server root directory.0\r\n\r\n No alert will be generated when inspect uri only is enabled. an alert is generated. tab uri delimiter This option turns on the use of the tab character (0x09) as a delimiter for a URI. 64 . only the URI portion of HTTP requests will be inspected for attacks. 34. If a url directory is larger than this argument size. enable this optimization. you’ll catch most of the attacks. ) and the we inspect the following URI: get /foo. Only use this option on servers that will accept URIs like this: ”get /index. This generates much fewer false positives than the directory option. oversize dir length <non-zero positive integer> This option takes a non-zero positive integer as an argument. This has no effect on HTTP rules in the rule set. 30. It’s important to note that if this option is used without any uricontent rules.28.html alsjdfk alsj lj aj la jsj s\n”. For example. specify an integer argument to max header length of 1 to 65535. the user is allowing proxy use on this server. then no inspection will take place. allow proxy use By specifying this keyword. content: "foo". A good argument value is 300 characters. no alerts This option turns off all alerts that are generated by the HTTP Inspect preprocessor module. Requests that exceed this length will cause a ”Long Header” alert. This alert is off by default.htm http/1. 32. As this field usually contains 90-95% of the web attacks. No argument is specified. 33. For IIS. So if you need extra performance. The argument specifies the max char directory length for URL directory. a tab is treated as whitespace if a space character (0x20) precedes it. Specifying a value of 0 is treated as disabling the alert. The inspect uri only configuration turns off all forms of detection except uricontent inspection. max header length <positive integer up to 65535> This option takes an integer as an argument. It only alerts when the directory traversals go past the web server root directory. No argument is specified. 31. generating an alert if the extra bytes are non-zero. braces and methods also needs to be separated by braces. directory. normalize utf This option turns on normalization of HTTP response bodies where the Content-Type header lists the character set as ”utf-16le”. HTTP Inspect will attempt to normalize these back into 8-bit encoding.1. Specifying a value of 0 is treated as disabling the alert. etc. 40. The list should be enclosed within braces and delimited by spaces.36 \ 65 . tabs.1. 39. 37. normalize cookies This option turns on normalization for HTTP Cookie Fields (using the same configuration parameters as the URI normalization (ie. http_methods { PUT CONNECT } ! △NOTE Please note the maximum length for a method name is 7 Examples preprocessor http_inspect_server: \ server 10. It is useful for normalizing Referrer URIs that may appear in the HTTP Header. line feed or carriage return. The integer is the maximum number of HTTP client request header fields. directory. multi-slash.). To enable. ”utf-32le”. or ”utf-32be”.). ”utf-16be”. Requests that contain more HTTP Headers than this value will cause a ”Max Header” alert. multi-slash. The config option. 38. It is useful for normalizing data in HTTP Cookies that may be encoded. http methods {cmd[cmd]} This specifies additional HTTP Request Methods outside of those checked by default within the preprocessor (GET and POST). not including Cookies (using the same configuration parameters as the URI normalization (ie. The alert is off by default. etc. normalize headers This option turns on normalization for HTTP Header Fields. max headers <positive integer up to 1024> This option takes an integer as an argument. specify an integer argument to max headers of 1 to 1024. 6. It will also mark the command. regular mail data can be ignored for an additional performance boost. ignore tls data Ignore TLS-encrypted data when processing rules. Absence of this option or a ”0” means never alert on command line length. Space characters are defined as space (ASCII 0x20) or tab (ASCII 0x09). SMTP command lines can be normalized to remove extraneous spaces. and TLS data. SMTP will decode the buffer and find SMTP commands and responses. 3. this will include 25 and possibly 465.7 SMTP Preprocessor The SMTP preprocessor is an SMTP decoder for user applications. inspection type <stateful | stateless> Indicate whether to operate in stateful or stateless mode.. Typically. such as port and inspection type. It saves state between individual packets. max command line len <int> Alert if an SMTP command line is longer than this value. ignore data Ignore data section of mail (except for mail headers) when processing rules. all checks all commands none turns off normalization for all commands. Also. ports { <port> [<port>] . } This specifies on what ports to check for SMTP data. which improves performance. data header data body sections. SMTP handles stateless and stateful processing. However maintaining correct state is dependent on the reassembly of the client side of the stream (ie. Normalization checks for more than one space character after a command. Given a data buffer. cmds just checks commands listed with the normalize cmds parameter. In addition. for encrypted SMTP. 66 . TLS-encrypted traffic can be ignored.2. normalize <all | none | cmds> This turns on normalization. The configuration options are described below: 1.. 5. 2. 4. Since so few (none in the current snort rule set) exploits are against mail data.ascii no \ chunk_length 500000 \ bare_byte yes \ double_decode yes \ iis_unicode yes \ iis_delimiter yes \ multi_slash no preprocessor http_inspect_server: \ server default \ profile all \ ports { 80 8080 } 2. Configuration SMTP has the usual configuration items. RFC 2821 recommends 512 as a maximum command line length. this is relatively safe to do and can improve the performance of data inspection. a loss of coherent stream data results in a loss of state). RFC 2821 recommends 1024 as a maximum data header line length. 10. 8. Multiple base64 encoded MIME attachments/data in one packet are pipelined. 19. Default is an empty list. normalize cmds { <Space-delimited list of commands> } Normalize this list of commands Default is { RCPT VRFY EXPN }. invalid cmds { <Space-delimited list of commands> } Alert if this command is sent from client side.5. This is useful when specifying the max mime depth and max mime mem in default policy without turning on the SMTP preprocessor. disabled Disables the SMTP preprocessor in a policy. max header line len <int> Alert if an SMTP DATA header line is longer than this value. The default value for this in snort in 1460 bytes. 67 . valid cmds { <Space-delimited list of commands> } List of valid commands. The option take values ranging from 5 to 20480 bytes.. 15. print cmds List all commands understood by the preprocessor. 12. max mime depth <int> Specifies the maximum number of base64 encoded data to decode per SMTP session. alt max command line len <int> { <cmd> [<cmd>] } Overrides max command line len for specific commands. The decoding of base64 encoded attachments/data ends when either the max mime depth or maximum MIME sessions (calculated using max mime depth and max mime mem) is reached or when the encoded data ends. no alerts Turn off all alerts for this preprocessor. 14. The decoded data is available for detection using the rule option file data:mime. RFC 2821 recommends 512 as a maximum response line length. This not normally printed out with the configuration because it can print so much data. 17. Default is off. See 3. Drop if alerted. Default is an empty list. 16. max response line len <int> Alert if an SMTP response line is longer than this value.7. alert unknown cmds Alert if we don’t recognize command. When stateful inspection is turned on the base64 encoded MIME attachments/data across multiple packets are decoded too. enable mime decoding Enables Base64 decoding of Mime attachments/data. Absence of this option or a ”0” means never alert on data header line length. xlink2state { enable | disable [drop] } Enable/disable xlink2state alert. 9. Default is enable.24 rule option for more details. We do not alert on commands in this list. Absence of this option or a ”0” means never alert on response line length. Note: It is suggested to set this value such that the max mime session calculated as follows is atleast 1. For the preprocessor configuration. The default value for this option is 838860. max mime mem <int> This option determines (in bytes) the maximum amount of memory the SMTP preprocessor will use for decoding base64 encode MIME attachments/data. they are referred to as RCPT and MAIL. This option along with max mime depth determines the base64 encoded MIME/SMTP sessions that will be decoded at any given instant. respectively. This value can be set from 3276 bytes to 100MB. Within the code.. preprocessor actually maps RCPT and MAIL to the correct command name. } \ } \ HELO ETRN } \ VRFY } 68 . FTP/Telnet works on both client requests and server responses. a particular session will be noted as encrypted and not inspected any further. The presence of the option indicates the option itself is on. Within FTP/Telnet.2. encrypted traffic <yes|no> This option enables detection and alerting on encrypted Telnet and FTP command channels. The FTP/Telnet global configuration must appear before the other three areas of configuration. meaning it only looks for information on a packet-bypacket basis. ! △NOTE When inspection type is in stateless mode. 2. check encrypted Instructs the preprocessor to continue to check an encrypted session for a subsequent command to cease encryption. 3. which should allow the user to emulate any type of FTP server or FTP Client. FTP/Telnet has a very “rich” user configuration. you’ll get an error if you try otherwise. there are four areas of configuration: Global. Configuration. FTP/Telnet has the capability to handle stateless processing. while the yes/no argument applies to the alerting functionality associated with that option.. and FTP Server. FTP/Telnet will decode the stream. The default is to run FTP/Telnet in stateful inspection mode.2. checks for encrypted traffic will occur on every packet.6). FTP Client. similar to that of HTTP Inspect (See 2. Global Configuration The global configuration deals with configuration options that determine the global functioning of FTP/Telnet. whereas in stateful mode. meaning it looks for information and handles reassembled data correctly. Users can configure individual FTP servers and clients with a variety of options. Telnet. identifying FTP commands and responses and Telnet escape sequences and normalize the fields. inspection type This indicates whether to operate in stateful or stateless mode. 69 .2. 70 . 3... SSH tunnels cannot be decoded. and subsequent instances will override previously set values. >]} This is how the user configures which ports to decode as telnet traffic.. This is anomalous behavior which could be an evasion case. it is also susceptible to this behavior. certain implementations of Telnet servers will ignore the SB without a corresponding SE. Rules written with ’raw’ content options will ignore the normalized buffer that is created when this option is in use. detect anomalies In order to support certain options. so adding port 22 will only yield false positives. Telnet supports subnegotiation. It functions similarly to its predecessor. Being that FTP uses the Telnet protocol on the control connection. 4. 2. the telnet decode preprocessor.. Typically port 23 will be included. ports {<port> [<port>< . Configuration 1. However. subnegotiation begins with SB (subnegotiation begin) and must end with an SE (subnegotiation end). It is only applicable when the mode is stateful.. normalize This option tells the preprocessor to normalize the telnet traffic by eliminating the telnet escape sequences. Configuration by IP Address This format is very similar to “default”. 3. Most of your FTP servers will most likely end up using the default configuration. Example IP specific FTP Server Configuration preprocessor _telnet_protocol: \ ftp server 10. This may be used to allow the use of the ’X’ commands identified in RFC 775.1 ports { 21 } ftp_cmds { XPWD XCWD } FTP Server Configuration Options 1. For example: ftp_cmds { XPWD XCWD XCUP XMKD XRMD } 4. so the appropriate configuration would be: alt_max_param_len 16 { USER } 6. ftp cmds {cmd[cmd]} The preprocessor is configured to alert when it sees an FTP command that is not allowed by the server. as well as any additional commands as needed. 71 . For example the USER command – usernames may be no longer than 16 bytes. the only difference being that specific IPs can be configured. outside of the default FTP command set as specified in RFC 959. It can be used as a basic buffer overflow detection.1. It can be used as a more specific buffer overflow detection. >]} This is how the user configures which ports to decode as FTP command channel traffic.Default This configuration supplies the default server configuration for any FTP server that is not individually configured.. chk str fmt {cmd[cmd]} This option causes a check for string format attacks in the specified commands. def max param len <number> This specifies the default maximum allowed parameter length for an FTP command. print cmds During initialization.1. Example Default FTP Server Configuration preprocessor ftp_telnet_protocol: \ ftp server default ports { 21 } Refer to 73 for the list of options set in default ftp server configuration. this option causes the preprocessor to print the configuration for each of the FTP commands for this server. 5. Typically port 21 will be included.. alt max param len <number> {cmd[cmd]} This specifies the maximum allowed parameter length for the specified FTP command(s). ports {<port> [<port>< . 2. This option specifies a list of additional commands allowed by this server. uuu]..n[n[n]]] ] string > MDTM is an off case that is worth discussing.ietf.txt) To check validity for a server that uses the TZ format. one of <chars> Parameter follows format specified.literal Parameter is a string (effectively unrestricted) Parameter must be a host/port specified. separated by | One of the choices enclosed within {}. cmd_validity MODE < char ASBCZ > # Allow for a date in the MDTM command.org/internetdrafts/draft-ietf-ftpext-mlst-16. fmt must be enclosed in <>’s and may contain the following: Value int number char <chars> date <datefmt> Description Parameter must be an integer Parameter must be an integer between 1 and 255 Parameter must be a single character. # This allows additional modes. While not part of an established standard. including mode Z which allows for # zip-style compression. These examples are the default checks. | {}. per RFC 2428 One of choices enclosed within. The most common among servers that do. cmd_validity MDTM < [ date nnnnnnnnnnnnnn[. Injection of telnet escape sequences could be used as an evasion attempt on an FTP command channel. per RFC 959 Parameter must be a long host port specified. use the following: cmd_validity MDTM < [ date nnnnnnnnnnnnnn[{+|-}n[n]] ] string > 8. + . certain FTP servers accept MDTM commands that set the modification time on a file. per RFC 1639 Parameter must be an extended host port specified. [] Examples of the cmd validity option are shown below. cmd validity cmd < fmt > This option specifies the valid format for parameters of a given command. accept a format using YYYYMMDDHHmmss[.7. per RFC 959 and others performed by the preprocessor. Some others accept a format using YYYYMMDDHHmmss[+—]TZ format. The example above is for the first case (time format as specified in. 72 . where: n Number C Character [] optional format enclosed | OR {} choice of options . telnet cmds <yes|no> This option turns on detection and alerting when telnet escape sequences are seen on the FTP command channel. optional value enclosed within [] string host port long host port extended host port {}. The other options will override those in the base configuration. other preprocessors) to ignore FTP data channel connections. It can be used to improve performance. and by IP address. Default This configuration supplies the default client configuration for any FTP client that is not individually configured. data chan This option causes the rest of snort (rules. Use of the ”data chan” option is deprecated in favor of the ”ignore data chan” option. it is recommended that this option not be used. Most of your FTP clients will most likely end up using the default configuration.. ignore data chan <yes|no> This option causes the rest of Snort (rules.9. Options specified in the configuration file will modify this set of options. Using this option means that NO INSPECTION other than TCP state will be performed on FTP data transfers. Some FTP servers do not process those telnet escape sequences. FTP Server Base Configuration Options The base FTP server configuration is as follows. the FTP client configurations has two types: default. especially with large file transfers from a trusted source. If your rule set includes virus-type rules. ignore telnet erase cmds <yes|no> This option allows Snort to ignore telnet escape sequences for erase character (TNC EAC) and erase line (TNC EAL) when normalizing FTP command channel. 10. 73 . 11. it is recommended that this option not be used. especially with large file transfers from a trusted source. ”data chan” will be removed in a future release. If your rule set includes virus-type rules. It can be used to improve performance. FTP commands are added to the set of allowed commands. Setting this option to ”yes” means that NO INSPECTION other than TCP state will be performed on FTP data transfers.. 74 ! △NOTE. 75. and optionally determines if and when Snort should stop inspection of it. Typically, SSL is used over port 443 as HTTPS. By enabling the SSLPP to inspect port 443 and enabling the noinspect encrypted option, only the SSL handshake of each connection will be inspected. Once the is legitimately encrypted. In some cases, especially when packets may be missed, the only observed response from one endpoint will be TCP ACKs. Therefore, if a user knows that server-side encrypted data can be trusted to mark the session as encrypted, the user should use the ’trustservers’ option, documented below. 77 Configuration 1. ports {<port> [<port>< ... >]} This option specifies which ports SSLPP will inspect traffic on. By default,. SSL versions in use simultaneously, multiple ssl version rule options should be used. Syntax ssl_version: <version-list> version-list = version | version , version-list version = ["!"] "sslv2" | "sslv3" | "tls1.0" | "tls1.1" | "tls1.2" Examples 78 79 If it is decided that a session is SMB or DCE/RPC. share handle or TID and file/named pipe handle or FID must be used to write data to a named pipe. The binding between these is dependent on OS/software version.40. Read.e. New rule options have been implemented to improve performance.22 and earlier Any valid UID and TID. Transaction.168. • IP defragmentation should be enabled. preprocessor arpspoof preprocessor arpspoof_detect_host: 192. servers or autodetecting.13 DCE/RPC 2 Preprocessor The main purpose of the preprocessor is to perform SMB desegmentation and DCE/RPC defragmentation to avoid rule evasion using these techniques.0. Dependency Requirements For proper functioning of the preprocessor: • Stream session tracking must be enabled.1 proxy and server. the FID that was created using this TID becomes invalid.168. the frag3 preprocessor should be enabled and configured.22 80 . preprocessor arpspoof: -unicast preprocessor arpspoof_detect_host: 192. SMB desegmentation is performed for the following commands that can be used to transport DCE/RPC requests and responses: Write. i. either through configured ports.2.168. Write and Close. UDP and RPC over HTTP v. stream5.40. Transaction Secondary.1 f0:0f:00:f0:0f:00 preprocessor arpspoof_detect_host: 192. The preprocessor requires a session tracker to keep its data.2 f0:0f:00:f0:0f:01 The third example configuration has unicast detection enabled. • Stream reassembly must be performed for TCP sessions. Write AndX. Read Block Raw and Read AndX.40. the dcerpc2 preprocessor will enable stream reassembly for that session if necessary. no more requests can be written to that named pipe instance. Target Based There are enough important differences between Windows and Samba versions that a target based approach has been implemented. Samba 3.168.e.40. The following transports are supported for DCE/RPC: SMB.168. Some important differences: Named pipe instance tracking A combination of valid login handle or UID. reduce false positives and reduce the count and complexity of DCE/RPC based rules.1 and 192.2. TCP.1 f0:0f:00:f0:0f:00 preprocessor arpspoof_detect_host: 192. i.2 f0:0f:00:f0:0f:01 2. if the TID used in creating the FID is deleted (via a tree disconnect).The next example configuration does not do unicast detection but monitors ARP mapping for hosts 192.168. Write Block Raw.40. along with a valid FID can be used to make a request. Samba greater than 3. however.0. i.e.40. deleting either the UID or TID invalidates the FID. only the UID used in opening the named pipe can be used to make a request using the FID handle to the named pipe instance. If the UID used to create the named pipe instance is deleted (via a Logoff AndX). Samba (all versions) Under an IPC$ tree. However. TID and FID used to make a request to a named pipe instance. Windows 2000 Windows 2000 is interesting in that the first request to a named pipe must use the same binding as that of the other Windows versions. multiple logins and tree connects (only one place to return handles for these). It also follows Samba greater than 3.e. It is necessary to track this so as not to munge these requests together (which would be a potential evasion opportunity). i.e.. along with a valid FID can be used to make a request. the FID becomes invalid. 81 . requests after that follow the same binding as Samba 3. no binding. What distinguishes them (when the same named pipe is being written to. Segments for each ”thread” are stored separately and written to the named pipe when all segments are received. Accepted SMB commands Samba in particular does not recognize certain commands under an IPC$ tree. login/logoff and tree connect/tree disconnect. Ultimately. having the same FID) are fields in the SMB header representing a process id (PID) and multiplex id (MID). e.0.e. These requests can also be segmented with Transaction Secondary commands. AndX command chaining Windows is very strict in what command combinations it allows to be chained. An MID represents different sub-processes within a process (or under a PID). Multiple Transaction requests can be made simultaneously to the same named pipe.22 and earlier. However. does not accept: Open Write And Close Read Read Block Raw Write Block Raw Windows (all versions) Accepts all of the above commands under an IPC$ tree. The PID represents the process this request is a part of. If the TID used to create the FID is deleted (via a tree disconnect). whereas in using the Write* commands. is very lax and allows some nonsensical combinations. the client has to explicitly send one of the Read* requests to tell the server to send the response and (2) a Transaction request is not written to the named pipe until all of the data is received (via potential Transaction Secondary requests) whereas with the Write* commands. Windows 2003 Windows XP Windows Vista These Windows versions require strict binding between the UID. the FID that was created using this TID becomes invalid.22 in that deleting the UID or TID used to create the named pipe instance also invalidates it. on the other hand. Samba. since it is necessary in making a request to the named pipe. i. i. Therefore.g.Any valid TID. data is written to the named pipe as it is received by the server.0. Both the UID and TID used to open the named pipe instance must be used when writing data to the same named pipe instance. no more requests can be written to that named pipe instance. we don’t want to keep track of data that the server won’t accept. The context id field in any other fragment can contain any value. Samba 3. Windows (all versions) The byte order of the stub data is that which was used in the Bind request. Windows (all versions) The context id that is ultimately used for the request is contained in the first fragment. Samba (all versions) The byte order of the stub data is that which is used in the request carrying the stub data.0. only one Bind can ever be made on a session whether or not it succeeds or fails. all previous interface bindings are invalidated. DCE/RPC Fragmented requests . The context id field in any other fragment can contain any value. Samba later than 3. Samba (all versions) Uses just the MID to define a ”thread”.20 and earlier Any amount of Bind requests can be made. DCE/RPC Fragmented requests . Samba (all versions) The context id that is ultimately used for the request is contained in the last fragment. Any binding after that must use the Alter Context request. Windows Vista The opnum that is ultimately used for the request is contained in the first fragment.Operation number Each fragment in a fragmented request carries an operation number (opnum) which is more or less a handle to a function offered by the interface. If another Bind is made. DCE/RPC Stub data byte order The byte order of the stub data is determined differently for Windows and Samba. Samba (all versions) Windows 2000 Windows 2003 Windows XP The opnum that is ultimately used for the request is contained in the last fragment. 82 . The opnum field in any other fragment can contain any value. The opnum field in any other fragment can contain any value.Context ID Each fragment in a fragmented request carries the context id of the bound interface it wants to make the request to. If a Bind after a successful Bind is made.Windows (all versions) Uses a combination of PID and MID to define a ”thread”. all previous interface bindings are invalidated. Multiple Bind Requests A Bind request is the first request that must be made in a connection-oriented DCE/RPC session in order to specify the interface/interfaces that one wants to communicate with. Windows (all versions) For all of the Windows versions.0.20 Another Bind request can be made if the first failed and no interfaces were successfully bound to. The allowed range for this option is 1514 . max frag len Specifies the maximum fragment size that will be added to the defragmention module. If the memcap is reached or exceeded. disabled Disables the preprocessor. smb 83 .65535. ’. Run-time memory includes any memory allocated after configuration. Global Configuration preprocessor dcerpc2 The global dcerpc2 configuration is required. Default is 100 MB.) memcap Only one event. Only one global dcerpc2 configuration can be specified. By default this value is turned off. events Specifies the classes of events to enable. Default is to do defragmentation. When the preprocessor is disabled only the memcap option is applied when specified with the configuration. alert. Default is set to -1. it is truncated before being added to the defragmentation module. (See Events section for an enumeration and explanation of events. The global preprocessor configuration name is dcerpc2 and the server preprocessor configuration name is dcerpc2 server.’ event-list "memcap" | "smb" | "co" | "cl" 0-65535 Option explanations memcap Specifies the maximum amount of run-time memory that can be allocated. If a fragment is greater than this size. events [memcap. the defaults will be used. co] events [memcap. it will override the default configuration. in effect. max_frag_len 14440 disable_defrag. The default and net options are mutually exclusive.conf CANNOT be used. co. smb. Note that port and ip variables defined in snort. Default is disabled. Alert on events related to connectionless DCE/RPC processing. cl Stands for connectionless DCE/RPC. Alert on events related to connection-oriented. events [memcap. This option is useful in inline mode so as to potentially catch an exploit early before full defragmentation is done. A value of 0 supplied as an argument to this option will. cl]. reassemble threshold Specifies a minimum number of bytes in the DCE/RPC desegmentation and defragmentation buffers before creating a reassembly packet to send to the detection engine. memcap 300000. co. co Stands for connection-oriented DCE/RPC. For any dcerpc2 server configuration. smb. default values will be used for the default configuration. When processing DCE/RPC traffic. disable this option. Zero or more net configurations can be specified. At most one default configuration can be specified. The net option supports IPv6 addresses. the default configuration is used if no net configurations match.Alert on events related to SMB processing. If a net configuration matches. Option examples memcap 30000 max_frag_len 16840 events none events all events smb events co events [co] events [smb.. events smb memcap 50000. If no default configuration is specified. A net configuration matches if the packet’s server IP address matches an IP address or net specified in the net configuration. A dcerpc2 server configuration must start with default or net options. Option syntax 84 . if non-required options are not specified. ’ share-list word | ’"’ word ’"’ | ’"’ var-word ’"’ graphical ASCII characters except ’.’ ’"’ ’]’ ’[’ 0-255 Because the Snort main parser treats ’$’ as the start of a variable and tries to expand it.’ ’"’ ’]’ ’[’ ’$’ graphical ASCII characters except ’. policy Specifies the target-based policy to use when processing. The configuration will only apply to the IP addresses and nets supplied as an argument. Defaults are ports 139 and 445 for SM. tcp 135.Option default net policy detect Argument NONE <net> <policy> <detect> Required YES YES NO Default NONE NONE policy WinXP detect [smb [139. 593 for RPC over HTTP server and 80 for RPC over HTTP proxy. rpc-over-http-server 593] autodetect [tcp 1025:. Default is ”WinXP”. Option explanations default Specifies that this configuration is for the default server configuration.’ port-list port | port-range ’:’ port | port ’:’ | port ’:’ port 0-65535 share | ’[’ share-list ’]’ share | share ’.20" "none" | detect-opt | ’[’ detect-list ’]’ detect-opt | detect-opt ’.0. udp 135. 135 for TCP and UDP.0. udp 1025:.445]. 85 . shares with ’$’ must be enclosed quotes. detect Specifies the DCE/RPC transport and server ports that should be detected on for the transport.22" | "Samba-3.’ detect-list transport | transport port-item | transport ’[’ port-list ’]’ "smb" | "tcp" | "udp" | "rpc-over-http-proxy" | "rpc-over-http-server" port-item | port-item ’. net Specifies that this configuration is an IP or net specific configuration. rpc-over-http-server 1025:] DISABLED (The preprocessor autodetects on all proxy ports by default) NONE smb max chain 3 ip | ’[’ ip-list ’]’ ip | ip ’. This option is useful if the RPC over HTTP proxy configured with the detect option is only used to proxy DCE/RPC traffic.168. "C$"] smb_max_chain 1 86 ..10 net 192. tcp 135. the preprocessor will always attempt to autodetect for ports specified in the detect configuration for rpc-over-http-proxy.0.0.0/24. RPC over HTTP server. tcp [135.255.168.0/24 net [192.0. rpc-over-http-server [1025:6001.168.0/24] net 192.255. udp.3003:]] autodetect [tcp.0.168. Default maximum is 3 chained commands.168. rpc-over-http-server [593. "C$"] smb_invalid_shares ["private".autodetect Specifies the DCE/RPC transport and server ports that the preprocessor should attempt to autodetect on for the transport.0. Option examples net 192. UDP and RPC over HTTP server.0.445] detect [smb [139. This is because the proxy is likely a web server and the preprocessor should not look at all web traffic.2103]] detect [smb [139. It would be very uncommon to see SMB on anything other than ports 139 and 445.0. A value of 0 disables this option. feab:45b3:ab92:8ac4:d322:007f:e5aa:7845] policy Win2000 policy Samba-3.0/255. smb max chain Specifies the maximum amount of AndX command chaining that is allowed before an alert is generated. tcp] detect [smb 139. no autodetect http proxy ports By default.22 detect none detect smb detect [smb] detect smb 445 detect [smb 445] detect smb [139. Default is empty. Defaults are 1025-65535 for TCP.445]] detect [smb. udp 135.445]. Note that most dynamic DCE/RPC ports are above 1024 and ride directly over TCP or UDP. feab:45b3::/32] net [192.10.168. Default is to autodetect on RPC over HTTP proxy detect ports. udp 2025:] autodetect [tcp 2025:.3003:] autodetect [tcp [2025:3001. udp] autodetect [tcp 2025:. This value can be set from 0 to 255.6005:]] smb_invalid_shares private smb_invalid_shares "private" smb_invalid_shares "C$" smb_invalid_shares [private. smb invalid shares Specifies SMB shares that the preprocessor should alert on if an attempt is made to connect to them via a Tree Connect or Tree Connect AndX. The autodetect ports are only queried if no detect transport/ports match the packet.TCP/UDP. detect smb.10. rpc-over-http-server 593]. udp 135.4. detect [smb.56. smb_max_chain 1 preprocessor dcerpc2_server: \ net [10. Either a request was made by the server or a response was given by the client.4. Positive Response (only from server). udp 1025:. policy WinXP.0/24.4.0/24.445]. 3 87 . smb_max_chain 3 Complete dcerpc2 default configuration preprocessor dcerpc2: memcap 102400 preprocessor dcerpc2_server: \ default. no_autodetect_http_proxy_ports preprocessor dcerpc2_server: \ net [10. "ADMIN$"].10.4.0/24.57].4. \ smb_invalid_shares ["C$". tcp 135. \ detect [smb [139.445]. Valid types are: Message. rpc-over-http-server 593]. policy WinVista. udp 1025:. "D$". smb_max_chain 3 Events The preprocessor uses GID 133 to register events. policy Win2000 preprocessor dcerpc2_server: \ net [10.11. An SMB message type was specified in the header. tcp 135. autodetect none Default server configuration preprocessor dcerpc2_server: default. rpc-over-http-proxy 8081]. \ autodetect [tcp 1025:. autodetect tcp 1025:. Memcap events SID 1 Description If the memory cap is reached and the preprocessor is configured to alert.Configuration examples preprocessor dcerpc2_server: \ default preprocessor dcerpc2_server: \ default. rpc-over-http-server 1025:]. tcp]. Negative Response (only from server). Request (only from client). rpc-over-http-server 1025:]. policy Samba. udp 135. tcp. \ autodetect [tcp 1025:.feab:45b3::/126]. SMB events SID 2 Description An invalid NetBIOS Session Service type was specified in the header. \ smb_invalid_shares ["C$". autodetect [tcp. policy WinXP. "ADMIN$"] preprocessor dcerpc2_server: net 10.feab:45b3::/126]. policy Win2000 preprocessor dcerpc2_server: \ default. policy Win2000.10. \ detect [smb. \ detect [smb [139.10.11. policy WinVista. rpc-over-http-proxy [1025:6001. Retarget Response (only from server) and Keep Alive.6005:]]. The preprocessor will alert if the number of chained commands in a single request is greater than or equal to the configured amount (default is 3).) Some of the Core Protocol commands (from the initial SMB implementation) require that the byte count be some value greater than the data size exactly. the preprocessor will alert. the preprocessor will alert. there is no indication in the Tree Connect response as to whether the share is IPC or not.) The preprocessor will alert if the total amount of data sent in a transaction is greater than the total data count specified in the SMB command header. Some commands. If this field is zero. word count of the command header is invalid. the preprocessor has to queue the requests up and wait for a server response to determine whether or not an IPC share was successfully connected to (which is what the preprocessor is interested in). The preprocessor will alert if the format is not that which is expected for that command. (The byte count must always be greater than or equal to the data size. The preprocessor will alert if the byte count specified in the SMB command header is less than the data size specified in the SMB command. There should be under normal circumstances no more than a few pending Read* requests at a time and the preprocessor will alert if this number is excessive. data size specified in the command header. especially the commands from the SMB Core implementation require a data format field that specifies the kind of data that will be coming next. they are responded to in the order they were sent. so it need to be queued with the request and dequeued with the response. The preprocessor will alert if the total data count specified in the SMB command header is less than the data size specified in the SMB command header. the preprocessor will alert. it issues a Read* command to the server to tell it to send a response to the data it has written. There should be under normal circumstances no more than a few pending tree connects at a time and the preprocessor will alert if this number is excessive. such as Transaction. 88 . If a command requires this and the byte count is less than the minimum required byte count for that command. however. (Total data count must always be greater than or equal to current data size. If multiple Read* requests are sent to the server. Some commands require a specific format for the data. the preprocessor will alert. Unlike the Tree Connect AndX response. Some commands require a minimum number of bytes after the command header. For the Tree Connect command (and not the Tree Connect AndX command). If this offset puts us before data that has already been processed or after the end of payload. id of \xfeSMB is turned away before an eventable point is reached. Some SMB commands. The Read* request contains the file id associated with a named pipe instance that the preprocessor will ultimately send the data to. does not contain this file id. After a client is done writing data using the Write* commands. The preprocessor will alert if the byte count minus a predetermined amount based on the SMB command is not equal to the data size. The server response. Many SMB commands have a field containing an offset from the beginning of the SMB header to where the data the command is carrying starts.4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 The SMB id does not equal \xffSMB. In this case the preprocessor is concerned with the server response. The preprocessor will alert if the remaining NetBIOS packet length is less than the size of the SMB command byte count specified in the command header. The preprocessor will alert if the NetBIOS Session Service length field contains a value less than the size of an SMB header. Note that since the preprocessor does not yet support SMB2. When a Session Setup AndX request is sent to the server. The preprocessor will alert if it sees this. The preprocessor will alert if it sees any of the invalid SMB shares configured. essentially connects to a share and disconnects from the same share in the same request and is anomalous behavior. essentially logins in and logs off in the same request and is anomalous behavior. however. The Tree Disconnect command is used to disconnect from that share. The preprocessor will alert if a non-last fragment is less than the size of the negotiated maximum fragment length. The preprocessor will alert if it sees this. Windows does not allow this behavior. however. however Samba does. The preprocessor will alert if the remaining fragment length is less than the remaining packet size. With AndX command chaining it is possible to chain multiple Tree Connect AndX commands within the same request. The preprocessor will alert if in a Bind or Alter Context request. This is used by the client in subsequent requests to indicate that it has authenticated. the login handle returned by the server is used for the subsequent chained commands. The preprocessor will alert if the connection-oriented DCE/RPC minor version contained in the header is not equal to 0. 89 35 36 . The combination of a Session Setup AndX command with a chained Logoff AndX command. This is anomalous behavior and the preprocessor will alert if it happens. A Logoff AndX request is sent by the client to indicate it wants to end the session and invalidate the login handle. The preprocessor will alert if a fragment is larger than the maximum negotiated fragment length. essentially opens and closes the named pipe in the same request and is anomalous behavior. With commands that are chained after a Session Setup AndX request.) The Close command is used to close that file or named pipe. The preprocessor will alert if in a Bind or Alter Context request. The preprocessor will alert if the fragment length defined in the header is less than the size of the header. The combination of a Tree Connect AndX command with a chained Tree Disconnect command. Connection-oriented DCE/RPC events SID 27 28 29 30 31 32 33 34 Description The preprocessor will alert if the connection-oriented DCE/RPC major version contained in the header is not equal to 5. The combination of a Open AndX or Nt Create AndX command with a chained Close command. The preprocessor will alert if the connection-oriented DCE/RPC PDU type contained in the header is not a valid PDU type. there are no transfer syntaxes to go with the requested interface. there are no context items specified. the server responds (if the client successfully authenticates) which a user id or login handle. only one place in the SMB header to return a tree handle (or Tid). however Samba does. The byte order of the request data is determined by the Bind in connection-oriented DCE/RPC for Windows. Most evasion techniques try to fragment the data as much as possible and usually each fragment comes well below the negotiated transmit size. It is anomalous behavior to attempt to change the byte order mid-session. It looks for a Tree Connect or Tree Connect AndX to the share. An Open AndX or Nt Create AndX command is used to open/create a file or named pipe. Windows does not allow this behavior. This is anomalous behavior and the preprocessor will alert if it happens. only one place in the SMB header to return a login handle (or Uid). The preprocessor will alert if it sees this. A Tree Connect AndX command is used to connect to a share.21 22 23 24 25 26 With AndX command chaining it is possible to chain multiple Session Setup AndX commands within the same request. There is. There is. (The preprocessor is only interested in named pipes as this is where DCE/RPC requests are written to. 37 38 39 The call id for a set of fragments in a fragmented request should stay the same (it is incremented for each complete. so this should be considered anomalous behavior. The preprocessor will alert if the packet data length is less than the size of the connectionless header. The representation of the interface UUID is different depending on the endianness specified in the DCE/RPC previously requiring two rules . The preprocessor will alert if the context id changes in a fragment mid-request. It is necessary for a client to bind to a service before being able to make a call to it. however. a rule can simply ask the preprocessor. When a client sends a bind request to the server. it can. If a request if fragmented. The context id is a handle to a interface that was bound to. Instead of using flow-bits. If a request is fragmented. wrapping the sequence number space produces strange behavior from the server. whether or not the client has bound to a specific interface UUID and whether or not this client request is making a request to it. The operation number specifies which function the request is calling on the bound interface. Connectionless DCE/RPC events SID 40 41 42 43 Description The preprocessor will alert if the connectionless DCE/RPC major version is not equal to 4. it will specify the context id so the server knows what service the client is making a request to. This can eliminate false positives where more than one service is bound to successfully since the preprocessor can correlate the bind UUID to the context id used in the request. specify one or more service interfaces to bind to. The server will respond with the interface UUIDs it accepts as valid and will allow the client to make requests to those services. When a client makes a request.one for big endian and 90 . Each interface UUID is paired with a unique index (or context id) that future requests can use to reference the service that the client is making a call to. Each interface is represented by a UUID. A DCE/RPC request can specify whether numbers are represented as big endian or little endian.. this number should stay the same for all fragments. this number should stay the same for all fragments. The preprocessor will alert if it changes in a fragment mid-request. The preprocessor will alert if the opnum changes in a fragment mid-request. In testing. using this rule option. Syntax <uuid> [ ’. Many checks for data in the DCE/RPC request are only relevant if the DCE/RPC request is a first fragment (or full request). since subsequent fragments will contain data deeper into the DCE/RPC request. Also. equal to (’=’) or not equal to (’!’) the version specified. hexlong and hexshort will be specified and interpreted to be in big endian order (this is usually the default way an interface UUID will be seen and represented). i. if the any frag option is used to specify evaluating on all fragments. 4b324fc8-1670-01d3-1278-5a47bf6ee188. By default it is reasonable to only evaluate if the request is a first fragment (or full request). since the beginning of subsequent fragments are already offset some length from the beginning of the request.one for little endian.it either accepts or rejects the client’s wish to bind to a certain interface. will be looking at the wrong data on a fragment other than the first.e. Some versions of an interface may not be vulnerable to a certain exploit.any_frag.’ . 4b324fc8-1670-01d3-1278-5a47bf6ee188.’ <operator> 91 . by default the rule will only be evaluated for a first fragment (or full request. The any frag argument says to evaluate for middle and last fragments as well. For each Bind and Alter Context request. This tracking is required so that when a request is processed. Also. This option requires tracking client Bind and Alter Context requests as well as server Bind Ack and Alter Context responses for connection-oriented DCE/RPC in the preprocessor. say 5 bytes into the request (maybe it’s a length field).=1. The server response indicates which interfaces it will allow the client to make requests to . Optional arguments are an interface version and operator to specify that the version be less than (’<’). Flags (and a field in the connectionless header) are set in the DCE/RPC header to indicate whether the fragment is the first. A rule which is looking for data. As an example. 4b324fc8-1670-01d3-1278-5a47bf6ee188. An interface contains a version. This can be a source of false positives in fragmented DCE/RPC traffic. the client specifies a list of interface UUIDs along with a handle (or context id) for each interface UUID that will be used during the DCE/RPC session to reference the interface. greater than (’>’).<2. a middle or the last fragment. However. This option is used to specify an interface UUID. not a fragment) since most rules are written to start at the beginning of a request. a DCE/RPC request can be broken up into 1 or more fragments.any_frag. the context id used in the request can be correlated with the interface UUID it is a handle for. The preprocessor eliminates the need for two rules by normalizing the UUID. flow specific function call to an interface. After is has been determined that a client has bound to a specific; 15-18; 15,18-20; specified with this option. This option matches if any one of the opnums specified match the opnum of the DCE/RPC request. dce stub data Since most netbios rules were doing. 92 byte test and byte jump with dce. byte test Syntax <convert> ’,’ [ ’!’ ] <operator> ’,’ <value> [ ’,’ <offset> [ ’,’ "relative" ]] \ ’,’ "dce" convert operator value offset = = = = 1 | 2 | 4 (only with option "dce") ’<’ | ’=’ | ’>’ | ’&’ | ’ˆ’ 0-4294967295 . byte jump Syntax <convert> ’,’ <offset> [ ’,’ "relative" ] [ ’,’ "multiplier" <mult-value> ] \ [ ’,’ "align" ] [ ’,’ "post_offet" <adjustment-value> ] ’,’ "dce" convert offset mult-value adjustment-value = = = = 1 | 2 | 4 (only with option "dce") -65535 to 65535 0-65535 -65535 to 65535 Example. 93 94 <pattern> count = 1-255 pattern = any string Option Explanations count This dictates how many times a PII pattern must be matched for an alert to be generated. \d \D \l \L \w \W {num} ! △NOTE\w in this rule option does NOT match underscores. or nothing in between groups. Group. Unlike PCRE. Group. example: ” ?” matches an optional space. The SSNs are expected to have dashes between the Area. 95 . SSNs have no check digits. then it is the definition of a custom PII pattern. ? makes the previous character or escape sequence optional. Social Security numbers. Syntax sd_pattern: <count>. This covers Visa. Social Security numbers without dashes separating the Area. example: ”{3}” matches 3 digits. pattern This is where the pattern of the PII gets specified. email This pattern matches against email addresses. but the preprocessor will check matches against the list of currently allocated group numbers.S.This rule option specifies what type of PII a rule should detect. Mastercard. If the pattern specified is not one of the above built-in patterns. us social This pattern matches against 9-digit U. This behaves in a greedy manner. These numbers may have spaces. There are a few built-in patterns to choose from: credit card The ”credit card” pattern matches 15. Other characters in the pattern will be matched literally. us social nodashes This pattern matches U. Custom PII types are defined using a limited regex-style syntax. and Serial sections. dashes. \} matches { and } \? matches a question mark. and American Express. . The count is tracked across all packets in a session.S. Discover.and 16-digit credit card numbers. Credit card numbers matched this way have their check digits verified using the Luhn algorithm. \\ matches a backslash \{. and Serial sections. The following special characters and escape sequences are supported: matches any digit matches any non-digit matches any letter matches any non-letter matches any alphanumeric character matches any non-alphanumeric character used to repeat a character or escape sequence ”num” times. There are also many new preprocessor and decoder rules to alert on or drop packets with ”abnormal” encodings. • rf reserved flag: clear this bit on incoming packets. fields are cleared only if they are non-zero.Examples sd_pattern: 2. To enable the normalizer. 2./configure --enable-normalizer The normalize preprocessor is activated via the conf as outlined below. gid:138. Note that in the following.15 Normalizer When operating Snort in inline mode. normalizations will only be enabled if the selected DAQ supports packet replacement and is operating in inline mode. Also. phone numbers.) Caveats sd pattern is not compatible with other rule options. use the following when configuring Snort: . rev:1. sid:1000. sd_pattern: 5. Alerts when 2 social security numbers (with dashes) appear in a session. • NOP all options octets. 96 . Trying to use other rule options with sd pattern will result in an error message. \ sd_pattern:4. Rules using sd pattern must use GID 138. Alerts on 5 U.us_social. • TTL normalization if enabled (explained below).2.(\d{3})\d{3}-\d{4}. IP4 Normalizations IP4 normalizations are enabled with: preprocessor normalize_ip4: [df]. If a policy is configured for inline test or passive mode. Optional normalizations include: • df don’t fragment: clear this bit on incoming packets.S. it is helpful to normalize packets to help minimize the chances of evasion. following the format (123)456-7890 Whole rule example: alert tcp $HOME_NET $HIGH_PORTS -> $EXTERNAL_NET $SMTP_PORTS \ (msg:"Credit Card numbers sent over email". • Clear the differentiated services field (formerly TOS). metadata:service smtp. any normalization statements in the policy config are ignored.credit_card. [rf] Base normalizations enabled with ”preprocessor normalize ip4” include: • Truncate packets with excess payload to the datagram length specified in the IP header. • Clear the reserved bits in the TCP header. • Clear the urgent pointer and the urgent flag if there is no payload. 12. 13 } <alt_checksum> ::= { 14.255) Base normalizations enabled with ”preprocessor normalize tcp” include: • Remove data on SYN. • NOP all options octets in hop-by-hop and destination options extension headers.IP6 Normalizations IP6 normalizations are enabled with: preprocessor normalize_ip6 Base normalizations enabled with ”preprocessor normalize ip6” include: • Hop limit normalizaton if enabled (explained below). TCP Normalizations TCP normalizations are enabled with: preprocessor normalize_tcp: \ [ips] [urp] \ [ecn <ecn_type>]. 5 } <echo> ::= { 6. 7 } <partial_order> ::= { 9.. \ [opts [allow <allowed_opt>+]] <ecn_type> ::= stream | packet <allowed_opt> ::= \ sack | echo | partial_order | conn_count | alt_checksum | md5 | <num> <sack> ::= { 4. 97 . 10 } <conn_count> ::= { 11. 15 } <md5> ::= { 19 } <num> ::= (3. • Clear the urgent pointer if the urgent flag is not set.. • ecn stream clear ECN flags if usage wasn’t negotiated.255) 98 . • opts NOP all option bytes other than maximum segment size. and any explicitly allowed with the allow keyword. window scaling. Should also enable require 3whs. NOP the timestamp octets. You can allow options to pass by name or number. Optional normalizations include: • ips ensure consistency in retransmitted data (also forces reassembly policy to ”first”).• Set the urgent pointer to the payload length if it is greater than the payload length. • urp urgent pointer: don’t adjust the urgent pointer if it is greater than payload length.. or valid but not negotiated. • Remove any data from RST packet. • Clear any option padding bytes.255) <new_ttl> ::= (<min_ttl>+1. • opts MSS and window scale options are NOP’d if SYN. block the packet. • Trim data to MSS. Any segments that can’t be properly reassembled will be dropped. • opts if timestamp is present but invalid. • Clear the urgent flag if the urgent pointer is not set. • ecn packet clear ECN flags on a per packet basis (regardless of negotiation). as follows: config min_ttl: <min_ttl> config new_ttl: <new_ttl> <min_ttl> ::= (1. • opts trim payload length to MSS if longer. • opts if timestamp was negotiated but not present. • Trim data to window.. timestamp. • opts clear TS ECR if ACK flag is not set. A packet will be dropped if either a decoder config drop option is in snort.conf.map under etc directory is also updated with new decoder and preprocessor rules. See doc/README. To change the rule type or action of a decoder/preprocessor rule.conf that reference the rules files.3. decoder events will not be generated regardless of whether or not there are corresponding rules for the event.6: preprocessor stream5_tcp: min_ttl <#> By default min ttl = 1 (TTL normalization is disabled).rules To disable any rule. var PREPROC_RULE_PATH /path/to/preproc_rules . e.. define the path to where the rules are located and uncomment the include lines in snort. then if a packet is received with a TTL ¡ min ttl.If new ttl ¿ min ttl. include $PREPROC_RULE_PATH/preprocessor. these options will take precedence over the event type of the rule.rules and preprocessor./configure --enable-decoder-preprocessor-rules The decoder and preprocessor rules are located in the preproc rules/ directory in the top level source tree.rules respectively. They also allow one to specify the rule type or action of a decoder or preprocessor event on a rule by rule basis. 2.rules include $PREPROC_RULE_PATH/decoder.decode for config options that control decoder events. Any one of the following rule types can be used: alert log pass drop sdrop reject For example one can change: 99 .8. Note that this configuration item was deprecated in 2. and have the names decoder. Decoder config options will still determine whether or not to generate decoder events.conf.3 Decoder and Preprocessor Rules Decoder and preprocessor rules allow one to enable and disable decoder and preprocessor events on a rule by rule basis. Of course.conf or the decoder or preprocessor rule type is drop. just replace alert with the desired rule type. These files are updated as new decoder and preprocessor events are added to Snort. The gen-msg. config enable decode drops. if config disable decode alerts is in snort.g. When TTL normalization is turned on the new ttl is set to 5 by default. the drop cases only apply if Snort is running inline. Also note that if the decoder is configured to enable drops. To enable these rules in snort. 2. the TTL will be set to new ttl. just comment it with a # or remove the rule completely from the file (commenting is recommended).1 Configuring The following options to configure will enable decoder and preprocessor rules: $ .. For example. decode.) to drop (as well as alert on) packets where the Ethernet protocol is IPv4 but version field in IPv4 header has a value other than 4.) to drop ( msg: "DECODE_NOT_IPV4_DGRAM". you also have to remove the decoder and preprocessor rules and any reference to them from snort.3. The generator ids ( gid ) for different preprocessors and the decoder are as follows: 2. classtype:protocol-command-decode.2 Reverting to original behavior If you have configured snort to use decoder and preprocessor rules.alert ( msg: "DECODE_NOT_IPV4_DGRAM".gre and the various preprocessor READMEs for descriptions of the rules in decoder.conf.rules. classtype:protocol-command-decode. This option applies to rules not specified and the default behavior is to alert. README. otherwise they will be loaded. gid: 116.rules and preprocessor. \ metadata: rule-type decode . the following config option in snort. See README. rev: 1. rev: 1. sid: 1.conf will make Snort revert to the old behavior: config autogenerate_preprocessor_decoder_rules Note that if you want to revert to the old behavior. \ metadata: rule-type decode . sid: 1.4 Event Processing Snort provides a variety of mechanisms to tune event processing to suit your needs: 100 . 2. gid: 116. This can be tuned to significantly reduce false alarms. sig_id 1. \ new_action drop. \ track by_src. seconds <s>.allow a maximum of 100 connection attempts per second from any one IP address. \ track <by_src|by_dst|by_rule>.10. sig_id 2. \ count <c>. which is optional. and block further connections from that IP address for 10 seconds: rate_filter \ gen_id 135. Examples Example 1 . and the first applicable action is taken.1 Rate Filtering rate filter provides rate based attack prevention by allowing users to configure a new action to take for a specified time when a given rate is exceeded. 2. seconds 0. This is covered in section 3. in which case they are evaluated in the order they appear in the configuration file. \ count 100. Multiple rate filters can be defined on the same rule. and block further connection attempts from that IP address for 10 seconds: rate_filter \ gen_id 135. • Rate Filters You can use rate filters to change a rule action when the number or rate of events indicates a possible attack.7. timeout 10 101 . \ new_action drop. \ count 100.4.all are required except apply to.• Detection Filters You can use detection filters to specify a threshold that must be exceeded before a rule generates an event. \ timeout <seconds> \ [. Format Rate filters are used as standalone configurations (outside of a rule) and have the following format: rate_filter \ gen_id <gid>. sig_id <sid>. timeout 10 Example 2 . apply_to <ip-list>] The options are described in the table below . \ new_action alert|drop|pass|log|sdrop|reject. • Event Filters You can use event filters to reduce the number of logged events for noisy rules. \ track by_src.allow a maximum of 100 successful simultaneous connections from any one IP address. • Event Suppression You can completely suppress the logging of unintersting events. seconds 1. sig_id <sid>. destination IP address. track by rule and apply to may not be used together. sdrop and reject are conditionally compiled with GIDS. For rules related to Stream5 sessions. This can be tuned to significantly reduce false alarms. If t is 0. Format event_filter \ gen_id <gid>. revert to the original rule action after t seconds. \ type <limit|threshold|both>. the time period over which count is accrued. the maximum number of rule matches in s seconds before the rate filter limit to is exceeded. 2. drop. even if the rate falls below the configured limit. \ 102 . seconds <s> threshold \ gen_id <gid>. • both Alerts once per time interval after seeing m occurrences of the event. \ type <limit|threshold|both>. restrict the configuration to only to source or destination IP address (indicated by track parameter) determined by <ip-list>. c must be nonzero value. An event filter may be used to manage number of alerts after the rule action is enabled by rate filter.4. rate filter may be used to detect if the number of connections to a specific server exceed a specific count. new action replaces rule action for t seconds. \ track <by_src|by_dst>. This means the match statistics are maintained for each unique source IP address. There are 3 types of event filters: • limit Alerts on the 1st m events during the time interval. • threshold Alerts every m times we see this event during the time interval. reject. sig_id <sid>.2 Event Filtering Event filtering can be used to reduce the number of logged alerts for noisy rules by limiting the number of times a particular event is logged during a specified time interval. \ count <c>. for each unique destination IP address. Note that events are generated during the timeout period. For example. track by rule and apply to may not be used together. \ track <by_src|by_dst>. then ignores events for the rest of the time interval. then ignores any additional events during the time interval. 0 seconds only applies to internal rules (gen id 135) and other use will produce a fatal error by Snort. or they are aggregated at rule level. 0 seconds means count is a total count instead of a specific rate. then rule action is never reverted back. or by rule. and sdrop can be used only when snort is used in inline mode. source and destination means client and server respectively.Option track by src | by dst | by rule count c seconds s new action alert | drop | pass | log | sdrop | reject timeout t apply to <ip-list> Description rate is tracked either by source IP address. seconds <s> threshold is an alias for event filter. however. if they do not block an event from being logged. \ type threshold. (gen id 0. then ignores any additional events during the time interval. If gen id is also 0. seconds 60 Limit logging to every 3rd event: event_filter \ gen_id 1. or for each unique destination IP addresses. \ count 3. track by_src. ! △NOTE can be used to suppress excessive rate filter alerts. Standard filtering tests are applied first. Specify the signature ID of an associated rule. sig_id 1851. then ignores events for the rest of the time interval. the global filtering test is applied. sig id != 0 is not allowed). sig id pair. s must be nonzero value. Type threshold alerts every m times we see this event during the time interval. Global event filters do not override what’s in a signature or a more specific stand-alone event filter. sig id 0 can be used to specify a ”global” threshold that applies to all rules.all are required. threshold is deprecated and will not be supported in future releases. type limit alerts on the 1st m events during the time interval. Such events indicate a change of state that are significant to the user monitoring the network. time period over which count is accrued. sig_id 1852. track by_src. \ type limit. Type both alerts once per time interval after seeing m occurrences of the event. rate is tracked either by source IP address. This means count is maintained for each unique source IP addresses. c must be nonzero value. or destination IP address. Both formats are equivalent and support the options described below . Thresholds in a rule (deprecated) will override a global event filter. Ports or anything else are not tracked. then the filter applies to all rules.count <c>. Examples Limit logging to 1 event per 60 seconds: event_filter \ gen_id 1. count 1. Snort will terminate with an error while reading the configuration information. event filters with sig id 0 are considered ”global” because they apply to all rules with the given gen id. seconds 60 103 \ . gen id 0. number of rule matching in s seconds that will cause event filter limit to be exceeded. Option gen id <gid> sig id <sid> type limit|threshold|both Description Specify the generator ID of an associated rule. If more than one event filter is Only one event applied to a specific gen id. the first new action event event filters of the timeout period is never suppressed. track by src|by dst count c seconds s ! △NOTE filter may be defined for a given gen id. sig id. sig id 0 specifies a ”global” filter because it applies to all sig ids for the given gen id. \ type limit. You may also combine one event filter and several suppressions to the same non-zero SID. sig_id 0.4. \ count 1. track by_src. seconds 60 Limit to logging 1 event per 60 seconds per IP.. \ suppress \ gen_id <gid>. \ count 1. track by_src. event filters are handled as part of the output system. Format The suppress configuration has two forms: suppress \ gen_id <gid>. track by_src. sig_id <sid>. sig_id 1853. SIDs. seconds 60 Events in Snort are generated in the usual way. \ type limit. but only if we exceed 30 events in 60 seconds: event_filter \ gen_id 1. sig_id <sid>.map for details on gen ids. Read genmsg. You may apply multiple suppressions to a non-zero SID. triggering each rule for each event generator: event_filter \ gen_id 0. Suppression are standalone configurations that reference generators. and IP addresses via an IP list .Limit logging to just 1 event per 60 seconds. \ count 30. ip <ip-list> 104 . sig_id 0. seconds 60 Limit to logging 1 event per 60 seconds per IP triggering each rule (rule gen id is 1): event_filter \ gen_id 1. Suppression tests are performed prior to either standard or global thresholding tests. \ track <by_src|by_dst>. \ type both. This allows a rule to be completely suppressed. Users can also configure a memcap for threshold with a “config:” option: config event_filter: memcap <bytes> # this is deprecated: config threshold: memcap <bytes> 2. track by_src. gen id 0. If track is provided. ip 10. 105 . Examples Suppress this event completely: suppress gen_id 1.1. You can’t log more than the max event number that was specified. The default value is 8. Specify the signature ID of an associated rule. ip 10. This is optional. For example. only 8 events will be stored for a single packet or stream.Option gen id <gid> sig id <sid> track by src|by dst ip <list> Description Specify the generator ID of an associated rule. The default value is 3. 1.1.1. if the event queue has a max size of 8.4. 3. order events This argument determines the way that the incoming events are ordered. log This determines the number of events to log for a given packet or stream.’. but if present. Restrict the suppression to only source or destination IP addresses (indicated by track parameter) determined by ¡list¿. max queue This determines the maximum size of the event queue. ip must be provided as well. such as max content length or event ordering using the event queue. sig_id 1852: Suppress this event from this IP: suppress gen_id 1. sig id 0 can be used to specify a ”global” threshold that applies to all rules. sig_id 1852. sig id 0 specifies a ”global” filter because it applies to all sig ids for the given gen id. sig_id 1852.0/24 2.4 Event Logging Snort supports logging multiple events per packet/stream that are prioritized with different insertion methods. ip must be provided as well. 2. track by_dst.54 Suppress this event to this CIDR block: suppress gen_id 1. Suppress by source IP address or destination IP address.The highest priority (1 being the highest) events are ordered first. We currently have two different methods: • priority .1. Each require only a simple config option to snort. the statistics will be saved in these files. The filenames will have timestamps appended to them. The method in which events are ordered does not affect rule types such as pass. you must build snort with the --enable-perfprofiling option to the configure script.. The default value is content length) 106 . To use this feature. but change event order: config event_queue: order_events priority Use the default event queue values but change the number of logged events: config event_queue: log 2 2.Rules are ordered before decode or preprocessor alerts.5 Performance Profiling Snort can provide statistics on rule and preprocessor performance.• content length . log. When a file name is provided in profile rules or profile preprocs. \ sort <sort_option> \ [.5. These files will be found in the logging directory. etc. 2. a new file will be created each time Snort is run.1 Rule Profiling Format config profile_rules: \ print [all | <num>]. If append is not specified.conf and Snort will print statistics on the worst (or all) performers on exit. and rules that have a longer content are ordered before rules with shorter contents. alert. txt append • Print top 20 rules. sort by avg ticks (default configuration if option is turned on) config profile rules • Print all rules. sort total ticks • Print with default options.txt each time config profile rules: filename performance.txt with timestamp in filename config profile rules: Output Snort will print a table much like the following at exit. save results to performance.0 90054 45027. based on total time config profile rules: print 100.0 0. sorted by number of checks config profile rules: print all.0 92458 46229.0 Avg/Match Avg/Nonmatch ========= ============ 385698.0 107822 53911. sort total ticks print 20.0 46229.0 53911.txt config profile rules: filename rules stats .0 0. based on highest average time config profile rules: print 10. and append to file rules stats.0 45027. save results to perf.0 0. sort by avg ticks.0 Figure 2. filename perf.txt append • Print the top 10 rules.1: Rule Profiling Example Output Examples • Print all rules. sort checks • Print top 100 rules. sort avg ticks • Print all rules. will be high for rules that have no options) • Alerts (number of alerts generated from this rule) • CPU Ticks • Avg Ticks per Check • Avg Ticks per Match 107 print.2 Preprocessor Profiling Format config profile_preprocs: \ print [all | <num>], \ sort <sort_option> \ [, 108 109. 110 111 . threshold 5. \ suspend-timeout 300. then no action is taken other than to increment the count of the number of packets that should be fastpath’d or the rules that should be suspended. suspend-expensive-rules. config ppm: \ max-pkt-time 50. debug-pkt config ppm: \ max-rule-time 50. A summary of this information is printed out when snort exits. fastpath-expensive-packets. Example 2: The following suspends rules and aborts packet inspection. \ 112 . threshold 5 If fastpath-expensive-packets or suspend-expensive-rules is not used. These rules were used to generate the sample output that follows. • This implementation is software based and does not use an interrupt driven timing mechanism and is therefore subject to the granularity of the software based timing tests. 0 rules.0438 usecs....6. Due to the granularity of the timing measurements any individual packet may exceed the user specified packet or rule processing time limit. latency thresholding is presently only available on Intel and PPC platforms. Hence the reason this is considered a best effort approach. This was a conscious design decision because when a system is loaded. not just the processor time the Snort application receives. Therefore this implementation cannot implement a precise latency guarantee with strict timing guarantees. packet fastpathed. it is recommended that you tune your thresholding to operate optimally when your system is under load..15385 usecs PPM: Process-EndPkt[61] PPM: Process-BeginPkt[62] caplen=342 PPM: Pkt[62] Used= 65. 2. Sample Snort Exit Output Packet Performance Summary: max packet time : 50 usecs packet events : 1 avg pkt time : 0. • Since this implementation depends on hardware based high performance frequency counters. PPM: Process-BeginPkt[61] caplen=60 PPM: Pkt[61] Used= 8.Sample Snort Run-time Output .394 usecs Process-EndPkt[63] PPM: Process-BeginPkt[64] caplen=60 PPM: Pkt[64] Used= 8.21764 usecs PPM: Process-EndPkt[64] . after 113 .6 Output Modules Output modules are new as of version 1. not processor usage by Snort. the latency for a packet is based on the total system time.633125 usecs Rule Performance Summary: max rule time : 50 usecs rule events : 0 avg nc-rule time : 0.2675 usecs Implementation Details • Enforcement of packet and rule processing times is done after processing each rule.3659 usecs PPM: Process-EndPkt[62] PPM: PPM: PPM: PPM: Pkt-Event Pkt[63] used=56. The output modules are run when the alert or logging subsystems of Snort are called. Therefore. Latency control is not enforced after each preprocessor. • Time checks are made based on the total system time. 1 nc-rules tested. They allow Snort to be much more flexible in the formatting and presentation of output to its users. Process-BeginPkt[63] caplen=60 Pkt[63] Used= 8. When multiple plugins of the same type (log.6.. they are stacked and called in sequence when an event occurs. output plugins send their data to /var/log/snort by default or to a user directed directory (using the -l command line switch). As with the standard logging and alerting systems. 114 . giving users greater flexibility in logging alerts. alert) are specified.1 alert syslog This module sends alerts to the syslog facility (much like the -s command line switch).the preprocessors and detection engine. This module also allows the user to specify the logging facility and priority within the Snort config file. The format of the directives in the config file is very similar to that of the preprocessors. 0.1. You may specify ”stdout” for terminal output.6. only brief single-line entries are logged. By default.6.13 for more information. The default port is 514.1:514.1. The default host is 127. Example output alert_fast: alert. The minimum is 1 KB.1. a hostname and port can be passed as options. <facility> <priority> <options> 2. • limit: an optional limit on file size which defaults to 128 MB. • packet: this option will cause multiline entries with full packet headers to be logged. See 2. The name may include an absolute or relative path.Options • log cons • log ndelay • log perror • log pid Format alert_syslog: \ <facility> <priority> <options> ! △NOTE As WIN32 does not run syslog servers locally by default.fast 115 . output alert_syslog: \ [host=<hostname[:<port>].] \ <facility> <priority> <options> Example output alert_syslog: host=10. The default name is ¡logdir¿/alert. Format output alert_fast: [<filename> ["packet"] [<limit>]] <limit> ::= <number>[(’G’|’M’|K’)] • filename: the name of the log file. See 2. The name may include an absolute or relative path. The default name is ¡logdir¿/alert.6. The name may include an absolute or relative path. See 2. External programs/processes can listen in on this socket and receive Snort alert and packet data in real time.5 log tcpdump The log tcpdump module logs packets to a tcpdump-formatted file.4 alert unixsock Sets up a UNIX domain socket and sends alert reports to it. This output method is discouraged for all but the lightest traffic situations.6.2. Format output log_tcpdump: [<filename> [<limit>]] <limit> ::= <number>[(’G’|’M’|K’)] • filename: the name of the log file. Format alert_unixsock Example output alert_unixsock 2. Format output alert_full: [<filename> [<limit>]] <limit> ::= <number>[(’G’|’M’|K’)] • filename: the name of the log file. a directory will be created per IP.6.13 for more information. The alerts will be written in the default logging directory (/var/log/snort) or in the logging directory specified at the command line.6.13 for more information. When a sequence of packets is to be logged. The minimum is 1 KB. You may specify ”stdout” for terminal output. Example output alert_full: alert. The creation of these files slows Snort down considerably. the aggregate size is used to test the rollover condition. The default name is ¡logdir¿/snort. These files will be decoded packet dumps of the packets that triggered the alerts.log.6. A UNIX timestamp is appended to the filename. This is useful for performing post-process analysis on collected traffic with the vast number of tools that are available for examining tcpdump-formatted files.3 alert full This will print Snort alert messages with full packet headers. 116 . • limit: an optional limit on file size which defaults to 128 MB. This is currently an experimental interface. Inside the logging directory.full 2. • limit: an optional limit on file size which defaults to 128 MB. requires post processing base64 . If you choose this option. then data for IP and TCP options will still be represented as hex because it does not make any sense for that data to be ASCII.3x the size of the binary Searchability . The arguments to this plugin are the name of the database to be logged to and a parameter list. This is the only option where you will actually lose data.impossible without post processing Human readability .log 2.6. Non-ASCII Data is represented as a ‘. it will connect using a local UNIX domain socket.<. Storage requirements .Password used if the database demands password authentication sensor name . <database type>. or socket filename extension for UNIX-domain connections.Specify your own name for this Snort sensor. Without a host name.Represent binary data as an ASCII string.Represent binary data as a base64 string.not readable requires post processing ascii . one will be generated automatically encoding .>) Searchability .3 for example usage. More information on installing and configuring this module can be found on the [91]incident. TCP/IP communication is used. port .very good Human readability . <parameter list> The following parameters are available: host . Format database: <log | alert>. You can choose from the following options.not readable unless you are a true geek.’.How much detailed data do you want to store? The options are: full (default) .very good detail . So i leave the encoding option to you.very good for searching for a text string impossible if you want to search for binary human readability .slightly larger than the binary because some characters are escaped (&.Log all details of a packet that caused an alert (including IP/TCP options and the payload) 117 .Because the packet payload and option data is binary. Storage requirements .Port number to connect to at the server host.Database username for authentication password . If a non-zero-length string is specified. Each has its own advantages and disadvantages: hex (default) . see Figure 2. If you do not specify a name. dbname .Host to connect to.Database name user .Example output log_tcpdump: snort. Blobs are not used because they are not portable across databases.Represent binary data as a hex string.6 database This module from Jed Pickel sends Snort data to a variety of SQL databases. there is no one simple and portable way to store it in a database.org web page.∼1.2x the size of the binary Searchability . Parameters are specified with the format parameter = argument. Storage requirements . the plugin will be called on the log output chain. log and alert. mysql. These are mssql. See section 3. Format output alert_csv: [<filename> [<format> [<limit>]]] <format> ::= "default"|<list> <list> ::= <field>(. You may specify ”stdout” for terminal output.7 csv The csv output plugin allows alert data to be written in a format easily importable to a database.7. Setting the type to log attaches the database logging functionality to the log facility within the program. and protocol) Furthermore.output database: \ log. source port.<field>)* <field> ::= "dst"|"src"|"ttl" . The output fields and their order may be customized. destination ip. Setting the type to alert attaches the plugin to the alert output chain within the program. If the formatting option is ”default”. and odbc. destination port. The default name is ¡logdir¿/alert.. There are two logging types available. ! △NOTE The database output plugin does not have the ability to handle alerts that are generated by using the tag keyword. The name may include an absolute or relative path.3: Database Output Plugin Configuration fast . The following fields are logged: timestamp. There are five database types available in the current version of the plugin. • format: The list of formatting options is below. If you set the type to log. <limit> ::= <number>[(’G’|’M’|K’)] • filename: the name of the log file. 2.5 for more details.csv. You severely limit the potential of some analysis applications if you choose this option. postgresql. dbname=snort user=snort host=localhost password=xyz Figure 2. oracle. – timestamp – sig generator – sig id – sig rev – msg – proto – src – srcport – dst 118 .6.. mysql. source ip. tcp flags. but this is still the best choice for some applications. the output is in the order of the formatting options listed. Set the type to match the database you are using.Log only a minimum amount of data. signature. there is a logging method and database type that must be defined. csv default output alert_csv: /var/log/alert.8 unified The unified output plugin is designed to be the fastest possible method of logging Snort events.–.h. The alert file contains the high-level details of an event (eg: IPs. The name unified is a misnomer. The unified output plugin logs events in binary format. The log file contains the detailed packet information (a packet dump with the associated event ID). <limit <file size limit in MB>] 119 . Both file types are written in a binary format described in spo unified. port.csv timestamp. <limit <file size limit in MB>] output log_unified: <base file name> [. msg 2. an alert file. allowing another programs to handle complex logging mechanisms that would otherwise diminish the performance of Snort. message id).6. protocol. as the unified output plugin creates two different files. Format output alert_unified: <base file name> [. and a log file. Example output alert_csv: /var/log/alert. See 2. ! △NOTE Files have the file creation time (in Unix Epoch format) appended to each file when it is created.13 for more information.6. The minimum is 1 KB. alert logging will only log events and is specified with alert unified2. then MPLS labels will be not be included in unified2 events.Example output alert_unified: snort.log. mpls_event_types] Example output output output output alert_unified2: filename snort.log. nostamp] output unified2: \ filename <base file name> [. or true unified logging. For more information on Prelude.alert. To use alert prelude.prelude-ids. If option mpls event types is not used. see. mpls_event_types] output log_unified2: \ filename <base filename> [. packet logging. The alert prelude output plugin is used to log to a Prelude database.alert.log. MPLS labels can be included in unified2 events. Use option mpls event types to enable this. nostamp log_unified2: filename snort. limit 128. Likewise.10 alert prelude ! △NOTE support to use alert prelude is not built in by default. nostamp] [. snort must be built with the –enable-prelude argument passed to . Format output alert_unified2: \ filename <base filename> [. limit 128. Unified2 can work in one of three modes. <limit <size in MB>] [. limit 128. To include both logging styles in a single. When MPLS support is turned on.6. ! △NOTE By default. nostamp] [.9 unified 2 The unified2 output plugin is a replacement for the unified output plugin.6. Packet logging includes a capture of the entire packet and is specified with log unified2. limit 128.log. See section 2. nostamp unified2: filename merged. It has the same performance characteristics. limit 128 2. unified file. nostamp. unified 2 files have the file creation time (in Unix Epoch format) appended to each file when it is created.or Format output alert_prelude: \ 120 .6. simply specify unified2. mpls_event_types 2. <limit <size in MB>] [. but a slightly different logging format./configure. nostamp unified2: filename merged. <limit <size in MB>] [. alert logging. limit 128 output log_unified: snort.8 on unified logging for more information. com/. Format output alert_aruba_action: \ <controller address> <secrettype> <secret> <action> The following parameters are required: controller address . see type. the log null plugin was introduced./configure. Communicates with an Aruba Networks wireless mobility controller to change the status of authenticated users.arubanetworks. This is equivalent to using the -n command line option but it is able to work within a ruletype.12 alert aruba action ! △NOTE Support to use alert aruba action is not built in by default. snort must be built with the –enable-aruba argument passed to . secrettype . one of ”sha1”.2. This allows Snort to take action against users on the Aruba controller to control their network privilege levels.alert output log_null } 2.11 log null Sometimes it is useful to be able to create rules that will alert to certain types of traffic but will not cause packet log entries. To use alert aruba action.Aruba mobility controller address.8. For more information on Aruba Networks access control. In Snort 1. Format output log_null Example output log_null # like using snort -n ruletype info { type alert output alert_fast: info.profile=<name of prelude profile> \ [ info=<priority number for info priority alerts>] \ [ low=<priority number for low priority alerts>] \ [ medium=<priority number for medium priority alerts>] Example output alert_prelude: profile=snort info=4 low=3 medium=2 2.6. ”md5” or ”cleartext”. 121 . 2. or a cleartext password.secret .Blacklist the station by disabling all radio communication. and IP-Frag policy (see section 2.7 Host Attribute Table Starting with version 2.13 Log Limits This section pertains to logs produced by alert fast.9. alert csv. service information is used instead of the ports when the protocol metadata in the rule matches the service corresponding to the traffic. unified and unified2 also may be given limits.Change the user´ role to the specified rolename.6. 2. s Example output alert_aruba_action: \ 10.1 Configuration Format attribute_table filename <path to file> 122 .1. For rule evaluation. represented as a sha1 or md5 hash. This information is stored in an attribute table.8.Action to apply to the source IP address of the traffic generating an alert.3.6 cleartext foobar setrole:quarantine_role 2. When a configured limit is reached. ! △NOTE To use a host attribute table. Snort associates a given packet with its attribute data from the table. alert full.2).1) and TCP Stream reassembly policies (see section 2. Rollover works correctly if snort is stopped/restarted. 2. Snort has the capability to use information from an outside source to determine both the protocol for use with Snort rules.Authentication secret configured on the Aruba mobility controller with the ”aaa xml-api client” configuration command. action . blacklist . and log tcpdump.7. which is loaded at startup.2. the rule relies on the port information. Snort must be configured with the –enable-targetbased flag. The table is re-read during run time upon receipt of signal number 30. Those limits are described in the respective sections. If the rule doesn’t have protocol metadata. setrole:rolename . if applicable. limit will be exceeded. Limits are configured as follows: <limit> ::= <number>[(<gb>|<mb>|<kb>)] <gb> ::= ’G’|’g’ <mb> ::= ’M’|’m’ <kb> ::= ’K’|’k’ Rollover will occur at most once per second so if limit is too small for logging rate. the current log is closed and a new log is opened with a UNIX timestamp appended to the configured log name. or the traffic doesn’t have any matching service information. 2 Attribute Table File Format The attribute table uses an XML format and consists of two sections. The mapping section is optional. used to reduce the size of the file for common data elements. a mapping section. An example of the file format is shown below. and the host attribute section.9p1</ATTRIBUTE_VALUE> <CONFIDENCE>93</CONFIDENCE> 123 .2.168.7.1. . port. only the IP protocol (tcp. and any client attributes are ignored. udp. The confidence metric may be used to indicate the validity of a given service or client application and its respective elements.8. etc).<> <VERSION> <ATTRIBUTE_VALUE>6.1. the stream and IP frag information are both used.0</ATTRIBUTE_VALUE> <CONFIDENCE>89</CONFIDENCE> </VERSION> </APPLICATION> </CLIENT> </CLIENTS> </HOST> </ATTRIBUTE_TABLE> </SNORT_ATTRIBUTES> ! △NOTE2. The application and version for a given service attribute. and protocol (http. They will be used in a future release. That field is not currently used by Snort. but may be in future releases. Of the service With Snort attributes. for a given host entry. ssh. A DTD for verification of the Host Attribute Table XML file is provided with the snort packages. etc) are used. 124 . The IP stack fragmentation and stream reassembly is mimicked by the ”linux” configuration (see sections 2. Snort will inspect packets for a connection to 192. • Application Layer Preprocessors The application layer preprocessors (HTTP.168.1. sid:10000002. Connection Service Matches One of them The following rule will be inspected and alert on traffic to host 192. Conversely.234 port 2300 as telnet. HTTP Inspect is configured to inspect traffic on port 2300. if. SMTP.established. rules configured for specific ports that have a service metadata will be processed based on the service identified by the attribute table.. metadata: service telnet. flow:to_server. Below is a list of the common services used by Snort’s application layer preprocessors and Snort rules (see below).2. flow:to_server.234. When both service metadata is present in the rule and in the connection.1 and 2.168.168. Snort will ONLY inspect the rules that have the service that matches the connection. Snort uses the service rather than the port. a host running Red Hat 2.2). for example.234 port 2300 because it is identified as telnet. etc) make use of the SERVICE information for connections destined to that host on that port. alert tcp any any -> any 23 (msg:"Telnet traffic".7. • Alert: Rule Has Service Metadata. and TCP port 2300 is telnet. sid:10000001.168.1.) • Alert: Rule Has Multiple Service Metadata.1.established.3 Attribute Table Example In the example above. Attribute Table Affect on rules Similar to the application layer preprocessors.) 125 .168. For example.234 port 2300 because it is identified as telnet. even if the telnet portion of the FTP/Telnet preprocessor is only configured to inspect port 23. Connection Service Matches The following rule will be inspected and alert on traffic to host 192. HTTP Inspect will NOT process the packets on a connection to 192. metadata: service telnet.234 port 2300 because it is identified as telnet.2. The following few scenarios identify whether a rule will be inspected or not. This host has an IP address of 192. alert tcp any any -> any 23 (msg:"Telnet traffic". TCP port 22 is ssh (running Open SSH).6 is described.1.2. On that host. service smtp. If there are rules that use the service and other rules that do not but the port matches.. Telnet. 8. Packet has service + other rules with service The first rule will NOT be inspected and NOT alert on traffic to host 192. (Same effect as --dynamic-preprocessor-lib or --dynamic-preprocessor-lib-dir options). alert tcp any any -> any 2300 (msg:"Port 2300 traffic". flow:to_server.168. alert tcp any any -> any 2300 (msg:"SSH traffic".) • No Alert: Rule Has No Service Metadata.1. metadata: service telnet.234 port 2300 because the port matches.1. metadata: service ssh.established.1 Format <directive> <parameters> 2.• No Alert: Rule Has Service Metadata. sid:10000006.234 port 2300 because that traffic is identified as telnet. Snort must be configured with the --disable-dynamicplugin flag.168. 2. See chapter 4 for more 126 information on dynamic preprocessor libraries. Specify file. sid:10000007.1.established. alert tcp any any -> any 2300 (msg:"Port 2300 traffic". Port Matches The following rule will NOT be inspected and NOT alert on traffic to host 192. ! △NOTE To disable use of dynamic modules.8 Dynamic Modules Dynamically loadable modules were introduced with Snort 2. They can be loaded via directives in snort.established.168.) • Alert: Rule Has No Service Metadata. sid:10000004. flow:to_server. Or. Port Matches The following rule will be inspected and alert on traffic to host 192. alert tcp any any -> any 23 (msg:"Port 23 traffic". Connection Service Does Not Match.234 port 2300 because the port does not match.) 2. followed by the full or relative path to a directory of preprocessor shared libraries.established.established. flow:to_server. followed by the full or relative path to the shared library.) • Alert: Rule Has No Service Metadata. specify directory.6. Port Does Not Match The following rule will NOT be inspected and NOT alert on traffic to host 192. . but the service is ssh. sid:10000005.2 Directives Syntax dynamicpreprocessor [ file <shared library path> | directory <directory of shared libraries> ] Description Tells snort to load the dynamic preprocessor shared library (if file is used) or all dynamic preprocessor shared libraries (if directory is used). flow:to_server. flow:to_server.) alert tcp any any -> any 2300 (msg:"Port 2300 traffic".conf or via command-line options.234 port 2300 because the service is identified as telnet and there are other rules with that service.8.1. sid:10000003.168. g. To disable this behavior and have Snort exit instead of restart.2 Reloading a configuration First modify your snort.1 Enabling support To enable support for reloading a configuration.9. $ kill -SIGHUP <snort pid> ! △NOTE If reload support is not enabled. Specify file. add --enable-reload to configure when compiling. (Same effect as --dynamic-detection-lib or --dynamic-detection-lib-dir options).9. 2. followed by the full or relative path to a directory of detection rules shared). send Snort a SIGHUP signal. followed by the full or relative path to the shared library. See chapter 4 for more information on dynamic engine libraries. e. add --disable-reload-error-restart in addition to --enable-reload to configure when compiling. (Same effect as --dynamic-engine-lib or --dynamic-preprocessor-lib-dir options). however. 2.conf (the file passed to the -c option on the command line). followed by the full or relative path to the shared library. Or. 2. ! △NOTE This functionality is not currently supported in Windows. This option is enabled by default and the behavior is for Snort to restart if any nonreloadable options are added/modified/removed. to initiate a reload. 127 . specify directory. use the new configuration.3 below). Specify file. Or. A separate thread will parse and create a swappable configuration object while the main Snort packet processing thread continues inspecting traffic under the current configuration. Tells snort to load the dynamic detection rules shared library (if file is used) or all dynamic detection rules shared libraries (if directory is used). When a swappable configuration object is ready for use. specify directory.9. All newly created sessions will. See chapter 4 for more information on dynamic detection rules libraries. Note that for some preprocessors. There is also an ancillary option that determines how Snort should behave if any non-reloadable options are changed (see section 2. Snort will restart (as it always has) upon receipt of a SIGHUP. Then. existing session data will continue to use the configuration under which they were created in order to continue with proper state for that session. followed by the full or relative path to a directory of preprocessor shared libraries. the main Snort packet processing thread will swap in the new configuration to use and will continue processing under the new configuration. Modifying any of these options will cause Snort to restart (as a SIGHUP previously did) or exit (if --disable-reload-error-restart was used to configure Snort). • Any changes to output will require a restart. $ snort -c sn. Changes to the following options are not reloadable: attribute_table config alertfile config asn1 config chroot. i. config ppm: max-rule-time <int> rule-log config profile_rules 128 .9. Those parameters are listed below the relevant config option or preprocessor.g. etc. startup memory allocations.! △NOTEconfiguration will still result in Snort fatal erroring. Reloadable configuration options of note: • Adding/modifying/removing text rules and variables are reloadable. any new/modified/removed shared objects will require a restart.e. dynamicengine and dynamicpreprocessor are not reloadable.conf -T 2. so you should test your new configuration An invalid before issuing a reload. • Adding/modifying/removing preprocessor configurations are reloadable (except as noted below). e. Negative vland Ids and alphanumeric are not supported. Each unique snort configuration file will create a new configuration instance within snort. A default configuration binds multiple vlans or networks to non-default configurations. 2. The format for ranges is two vlanId separated by a ”-”. vlanIdList .conf> net <ipList> path to snort. using the following configuration line: config binding: <path_to_snort. ipList . Spaces are allowed within ranges.1 Creating Multiple Configurations Default configuration for snort is specified using the existing -c option 2.conf for specific configuration.conf .Refers to ip subnets. Subnets can be CIDR blocks for IPV6 or IPv4.Refers to the comma seperated list of vlandIds and vlanId ranges. Valid vlanId is any number in 0-4095 range. A maximum of 512 individual IPv4 or IPv6 addresses or CIDRs can be specifi the absolute or relative path to the snort.conf> vlan <vlanIdList> config binding: <path_to_snort. 129 .10. Even though 2. The following config options are specific to each configuration.10.e. Parts of the rule header can be specified differently across configurations. If a rule is not specified in a configuration then the rule will never raise an event for the configuration. ”portvar” and ”ipvar” are specific to configurations. including the general options. ! △NOTE Vlan Ids 0 and 4095 are reserved. config config config config config config config config config config config config config config Rules Rules are specific to configurations but only some parts of a rule can be customized for performance reasons. 130 .2 Configuration Specific Elements Config Options Generally config options defined within the default configuration are global by default i. those variables must be defined in that configuration. the default values of the option (not the default configuration values) take effect. and post-detection options. Configurations can be applied based on either Vlans or Vlan and Subnets Subnets not both.! △NOTE can not be used in the same line. their value applies to all other configurations. If not defined in a configuration. policy_id policy_mode policy_version The following config options are specific to each configuration. Variables Variables defined using ”var”. non-payload detection options. limited to: Source IP address and port Destination IP address and port Action A higher revision of a rule in one configuration will override other revisions of the same rule in other configurations. A rule shares all parts of the rule options. If the rules in a configuration use variables. payload detection options. they are included as valid in terms of configuring Snort. Refers to the absolute or relative filename. A preprocessor must be configured in default configuration before it can be configured in non-default configuration. including: 131 . vlan event types . that can be applied to the packet.11 Active Response Snort 2. In the end.3 How Configuration is applied? Snort assigns every incoming packet to a unique configuration based on the following criteria. vlan_event_types (true unified logging) filename . then the innermost VLANID is used to find bound configuration. snort will use the first configuration in the order of definition. This policy id will be used to identify alerts from a specific configuration in the unified2 records. are processed only in default policy. If VLANID is present. snort will use unified2 event type 104 and 105 for IPv4 and IPv6 respectively.Refers to a 16-bit unsigned value.9 includes a number of changes to better handle inline operation. 2. Events and Output An unique policy id can be assigned by user. ! △NOTE If no policy id is specified. In this case.Preprocessors Preprocessors configurations can be defined within each vlan or subnet specific configuration. output alert_unified2: vlan_event_types (alert logging only) output unified2: filename <filename>.When this option is set. through specific limit on memory usage or number of instances. The options control total memory usage for a preprocessor across all policies.. Options controlling specific preprocessor memory usage. These options are ignored in non-default policies without raising an error. This is required as some mandatory preprocessor configuration options are processed only in default configuration.. For addressed based configuration binding.10. to each configuration using the following config line: config policy_id: <id> id . default configuration is used if no other matching configuration is found. If the bound configuration is the default configuration. ! △NOTE Each event logged will have the vlanId from the packet if vlan headers are present otherwise 0 will be used. snort assigns 0 (zero) value to the configuration. 2. . .• a single mechanism for all responses • fully encoded reset or icmp unreachable packets • updated flexible response rule option • updated react rule option • added block and sblock rule actions These changes are outlined below. and will be deleted in a future release: 132 .25) <min_sec> ::= (1.3 Flexresp Flexresp and flexresp2 are replaced with flexresp3. In inline mode the reset is put straight into the stream in lieu of the triggering packet so strafing is not necessary. 2. At most 1 ICMP unreachable is sent.1 Enabling Active Response This enables active responses (snort will send TCP RST or ICMP unreachable/port) when dropping a session. This sequence ”strafing” is really only useful in passive mode. TCP data (sent for react) is multiplied similarly. TTL will be set to the value captured at session pickup. non-functional..20) 2. these features are deprecated. if and only if attempts ¿ 0. 2..300) Active responses will be encoded based on the triggering packet.11./configure --enable-flexresp / -DENABLE_RESPOND -DENABLE_RESPONSE config flexresp: attempts 1 * Flexresp2 is deleted./configure --enable-active-response / -DACTIVE_RESPONSE preprocessor stream5_global: \ max_active_responses <max_rsp>. Each attempt (sent in rapid succession) has a different sequence number.11./configure --enable-active-response config response: attempts <att> <att> ::= (1.11. . \ min_response_seconds <min_sec> <max_rsp> ::= (0. these features are no longer avaliable: . * Flexresp is deleted. charset=UTF-8\" />\r\n" \ "<title>Access Denied</title>\r\n" \ "</head>\r\n" \ "<body>\r\n" \ "<h1>Access Denied</h1>\r\n" \ "<p>%s</p>\r\n" \ "</body>\r\n" \ "</html>\r\n".org/1999/xhtml\" xml:lang=\"en\">\r\n" \ "<head>\r\n" \ "<meta http-equiv=\"Content-Type\" content=\"text/html.11. including any HTTP headers. You could craft a binary payload of arbitrary content./configure --enable-flexresp3 / -DENABLE_RESPOND -DENABLE_RESPONSE3 alert tcp any any -> any 80 (content:"a". When the rule is configured. the response isn’t strictly limited to HTTP.1 403 Forbidden\r\n" "Connection: close\r\n" "Content-Type: text/html.1//EN\"\r\n" \ " \". charset=utf-8\r\n" "\r\n" "<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1. . Note that the file must contain the entire response.w3. In fact.4 React react is a rule option keyword that enables sending an HTML page on a session and then resetting it. resp:<resp_t>. This is built with: . the page is loaded and the selected message.html> or else the default is used: <default_page> ::= \ "HTTP/1.org/TR/xhtml11/DTD/xhtml11. sid:1.) *-react / -DENABLE_REACT The page to be sent can be read from a file: config react: <block.dtd\">\r\n" \ "<html xmlns=\". which defaults to: 133 .. 134 . \ react: <react_opts>. [proxy <port#>] The original version sent the web page to one end of the session only if the other end of the session was port 80 or the optional proxy port. This is an example rule: drop tcp any any -> any $HTTP_PORTS ( \ content: "d".11. msg:"Unauthorized Access Prohibited!". sid:4.<br />" \ "Consult your system administrator for details.) <react_opts> ::= [msg] [.5 Rule Actions The block and sblock actions have been introduced as synonyms for drop and sdrop to help avoid confusion between packets dropped due to load (eg lack of available buffers for incoming packets) and packets blocked due to Snort’s analysis.". a resp option can be used instead. The deprecated options are ignored. 2. <dep_opts>] These options are deprecated: <dep_opts> ::= [block|warn].<default_msg> ::= \ "You are attempting to access a forbidden site. The new version always sends the page to the client. If no page should be sent. where. The words before the colons in the rule options section are called option keywords. In current versions of Snort. The rule option section contains alert messages and information on which parts of the packet should be inspected to determine if the rule action should be taken. rules may span multiple lines by adding a backslash \ to the end of the line. and the source and destination ports information. the rule header and the rule options. lightweight rules description language that is flexible and quite powerful. as well as what to do in the event that a packet with all the attributes indicated in the rule should show up. source and destination IP addresses and netmasks.2. There are a number of simple guidelines to remember when developing Snort rules that will help safeguard your sanity. for that matter).1. At the same time. Snort rules are divided into two logical sections.2 Rules Headers 3.168. msg:"mountd access". the various rules in a Snort rules library file can be considered to form a large logical OR statement. the elements can be considered to form a logical AND statement.1 The Basics Snort uses a simple.8. When taken together. Most Snort rules are written in a single line. protocol. 3. ! △NOTE Note that the rule options section is not specifically required by any rule.0/24 111 \ (content:"|00 01 86 a5|". and what of a packet.Chapter 3 Writing Snort Rules 3. This was required in versions prior to 1. Figure 3.1 illustrates a sample Snort rule.1: Sample Snort Rule 135 .) Figure 3. The rule header contains the rule’s action. All of the elements in that make up a rule must be true for the indicated rule action to be taken. they are just used for the sake of making tighter definitions of packets to collect or alert on (or drop. The text up to the first parenthesis is the rule header and the section enclosed in parenthesis contains the rule options.1 Rule Actions The rule header contains the information that defines the who. The first item in a rule is the rule alert tcp any any -> 192. action.log the packet 3. and /32 indicates a specific machine address. activate. In addition.1 to 192. IGRP. alert.2.168. then act as a log rule 6. such as ARP. you have additional options which include drop. and sdrop. UDP.168. IPX.1.1.generate an alert using the selected alert method. etc. 8. 1. OSPF. GRE.block the packet.remain idle until activated by an activate rule . 136 . A CIDR block mask of /24 indicates a Class C network. alert . In the future there may be more. The CIDR designations give us a nice short-hand way to designate large address spaces with just a few characters.0/24 would signify the block of addresses from 192. The addresses are formed by a straight numeric IP address and a CIDR[3] block. You can then use the rule types as actions in Snort rules. There are four protocols that Snort currently analyzes for suspicious behavior – TCP.168.ignore the packet 4.3 IP Addresses The next portion of the rule header deals with the IP address and port information for a given rule.255. mysql.block and log the packet 7. and dynamic. if you are running Snort in inline mode. reject . dynamic . There are 5 available default actions in Snort. activate .alert and then turn on another dynamic rule 5. Any rule that used this designation for. user=snort dbname=snort host=localhost } 3. sdrop . log. and then send a TCP reset if the protocol is TCP or an ICMP port unreachable message if the protocol is UDP. RIP. /16 a Class B network. pass . The rule action tells Snort what to do when it finds a packet that matches the rule criteria. and IP. say. The keyword any may be used to define any address. reject. 3. This example will create a type that will log to just tcpdump: ruletype suspicious { type log output log_tcpdump: suspicious. drop . the destination address would match on any address in that range. log .block the packet but do not log it.2. and then log the packet 2. Snort does not have a mechanism to provide host name lookup for the IP address fields in the config file. log it.2 Protocols The next field in a rule is the protocol. pass. You can also define your own rule types and associate one or more output plugins with them. For example.1. The CIDR block indicates the netmask that should be applied to the rule’s address and any incoming packets that are tested against the rule.log } This example will create a rule type that will log to syslog and a MySQL database: ruletype redalert { type alert output alert_syslog: LOG_AUTH LOG_ALERT output database: log. ICMP. the address/CIDR combination 192. 1.0/24 :6000 log tcp traffic from any port going to ports less than or equal to 6000 log tcp any :1024 -> 192. ranges.168.1. For example. Static ports are indicated by a single port number.1.2: Example IP Address Negation Rule alert tcp ![192..1. or 80 for http.1.1.0 Class C network. such as in Figure 3.0/24] 111 (content: "|00 01 86 a5|".0/24.168.1. the source IP address was set to match for any computer talking.1.0/24 500: log tcp traffic from privileged ports less than or equal to 1024 going to ports greater than or equal to 500 Figure 3.. \ msg: "external mountd access".alert tcp !192. 23 for telnet. meaning literally any port.0/24 1:1024 log udp traffic coming from any port and destination ports ranging from 1 to 1024 log tcp any any -> 192.) Figure 3.168.) Figure 3.1. if for some twisted reason you wanted to log everything except the X Windows ports. the IP list may not include spaces between the addresses. such as 111 for portmapper. msg: "external mountd access". 3.168. For the time being. The range operator may be applied in a number of ways to take on different meanings.).5. See Figure 3.5 The Direction Operator The direction operator -> indicates the orientation. Port negation is indicated by using the negation operator !.2. Port ranges are indicated with the range operator :.2. For example. Any ports are a wildcard value.168.2.1. You may also specify lists of IP addresses. The negation operator is indicated with a !.3 for an example of an IP list in action. or direction. There is an operator that can be applied to IP addresses. the negation operator. This rule’s IP addresses indicate any tcp packet with a source IP address not originating from the internal network and a destination address on the internal network.0/24.3: IP Address Lists In Figure 3. static port definitions. you could do something like the rule in Figure 3. of the traffic that the rule applies to.168. including any ports.1. and the destination address was set to match on the 192. and by negation. which would translate to none.1. The IP address and port numbers on the left side of the direction operator is considered to be the traffic coming from the source log udp any any -> 192.4: Port Range Examples 137 .4. etc. an easy modification to the initial example is to make it alert on any traffic that originates outside of the local net with the negation operator as shown in Figure 3.10.4 Port Numbers Port numbers may be specified in a number of ways.168. An IP list is specified by enclosing a comma separated list of IP addresses and CIDR blocks within square brackets.1. The negation operator may be applied against any of the other rule types (except any.0/24 any -> 192.0/24 111 \ (content: "|00 01 86 a5|".0/24] any -> \ [192.10. how Zen.168. 3. This operator tells Snort to match any IP address except the one indicated by the listed IP address. activate tcp !$HOME_NET any -> $HOME_NET 143 (flags: PA. so there’s value in collecting those packets for later analysis.6 Activate/Dynamic Rules ! △NOTE Activate and Dynamic rules are being phased out in favor of a combination of tagging (3. activates: 1.) Figure 3. except they have a *required* option field: activates.8. \ msg: "IMAP buffer overflow!".168.10).1. count: 50. This is very useful if you want to set Snort up to perform follow on recording when a specific rule goes off. Activate rules act just like alert rules. In Snort versions before 1.operator. This is handy for recording/analyzing both sides of a conversation. This tells Snort to consider the address/port pairs in either the source or destination orientation.168. Dynamic rules have a second required field as well.168.6.5: Example of Port Negation log tcp !192.does not exist is so that rules always read consistently. there’s a very good possibility that useful data will be contained within the next 50 (or whatever) packets going to that same service port on the network.0/24 !6000:6010 Figure 3. \ content: "|E8C0FFFFFF|/bin".1.7. An example of the bidirectional operator being used to record both sides of a telnet session is shown in Figure 3.1. There is also a bidirectional operator. Rule option keywords are separated from their arguments with a colon (:) character. Put ’em together and they look like Figure 3. but they have a different option field: activated by. 3. the direction operator did not have proper error checking and many people used an invalid token.6: Snort rules using the Bidirectional Operator host.log tcp any any -> 192.5) and flowbits (3. Dynamic rules act just like log rules. Dynamic rules are just like log rules except are dynamically enabled when the activate rule id goes off. Also. count. Activate rules are just like alerts but also tell Snort to add a rule when a specific network event occurs. The reason the <. If the buffer overflow happened and was successful.7. combining ease of use with power and flexibility.) character.6. 3.0/24 23 Figure 3. such as telnet or POP3 sessions. Activate/dynamic rule pairs give Snort a powerful capability.) dynamic tcp !$HOME_NET any -> $HOME_NET 143 (activated_by: 1. These rules tell Snort to alert when it detects an IMAP buffer overflow and collect the next 50 packets headed for port 143 coming from outside $HOME NET headed to $HOME NET. which is indicated with a <> symbol. and the address and port information on the right side of the operator is the destination host.2.7. You can now have one rule activate another when it’s action is performed for a set number of packets.7: Activate/Dynamic Rule Example 138 .3 Rule Options Rule options form the heart of Snort’s intrusion detection engine. note that there is no <. All Snort rule options are separated from each other using the semicolon (.0/24 any <> 192. com/info/IDS. content:"|31c031db 31c9b046 cd80 31c031db|". character). Table 3.com/bid/. reference:arachnids. Format msg: "<message text>".4).<id>. Make sure to also take a look at. \ flags:AP.cgi?name= are four major categories of rule options.mitre.nessus. This plugin is to be used by output plugins to provide a link to additional information about the alert produced.com/vil/dispVirus.” 3. \ flags:AP . The plugin currently supports several specific systems as well as unique URLs.asp?virus k= http:// System bugtraq cve nessus arachnids mcafee url Format reference: <id system>.1: Supported Systems URL Prefix.) alert tcp any any -> any 21 (msg:"IDS287/ftp-wuftp260-venglin-linux".securityfocus.] Examples alert tcp any any -> any 7070 (msg:"IDS411/dos-realaudio". content:"|fff4 fffd 06|".php3?id= (currently down) reference The reference keyword allows rules to include references to external attack identification systems. [reference: <id system>.org/plugins/dump. 3.org/cgi-bin/cvename. General Rule Options 3.IDS411. \ 139 .snort.cgi/ for a system that is indexing descriptions of alerts based on of the sid (See Section 3. alert tcp any any -> any 80 (content:"BOB". it is not recommended that the gid keyword be used.4) The file etc/gen-msg.000 be used. For example gid 1 is associated with the rules subsystem and various gids over 100 are designated for specific preprocessors and the decoder.000 Used for local rules The file sid-msg.reference:arachnids.4.000.) 3.map contains a mapping of alert messages to Snort rule IDs. To avoid potential conflict with gids defined in Snort (that for some reason aren’t noted it etc/generators).4.5) • <100 Reserved for future use • 100-999. sid:1. This option should be used with the sid keyword.999 Rules included with the Snort distribution • >=1. For general rule writing. rev:1.IDS287. sid:1000983.000. (See section 3.CAN-2000-1574.4.3 gid The gid keyword (generator id) is used to identify what part of Snort generates the event when a particular rule fires.) 140 .4 sid The sid keyword is used to uniquely identify Snort rules. Example This example is a rule with a generator id of 1000001. This option should be used with the rev keyword. Example This example is a rule with the Snort Rule ID of 1000983. gid:1000001. reference:bugtraq. \ reference:cve. alert tcp any any -> any 80 (content:"BOB". Format gid: <generator id>. Format sid: <snort rules id>.4. rev:1.1387. Note that the gid keyword is optional and if it is not specified in a rule. See etc/generators in the source tree for the current generator ids in use. This information allows output plugins to identify rules easily. it will default to 1 and the rule will be part of the general rule subsystem. This information is useful when postprocessing alert to map an ID to an alert message. (See section 3.map contains contains more information on preprocessor and decoder gids. it is recommended that values starting at 1.) 3. The file uses the following syntax: config classification: <class name>. Example This example is a rule with the Snort Rule Revision of 1.6 classtype The classtype keyword is used to categorize a rule as detecting an attack that is part of a more general type of attack class. Example alert tcp any any -> any 25 (msg:"SMTP expn root". Format classtype: <class name>.) .2.) Attack classifications defined by Snort reside in the classification. rev:1. A priority of 1 (high) is the most severe and 4 (very low) is the least severe. flags:A+.<default priority> These attack classifications are listed in Table 3. This option should be used with the sid keyword.4. Revisions. They are currently ordered with 4 default priorities. Snort provides a default set of attack classes that are used by the default set of rules it provides. (See section 3. \ content:"expn root".5 rev The rev keyword is used to uniquely identify revisions of Snort rules. Defining classifications for rules provides a way to better organize the event data Snort produces.4.3. alert tcp any any -> any 80 (content:"BOB". Table 3. along with Snort rule id’s.config file. nocase.<class description>. sid:1000983.4.4) Format rev: <revision integer>. classtype:attempted-recon. allow signatures and descriptions to be refined and replaced with updated information. classtype:attempted-admin. 142 . \ content: "/cgi-bin/phf". Examples of each case are given below. Examples alert TCP any any -> any 80 (msg: "WEB-MISC phf attempt".4.conf by using the config classification option. priority:10.config that are used by the rules it provides.7 priority The priority tag assigns a severity level to rules. A classtype rule assigns a default priority (defined by the config classification option) that may be overridden with a priority rule. \ dsize: >128. priority:10 ). flags:A+. 3.) alert tcp any any -> any 80 (msg:"EXPLOIT ntpdx overflow". Format priority: <priority integer>. Snort provides a default set of classifications in classification. The first uses multiple metadata keywords.9 General Rule Quick Reference Table 3. the second a single metadata keyword. while keys and values are separated by a space. metadata: key1 value1.7 for details on the Host Attribute Table. \ metadata:engine shared.4.) alert tcp any any -> any 80 (msg: "HTTP Service Rule Example". . the rule is not applied (even if the ports specified in the rule match). The reference keyword allows rules to include references to external attack identification systems. the rule is applied to that packet. \ metadata:engine shared. \ metadata:service http.3. 143 .3. metadata:soid 3|12345. The gid keyword (generator id) is used to identify what part of Snort generates the event when a particular rule fires. Certain metadata keys and values have meaning to Snort and are listed in Table 3. key2 value2.4. Multiple keys are separated by a comma. See Section 2.) 3. with a key and a value. with keys separated by commas. metadata: key1 value1. When the value exactly matches the service ID as specified in the table.4: General rule option keywords Keyword msg reference gid Description The msg keyword tells the logging and alerting engine the message to print with the packet dump or alert.8 metadata The metadata tag allows a rule writer to embed additional information about the rule. typically in a key-value format. Format The examples below show an stub rule from a shared library rule. Table 3. Keys other than those listed in the table are effectively ignored by Snort and can be free-form. otherwise. soid 3|12345. Examples alert tcp any any -> any 80 (msg: "Shared Library Rule Example".) alert tcp any any -> any 80 (msg: "Shared Library Rule Example". Note that multiple content rules can be specified in one rule. Be aware that this test is case sensitive.) ! △NOTE A ! modifier negates the results of the entire content search. 3.1 content The content keyword is one of the more important features of Snort. it can contain mixed text and binary data. and there are only 5 bytes of payload and there is no ”A” in those 5 bytes. The binary data is generally enclosed within the pipe (|) character and represented as bytecode. The classtype keyword is used to categorize a rule as detecting an attack that is part of a more general type of attack class.sid rev classtype priority metadata The sid keyword is used to uniquely identify Snort rules. The metadata keyword allows a rule writer to embed additional information about the rule. \ " Format content: [!] "<content string>"..5. within:50. Examples alert tcp any any -> any 139 (content:"|5c 00|P|00|I|00|P|00|E|00 5c|". The option data for the content keyword is somewhat complex. Whenever a content option pattern match is performed. the result will return a match. If data exactly matching the argument data string is contained anywhere within the packet’s payload. if using content:!"A". the Boyer-Moore pattern match function is called and the (rather computationally expensive) test is performed against the packet contents. For example. The rev keyword is used to uniquely identify revisions of Snort rules. typically in a key-value format.) alert tcp any any -> any 80 (content:!"GET". the test is successful and the remainder of the rule option tests are performed. This allows rules to be tailored for less false positives. Bytecode represents binary data as hexadecimal numbers and is a good shorthand method for describing complex binary data.5 Payload Detection Rule Options 3. It allows the user to set rules that search for specific content in the packet payload and trigger response based on that data. If the rule is preceded by a !. modifiers included. 144 . The priority keyword assigns a severity level to rules. If there must be 50 bytes for a valid match. the alert will be triggered on packets that do not contain this content. 6 within 3.17 fast pattern 3.5. This acts as a modifier to the previous content 3.19 3.13 http uri 3.5. nocase modifies the previous ’content’ keyword in the rule.5.5.5.3 depth 3.5.12 http method 3.15 http stat code 3.5.14 http raw uri 3.7 http client body 3.5.9 http raw cookie 3.5.4 offset 3. The modifier keywords change how the previously specified content works.5. These modifier keywords are: Table 3.5 distance 3. content:"USER root".8 http cookie 3. ignoring any decoding that was done by preprocessors.5: Content Modifiers Modifier Section nocase 3.5.Changing content behavior The content keyword has a number of modifier keywords.2 rawbytes 3.5.5.5.5.3 rawbytes The rawbytes keyword allows rules to look at the raw packet data. nocase.5.) 3.10 http header 3.11 http raw header 3. format rawbytes.5. 145 .2 nocase The nocase keyword allows the rule writer to specify that the Snort should look for the specific pattern. Example alert tcp any any -> any 21 (msg:"FTP ROOT".16 http stat msg 3. Format nocase.5. ignoring case.1 option.5.5. 146 .) 3.4 depth The depth keyword allows the rule writer to specify how far into a packet Snort should search for the specified pattern. Example The following example shows use of a combined content. offset.5. there must be a content in the rule before ’offset’ is specified.5. content: "|FF F1|". alert tcp any any -> any 80 (content: "cgi-bin/phf".5. depth:20.Example This example tells the content pattern matcher to look at the raw traffic.5 offset The offset keyword allows the rule writer to specify where to start searching for a pattern within a packet. alert tcp any any -> any 21 (msg: "Telnet NOP". This keyword allows values from -65535 to 65535. depth modifies the previous ‘content’ keyword in the rule. instead of the decoded traffic provided by the Telnet decoder. offset modifies the previous ’content’ keyword in the rule. and depth search rule. An offset of 5 would tell Snort to start looking for the specified pattern after the first 5 bytes of the payload. 3. As this keyword is a modifier to the previous ’content’ keyword. except it is relative to the end of the last pattern match instead of the beginning of the packet.. As the depth keyword is a modifier to the previous ‘content’ keyword. This keyword allows values equal to 0 or values greater than or equal to the pattern length being searched. Format depth: <number>.5.5). Format offset: <number>. This can be thought of as exactly the same thing as offset (See Section 3. offset:4.) 3. A depth of 5 would tell Snort to only look for the specified pattern within the first 5 bytes of the payload. there must be a content in the rule before ‘depth’ is specified. rawbytes. The maximum allowed value for this keyword is 65535. within:10.7 within The within keyword is a content modifier that makes sure that at most N bytes are between pattern matches using the content keyword ( See Section 3. http_client_body.5. As this keyword is a modifier to the previous ’content’ keyword.8 http client body The http client body keyword is a content modifier that restricts the search to the body of an HTTP client request.) ! △NOTE body modifier is not allowed to be used with the rawbytes modifier for the same content. Pattern matches with this keyword wont work when post depth is set to -1. Format within: <byte count>.5. alert tcp any any -> any any (content:"ABC". Format http_client_body. The http client 147 .5. Examples This rule constrains the search of EFG to not go past 10 bytes past the ABC match. content: "DEF". content: "EFG". alert tcp any any -> any 80 (content:"ABC".Format distance: <byte count>.) 3.6) rule option. there must be a content in the rule before ’http client body’ is specified. This keyword allows values greater than or equal to pattern length being searched. distance:1. Examples This rule constrains the search for the pattern ”EFG” to the raw body of an HTTP client request. content: "EFG".1 ). The maximum allowed value for this keyword is 65535. It’s designed to be used in conjunction with the distance (Section 3. The amount of data that is inspected with this option depends on the post depth config option of HttpInspect. Example The rule below maps to a regular expression of /ABC. alert tcp any any -> any any (content:"ABC".) 3.{1}DEF/.5. ) ! △NOTE The http raw cookie modifier is not allowed to be used with the rawbytes. The Cookie Header field will be extracted only when this option is configured. http_raw_cookie. As this keyword is a modifier to the previous ’content’ keyword. This keyword is dependent on the ’enable cookie’ config option. there must be a content in the rule before ’http raw cookie’ is specified. alert tcp any any -> any 80 (content:"ABC". Format http_raw_cookie. per the configuration of HttpInspect (see 2.2. alert tcp any any -> any 80 (content:"ABC". Examples This rule constrains the search for the pattern ”EFG” to the extracted Unnormalized Cookie Header field of a HTTP client request. http cookie or fast pattern modifiers for the same content.5.6). The extracted Cookie Header field may be NORMALIZED. Format http_cookie. As this keyword is a modifier to the previous ’content’ keyword. Examples This rule constrains the search for the pattern ”EFG” to the extracted Cookie Header field of a HTTP client request.6).5. content: "EFG". This keyword is dependent on the ’enable cookie’ config option. 3.) ! △NOTE The http cookie modifier is not allowed to be used with the rawbytes or fast pattern modifiers for the same content. there must be a content in the rule before ’http cookie’ is specifi.3. The Cookie Header field will be extracted only when this option is configured.6). 148 .2. http_cookie. content: "EFG".2. alert tcp any any -> any 80 (content:"ABC". per the configuration of HttpInspect (see 2. alert tcp any any -> any 80 (content:"ABC".5. As this keyword is a modifier to the previous ’content’ keyword.) ! △NOTE The http header modifier is not allowed to be used with the rawbytes modifier for the same content.2. 149 .6). content: "EFG". there must be a content in the rule before ’http raw header’ is specified.6).) ! △NOTE The http raw header modifier is not allowed to be used with the rawbytes.5.6)._raw_header. Format http_header. http header or fast pattern modifiers for the same content.3. Examples This rule constrains the search for the pattern ”EFG” to the extracted Header fields of a HTTP client request or a HTTP server response.2.2. there must be a content in the rule before ’http header’ is specified. content: "EFG". 3. Format http_raw_header. Examples This rule constrains the search for the pattern ”EFG” to the extracted Header fields of a HTTP client request or a HTTP server response.. The extracted Header fields may be NORMALIZED. 3.5.) ! . content: "EFG".5.20).5. Examples This rule constrains the search for the pattern ”GET” to the extracted Method from a HTTP client request. As this keyword is a modifier to the previous ’content’ keyword. Format http_uri. http_uri. Format http_method.15 http raw uri The http raw uri keyword is a content modifier that restricts the search to the UNNORMALIZED request URI field . content: "GET". alert tcp any any -> any 80 (content:"ABC". 3. As this keyword is a modifier to the previous ’content’ keyword. As this keyword is a modifier to the previous ’content’ keyword. Using a content rule option followed by a http uri modifier is the same as using a uricontent by itself (see: 3. there must be a content in the rule before ’http raw uri’ is specified. 150 . there must be a content in the rule before ’http uri’ is specified.) ! △NOTE The http method modifier is not allowed to be used with the rawbytes modifier for the same content. Examples This rule constrains the search for the pattern ”EFG” to the NORMALIZED URI. alert tcp any any -> any 80 (content:"ABC".5.3. http_method. ) ! △NOTE The http raw uri modifier is not allowed to be used with the rawbytes.16 http stat code The http stat code keyword is a content modifier that restricts the search to the extracted Status code field from a HTTP server response. The Status Message field will be extracted only if the extended reponse inspection is configured for the HttpInspect (see 2. http_raw_uri.17 http stat msg The http stat msg keyword is a content modifier that restricts the search to the extracted Status Message field from a HTTP server response. alert tcp any any -> any 80 (content:"ABC". The Status Code field will be extracted only if the extended reponse inspection is configured for the HttpInspect (see 2.5.Format http_raw_uri. As this keyword is a modifier to the previous ’content’ keyword. there must be a content in the rule before ’http stat msg’ is specified. alert tcp any any -> any 80 (content:"ABC". http_stat_code. content: "EFG".) ! △NOTE The http stat code modifier is not allowed to be used with the rawbytes or fast pattern modifiers for the same content.5. there must be a content in the rule before ’http stat code’ is specified. Examples This rule constrains the search for the pattern ”200” to the extracted Status Code field of a HTTP server response.2. 3.2. http uri or fast pattern modifiers for the same content. As this keyword is a modifier to the previous ’content’ keyword.6).6). Format http_stat_code. content: "200". 151 . 3. Examples This rule constrains the search for the pattern ”EFG” to the UNNORMALIZED URI. ’uencode’ and ’bare byte’ determine the encoding type which would trigger the alert.2. [!][<utf8|double_encode|non_ascii|base36|uencode|bare_byte|ascii>]. Examples This rule constrains the search for the pattern ”Not Found” to the extracted Status Message field of a HTTP server response. content: "Not Found".) alert tcp any any -> any any (msg:"No UTF8". http_encode:uri. The keyword ’cookie’ is dependent on config options ’enable cookie’ and ’normalize cookies’ (see 2. The keywords ’uri’.18 http encode The http encode keyword will enable alerting based on encoding type present in a HTTP client request or a HTTP server response (per the configuration of HttpInspect 2. [!] <encoding type> http_encode: [uri|header|cookie]. http_encode:uri. ’double encode’.6). ’non ascii’.6).!utf8. http_stat_msg. 152 . This rule option will not be able to detect encodings if the specified HTTP fields are not NORMALIZED. These keywords can be combined using a OR operation. The config option ’normalize headers’ needs to be turned on for rules to work with the keyword ’header’. There are nine keywords associated with http encode.2.5. ’base36’. Examples alert tcp any any -> any any (msg:"UTF8/UEncode Encoding present". ’header’ and ’cookie’ determine the HTTP fields used to search for a particular encoding type.) Description Check for the specified encoding type in HTTP client request URI field. Option uri header cookie utf8 double encode non ascii base36 uencode bare byte ascii Format http_encode: <http buffer type>. The keywords ’utf8’. Negation is allowed on these keywords. 3.Format http_stat_msg.utf8|uencode.) ! △NOTE The http stat msg modifier is not allowed to be used with the rawbytes or fast pattern modifiers for the same content. alert tcp any any -> any 80 (content:"ABC". depth. Note that (1) the modified content must be case insensitive since patterns are inserted into the pattern matcher in a case insensitive manner. if a known content must be located in the payload independent of location in the payload. it can significantly reduce the number of rules that need to be evaluated and thus increases performance. Format The fast pattern option can be used alone or optionally take arguments. ! △NOTE The fast pattern modifier cannot be used with the following http content modifiers: http cookie.<length>. The optional argument <offset>.19 fast pattern The fast pattern keyword is a content modifier that sets the content within a rule to be used with the fast pattern matcher.<length> can be used to specify that only a portion of the content should be used for the fast pattern matcher. however. fast_pattern:<offset>. The optional argument only can be used to specify that the content should only be used for the fast pattern matcher and should not be evaluated as a rule option.! △NOTE Negation(!) and OR(|) operations cannot be used in conjunction with each other for the http encode keyword. ! △NOTE The fast pattern modifier can be used with negated contents only if those contents are not modified with offset. This is useful. for example. distance or within. that it is okay to use the fast pattern modifier if another http content modifier not mentioned above is used in combination with one of the above to modify the same content. The fast pattern matcher is used to select only those rules that have a chance of matching by using a content in the rule for selection and only evaluating that rule if the content is found in the payload. Since the default behavior of fast pattern determination is to use the longest content in the rule. meaning the shorter content is less likely to be found in a packet than the longer content. fast_pattern:only.5. distance or within. This is useful if the pattern is very long and only a portion of the pattern is necessary to satisfy ”uniqueness” thus reducing the memory required to store the entire pattern in the fast pattern matcher. http raw cookie. 3. As this keyword is a modifier to the previous content keyword. the less likely the rule will needlessly be evaluated. it is useful if a shorter content is more ”unique” than the longer content. http raw header. The better the content used for the fast pattern matcher. fast_pattern. The OR and negation operations work only on the encoding type field and not on http buffer type field. Though this may seem to be overhead. http stat code. http raw uri. Note. 153 . The fast pattern option may be specified only once per rule. as it saves the time necessary to evaluate the rule option. http stat msg. the meaning is simply to use the specified content as the fast pattern content for the rule. depth. When used alone. (2) negated contents cannot be used and (3) contents cannot have any positional modifiers such as offset. there must be a content rule option in the rule before fast pattern is specified. the URI: /cgi-bin/aaaaaaaaaaaaaaaaaaaaaaaaaa/. Examples This rule causes the pattern ”IJKLMNO” to be used with the fast pattern matcher.exe?/c+ver Another example. alert tcp any any -> any 80 (content:"ABCDEFGH". This option works in conjunction with the HTTP Inspect preprocessor specified in Section 2. see the content rule options in Section 3.) 3. 154 . fast_pattern:1. (See Section 3.1. alert tcp any any -> any 80 (content:"ABCDEFGH".exe?/c+ver will get normalized into: /winnt/system32/cmd. For example. alert tcp any any -> any 80 (content:"ABCDEFGH". The reason is that the things you are looking for are normalized out of the URI buffer.1) For a description of the parameters to this function. This means that if you are writing rules that include things that are normalized. content:"IJKLMNO". nocase. even though it is shorter than the earlier pattern ”ABCDEFGH”.5.%252fp%68f? will get normalized into: /cgi-bin/phf? When writing a uricontent rule. write the content that you want to find in the context that the URI will be normalized. content:"IJKLMNO". do not include directory traversals. content:"IJKLMNO".) This rule says to use the content ”IJKLMNO” for the fast pattern matcher and that the content should only be used for the fast pattern matcher and not evaluated as a content rule option. these rules will not alert.<length> are mutually exclusive. fast_pattern. such as %2f or directory traversals.5. the URI: /scripts/. but still evaluate the content rule option as ”IJKLMNO”..20 uricontent The uricontent keyword in the Snort rule language searches the NORMALIZED request URI field. fast_pattern:only.. You can write rules that look for the non-normalized content by using the content option.2..6. if Snort normalizes directory traversals.! △NOTE The optional arguments only and <offset>.%c0%af. For example.5./winnt/system32/cmd.) This rule says to use ”JKLMN” as the fast pattern content.5. This modifier will work with the relative modifier as long as the previous content match was in the raw packet data.relative. it looks at the raw packet data. \ content:!"|0a|". then verifies that there is not a newline character within 50 bytes of the end of the PASS string. uricontent 3.) This rule looks for the string PASS exists in the packet. 3.5.>] <int>. isdataat:50. ignoring any decoding that was done by the preprocessors.6. within:50. 155 .. or range of URI lengths to match. the maximum length.2. urilen: [<.21 urilen The urilen keyword in the Snort rule language specifies the exact length.relative|rawbytes]. Example alert tcp any any -> any 111 (content:"PASS". then verifies there is at least 50 bytes after the end of the string PASS. Format isdataat:[!] <int>[.22 isdataat Verify that the payload has data at a specified location.Format uricontent:[!]<content string>. When the rawbytes modifier is specified with isdataat. ! △NOTE cannot be modified by a rawbytes modifier. Format urilen: int<>int.5. the minimum length. optionally looking for data relative to the end of the previous content match. alert ip any any -> any any (pcre:"/BLAH/i". would alert if there were not 10 bytes after ”foo” before the payload ended. K. whitespace data characters in the pattern are ignored except when escaped or inside a character class i s m x A E G Table 3. as well as the very start and very end of the buffer. 3.5. ˆ and $ match at the beginning and ending of the string.8 for descriptions of each modifier. 156 . D.A ! modifier negates the results of the isdataat test. The modifiers H. Without E. I.) ! △NOTE of multiple URIs with PCRE does not work as expected.org Format pcre:[!]"(/<regex>/|m<delim><regex><delim>)[ismxAEGRUBPHMCOIDKYS]". isdataat:!10. For more detail on what can be done via a pcre regular expression. Example This example performs a case-insensitive search for the string BLAH in the payload. but become greedy if followed by ”?”. PCRE when used without a Snort’s handling uricontent only evaluates the first URI. the rule with modifiers content:"foo". 3.relative. When m is set.23 pcre The pcre keyword allows rules to be written using perl compatible regular expressions. See tables 3. Table 3.7: PCRE compatible modifiers for pcre the pattern must match only at the start of the buffer (same as ˆ ) Set $ to match only at the end of the subject string. It will alert if a certain amount of data is not present within the payload. and 3.pcre. the string is treated as one big line of characters. The post-re modifiers set compile time flags for the regular expression. C.6. M.7. Inverts the ”greediness” of the quantifiers so that they are not greedy by default. ˆ and $ match immediately following or immediately before any newline in the buffer. S and Y.6: Perl compatible modifiers for pcre case insensitive include newlines in the dot metacharacter By default. ! △NOTE R (relative) and B (rawbytes) are not allowed with any of the HTTP modifiers such as U. For example. check out the PCRE web site. $ also matches immediately before the final character if it is a newline (but not before any other newlines). P. In order to use pcre to inspect all URIs. you must use either a content or a uricontent. 3). Match unnormalized HTTP request body (Similar to http client body) Match normalized HTTP request or HTTP response header (Similar to http header). This option will operate similarly to the dce stub data option added with DCE/RPC2. This modifier is not allowed with the HTTP request uri buffer modifier(U) for the same content. This modifier is not allowed with the normalized HTTP request or HTTP response cookie modifier(C) for the same content.2. See 2. Match unnormalized HTTP request or HTTP response cookie (Similar to http raw cookie). certain HTTP Inspect options such as extended response inspection and inspect gzip (for decompressed gzip data) needs to be turned on. It completely ignores the limits while evaluating the pcre pattern specified. 157 . This modifier is not allowed with the unnormalized HTTP request or HTTP response header modifier(D) for the same content. file_data:mime. pcre) to use.. For this option to work with HTTP response. (Similar to distance:0.1. Match the unnormalized HTTP request uri buffer (Similar to http raw uri). When used with argument mime it places the cursor at the beginning of the base64 decoded MIME attachment or base64 decoded MIME body. Match unnormalized HTTP request or HTTP response header (Similar to http raw header).R U I P H D M C K S Y B O Table 3.6 for more details.2. in that it simply sets a reference for other relative rule options ( byte test.24 file data This option is used to place the cursor (used to walk the packet payload in rules processing) at the beginning of either the entity body of a HTTP response or the SMTP body data. 3. ! △NOTE Multiple base64 encoded attachments in one packet are pipelined. This modifier is not allowed with the normalized HTTP request or HTTP response header modifier(H) for the same content. byte jump. Match normalized HTTP request method (Similar to http method) Match normalized HTTP request or HTTP response cookie (Similar to http cookie). This is dependent on the SMTP config option enable mime decoding. See 2.5. Format file_data.) Match the decoded URI buffers (Similar to uricontent and http uri). This option matches if there is HTTP response body or SMTP body or SMTP MIME base64 decoded data. This file data can point to either a file or a block of data. This modifier is not allowed with the unnormalized HTTP request or HTTP response cookie modifier(K) for the same content. relative]]] Option bytes Description Number of base64 encoded bytes to decode. base64_data. \ within:20. content:"foo". base64_data.) alert tcp any any -> any any(msg:"MIME BASE64 Encoded Data".\ file_data:mime. ][offset <offset>[. nocase. \ file_data. within:20. This option unfolds the data before decoding it. \ content:"Authorization:".25 base64 decode This option is used to decode the base64 encoded data. ! △NOTE This option can be extended to protocols with folding similar to HTTP. Examples alert tcp $EXTERNAL_NET any -> $HOME_NET any \ (msg:"Base64 Encoded Data". This argument takes positive and non-zero values only. \ content:"NTLMSSP". within:3. When this option is not specified we look for base64 encoded data till either the end of header line is reached or end of packet payload is reached. This option is particularly useful in case of HTTP headers such as HTTP authorization headers. base64_decode. ) 158 . Specifies the inspection for base64 encoded data is relative to the doe ptr. within:10. http_header. \ content:"foo bar". Determines the offset relative to the doe ptr when the option relative is specified or relative to the start of the packet payload to begin inspection of base64 encoded data. content:"NTLMSSP".) 3.) alert tcp any any -> any any (msg:"Authorization NTLM". offset 6.Example alert tcp any 80 -> any any(msg:"foo at the start of http response body". content:"foo". This argument takes positive and non-zero values only. content:"Authorization: NTLM". base64_decode:relative.relative .. base64_data.) alert tcp $EXTERNAL_NET any -> $HOME_NET any \ (msg:"Authorization NTLM". offset relative The above arguments to base64 decode are optional.5. \ base64_decode: bytes 12.within:8. Format base64_decode[: [bytes <bytes_to_decode>][. relative] [.<number type>.27 byte test Test a byte field against a specific value (with operator). <offset> [. in that it simply sets a reference for other relative rule options ( byte test. Format byte_test: <bytes to convert>.9. convert operator value offset = = = = 1 . please read Section 3. For a more detailed explanation. Fast pattern content matches are not allowed with this buffer. \ content:"NTLMSSP". \ base64_decode: bytes 12. pcre) to use. ) 3.<endian>] [. [!]<operator>.5. This option will operate similarly to the file data option. string]. byte jump. Format base64_data. Example alert tcp any any -> any any (msg:"Authorization NTLM". ! △NOTE Any non-relative rule options in the rule will reset the cursor(doe ptr) from base64 decode buffer. <value>.10 ’<’ | ’=’ | ’>’ | ’&’ | ’ˆ’ 0-4294967295 -65535 to 65535 \ 159 .3. base64_data. Capable of testing binary values or converting representative byte strings to their binary equivalent and testing them.relative . offset 6.within:8.5. This option does not take any arguments. \ content:"Authorization:". http_header.26 base64 data This option is used to place the cursor (used to walk the packet payload in rules processing) at the beginning of the base64 decode buffer if present.5. The rule option base64 decode needs to be specified before the base64 data option. This option matches if there is base64 decoded buffer. Process data as big endian (default) • little . within: 4.bitwise OR value offset relative endian Value to test the converted value against Number of bytes into the payload to start processing Use an offset relative to last pattern match Endian type of the number being read: • big . 20. dec. See section 2. \ byte_test: 4. string. \ content: "|00 04 93 F3|". If ! is specified without an operator. Operation to perform to test the value: • < . For example. 0. \ msg: "got 1234!".Converted string data is represented in hexadecimal • dec .Process data as little endian string number type Data is stored in string format in packet Type of number being read: • hex . dec. distance: 4. 1234.>.) alert udp any any -> any 1234 \ (byte_test: 4. \ msg: "got 1234567890!".not • & . =. 0.} Examples alert udp $EXTERNAL_NET any -> $HOME_NET any \ (msg:"AMD procedure 7 plog overflow ". within: 4. string. \ content: "|00 00 00 07|".Converted string data is represented in decimal • oct . Please note that the ! operator cannot be used with itself. 20. If the & operator is used. 12. 0. \ msg: "got 12!". string. =. =. 1234567890.2. relative. \ content: "|00 04 93 F3|". =.) alert udp any any -> any 1236 \ (byte_test: 2.1000. The allowed values are 1 to 10 when used without dce.greater than • = .2. ! △NOTE Snort uses the C operators for each of these operators. 1000. dec. then it would be the same as using if (data & value) { do something().bitwise AND • ˆ .13 for a description and examples (2.Option bytes to convert operator Description Number of bytes to pick up from the packet. >. \ content: "|00 00 00 07|". then the operator is set to =.Converted string data is represented in octal dce Let the DCE/RPC 2 preprocessor determine the byte order of the value to be converted.less than • > . 123.) alert udp any any -> any 1235 \ (byte_test: 3.13 for quick reference). string. Any of the operators can also include ! to check if the operator is not true. dec. 0. \ byte_test: 4. distance: 4. 2 and 4. !! is not allowed.) alert tcp $EXTERNAL_NET any -> $HOME_NET any \ (msg:"AMD procedure 7 plog overflow ". \ msg: "got 123!".equal • ! .) alert udp any any -> any 1237 \ (byte_test: 10. If used with dce allowed values are 1. relative.) 160 .. Format byte_jump: <bytes_to_convert>. 161 .2. By having an option that reads the length of a portion of data. 20. \ byte_test: 4. 900.13 for quick reference).5.5. convert operator value offset = = = = 1 . \ byte_jump: 4. See section 2.big] [. move that many bytes forward and set a pointer for later detection. Number of bytes into the payload to start processing Use an offset relative to last pattern match Multiply the number of calculated bytes by <value> and skip forward that number of bytes. then skips that far forward in the packet. ! △NOTE Only two byte extract variables may be created per rule.hex] [. 0. rules can be written that skip over specific portions of length-encoded protocols and perform detection in very specific locations.10 ’<’ | ’=’ | ’>’ | ’&’ | ’ˆ’ 0-4294967295 -65535 to 65535 Description Number of bytes to pick up from the packet.alert udp any any -> any 1238 \ (byte_test: 8. align. 2 and 4. within: 4.13 for a description and examples (2. Option bytes to convert offset relative multiplier <value> big little string hex dec oct align from beginning post offset <value> dce Example alert udp any any -> any 32770:34000 (content: "|00 01 86 B8|".) 3. It reads in some number of bytes from the packet payload and saves it to a variable. \ msg: "statd format string buffer overflow". Let the DCE/RPC 2 preprocessor determine the byte order of the value to be converted. This pointer is known as the detect offset end pointer. 0xdeadbeef. Skip forward or backwards (positive of negative value) by <value> number of bytes after the other jump options have been applied. 12. instead of using hard-coded values. If used with dce allowed values are 1. please read Section 3.5. hex.align] [.multiplier <multiplier value>] [.) 3. relative.string]\ [.29 byte extract The byte extract keyword is another useful option for writing rules against length-encoded protocols. The allowed values are 1 to 10 when used without dce. <offset> \ [. or doe ptr.post_offset <adjustment value>]. The byte jump option does this by reading some number of bytes.from_beginning] [. =. \ content: "|00 00 00 01|". string.28 byte jump The byte jump keyword allows rules to be written for length encoded protocols trivially. convert them to their numeric representation. distance: 4.dec] [. \ msg: "got DEADBEEF!".9.2. relative.relative] [. >.oct] [. For a more detailed explanation. These variables can be referenced later in the rule.little][. They can be re-used in the same rule any number of times. str_offset.align <align value>] Option bytes to convert offset name relative multiplier <value> big little dce string hex dec oct align <value> Description Number of bytes to pick up from the packet Number of bytes into the payload to start processing Name of the variable.hex] [.multiplier <multiplier value>] [. depth. value offset offset offset Examples This example uses two variables to: • Read the offset of a string from a byte at offset 0. This will be used to reference the variable in other rule options. \ content: "bad stuff". pcre:"/ˆPORT/smi". \ flow:to_server. <offset>. 0. Format ftpbounce. \ byte_extract: 1.Format byte_extract: <bytes_to_extract>.dce]\ [. sid:3441. depth: str_depth. ftpbounce.dec] [. Process data as big endian (default) Process data as little endian Use the DCE/RPC 2 preprocessor to determine the byte-ordering.established. Data is stored in string format in packet Converted string data is represented in hexadecimal Converted string data is represented in decimal Converted string data is represented in octal Round the number of converted bytes up to the next <value>-byte boundary.big] [. content:"PORT". <name> \ [.30 ftpbounce The ftpbounce keyword detects FTP bounce attacks. The DCE/RPC 2 preprocessor must be enabled for this option to work.5. distance. Use an offset relative to last pattern match Multiply the bytes read from the packet by <value> and save that number into the variable. Example alert tcp $EXTERNAL_NET any -> $HOME_NET 21 (msg:"FTP PORT bounce attempt". \ msg: "Bad Stuff detected within field".) 162 .) 3. <value> may be 2 or 4. 1. alert tcp any any -> any any (byte_extract: 1. nocase. Other options which use byte extract variables A byte extract rule option detects nothing by itself. offset: str_offset.oct] [.little] [. rev:1. Here is a list of places where byte extract variables can be used: Rule Option content byte test byte jump byte extract isdataat Arguments that Take Variables offset. • Use these values to constrain a pattern match to a smaller area.\ classtype:misc-attack. Its use is in extracting packet data for use in other rule options.string] [. • Read the depth of a string from a byte at offset 1.relative] [. str_depth. within offset. 13 for a description and examples of using this rule option. Examples alert tcp any any -> any 2401 (msg:"CVS Invalid-entry".g.15 and before. For example. CVE-2004-0396: ”Malformed Entry Modified and Unchanged flag insertion”. Multiple options can be used in an ’asn1’ option and the implied logic is boolean OR. the whole option evaluates as true.5. you would specify ’content:"foo".33 dce iface See the DCE/RPC 2 Preprocessor section 2. The syntax looks like. Offset may be positive or negative. cvs:invalid-entry. ! △NOTE Format This plugin cannot do detection over encrypted sessions. \ flow:to_server. If an option has an argument.2. but it is unknown at this time which services may be exploitable. option[ argument]] .1 sequence right after the content “foo”. you would say “absolute offset 0”. \ asn1: oversize_length 10000. absolute_offset 0. if you wanted to decode snmp packets.) 3. then this keyword is evaluated as true. \ asn1: bitstring_overflow.1 options provide programmatic detection capabilities as well as some more dynamic type detection. Default CVS server ports are 2401 and 514 and are included in the default ports for stream reassembly. content:"foo". This means that if an ASN. The preferred usage is to use a space between option and argument. This keyword must have one argument which specifies the length to compare against. “oversize length 500”.5.3. relative_offset 0. the offset number. Compares ASN. absolute offset has one argument. e. absolute offset <value> relative offset <value> Examples alert udp any any -> any 161 (msg:"Oversize SNMP Length". This is known to be an exploitable function in Microsoft. Detects a double ASCII encoding that is larger than a standard buffer.established. cvs:<option>. relative_offset 0’. relative offset has one argument.1 detection plugin decodes a packet or a portion of a packet. This is the relative offset from the last content match or byte test/jump.) 3. and looks for various malicious encodings. This is the absolute offset from the beginning of the packet. 163 . which is a way of causing a heap overflow (see CVE-2004-0396) and bad pointer derefenece in versions of CVS 1. So if you wanted to start decoding and ASN.1 type is greater than 500.11.5. The ASN. Format asn1: option[ argument][. the option and the argument are separated by a space or a comma. Offset values may be positive or negative. Option invalid-entry Description Looks for an invalid Entry string. asn1: bitstring_overflow.31 asn1 The ASN. the offset value. . SSH (usually port 22). So if any of the arguments evaluate as true.1 type lengths with the supplied argument.32 cvs The CVS detection plugin aids in the detection of: Bugtraq-10384. Option bitstring overflow double overflow oversize length <value> Description Detects invalid bitstring encodings that are known to be remotely exploitable. .) alert tcp any any -> any 80 (msg:"ASN1 Relative Foo". The asn1 detection plugin decodes a packet or a portion of a packet.5.2. The depth keyword allows the rule writer to specify how far into a packet Snort should search for the specified pattern.13. The byte jump keyword allows rules to read the length of a portion of data. The pcre keyword allows rules to be written using perl compatible regular expressions.2.13.6 Non-Payload Detection Rule Options 3. 3.2.35 dce stub data See the DCE/RPC 2 Preprocessor section 2.2. See the DCE/RPC 2 Preprocessor section 2.37 ssl state See the SSL/TLS Preprocessor section 2. 3.2.5. See the DCE/RPC 2 Preprocessor section 2. The uricontent keyword in the Snort rule language searches the normalized request URI field. 3. Format fragoffset:[!|<|>]<number>. The offset keyword allows the rule writer to specify where to start searching for a pattern within a packet.5.5.13 for a description and examples of using this rule option. then skip that far forward in the packet. See the DCE/RPC 2 Preprocessor section 2. To catch all the first fragments of an IP session. ignoring any decoding that was done by preprocessors.1 fragoffset The fragoffset keyword allows one to compare the IP fragment offset field against a decimal value.11 for a description and examples of using this rule option.13. The ftpbounce keyword detects FTP bounce attacks. you could use the fragbits keyword and look for the More fragments option in conjunction with a fragoffset of 0. and looks for various malicious encodings.2. 3. 3.34 dce opnum See the DCE/RPC 2 Preprocessor section 2. The isdataat keyword verifies that the payload has data at a specified location.36 ssl version See the SSL/TLS Preprocessor section 2.38 Payload Detection Quick Reference Table 3. The rawbytes keyword allows rules to look at the raw packet data. 164 .13 for a description and examples of using this rule option. The byte test keyword tests a byte field against a specific value (with operator). The distance keyword allows the rule writer to specify how far into a packet Snort should ignore before starting to search for the specified pattern relative to the end of the previous pattern match.11 for a description and examples of using this rule option.3.2. The within keyword is a content modifier that makes sure that at most N bytes are between pattern matches using the content keyword. The cvs keyword detects invalid entry strings.5.6. 2 ttl The ttl keyword is used to check the IP time-to-live value. This keyword takes numbers from 0 to 255. ttl:5-. Example This example looks for a tos value that is not 4 tos:!4.6. This example checks for a time-to-live value that between 3 and 5. ttl:=5. ttl:3-5. ttl:=<5. ttl:<3.) 3. ttl:5-3. Format ttl:[[<number>-]><=]<number>.Example alert ip any any -> any any \ (msg: "First Fragment". 165 . ttl:>=5. fragbits: M. 3. The following examples are NOT allowed by ttl keyword: ttl:=>5. This example checks for a time-to-live value that between 5 and 255. Format tos:[!]<number>. ttl:-5. fragoffset: 0.6. Few other examples are as follows: ttl:<=5. This option keyword was intended for use in the detection of traceroute attempts. This example checks for a time-to-live value that between 0 and 5.3 tos The tos keyword is used to check the IP TOS field for a specific value. Example This example checks for a time-to-live value that is less than 3. The following bits may be checked: M .IP Security esec .Don’t Fragment R .4 id The id keyword is used to check the IP ID field for a specific value.6.More Fragments D . Some tools (exploits. Example This example looks for the IP ID of 31337. ipopts:lsrr. Warning Only a single ipopts keyword may be specified per rule. for example.IP Extended Security lsrr .5 ipopts The ipopts keyword is used to check if a specific IP option is present. scanners and other odd programs) set this field specifically for various purposes.6 fragbits The fragbits keyword is used to check if fragmentation and reserved bits are set in the IP header.Loose Source Routing ssrr .Record Route eol .6. The following options may be checked: rr .End of list nop . Format id:<number>.3. Example This example looks for the IP Option of Loose Source Routing. id:31337.Strict Source Routing satid . the value 31337 is very popular with some hackers. 3.No Op ts .Stream identifier any .Reserved Bit 166 .any IP options are set The most frequently watched for IP options are strict and loose source routing which aren’t used in any widespread internet applications.6. 3.Time Stamp sec . Format ipopts:<rr|eol|nop|ts|sec|esec|lsrr|ssrr|satid|any>. an option mask may be specified. it is useful for detecting buffer overflows.6. A rule could check for a flags value of S.PSH A .Reserved bit 1 (MSB in TCP Flags byte) 2 . fragbits:MD+.FIN (LSB in TCP Flags byte) S . The following bits may be checked: F . dsize:300<>400.match if any of the specified bits are set ! . regardless of the size of the payload. Example This example looks for a dsize that is between 300 and 400 bytes. Format dsize: [<>]<number>[<><number>]. In many cases.ACK U .6.No TCP Flags Set The following modifiers can be set to change the match criteria: + . 167 .The following modifiers can be set to change the match criteria: + match on the specified bits. This may be used to check for abnormally sized packets.URG 1 . Example This example checks if the More Fragments bit and the Do not Fragment bit are set. regardless of the values of the reserved bits.match if the specified bits are not set To handle writing rules for session initiation packets such as ECN where a SYN packet is sent with the previously reserved bits 1 and 2 set.Reserved bit 2 0 .match on the specified bits. 3. plus any others * match if any of the specified bits are set ! match if the specified bits are not set Format fragbits:[+*!]<[MDR]>. plus any others * . Warning dsize will fail on stream rebuilt packets.12 if one wishes to find packets with just the syn bit.SYN R .7 dsize The dsize keyword is used to test the packet payload size. 3.RST P .8 flags The flags keyword is used to check if specific TCP flag bits are present. ) alert tcp !$HOME_NET 0 -> $HOME_NET 0 (msg: "Port 0 TCP traffic".9 flow The flow keyword is used in conjunction with TCP stream reassembly (see Section 2. Most of the options need a user-defined name for the specific state that is being checked. and underscores.Format flags:[!|*|+]<FSRPAU120>[. This allows rules to only apply to clients or servers.)] [.12. The keywords set and toggle take an optional argument which specifies the group to which the keywords will belong. alert tcp any any -> any any (flags:SF. content:"CWD incoming".) 3. The flowbits option is most useful for TCP sessions. \ flow:stateless. It allows rules to track states during a transport protocol session. \ flow:from_client.2). Example This example checks if just the SYN and the FIN bits are set. This string should be limited to any alphanumeric string including periods.) 3. ignoring reserved bit 1 and reserved bit 2.2. The established keyword will replace the flags: A+ used in many places to show established TCP connections.(no_stream|only_stream)]. It allows rules to only apply to certain directions of the traffic flow.6. A particular flow cannot belong to more than one group. Examples alert tcp !$HOME_NET any -> $HOME_NET 21 (msg:"cd incoming detected".10 flowbits The flowbits keyword is used in conjunction with conversation tracking from the Stream preprocessor (see Section2. All the flowbits in a particular group (with an exception of default group) are mutually exclusive. dashes. When no group name is specified the flowbits will belong to a default group.2). as it allows rules to generically track the state of an application protocol. This allows packets related to $HOME NET clients viewing web pages to be distinguished from servers running in the $HOME NET.2. There are eight keywords associated with flowbits.<FSRPAU120>].(to_client|to_server|from_client|from_server)] [. nocase. 168 .6. content:"OK LOGIN". Example This example looks for a TCP acknowledge number of 0.6. Checks if the specified state is set. Unsets the specified state for the current flow.<GROUP_NAME>].logged_in. ack:0. seq:0. Example This example looks for a TCP sequence number of 0. Cause the rule to not generate an alert.<STATE_NAME>][. Format flowbits: [set|unset|toggle|isset|reset|noalert][.) 3. flowbits:noalert. Examples alert tcp any 143 -> any any (msg:"IMAP login".6. flowbits:isset. Format seq:<number>. otherwise unsets the state if the state is set.13 window The window keyword is used to check for a specific TCP window size. Sets the specified state if the state is unset and unsets all the other flowbits in a group when a GROUP NAME is specified. 3. content:"LIST". regardless of the rest of the detection options.6.12 ack The ack keyword is used to check for a specific TCP acknowledge number. 3. 169 . Checks if the specified state is not set.11 seq The seq keyword is used to check for a specific TCP sequence number. Format ack: <number>.) alert tcp any any -> any 143 (msg:"IMAP LIST". flowbits:set.logged_in. This is useful because some covert channel programs use static ICMP fields when they communicate. 3. This particular plugin was developed to detect the stacheldraht DDoS agent.6.Format window:[!]<number>. Example This example looks for an ICMP ID of 0. 170 . Example This example looks for an ICMP type greater than 30. 3.6.15 icode The icode keyword is used to check for a specific ICMP code value.14 itype The itype keyword is used to check for a specific ICMP type value. icmp_id:0. code:>30. Format icmp_id:<number>. Example This example looks for a TCP window size of 55808. window:55808.16 icmp id The icmp id keyword is used to check for a specific ICMP ID value.6. Format itype:[<|>]<number>[<><number>]. itype:>30. Example This example looks for an ICMP code greater than 30. Format icode: [<|>]<number>[<><number>]. 3. ) 3. [<version number>|*].). Warning Because of the fast pattern matching engine. This particular plugin was developed to detect the stacheldraht DDoS agent.20 sameip The sameip keyword allows rules to check if the source ip is the same as the destination IP.19 ip proto The ip proto keyword allows checks against the IP protocol header. and procedure numbers in SUNRPC CALL requests. For a list of protocols that may be specified by name. Format rpc: <application number>.6. see /etc/protocols. [<procedure number>|*]>. the RPC keyword is slower than looking for the RPC values by using normal content matching. alert tcp any any -> any 111 (rpc: 100000. icmp_seq:0. Format icmp_seq:<number>. 3.3.17 icmp seq The icmp seq keyword is used to check for a specific ICMP sequence value.*. Example This example looks for an ICMP Sequence of 0.18 rpc The rpc keyword is used to check for a RPC application. This is useful because some covert channel programs use static ICMP fields when they communicate.6. 3.6. Format ip_proto:[!|>|<] <name or number>. 171 . version. alert ip any any -> any any (ip_proto:igmp. Wildcards are valid for both version and procedure numbers by using ’*’. Example This example looks for IGMP traffic.6.3. Example The following example looks for an RPC portmap GETPORT request. ) 172 .<operator>. content:"200 OK". use: alert tcp any 80 -> any any (flow:to_client. stream_reassemble:<enable|disable>. Example This example looks for any traffic where the Source IP and the Destination IP is the same.Format sameip. ! △NOTE Format The stream reassemble option is only available when the Stream5 preprocessor is enabled.<server|client|both> [. • The optional fastpath parameter causes Snort to ignore the rest of the connection. as determined by the TCP sequence numbers. stream_reassemble:disable.<number> Where the operator is one of the following: • < .greater than or equal Example For example.<.established.noalert] [.) 3. use: alert tcp any any -> any any (stream_size:client.noalert.6.not • <= .equal • != .6.less than • > .client. to look for a session that is less that 6 bytes from the client side.) 3.21 stream reassemble The stream reassemble keyword allows a rule to enable or disable TCP stream reassembly on matching traffic.greater than • = . stream_size:<server|client|both|either>. to disable TCP reassembly for client traffic when we see a HTTP 200 Ok Response message. Example For example.less than or equal • >= .fastpath] • The optional noalert parameter causes the rule to not generate an alert when it matches. ! △NOTE Format The stream size option is only available when the Stream5 preprocessor is enabled.6. alert ip any any -> any any (sameip.22 stream size The stream size keyword allows a rule to match traffic according to the number of bytes observed. 3.6. Format session: [printable|all]. The printable keyword only prints out data that the user would normally see or be able to type. and procedure numbers in SUNRPC CALL requests. Format logto:"filename".2 session The session keyword is built to extract user data from TCP Sessions. The seq keyword is used to check for a specific TCP sequence number. The window keyword is used to check for a specific TCP window size. The icmp seq keyword is used to check for a specific ICMP sequence value.7. or even web sessions is very useful. The flowbits keyword allows rules to track states during a transport protocol session. log tcp any any <> any 23 (session:printable. There are two available argument keywords for the session rule option.7 Post-Detection Rule Options 3.3. 3. It should be noted that this option does not work when Snort is in binary logging mode. ftp. The ack keyword is used to check for a specific TCP acknowledge number.23 Non-Payload Detection Quick Reference Table 3.) 173 . The flags keyword is used to check if specific TCP flag bits are present. The dsize keyword is used to test the packet payload size. The ttl keyword is used to check the IP time-to-live value. rlogin. The sameip keyword allows rules to check if the source ip is the same as the destination IP. The all keyword substitutes non-printable characters with their hexadecimal equivalents. The itype keyword is used to check for a specific ICMP type value. The ipopts keyword is used to check if a specific IP option is present. This is especially handy for combining data from things like NMAP activity. printable or all. The flow keyword allows rules to only apply to certain directions of the traffic flow. The ip proto keyword allows checks against the IP protocol header. The tos keyword is used to check the IP TOS field for a specific value. The icode keyword is used to check for a specific ICMP code value.7. etc. The icmp id keyword is used to check for a specific ICMP ID value. There are many cases where seeing what users are typing in telnet. The rpc keyword is used to check for a RPC application. HTTP CGI scans. version. The fragbits keyword is used to check if fragmentation and reserved bits are set in the IP header.1 logto The logto keyword tells Snort to log all packets that trigger this rule to a special output log file. The id keyword is used to check the IP ID field for a specific value. Example The following example logs all printable strings in a telnet packet. ) Also note that if you have a tag option in a rule that uses a metric other than packets. React can be used in both passive and inline modes.conf to 0). type • session .7.4 for details.0. Format tag: <type>. Tagged traffic is logged to allow analysis of response codes and post-attack traffic.3 resp The resp keyword enables an active response that kills the offending session.Log packets in the session that set off the rule • host .Tag packets containing the destination IP address of the packet that generated the initial event. 3.1. tag:host. See 2.Tag packets containing the source IP address of the packet that generated the initial event.conf file (see Section 2. described in Section 2.1 any \ (content:"TAGMYPACKETS". • dst . Units are specified in the <metric> field.Count is specified as a number of units. 3. tagged alerts will be sent to the same output plugins as the original alert.4 any -> 10.7. See 2.Tag the host/session for <count> packets • seconds . You can disable this packet limit for a particular rule by adding a packets metric to your tag option and setting its count to 0 (This can be done on a global scale by setting the tagged packet limit option in snort. Subsequent tagged alerts will cause the limit to reset. <count>.seconds. The session keyword is best suited for post-processing binary (pcap) log files. the database output plugin.600.3 on how to use the tagged packet limit config option).only relevant if host type is used.packets. alert tcp any any <> 10.1. The default tagged packet limit value is 256 and can be modified by using a config option in your snort.src.1.4 react The react keyword enables an active response that includes sending a web page or other content to the client and then closing the connection.6.tagged. flowbits:set.3 for details.Tag the host/session for <count> bytes direction . Note that neither subsequent alerts nor event filters will prevent a tagged packet from being logged.11. 3. metric • packets .1. [direction]. Resp can be used in both passive or inline modes. additional traffic involving the source and/or destination host is tagged.1.Log packets from the host that caused the tag to activate (uses [direction] modifier) count • <integer> . (Note that the tagged packet limit was introduced to avoid DoS situations on high bandwidth sensors for tag rules with a high seconds or bytes counts.Tag the host/session for <count> seconds • bytes .6. tag:host. • src . Once a rule is triggered.1 any (flowbits:isnotset.1.Warnings Using the session keyword can slow Snort down considerably.11. Currently. <metric>.tagged.7. but it is the responsibility of the output plugin to properly handle these special alerts.seconds. Doing this will ensure that packets are tagged for the full amount of seconds or bytes and will not be cut off by the tagged packet limit.5 tag The tag keyword allow rules to log more than just the single packet that triggered the rule.) 174 .1. so it should not be used in heavy load situations.src. does not properly handle tagged alerts.600. a tagged packet limit will be used to limit the number of tagged packets regardless of whether the seconds or bytes count has been reached.) alert tcp 10. You can have multiple replacements within a rule. Format activated_by: 1.2.12.10 detection filter detection filter defines a rate which must be exceeded by a source or destination host before a rule can generate an event. count 30. tag:session.seconds.) 175 .2.7.1. Example . See Section 3.100 during one sampling period of 60 seconds. seconds 60. after the first 30 failed login attempts: drop tcp 10. Snort evaluates a detection filter as the last step of the detection phase.2.7.7. Format activated_by: 1. 3.1. \ sid:1000001. after evaluating all other rule options (regardless of the position of the filter within the rule source). See Section 3. \ count <c>. See Section 3.2.1.this rule will fire on every failed login attempt from 10. count: 50. 3.100 any > 10.2.8 count The count keyword must be used in combination with the activated by keyword.6 activates The activates keyword allows the rule writer to specify a rule to add when a specific network event occurs. Format activates: 1. one per content.6 for more information. seconds <s>.to_server. Both the new string and the content it is to replace must have the same length.9 replace The replace keyword is a feature available in inline mode which will cause Snort to replace the prior matching content with the given string. 3.100 22 ( \ msg:"SSH Brute Force Attempt". rev:1. depth:4. 3.1. replace: <string>.7.Example This example logs the first 10 seconds or the tagged packet limit (whichever comes first) of any telnet session.7. offset:0.) 3.6 for more information.7 activated by The activated by keyword allows the rule writer to dynamically enable a rule when a specific activate rule is triggered. detection filter has the following format: detection_filter: \ track <by_src|by_dst>. nocase.6 for more information. It allows the rule writer to specify how many packets to leave the rule enabled for after it is activated. \ content:"SSH". \ detection_filter: track by_src.10. alert tcp any any -> any 23 (flags:s. flow:established. At most one detection filter is permitted per rule. Available in inline mode only. track \ 176 . threshold: type limit. Since potentially many events will be generated. For instance. The resp keyword is used attempt to close sessions when an alert is triggered. This keyword allows the rule writer to dynamically enable a rule when a specific activate rule is triggered. This keyword allows the rule writer to specify a rule to add when a specific network event occurs. Format threshold: \ type <limit|threshold|both>. \ classtype:web-application-activity. a rule for detecting a too many login password attempts may require more than 5 attempts.4.8 Rule Thresholds ! △NOTE Rule thresholds are deprecated and will not be supported in a future release. These should incorporate the threshold into the rule. or event filters (2.txt access". This keyword must be used in combination with the activated by keyword. This keyword implements an ability for users to react to traffic that matches a Snort rule by closing connection and sending a notice.2) as standalone configurations instead. Use detection filters (3. C must be nonzero.7. Time period over which count is accrued. nocase. It allows the rule writer to specify how many packets to leave the rule enabled for after it is activated. a detection filter would normally be used in conjunction with an event filter to reduce the number of logged events.Option track by src|by dst count c seconds s Description Rate is tracked either by source IP address or destination IP address.11 Post-Detection Quick Reference Table 3. established. The maximum number of rule matches in s seconds allowed before the detection filter limit to be exceeded. There is a logical difference. \ track <by_src|by_dst>. \ count <c>. The tag keyword allow rules to log more than just the single packet that triggered the rule. This means count is maintained for each unique source IP address or each unique destination IP address.10302. \ uricontent:"/robots. threshold can be included as part of a rule. It makes sense that the threshold feature is an integral part of this rule. The session keyword is built to extract user data from TCP Sessions. alert tcp $external_net any -> $http_servers $http_ports \ (msg:"web-misc robots. Some rules may only make sense with a threshold. or you can use standalone thresholds that reference the generator and SID they are applied to. flow:to_server. The value must be nonzero. This can be done using the ‘limit’ type of threshold.txt". There is no functional difference between adding a threshold to a rule.7. 3. reference:nessus. Examples This rule logs the first event of this SID every 60 seconds. or using a standalone threshold applied to the same rule. Track by source or destination IP address and if the rule otherwise matches more than the configured rate it will fire. 3.10) within rules. seconds <s>. Replace the prior matching content with the given string of the same length.11: Post-detection rule option keywords Keyword logto session resp react tag activates activated by count replace detection filter Description The logto keyword tells Snort to log all packets that trigger this rule to a special output log file. Selecting rules for evaluation via this ”fast” pattern matcher was found to increase performance. For rules with content. instead of a specific exploit.txt access". 3. In FTP. Rules without content are always evaluated (relative to the protocol and port group in which they reside).9. the less likely that rule and all of it’s rule options will be evaluated unnecessarily . they are not used by the fast pattern matching engine. FTP is a good example. This means count is maintained for each unique source IP addresses. alert tcp $external_net any -> $http_servers $http_ports \ (msg:"web-misc robots. reference:nessus. the client sends: user username_here A simple rule to look for FTP root login attempts could be: 177 . count 10 . especially when applied to large rule groups like HTTP. then ignores any additional events during the time interval.txt access".3 Catch the Oddities of the Protocol in the Rule Many services typically send the commands in upper case letters. seconds 60 .Option type limit|threshold|both track by src|by dst count c seconds s Description type limit alerts on the 1st m events during the time interval. then ignores events for the rest of the time interval. flow:to_server. time period over which count is accrued. nocase. try and have at least one content (or uricontent) rule option in your rule. 3. sid:1000852. udp. By writing rules for the vulnerability. nocase. reference:nessus. count 10 . or destination IP address. \ uricontent:"/robots. For example. c must be nonzero value.it’s safe to say there is generally more ”good” traffic than ”bad”. \ classtype:web-application-activity.) This rule logs at most one event every 60 seconds if at least 10 events on this SID are fired. Ports or anything else are not tracked.txt". sid:1000852.10302. such as pcre and byte test. The longer and more unique a content is. the rule is less vulnerable to evasion when an attacker changes the exploit slightly.9.9 Writing Good Rules There are some general concepts to keep in mind when developing Snort rules to maximize efficiency and speed. rate is tracked either by source IP address. alert tcp $external_net any -> $http_servers $http_ports \ (msg:"web-misc robots.1 Content Matching Snort groups rules by protocol (ip. Type both alerts once per time interval after seeing m occurrences of the event. Type threshold alerts every m times we see this event during the time interval. seconds 60 .2 Catch the Vulnerability. threshold: type both . potentially putting a drag on performance. number of rule matching in s seconds that will cause event filter limit to be exceeded. While some detection options. perform detection in the payload section of the packet. instead of shellcode that binds a shell.txt".) 3. rev:1. Not the Exploit Try to write rules that target the vulnerability. threshold: type threshold. a multi-pattern matcher is used to select rules that have a chance at matching based on a single content. to send the username. rev:1. track \ by_dst. then by those with content and those without.9. \ classtype:web-application-activity. \ track by_dst.10302. If at all possible. established. or for each unique destination IP addresses. tcp. established. icmp). then by ports (ip and icmp use slightly differnet logic). s must be nonzero value. look for a the vulnerable command with an argument that is too large. \ uricontent:"/robots. 3. flow:to_server. verifying this is traffic going to the server on an established session. and because of recursion. the payload “aab” would fail. it is obvious the rule looks for a packet with a single byte of 0x13. each of the following are accepted by most FTP servers: user root user root user root user root user<tab>root To handle all of the cases that the FTP server might handle. Why? The content 0x13 would be found in the first byte. once it is found. the recursion implementation is not very smart. followed at least one space character (which includes tab). followed by root. For example. Reordering the rule options so that discrete checks (such as dsize) are moved to the beginning of the rule speed up Snort. Rules that are not properly written can cause Snort to waste time duplicating checks. that may not sound like a smart idea. looking for user. repeating until 0x13 is not found in the payload again. A good rule that looks for root login on ftp would be: alert tcp any any -> any 21 (flow:to_server.established. and if any of the detection options after that pattern fail. The way the recursion works now is if a pattern matches. For example. A packet of 1024 bytes of 0x13 would fail immediately. immediately followed by “b”. then check the dsize again.4 Optimizing Rules The content matching portion of the detection engine has recursion to handle a few evasion cases. Without recursion. The optimized rule snipping would be: dsize:1. within:1. • The rule has a pcre option. 3. While recursion is important for detection. content:"|13|". a good rule will handle all of the odd things that the protocol might handle when accepting the user command. ignoring case. then look for the pattern again after where it was found the previous time. However. because of recursion. • The rule has a content option. even though it is obvious that the payload “aab” has “a” immediately followed by “b”. content:"b". On first read. The following rule options are discrete and should generally be placed at the beginning of any rule: • dsize • flags • flow 178 . as the dsize check is the first option checked and dsize is a discrete check without recursion. take the following rule: alert ip any any -> any any (content:"a". most unique string in the attack. By looking at this rule snippit. then the dsize option would fail.alert tcp any any -> any any 21 (content:"user root".9. This option is added to allow the fast pattern matcher to select this rule for evaluation only if the content root is found in the payload. looking for root. which is the longest. a packet with 1024 bytes of 0x13 could cause 1023 too many pattern match attempts and 1023 too many dsize checks. the content 0x13 would be found again starting after where the previous 0x13 was found.) There are a few important things to note in this rule: • The rule has a flow option. the rule needs more smarts than a simple string match.) This rule would look for “a”. because the first ”a” is not immediately followed by “b”. \ content:"root". but it is needed. pcre:"/user\s+root/i". dsize:1. Repeat until the pattern is not found again or the opt functions all succeed. For example. the following rule options are not optimized: content:"|13|".) While it may seem trivial to write a rule that looks for the username root. The string “bob” would show up as 0x00000003626f6200./ .......... and figure out how to write a rule to catch this exploit.... taking four bytes............ .... Let’s break this up. ......../bin/sh...... unique to each request rpc type (call = 0... There are a few things to note with RPC: • Numbers are written as uint32s....... the string.........e.... as RPC uses simple length based encoding for passing data.. ..../..... 89 00 00 00 00 00 00 00 09 00 00 01 00 00 00 00 9c 00 00 87 00 00 00 00 e2 00 02 88 0a 01 01 20 the request id. ........ 179 . describe each of the fields.....5 Testing Numerical Values The rule options byte test and byte jump were written to support writing rules for protocols that have length encoded data....@(:.... In order to understand why byte test and byte jump are useful........... • Strings are written as a uint32 specifying the length of the string./.• fragbits • icmp id • icmp seq • icode • id • ipopts • ip proto • itype • seq • session • tos • ttl • ack • window • resp • sameip 3. let’s go through an exploit attempt against the sadmind service...... ..... .. .....................system.......... ......... ........ ....metasplo it. @(:. . .......9. a random uint32.......... and then null bytes to pad the length of the string to end on a 4 byte boundary.. The number 26 would show up as 0x0000001a.........metasplo it../............. RPC was the protocol that spawned the requirement for these two rule options..................... ...... ........ aka none) The rest of the packet is the request that gets passed to procedure 1 of sadmind.36.40 28 3a 10 . let’s put them all together. offset:4. we know the vulnerability is that sadmind trusts the uid coming from the client. Then. making sure to account for the padding that RPC requires on strings. then we want to look for the uid of 0. As such. and jump that many bytes forward. the vulnerable procedure.verifier flavor (0 = auth\_null. we need to make sure that our packet has auth unix credentials. aka none) .length of the client machine name (0x0a = 10) 4d 45 54 41 53 50 4c 4f 49 54 00 00 . To do that in a Snort rule.uid of requesting user (0) 00 00 00 00 .extra group ids (0) 00 00 00 00 00 00 00 00 . This is where byte test is useful. If we do that. we need to make sure that our packet is a call to sadmind. we use: byte_jump:4. Starting at the length of the hostname. offset:20. depth:4. offset:16. within:4. Then. First. offset:4. offset:20. depth:4. content:"|00 00 00 00|". content:"|00 00 00 01|". within:4. In english. turn it into a number. sadmind runs any request where the client’s uid is 0 as root. Then.length of verifier (0. aligning on the 4 byte boundary. However. the value we want to check. offset:12. content:"|00 00 00 00|".. byte_jump:4. content:"|00 00 00 01|". we need to make sure that our packet is an RPC call. depth:4. offset:12. we have decoded enough of the request to write our rule. content:"|00 00 00 00|".align.36.metasploit 00 00 00 00 . depth:4. depth:4. we need to make sure that our packet is a call to the procedure 1.unix timestamp (0x40283a10 = 1076378128 = feb 10 01:55:28 2004 gmt) 00 00 00 0a . 36 bytes from the beginning of the packet. and turn those 4 bytes into an integer and jump that many bytes forward. Now that we have all the detection capabilities for our rule. 180 . content:"|00 00 00 01|". content:"|00 00 00 01|". content:"|00 01 87 88|". but we want to skip over it and check a number value after the hostname. depth:4. content:"|00 01 87 88|". depth:4. we are now at: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 which happens to be the exact location of the uid.align.gid of requesting user (0) 00 00 00 00 . We don’t care about the hostname. offset:16. content:"|00 00 00 00|". depth:4. we want to read 4 bytes. content:"|00 00 00 01 00 00 00 01|". depth:4. we would check the length of the hostname to make sure it is not too large. depth:4. offset:12. If the sadmind service was vulnerable to a buffer overflow when reading the client’s hostname. instead of reading the length of the hostname and jumping that many bytes forward. content:"|00 01 87 88|".The 3rd and fourth string match are right next to each other. We end up with: content:"|00 00 00 00|". offset:4.36.36. we would read 4 bytes.align.36. depth:8.>. Our full rule would be: content:"|00 00 00 00|". depth:4. content:"|00 00 00 01 00 byte_jump:4. To do that.200. content:"|00 01 87 88|". In Snort. offset:16. we do: byte_test:4.200. starting 36 bytes into the packet. and then make sure it is not too large (let’s say bigger than 200 bytes).>. byte_test:4. offset:12. within:4. turn it into a number. depth:4. 181 . depth:8. so we should combine those patterns. 00 00 01|". offset:4. offset:16. content:"|00 00 00 00|". A shared library can implement all three types.1 DynamicPluginMeta The DynamicPluginMeta structure defines the type of dynamic module (preprocessor. 4. and path to the shared library. the version information. This includes functions to register the preprocessor’s configuration parsing. the dynamic API presents a means for loading dynamic libraries and allowing the module to utilize certain functions within the main snort code.1. It is defined in sf dynamic preprocessor. It includes function to log messages. int build.h. This data structure should be initialized when the preprocessor shared library is loaded. char uniqueName[MAX_NAME_LEN]. and rules can now be developed as dynamically loadable module to snort. int major. detection engines. and rules as a dynamic plugin to snort. 182 . but typically is limited to a single functionality such as a preprocessor. errors. and debugging info.1 Data Structures A number of data structures are central to the API. detection capabilities. Beware: the definitions herein may be out of date. and it provides access to the normalized http and alternate data buffers. The definition of each is defined in the following sections. char *libraryPath. check the appropriate header files for the current definitions. handling Inline drops. The remainder of this chapter will highlight the data structures and API functions used in developing preprocessors. exit. 4. 4. It is defined in sf dynamic meta. access to the StreamAPI. When enabled via the –enabledynamicplugin configure option.1. Check the header file for the current definition. or detection engine).h as: #define MAX_NAME_LEN 1024 #define TYPE_ENGINE 0x01 #define TYPE_DETECTION 0x02 #define TYPE_PREPROCESSOR 0x04 typedef struct _DynamicPluginMeta { int type. int minor. and processing functions.Chapter 4 Dynamic Modules Preprocessors. restart. fatal errors.2 DynamicPreprocessorData The DynamicPreprocessorData structure defines the interface the preprocessor uses to interact with snort itself. } DynamicPluginMeta. rules. It also includes information for setting alerts. u_int8_t *altBuffer. It is defined in sf dynamic engine. classification.h. SetRuleData setRuleData. and a list of references). RuleInformation info. char *dataDumpDirectory. Rule The Rule structure defines the basic outline of a rule and contains the same set of information that is seen in a text rule.4. #ifdef HAVE_WCHAR_H DebugWideMsgFunc debugWideMsg.4 SFSnortPacket The SFSnortPacket structure mirrors the snort Packet structure and provides access to all of the data contained in a given packet. Additional data structures may be defined to reference other protocol fields. It and the data structures it incorporates are defined in sf snort packet. RuleOption **options. } DynamicEngineData.1. errors. 4. DebugMsgFunc debugMsg. CheckFlowbit flowbitCheck. It also includes a location to store rule-stubs for dynamic rules that are loaded. Check the header file for the current definitions.h. address and port information and rule information (classification. PCREStudyFunc pcreStudy. That includes protocol. RegisterRule ruleRegister. DetectAsn1 asn1Detect. RegisterBit flowbitRegister. generator and signature IDs. It also includes a list of rule options and an optional evaluation function. 4.h as: typedef struct _DynamicEngineData { int version. #define RULE_MATCH 1 #define RULE_NOMATCH 0 typedef struct _Rule { IPInfo ip. int *debugMsgLine. PCRECompileFunc pcreCompile. fatal errors.1. and it provides access to the normalized http and alternate data buffers. GetRuleData getRuleData. LogMsgFunc fatalMsg. and debugging info as well as a means to register and check flowbits. This includes functions for logging messages.5 Dynamic Rules A dynamic rule should use any of the following data structures. 183 . LogMsgFunc errMsg.3 DynamicEngineData The DynamicEngineData structure defines the interface a detection engine uses to interact with snort itself. #endif char **debugMsgFile. UriInfo *uriBuffers[MAX_URIINFOS]. /* NULL terminated array of RuleOption union */ ruleEvalFunc evalFunc. priority. PCREExecFunc pcreExec.1. LogMsgFunc logMsg. The following structures are defined in sf snort plugin api. revision. GetPreprocRuleOptFuncs getPreprocOptFuncs. /* non-zero is bi-directional */ char * dst_addr. and a list of references. used internally */ /* Rule option count. IPInfo The IPInfo structure defines the initial matching criteria for a rule and includes the protocol. including the system name and rereference identifier. /* Rule Initialized. etc.any. char * src_port. typedef struct _RuleReference { char *systemName. /* String format of classification name */ u_int32_t priority. char *refIdentifier. revision. u_int32_t revision. classification. #define #define #define #define #define #define #define ANY_NET HOME_NET EXTERNAL_NET ANY_PORT HTTP_SERVERS HTTP_PORTS SMTP_SERVERS "any" "$HOME_NET" "$EXTERNAL_NET" "any" "$HTTP_SERVERS" "$HTTP_PORTS" "$SMTP_SERVERS" 184 . void *ruleData. src address and port. RuleReference The RuleReference structure defines a single rule reference. HTTP PORTS. typedef struct _RuleInformation { u_int32_t genID. } RuleReference. Some of the standard strings and variables are predefined . used internally */ Hash table for dynamic data pointers */ The rule evaluation function is defined as typedef int (*ruleEvalFunc)(void *). /* NULL terminated array of references */ } RuleInformation. /* 0 for non TCP/UDP */ } IPInfo. u_int32_t sigID. char * src_addr. HTTP SERVERS. /* NULL terminated array of references */ RuleMetaData **meta.char initialized. /* 0 for non TCP/UDP */ char direction. u_int32_t numOptions. char noAlert. char * dst_port. typedef struct _IPInfo { u_int8_t protocol. destination address and port. message text. /* } Rule. char *message. priority. used internally */ /* Flag with no alert. where the parameter is a pointer to the SFSnortPacket structure. RuleReference **references. char *classification. RuleInformation The RuleInformation structure defines the meta data for a rule and includes generator ID. signature ID. and direction. HOME NET. the integer ID for a flowbit. such as the compiled PCRE information. It includes the pattern. u_int32_t flags. typedef struct _RuleOption { int optionType. Asn1Context *asn1. HdrOptCheck *hdrData. PCREInfo *pcre. and flags (one of which must specify the buffer – raw. The ”Not” flag is used to negate the results of evaluating that option. PreprocessorOption *preprocOpt. #define NOT_FLAG 0x10000000 Some options also contain information that is initialized at run time. that which distinguishes this rule as a possible match to a packet. ContentInfo *content. #define CONTENT_NOCASE #define CONTENT_RELATIVE #define CONTENT_UNICODE2BYTE 0x01 0x02 0x04 185 . URI or normalized – to search). u_int32_t depth. typedef enum DynamicOptionType { OPTION_TYPE_PREPROCESSOR. OPTION_TYPE_ASN1. OPTION_TYPE_HDR_CHECK. depth and offset. and a designation that this content is to be used for snorts fast pattern evaluation. OPTION_TYPE_MAX }. The most unique content. Each option has a flags field that contains specific flags for that option as well as a ”Not” flag. } option_u. FlowBitsInfo *flowBit. • OptionType: Content & Structure: ContentInfo The ContentInfo structure defines an option for a content search. OPTION_TYPE_SET_CURSOR. u_int8_t *patternByteForm. OPTION_TYPE_CURSOR. union { void *ptr. if no ContentInfo structure in a given rules uses that flag. /* must include a CONTENT_BUF_X */ void *boyer_ptr. OPTION_TYPE_PCRE. u_int32_t patternByteFormLength. OPTION_TYPE_LOOP. the one with the longest content length will be used. typedef struct _ContentInfo { u_int8_t *pattern. ByteData *byte. } ContentInfo. unicode. Boyer-Moore content information. In the dynamic detection engine provided with Snort. LoopInfo *loop. ByteExtract *byteExtract. OPTION_TYPE_FLOWBIT.RuleOption The RuleOption structure defines a single rule option as an option type and a reference to the data specific to that option. } RuleOption. relative. etc. OPTION_TYPE_BYTE_JUMP. should be marked for fast pattern evaluation. OPTION_TYPE_BYTE_EXTRACT. Additional flags include nocase. OPTION_TYPE_FLOWFLAGS. The option types and related structures are listed below. CursorInfo *cursor. OPTION_TYPE_BYTE_TEST. OPTION_TYPE_CONTENT. FlowFlags *flowFlags. int32_t offset. u_int32_t incrementLength. u_int32_t compile_flags.h. u_int8_t operation. It includes the name of the flowbit and the operation (set. • OptionType: Flowbit & Structure: FlowBitsInfo The FlowBitsInfo structure defines a flowbits option. } FlowFlags. void *compiled_extra. It mirrors the ASN1 rule option and also includes a flags field. which specify the direction (from server. etc. u_int32_t flags. } FlowBitsInfo. pcre flags such as caseless. /* pcre. /* must include a CONTENT_BUF_X */ } PCREInfo. • OptionType: Flow Flags & Structure: FlowFlags The FlowFlags structure defines a flow option. It includes the PCRE expression. isnotset). established session. • OptionType: ASN. u_int32_t id. and flags to specify the buffer. unset. It includes the flags. toggle.h provides flags: PCRE_CASELESS PCRE_MULTILINE PCRE_DOTALL PCRE_EXTENDED PCRE_ANCHORED PCRE_DOLLAR_ENDONLY PCRE_UNGREEDY */ typedef struct _PCREInfo { char *expr. #define ASN1_ABS_OFFSET 1 186 . . to server).. u_int32_t flags. as defined in PCRE. isset. =. It includes the header field. u_int32_t flags. and flags. a value. unsigned int max_length. an operation (for ByteTest. as related to content and PCRE searches. and flags.¿. ¡. the operation (¡. /* u_int32_t mask_value. int double_overflow. The cursor is the current position within the evaluation buffer. similar to the isdataat rule option. Field to check */ Type of comparison */ Value to compare value against */ bits of value to ignore */ • OptionType: Byte Test & Structure: ByteData The ByteData structure defines the information for both ByteTest and ByteJump operations. multiplier. #define #define #define #define #define #define #define #define #define CHECK_EQ CHECK_NEQ CHECK_LT CHECK_GT CHECK_LTE CHECK_GTE CHECK_AND CHECK_XOR CHECK_ALL 0 1 2 3 4 5 6 7 8 187 .etc). • OptionType: Protocol Header & Structure: HdrOptCheck The HdrOptCheck structure defines an option to check a protocol header for a specific value. int length. u_int32_t flags. typedef struct _CursorInfo { int32_t offset. /* u_int32_t value. } HdrOptCheck. an offset. -. • OptionType: Cursor Check & Structure: CursorInfo The CursorInfo structure defines an option for a cursor evaluation. } Asn1Context. a mask to ignore that part of the header field. It includes an offset and flags that specify the buffer. It includes the number of bytes. int offset_type. as well as byte tests and byte jumps.etc). /* specify one of CONTENT_BUF_X */ } CursorInfo. a value. This can be used to verify there is sufficient data to continue evaluation. /* u_int32_t op.#define ASN1_REL_OFFSET 2 typedef struct _Asn1Context { int bs_overflow. int offset. -. The flags must specify the buffer. /* u_int32_t flags.=. int print. static or reference */ char *refId. /* char *refId. u_int8_t initialized. u_int32_t flags. The loop option acts like a FOR loop and includes start. int32_t offset.. multiplier. an offset.#define CHECK_ATLEASTONE #define CHECK_NONE typedef struct _ByteData { u_int32_t bytes. /* u_int32_t flags. One of those options may be a ByteExtract. /* } ByteExtract. specifies * relative. /* type of this field . For a dynamic element. /* Value of static */ int32_t *dynamicInt. #define DYNAMIC_TYPE_INT_STATIC 1 #define DYNAMIC_TYPE_INT_REF 2 typedef struct _DynamicElement { char dynamicType.ByteExtract. It includes whether the element is static (an integer) or dynamic (extracted from a buffer in the packet) and the value. /* /* /* /* /* /* * /* /*. /* Pointer to value of dynamic */ } data. CursorInfo *cursorAdjust. /* reference ID (NULL if static) */ union { void *voidPtr. struct _Rule *subRule. and a reference to the DynamicElement. /* Holder */ int32_t staticInt. It includes the number of bytes. • OptionType: Loop & Structures: LoopInfo. } ByteData. typedef struct _ByteExtract { u_int32_t bytes. • OptionType: Set Cursor & Structure: CursorInfo See Cursor Check above. } LoopInfo. 4. and increment values as well as the comparison operation for termination. It includes a cursor adjust that happens through each iteration of the loop. u_int32_t flags. u_int32_t op. end. } DynamicElement. */ The ByteExtract structure defines the information to use when extracting bytes for a DynamicElement used a in Loop evaltion.DynamicElement The LoopInfo structure defines the information for a set of options that are to be evaluated repeatedly. /* void *memoryLocation.2 Required Functions Each dynamic module must define a set of functions and data objects to work within this framework. or extracted value */ Offset from cursor */ Used for byte jump -. DynamicElement *end. 188 . flags specifying the buffer. the value is filled by a related ByteExtract option that is part of the loop. for checkValue */ Value to compare value against. u_int32_t multiplier. /* u_int32_t multiplier.32bits is MORE than enough */ must include a CONTENT_BUF_X */ • OptionType: Byte Jump & Structure: ByteData See Byte Test above. typedef struct _LoopInfo { DynamicElement *start. DynamicElement *increment. a reference to a RuleInfo structure that defines the RuleOptions are to be evaluated through each iteration. /* int32_t offset. u_int32_t op. u_int32_t value. for checkValue. 9 10 /* /* /* /* /* /* Number of bytes to extract */ Type of byte comparison. ByteData *byteData. • int InitializePreprocessor(DynamicPreprocessorData *) This function initializes the data structure for use by the preprocessor into a library global variable. • int LibVersion(DynamicPluginMeta *) This function returns the metadata for the shared library.2. • int LibVersion(DynamicPluginMeta *) This function returns the metadata for the shared library. CursorInfo *cursorInfo. Asn1Context *asn1. ByteData *byteData. u int8 t **cursor) This function evaluates a single pcre for a given packet. PCREInfo *pcre. • int ruleMatch(void *p. log. – int pcreMatch(void *p. FlowBitsInfo *flowbits) This function evaluates the flowbits for a given packet. – int detectAsn1(void *p. checking for the existence of the expression as delimited by PCREInfo and cursor. – int byteTest(void *p.1 check for a given packet.h. u int32 t value. With a text rule. u int8 t **cursor) This function evaluates a single content for a given packet. dpd and invokes the setup function. ByteExtract *byteExtract.2. ByteData *byteData. PCRE evalution data. byteJump. as specified by ByteExtract and delimited by cursor. • int InitializeEngineLib(DynamicEngineData *) This function initializes the data structure for use by the engine. u int8 t *cursor) This is a wrapper for extractValue() followed by checkValue(). initialize it to setup content searches. as delimited by Asn1Context and cursor. Value extracted is stored in ByteExtract memoryLocation parameter. as specified by FlowBitsInfo.1 Preprocessors Each dynamic preprocessor library must define the following functions. checking for the existence of that content as delimited by ContentInfo and cursor. etc). • int RegisterRules(Rule **) This is the function to iterate through each rule in the list. The sample code provided with Snort predefines those functions and defines the following APIs to be used by a dynamic rules library. Each of the functions below returns RULE MATCH if the option matches based on the current criteria (cursor position. the with option corresponds to depth. and register flowbits. – int checkValue(void *p.4. – int byteJump(void *p. It will interact with flowbits used by text-based rules. 189 . u int8 t *cursor) This function extracts the bytes from a given packet. – int checkFlow(void *p. This uses the individual functions outlined below for each of the rule options and handles repetitive content issues. drop. 4. New cursor position is returned in *cursor.Rule **) This is the function to iterate through each rule in the list and write a rule-stop to be used by snort to control the action of the rule (alert. Rule *rule) This is the function to evaluate a rule if the rule does not have its own Rule Evaluation Function. – int processFlowbits(void *p. u int8 t *cursor) This function evaluates an ASN. CursorInfo *cursorInfo. The metadata and setup function for the preprocessor should be defined sf preproc info. u int8 t **cursor) This function adjusts the cursor as delimited by CursorInfo. u int8 t *cursor) This function compares the value to the value stored in ByteData. These are defined in the file sf dynamic preproc lib. – int extractValue(void *p. Cursor position is updated and returned in *cursor.c. u int8 t **cursor) This is a wrapper for extractValue() followed by setCursor(). – int checkCursor(void *p. and pcreMatch to adjust the cursor position after a successful match. – int setCursor(void *p. It handles bounds checking for the specified buffer and returns RULE NOMATCH if the cursor is moved out of bounds. Cursor position is updated and returned in *cursor. FlowFlags *flowflags) This function evaluates the flow for a given packet. • int DumpRules(char *. u int8 t *cursor) This function validates that the cursor is within bounds of the specified buffer. ContentInfo* content. and the distance option corresponds to offset. – int contentMatch(void *p. It is also used by contentMatch. etc).2 Detection Engine Each dynamic detection engine library must define the following functions. • int LibVersion(DynamicPluginMeta *) This function returns the metadata for the shared library.1 Preprocessor Example The following is an example of a simple preprocessor. 4. This assumes the the files sf dynamic preproc lib.3 Rules Each dynamic rules library must define the following functions. as spepcifed by PreprocessorOption. This preprocessor always alerts on a Packet if the TCP port matches the one configured. as delimited by LoopInfo and cursor. Define the Setup function to register the initialization function. patterns that occur more than once may result in false negatives. The remainder of the code is defined in spp example.c and sf dynamic preproc lib. register flowbits.h.c into lib sfdynamic preprocessor example. as specified by HdrOptCheck. – void setTempCursor(u int8 t **temp cursor.3. • int InitializeDetection() This function registers each rule in the rules library. defined in sf preproc info. 4. u int8 t **cursor) This function is used to revert to a previously saved temporary cursor position. Cursor position is updated and returned in *cursor. This is the metadata for this preprocessor. This should be done for both content and PCRE options. Take extra care to handle this situation and search for the matched pattern again if subsequent rule options fail to match. u int8 t **cursor) This function iterates through the SubRule of LoopInfo. – void revertTempCursor(u int8 t **temp cursor.h. • int EngineVersion(DynamicPluginMeta *) This function defines the version requirements for the corresponding detection engine library. etc. u int8 t **cursor) This function is used to handled repetitive contents to save off a cursor position temporarily to be reset at later point. It should set up fast pattern-matcher content. Cursor position is updated and returned in *cursor.c. • int DumpSkeletonRules() This functions writes out the rule-stubs for rules that are loaded. PreprocessorOption *preprocOpt.2.c and is compiled together with sf dynamic preproc lib. ! △NOTE 4. #define #define #define #define MAJOR_VERSION 1 MINOR_VERSION 0 BUILD_VERSION 0 PREPROC_NAME "SF_Dynamic_Example_Preprocessor" ExampleSetup #define DYNAMIC_PREPROC_SETUP extern void ExampleSetup(). Examples are defined in the file sfnort dynamic detection lib. The sample code provided with Snort predefines those functions and uses the following data within the dynamic rules library.so. – int loopEval(void *p. HdrOptCheck *optData) This function evaluates the given packet’s protocol headers. LoopInfo *loop. 190 . The metadata and setup function for the preprocessor should be defined in sfsnort dynamic detection lib.3 Examples This section provides a simple example of a dynamic preprocessor and a dynamic rule.h are used. u int8 t **cursor) This function evaluates the preprocessor defined option. • Rule *rules[] A NULL terminated list of Rule structures that this library defines. – int preprocOptionEval(void *p. If you decide to write you own rule evaluation function.– int checkHdrOpt(void *p. if (!p->ip4_header || p->ip4_header->proto != IPPROTO_TCP || !p->tcp_header) { /* Not for me. "Preprocessor: Example is setup\n"). _dpd. } /* Register the preprocessor function. if (port < 0 || port > 65535) { _dpd. ID 10000 */ _dpd. } The initialization function to parse the keywords from snort. portToCheck). arg)) { arg = strtok(NULL. _dpd.logMsg(" } else { _dpd.debugMsg(DEBUG_PLUGIN. char *argEnd. Transport layer. ExampleInit). arg). 10).fatalMsg("ExamplePreproc: Invalid port %d\n". void ExampleInit(unsigned char *). arg = strtok(args.fatalMsg("ExamplePreproc: Missing port\n").). } port = strtoul(arg.debugMsg(DEBUG_PLUGIN.). port). unsigned long port.registerPreproc("dynamic_example". PRIORITY_TRANSPORT. void ExampleSetup() { _dpd.logMsg("Example dynamic preprocessor configuration\n").addPreproc(ExampleProcess. DEBUG_WRAP(_dpd. 191 . #define SRC_PORT_MATCH 1 #define SRC_PORT_MATCH_STR "example_preprocessor: src port match" #define DST_PORT_MATCH 2 #define DST_PORT_MATCH_STR "example_preprocessor: dest port match" void ExampleProcess(void *pkt.#define GENERATOR_EXAMPLE 256 extern DynamicPreprocessorData _dpd. if (!arg) { _dpd. DEBUG_WRAP(_dpd. } Port: %d\n". void *). void *context) { SFSnortPacket *p = (SFSnortPacket *)pkt. return */ return. 10000). } The function to process the packet and log an alert if the either port matches. if(!strcasecmp("port". "Preprocessor: Example is initialized\n").conf. u_int16_t portToCheck. } portToCheck = port. "\t\n\r"). " \t\n\r").fatalMsg("ExamplePreproc: Invalid option %s\n". &argEnd. void ExampleInit(unsigned char *args) { char *arg. void ExampleProcess(void *. take from the current rule set.alertAdd(GENERATOR_EXAMPLE.established. and non-relative. return.401. \ sid:109.if (p->src_port == portToCheck) { /* Source port matched. 1.2 Rules The following is an example of a simple rule.h. defined in detection lib meta. \ content:"NetBus".established. Per the text version. reference:arachnids. Per the text version. log alert */ _dpd. static FlowFlags sid109flow = { FLOW_ESTABLISHED|FLOW_TO_CLIENT }.) This is the metadata for this rule library. log alert */ _dpd. 0.3. case sensitive.c. static RuleOption sid109option1 = { OPTION_TYPE_FLOWFLAGS. rev:5. 3. • Flow option Define the FlowFlags structure and its corresponding RuleOption. no depth or offset. flow is from server. DST_PORT_MATCH. } if (p->dst_port == portToCheck) { /* Destination port matched. 0). content is ”NetBus”. • Content Option Define the ContentInfo structure and its corresponding RuleOption. 0.alertAdd(GENERATOR_EXAMPLE. 3. classtype:misc-activity. It is implemented to work with the detection engine provided with snort. return. NOTE: This content will be used for the fast pattern matcher since it is the longest content option for this rule and no contents have a flag of CONTENT FAST PATTERN. } } 4. 192 . SRC_PORT_MATCH_STR. 1. Search on the normalized buffer by default. SRC_PORT_MATCH. SID 109. { &sid109flow } }. flow:from_server. Declaration of the data structures. DST_PORT_MATCH. 0). The snort rule in normal format: alert tcp $HOME_NET 12345:12346 -> $EXTERNAL_NET any \ (msg:"BACKDOOR netbus active". used internally */ 0. • Rule and Meta Data Define the references. /* source port(s) */ 0. static RuleReference *sid109refs[] = { &sid109ref_arachnids. no alert. /* metadata */ { 3. /* destination port */ }. RuleOption *sid109options[] = { &sid109option1. /* revision */ "misc-activity". /* holder for NULL. /* offset */ CONTENT_BUF_NORMALIZED. &sid109option2. static RuleReference sid109ref_arachnids = { "arachnids". /* Type */ "401" /* value */ }. /* flags */ NULL. rule data.static ContentInfo sid109content = { "NetBus". /* sigid */ 5. message. used internally */ 193 . not yet initialized. meta data (sid. search for */ boyer/moore info */ byte representation of "NetBus" */ length of byte representation */ increment length */ The list of rule options. { &sid109content } }. /* proto */ HOME_NET. The rule itself. etc). /* classification */ 0. /* Holder.use 3 to distinguish a C rule */ 109. NULL }. /* genid -. /* depth */ 0. Rule options are evaluated in the order specified. /* destination IP */ ANY_PORT. option count. Rule sid109 = { /* protocol header. /* pattern to 0. /* holder for 0. used internally for flowbits */ NULL /* Holder. /* Direction */ EXTERNAL_NET. /* priority */ "BACKDOOR netbus active". static RuleOption sid109option2 = { OPTION_TYPE_CONTENT. /* ptr to rule options */ NULL. /* Holder. with the protocol header. akin to => tcp any any -> any any */ { IPPROTO_TCP. /* holder for 0 /* holder for }. NULL }. /* source IP */ "12345:12346". sid109options. /* Holder. /* message */ sid109refs /* ptr to references */ }. used internally */ 0. /* Use internal eval func */ 0. classification. The InitializeDetection iterates through each Rule in the list and initializes the content. pcre. Rule *rules[] = { &sid109. extern Rule sid109.• The List of rules defined by this rules library The NULL terminated list of rules. &sid637. etc. flowbits. 194 . extern Rule sid637. NULL }. 2 Detection Plugins Basically. Bug fixes are what goes into STABLE. please use the HEAD branch of cvs. The detection engine checks each packet against the various options listed in the Snort config files. It can do this by checking: if (p->tcph==null) return. there are a lot of packet flags available that can be used to mark a packet as “reassembled” or logged.1 Submitting Patches Patches to Snort should be sent to the snort-devel@lists.2 Snort Data Flow First. Similarly. This is intended to help developers get a basic understanding of whats going on quickly.3 Output Plugins Generally.2. Packets are then sent through the detection engine.2. It will someday contain references on how to create new detection plugins and preprocessors. 5. Patches should done with the command diff -nu snort-orig snort-new. This allows this to be easily extensible.sourceforge.Chapter 5 Snort Development Currently.net mailing list. Each of the keyword options is a plugin. 5. Check out src/decode.1 Preprocessors For example. Each preprocessor checks to see if this packet is something it should look at. a TCP analysis preprocessor could simply return if the packet does not have a TCP header. we’ll document what these few things are.h for the list of pkt * constants. Later. Packets are then sent through the registered set of preprocessors. 5. Packets are passed through a series of decoder routines that first fill out the packet structure for link level protocols then are further decoded for things like TCP and UDP ports. If you are going to be helping out with Snort development. End users don’t really need to be reading this section. 5. 195 . 5. Features go into HEAD. We are currently cleaning house on the available output options.2. this chapter is here as a place holder. We’ve had problems in the past of people submitting patches only to the stable branch (since they are likely writing this stuff for their own IDS purposes). look at an existing output plugin and copy it to a new item and change a few things. traffic is acquired from the network link via libpcap. new output plugins should go into the barnyard project rather than the Snort project. 196 . net/dedicated/cidr.com/mag/phrack/phrack49/p49-06 [2] [1] 197 .incident.org [3] [4] [6] [5]. This action might not be possible to undo. Are you sure you want to continue? We've moved you to where you read on your other device. Get the full title to continue reading from where you left off, or restart the preview.
https://www.scribd.com/document/45467056/Snort-Manual
CC-MAIN-2016-50
refinedweb
57,754
69.28
Host wix website different server jobs ...minor edits and changes made on our website, [login to view URL] which is built in Wix. We would like to shorten the size of our home page, delete one of the 2 identical twitter feeds, and a few other basic formatting issues resolved before making our website live again. Please contact me if you are experienced in Wix and can finish this project quickly Im looking to get someone to add zippay to my wix store? I am designing a new website for my Audio Production business on WIX. It hs not been Looking for an experienced app developer to c...developer to construct the back end for an app called UpDoIN2. UpDoIN2 connects stylists with clients wanting to get a style, cut, or updo. Please view the Wix site at: [login to view URL] Additionally if you are interested in investment view at. ... [login to view URL] Sincerely ...Rush interval or if the refresh/rescan button is presses. Sorting and filtering is done in public class MainWindowViewModel The project requires 4.6.2 .NET framework and Wix Toolset to run properly. [login to view URL] I need this project finished as soon as possible Online store with Wix and we would like to get our product on Google shopping Have created a website on Wix. The site is ok but its missing some design touch.. I want to host 10 domains on One Google Cloud instance and each domain should resolve to different ip address. Only Google Cloud experts to please bid. Prove in bid message, why do you consider yourself as expert. I need a Wix website developer who can develop my webpages I have the design almost ready in wix ..i just need to set up the Arabic version and set up the log in page Hello I'm currently working on a website through WIX. It is not finished yet but I will do that myself. The issue we have is that while working on our home page we have streched the text, videos & html...I'm working on a 19 inch screen, whenever I move to my laptop of 15 inch, everything is unsorted on the page. In short, we are looking for someone ...have a website running at. Since Wix did not previously support Multilanguage sites properly we had to make an additional website and use this as the alternative language version. Currently we have the main website in Danish. [login to view URL] And the alternative language site has been created as a subsite [login to view URL] Now Wix finally Starting new outreach. Need entirely new landing page and site changes, rework. Currently in Wix. Looking for advice in design. ..] I need to add a product configurator to my Wix Stores site. The product configurator allows site visitors to choose different patterns and colours to design a badge. Something similar based on this functionality [login to view URL] ...child therapy website to] I need to .. run a small business providing mobile bar hire and bartender hire services - 'The Sydney Mixologists'. We need help with improving our rankings. We have good content, videos etc. however our site is not optimized for the right words etc. I have a draft website [[login to view URL]] I: Build a wix based website to dentists website done on Wix, I would like someone to recreate it so that I can have all the code and put it in my localhost for my company. Attached is the SQL database and the image used. Please copy the following website: [login to view URL] Log in for Wix: contact me to log in! ...college scouts into members. Goal #2 provide a .. calendars for live Our We offer online fitness and ex is available. My site is in Wix and I don't have time to design it. Need someone to do it for me.
https://www.freelancer.com.au/job-search/host-wix-website-different-server/2/
CC-MAIN-2018-47
refinedweb
652
74.49
/* * OutputAttribute>OutputAttribute</code> object is used to represent a * node added to the output node map. It represents a simple name * value pair that is used as an attribute by an output element. * This shares its namespaces with the parent element so that any * namespaces added to the attribute are actually added to the * parent element, which ensures correct scoping. * @see org.simpleframework.xml.stream.Node */ class OutputAttribute implements OutputNode { /** * This contains the namespaces for the parent element. */ private NamespaceMap scope; * Represents the output node that this node requires. */ private OutputNode source; * Represents the namespace reference for this node. private String reference; * Represents the name of this node object instance. */ private String name; * Represents the value of this node object instance. */ private String value; * Constructor for the <code>OutputAttribute</code> object. This * is used to create a simple name value pair attribute holder. * * @param name this is the name that is used for the node * @param value this is the value used for the node */ public OutputAttribute(OutputNode source, String name, String value) { this.scope = source.getNamespaces(); this.source = source; this.value = value; this.name = name; } * Returns the value for the node that this represents. This * is a modifiable property for the node and can be changed. * When set this forms the value the attribute contains in * the parent XML element, which is written in quotations. * * @return the name of the value for this node instance */ public String getValue() { return value; } * This is used to set a text value to the attribute. This should * be added to the attribute if the attribute is to be written * to the parent element. Without a value this is invalid. * @param value this is the text value to add to this attribute public void setValue(String value) { this.value = value; * This is used to change the name of an output node. This will * only affect the name of the node if the node has not yet been * committed. If the node is committed then this will not be * reflected in the resulting XML generated. * * @param name this is the name to change the node to public void setName(String name) { this.name = name; * Returns the name of the node that this represents. This is * an immutable property and should not change for any node. * If this is null then the attribute will not be added to * the node map, all attributes must have a valid key. * * @return returns the name of the node that this represents */ public String getName() { return name; * OutputNode getParent() { return source; } * This returns a <code>NodeMap</code> which can be used to add * nodes to the element before that element has been committed. * Nodes can be removed or added to the map and will appear as * attributes on the written element when it is committed. * @return returns the node map used to manipulate attributes public NodeMap<OutputNode> getAttributes() { return new OutputNodeMap(this); * This is used to create a child element within the element that * this object represents. When a new child is created with this * method then the previous child is committed to the document. * The created <code>OutputNode</code> object can be used to add * attributes to the child element as well as other elements. * @param name this is the name of the child element to create public OutputNode getChild(String name) { return null; * This is used to get the text comment for the element. This can * be null if no comment has been set. If no comment is set on * the node then no comment will be written to the resulting XML. * @return this is the comment associated with this element public String getComment() { * This is used to set a text comment to the element. This will * be written just before the actual element is written. Only a * single comment can be set for each output node written. * @param comment this is the comment to set on the node public void setComment(String comment) { return; } * The <code>Mode</code> is used to indicate the output mode * of this node. Three modes are possible, each determines * how a value, if specified, is written to the resulting XML * document. This is determined by the <code>setData</code> * method which will set the output to be CDATA or escaped, * if neither is specified the mode is inherited. * @return this returns the mode of this output node object public Mode getMode() { return Mode.INHERIT; * This is used to set the output mode of this node to either * be CDATA, escaped, or inherited. If the mode is set to data * then any value specified will be written in a CDATA block, * if this is set to escaped values are escaped. If however * this method is set to inherited then the mode is inherited * from the parent node. * @param mode this is the output mode to set the node to public void setMode(Mode mode) { return; * be CDATA or escaped. If this is set to true the any value * specified will be written in a CDATA block, if this is set * to false the values is escaped. If however this method is * never invoked then the mode is inherited from the parent. * @param data if true the value is written as a CDATA block public void setData(boolean data) { * This is used to acquire the prefix for this output node. If * the output node is an element then this will search its parent * nodes until the prefix that is currently in scope is found. * If however this node is an attribute then the hierarchy of * nodes is not searched as attributes to not inherit namespaces. * @return this returns the prefix associated with this node public String getPrefix() { return scope.getPrefix(reference); * @param inherit if there is no explicit prefix then inherit public String getPrefix(boolean inherit) { return scope.getPrefix(reference); * This is used to acquire the namespace URI reference associated * with this node. Although it is recommended that the namespace * reference is a URI it does not have to be, it can be any unique * identifier that can be used to distinguish the qualified names. * @return this returns the namespace URI reference for this public String getReference() { return reference; * This is used to set the reference for the node. Setting the * reference implies that the node is a qualified node within the * XML document. Both elements and attributes can be qualified. * Depending on the prefix set on this node or, failing that, any * parent node for the reference, the element will appear in the * XML document with that string prefixed to the node name. * @param reference this is used to set the reference for the node public void setReference(String reference) { this.reference = reference; * This returns the <code>NamespaceMap</code> for this node. Only * an element can have namespaces, so if this node represents an * attribute the elements namespaces will be provided when this is * requested. By adding a namespace it becomes in scope for the * current element all all child elements of that element. * @return this returns the namespaces associated with the node public NamespaceMap getNamespaces() { return scope; * This returns the node that has just been added public OutputNode setAttribute(String name, String value) { return null; * This is used to remove any uncommitted changes. Removal of an * output node can only be done if it has no siblings and has * not yet been committed. If the node is committed then this * will throw an exception to indicate that it cannot be removed. public void remove() { * The <code>commit</code> method is used flush and commit any * child nodes that have been created by this node. This allows * the output to be completed when building of the XML document * has been completed. If output fails an exception is thrown. public void commit() { * false; * This is used to determine whether the node has been committed. * If the node has been committed, then this will return true. * When committed the node can no longer produce child nodes. * @return true if this node has already been committed public boolean isCommitted() { return true; * This is used to acquire the name and value of the attribute. * Implementing this method ensures that debugging the output * node is simplified as it is possible to get the actual value. * @return this returns the details of this output node public String toString() { return String.format("attribute %s='%s'", name, value); }
http://simple.sourceforge.net/download/stream/report/cobertura/org.simpleframework.xml.stream.OutputAttribute.html
CC-MAIN-2017-13
refinedweb
1,387
62.07
On Tue, Nov 17, 2009 at 1:10 PM, Rakesh Vidyadharan <rakesh@sptci.com> wrote: > > On 17 Nov 2009, at 5:32:13 AM, Ard Schrijvers wrote: >>). > > I am using - a simple generic map wrapper around a node that can be used for tempting systems easily. Not final yet, but it works. I would recommend to add some ObjectConverter capable of mapping primary nodetypes to certain beans. Then, your NodeBean could be something like the base fallback bean. With generics you can then add methods to your base bean like below. You could take a look at [1]. Regards Ard [1] public <T> T getBean(String relPath, Class<T> beanMappingClass) { try { Object o = this.objectConverter.getObject(node, relPath); if(o == null) { log.debug("Cannot get bean for relpath {} for current bean {}.", relPath, this.getPath()); return null; } if(!beanMappingClass.isAssignableFrom(o.getClass())) { log.debug("Expected bean of type '{}' but found of type '{}'. Return null.", beanMappingClass.getName(), o.getClass().getName()); return null; } return (T)o; } catch (ObjectBeanManagerException e) { log.warn("Cannot get Object at relPath '{}' for '{}'", relPath, this.getPath()); } return null; } > > Rakesh
http://mail-archives.apache.org/mod_mbox/jackrabbit-users/200911.mbox/%3C697f8380911170429w2159172dh575a060e3f14e9fc@mail.gmail.com%3E
CC-MAIN-2016-26
refinedweb
180
61.73
Note: Palindrome Example is available in second page. 1. Deleting the Characters To delete characters from StringBuffer, two methods exist – deleteCharAt() and delete(). Supported methods from String class - StringBuffer deleteCharAt(int pos): Delete the character in the StringBuffer at the specified index number, pos. - StringBuffer delete(int start, int end): Deletes all the characters in the StringBuffer existing in between start and end-1. public class DeleteDemo { public static void main(String args[]) { // to delete one character StringBuffer buffer1 = new StringBuffer("Lord Almighty"); buffer1.deleteCharAt(3); // deletes d System.out.println(buffer1); // prints Lor Almighty // to delete a few characters StringBuffer buffer2 = new StringBuffer("UnitedStates"); buffer2.delete(1, 11); // deletes nitedState (1 to 9-1) System.out.println(buffer2); // prints Us // to delete all StringBuffer buffer3 = new StringBuffer("Himalayas"); buffer3.delete(0, buffer3.length()); // deletes all characters System.out.println(buffer3); // no output } } buf1.deleteCharAt(4); The method deleteCharAt(4) deletes only a single character present at 4th index number. buf2.delete(2, 8); The method delete(2, 8) deletes a group of characters that ranges from 2 to 8-1. buf3.delete(0, buf3.length()); The above statement also deletes a group of characters but it is complete string because the first parameter is 0, the starting index of the string and buf3.length(), the complete length of string. 2. Replacing and Reversing Characters We have seen earlier, deleting a single character and few characters. Now let us go for replacing a single character and few characters. For this two methods exist – setCharAt() and replace(). In this program, let us see how to reverse the contents of StringBuffer using reverse() method. Supported methods from String class - void setCharAt(int x, char ch): Replaces the existing character at the index number x with the character ch. - StringBuffer replace(int start, int end, String str): Replaces all the characters existing from start to end-1 with string str. - StringBuffer reverse(): Reverses all the characters in StringBuffer. public class ReplaceAndReverse { public static void main(String args[]) { // replacing one character StringBuffer buffer1 = new StringBuffer("planetarium"); System.out.println(buffer1); // planetarium buffer1.setCharAt(0, 'P'); System.out.println(buffer1); // Planetarium // replacing a group characters StringBuffer buffer2 = new StringBuffer("Lord Balaji"); buffer2.replace(0, 4, "Great"); // repalces 0, 1, 2, 3 (4-1) with Great System.out.println(buffer2); // Great Balaji // reversing the characters StringBuffer buffer3 = new StringBuffer("INDIA"); System.out.println(buffer3); // INDIA buffer3.reverse(); System.out.println(buffer3); // AIDNI } } - buffer1.setCharAt(0, ‘P’) replaces the single character p existing in the index number 0 in buffer1 with P. - buffer2.replace(0, 4, “Great”) replaces the characters existing from 0 to 3 (constituting Lord) with Great. - buffer3.reverse() reverses the contents of buffer3. The affect comes in the original buffer itself. 2 thoughts on “Palindrome Delete Replace Reverse Java Example” class ReplaceAndReverse { public static void main(String args[]) { StringBuffer str=new StringBuffer(“pavan”); System.out.println(str.setCharAt(0,’a’)); System.out.println(str.reverse()); } } Sir in this program at line no: replacemethod.java:6: ‘void’ type not allowed here System.out.println(str.setCharAt(0,’a’)); ^ 1 error this error is coming what is this meaning?? When a method returns does not return a value (void), you cannot keep it in println() method. This rule applies to C/C++ also. str.setCharAt(0,’a’) setCharAt() method replaces in the original buffer. After this method call, keep only str in println() method. you get output. Following works. public class Demo { public static void main(String[] args) { StringBuffer str=new StringBuffer(“pavan”); str.setCharAt(0,’a’); System.out.println(str.reverse()); } }
https://way2java.com/string-and-stringbuffer/stringbuffer-deleting-replacing-palindrome/
CC-MAIN-2020-50
refinedweb
596
51.65
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Kai Grossjohann wrote: > This is a wmii usage question. I'm a newbie with wmii, and I'm asking > for hints on how others use it, so that my usage can become more > efficient, too. > > For the purpose of presentation, assume that I work with xterms a lot > and that my screen has room for four of them (top left, top right, > bottom left and bottom right). Now assume further that I have more than > 4 xterm windows, and at any given time, I would like to see a different > subset of them. > > Now, my screen layout would mean that I have two columns, each of which > has two xterms in it and is in default layout mode. But now assume that > I would like to swap one of the xterms out and replace it with a > different one: Great question and thanks for the inspiration! I really miss this ability to temporarily hide some windows and un-hide them when I need to (like wmii-2 detaching behavior). > > * Where do all the xterms live that I'm not currently looking at? > * How to swap the xterm out that I don't need to see anymore and how > to swap in the one that I do want to see now? Like Anselm said, you can do this with tagging, but it would be nice to have it automated. Here's how I implemented this (by using the 'status' area of the bar as the tag for temporarily hidden clients): DETACHED_TAG = 'status' # Detach the currently selected client def detachClient write '/view/sel/sel/tags', DETACHED_TAG end # Attach the most recently detached client def attachClient if areaList = read("/#{DETACHED_TAG}") area = areaList.split.grep(/^\d+$/).last if clientList = read("/#{DETACHED_TAG}/#{area}") client = clientList.split.grep(/^\d+$/).last write "/#{DETACHED_TAG}/#{area}/#{client}/tags", read('/view/name') end end end -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2.2 (GNU/Linux) iD8DBQFE03X+mV9O7RYnKMcRAg4mAJ9iG5meNCPVaHwENIPXdbJdHjS8ZACfQ0+x ZPPS0dT1yQWBdRzssiFg0DU= =AU7D -----END PGP SIGNATURE----- Received on Fri Aug 04 2006 - 18:30:51 UTC This archive was generated by hypermail 2.2.0 : Sun Jul 13 2008 - 16:11:47 UTC
http://lists.suckless.org/wmii/0608/2500.html
CC-MAIN-2019-26
refinedweb
357
66.78
Opened 12 years ago Closed 11 years ago #2829 closed defect (invalid) I can't clear what looks like a Model-level DB cache Description It looks like my models are caching their DB query in a way that I can't clear. If I call "Model.objects.all()" and then make any changes to the DB with my MySQL client, the results of subsequent Model.objects.all() invocations never changes. Example, with model PendingAlert: PendingAlert.objects.all() [<PendingAlert: PendingAlert object>, <PendingAlert: PendingAlert object>] (...now, in mysql...) mysql> delete from pending_alert; Query OK, 2 rows affected (0.00 sec) (...now, back in my Django session) PendingAlert.objects.all() [<PendingAlert: PendingAlert object>, <PendingAlert: PendingAlert object>] ...I just verified - the first Django session never clears its cache even if I alter the pending_alert table using Django instead of straight in MySQL. Just to make sure that I have the right mental model here: Isn't Model.objects.all() supposed to create a QuerySet with its own search? Shouldn't these calls be touching the database directly? Change History (6) comment:1 Changed 12 years ago by comment:2 Changed 12 years ago by Just to add some more data: This definitely isn't an uncommitted transaction. The deletes hit the database, other clients see them, and if I quit my Django process and restart it then it sees the deletes (...but doesn't see any further changes until it's quit and restarted again). comment:3 Changed 12 years ago by Resolving as worksforme unless the reporter or anyone else is still having this issue. comment:4 follow-up: 5 Changed 11 years ago by:5 Changed 11 years ago by Tried using the same django setup as I have on Windows on my debian system and running the same tests... a new list is returned here. Linux abaddon 2.6.18-4-686 #1 SMP Mon Mar 26 17:17:36 UTC 2007 i686 GNU/Linux MySQL 5.0.32-Debian-7etch1-log These is my first attempt ever submitting tickets so I hope Im doing this right :) Replying to ejot <magnus@derelik.net>::6 Changed 11 years ago by Hmm... I can't replicate this. I'm running OSX, MySQL 5.0.45. Here's what I've done: In [1]: from t2829.models import * In [2]: all = two829.objects.all() In [3]: all Out[3]: [<1:hello>, <2:fudge>] # Ok - right here, I open another terminal to a MySQL command prompt, and execute this: # INSERT INTO t2829_two829 (var1) VALUES ('spork'); # there are now 3 records. In [4]: all = two829.objects.all() In [5]: all Out[5]: [<1:hello>, <2:fudge>, <3:spork>] I'm getting the correct answer, and the same happens if I update/delete from within the MySQL client. Are you using MyISAM tables (I am) or InnoDB tables? This may be an outcome of some mysql-level query cache, but I know that if anything changes in a MyISAM table, then the qcache goes, but this might not be the same for InnoDB. Please - try this out, and see if you can recreate it. Here's the model I've used: from django.db import models # Create your models here. class two829(models.Model): var1 = models.CharField(maxlength=20) def __repr__(self): return '<%d:%s>' % (self.id, self.var1) class Admin: pass There is no model-level cache or anything like that involved here. My guess would be that there is an uncommitted transaction floating around somewhere that means the deletes haven't really hit the database. I'll leave this open for now, pending a bit more thinking, but I strongly suspect it's not a Django bug.
https://code.djangoproject.com/ticket/2829
CC-MAIN-2018-47
refinedweb
613
75.1
easy HTML and XHTML transcription Project description Malformed markup is enraging. Therefore, when I must generate HTML I construct a token structure using natural Python objects (strings, lists, dicts) and use this module to transcribe them to syntacticly correct HTML. This also avoids lots of tedious and error prone entity escaping. A “token” in this scheme is: - a string: transcribed safely to HTML, eg “some text here” - an int or float: transcribed safely to HTML, eg 1 or 2.5. - a sequence: an HTML tag: element 0 is the tag name, element 1 (if a mapping) is the element attributes, any further elements are enclosed tokens, eg: [‘H1’, {‘align’: ‘centre’}, ‘Heading Text’] - because a string like “&foo” gets its “&” transcribed into the entity “&”, a single element list whose tag begins with “&” encodes an entity, example: [“<”] - a preformed token object with .tag (a string) and .attrs (a mapping) attributes Core functions: - transcribe(*tokens): a generator yielding strings comprising HTML - xtranscribe(*tokens): a generator yielding strings comprising XHTML - attrquote(s): quote the string s for use as a tag attribute according to HTML 4.01 section 3.2.2 - nbsp(s): convert s to nonbreaking text: generator yielding tokens with whitespace converted to entities Convenience routines: - transcribe_s(*tokens): convert tokens into a string containing HTML - xtranscribe_s(*tokens): convert tokens into a string containing XHTML Obsolete: - tok2s: transcribe tokens to a string; trivial wrapper for puttok - puttok: transcribe tokens to a file - text2s: transcribe a string to an HTML-safe string; trivial wrapper for puttext - puttext: transcribe a string as HTML-safe text to a file Example: from cs.html import transcribe, transcribe_s, xtranscribe, puttok [...] table = ['TABLE', {'width': '80%'}, ['TR', ['TD', 'a truism'], ['TD', '1 < 2'] ] ['TR', ['TD', 'a couple'], ['TD', 'A & B'] ] ] prose_with_table = [ 'Here is a line with a line break.', ['BR'], 'Here is a trite table:', table, ] [...] print('Here is the table's HTML:', transcribe_s(table)) [...] # write HTML tokens to a file for s in transcribe(['H1', {'align': 'left'}, 'Prose'], *prose_with_table): fp.write(s) [...] # write XHTML tokens to a file for s in xtranscribe(*prose_with_table): fp.write(s) Project details Release history Release notifications Download files Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
https://pypi.org/project/cs.html/
CC-MAIN-2018-22
refinedweb
374
59.03
This is a description of my passion project. I plan to publish more detail and motivation when I get to a minimum viable product. I want to make social collaboration software without walls. A company can have its private discussions and documents - but people in a company should be able to include clients or contractors in discussions seamlessly. It should not be necessary to require people to join a private account on service X just to have a conversation. The idea is to make a decentralized protocol - there is no central server, and no one company that controls everything. This has been attempted before by Identi.ca, Diaspora, Google Wave, and others. I thought that a decentralized protocol could have more success if it takes a different approach: reinvent as little as possible, and build on top of an existing protocol with a large user base. I’m working on a reference client (called Poodle) that implements a new protocol that builds on email. Email is one of the few decentralized social protocols that has broad adoption (2.6 billion users); and it has stood the test of time. Email is not perfect - but over the years email systems have evolved to address many subtle problems; and we have deployed a great deal of email infrastructure and supporting software. A protocol that builds on email instead of attempting to replace it will have a massive head start thanks to all of that work. There is a deeply-set mindset that email messages are text or HTML, and that one message corresponds to one reply. This is the same way people thought about web pages in the ’90s. Then AJAX came along and changed everything by decoupling HTTP requests from page views. That was the big idea that led to Web 2.0. I want to apply a similar idea: decouple email messages from conversation replies, and use email to transport structured JSON data representing activities. A basic activity type would be “post a message” or “post a reply”. But there are less obvious activity types, such as “make an edit to a message that I sent earlier”, or “upvote that other message”. Those latter types affect the way that participants see a discussion, but are not presented the same way that replies are. I think that this idea can lead to many new applications that operate over email in ways that we never imagined. An important feature is that I do not have to get people to switch to a new system en masse. These new-style exchanges degrade gracefully when viewed in a traditional email client. If someone edits one of their messages after sending it, Poodle users see the edited version with a small note that says “edited a few minutes ago”. Users on traditional email clients see the edit as a follow-up message with the new content. Where Poodle users see +1 counts, traditional email users see messages that just say “+1” (or whatever text the sender has selected for their fallback “like” message). This works because email supports multiple data parts, including fallback presentation for clients that do not understand a new format. Poodle messages contain a JSON part intended to be consumed by Poodle (or other interoperable clients), and an HTML view of the same content for traditional clients. Poodle supports interaction modes beyond the traditional “email exchanges are discussions” point of view. Poodle splits out several activity types that can serve as the starting point of an interaction - for example there is a “share a document” option. The document might be HTML edited directly in the client, or an uploaded file such as a spreadsheet, presentation, image, or video. Anyone who the document is shared with can edit the document. What really happens is that their client sends out an “edit” activity to collaborators; but what everyone sees is that the document in their client updates with the new changes. (And anyone can browse previous revisions of a document at any time, because those revisions are really just email messages on their IMAP server.) Once again, people using traditional clients see document edits as follow-up messages with the new content in its entirety. I have a small slide deck of screen shots from an early iteration of Poodle: Keep in mind that all of the features that you see work without any new servers. This is all just email. The only thing that is new is a special email client (which runs locally via a downloaded app). And everything gracefully degrades when interacting with people with regular email clients. Going slide-by-slide: Participants can edit their own post after-the-fact; each activity has +1 counts. An interaction might be presented as a collaborative document instead of as a thread. In this case there are calls-to-action to edit, or link to the document. (In this example the document content is markdown; but this concept could work for any type of file: images, videos, slide decks, whatever.) Linking to email messages is a much under-used feature in my opinion. There is actually already an RFC that specifies how to construct a globally-unique URI for any email message. This is an early iteration of the process of linking to a document from another activity. Combining collaborative documents with linking allows for a decentralized wiki that actually lives in copies in the participant’s email accounts. I was experimenting with features to make email more usable generally. I tried to design Poodle to make it really obvious who sees what in any exchange. Poodle uses a reply-to-all form as the default reply option, and the user must go through extra steps to reply to just one person, or to a subset of the people already participating in a discussion. If someone does reply without including everyone, you get this “private aside” feature. (This works just by examining To:, From:, and Cc: fields in email messages in the discussion.) The private aside acts like a self-contained sub-discussion, interleaved with the original discussion. My hope is that this kind of feature can help to avoid embarrassing information leaks. Private aside messages are interleaved time-wise with the top-level discussion. And each private aside has its own private reply form after the last message in the aside. Somehow I missed including a slide showing another feature that I think is useful: when someone includes a new person in the recipient list in a reply, there is a card that appears in the discussion view that says “so-and-so joined the discussion”. I think those features work well for small discussions with a fixed set of participants. On the roadmap is scaling up via hosted groups. Each group has its own email address - to start an interaction with the group you send to the group’s address (e.g. backyard-goats@raddiscussions.net). People who join the group later have access to existing discussions and documents via archives on the group server. This is basically just the concept of a mailing list, but with some added usability features. The combination of social collaboration features and groups produces something like subreddits, or Facebook groups, or Jive communities. Groups support the philosophy of decentralization: anyone can start up their own group servers and have complete control over them; anyone can bring people from outside the group into a group interaction by including them in the recipient list; an interaction can be shared with multiple groups simultaneously; and so on.]]> Last. These are some features of Go that I dislike on what I think are more subjective grounds than the “bad parts”, or that could be worked around if some of the bad parts were fixed.. nilvalue. Despite the lack of a compile-time concrete type, it is safe to dispatch trait methods on a trait object because there is compile-time verification that whatever value is in the object implements the given trait and therefore implements the appropriate methods.: A parallel program is one that uses a multiplicity of computational hardware (e.g., several processor cores) to perform a computation more quickly. The aim is to arrive at the answer earlier, by delegating different parts of the computation to different processors that execute at the same time. By contrast, concurrency is a program-structuring technique in which there are multiple threads of control. Conceptually, the threads of control execute “at the same time”; that is, the user sees their effects interleaved. Whether they actually execute at the same time or not is an implementation detail; a concurrent program can execute on a single processor through interleaved execution or on multiple physical processors.. nil, slice type manipulation, and make; add discussion of zero values; lots of edits This recipe is part of the Flow Cookbook series. Flow and React are both Facebook projects - so as you might imagine, they work quite well together. React components can take type parameters to specify types for props and state. Type-checking works well with both functional and class components. Flow type annotations provide an alternative to propTypes runtime checks. Flow’s static checking has some advantages: propsmismatches. propTypes. stateas well as props. props, Flow checks that propsand statesare used correctly within the component’s rendermethod, and in other component methods. Flow changed the way that it handles React types in version 0.53.0. This recipe assumes that you are using Flow v0.53.0 or later. With Flow you specify the types of props and state using type parameters on the React.Component class. The form for type parameters is: Where Props, and State can be whatever object types you want. If your component has the props title, createdAt, and authorId then a definition for Props could look like this: If your component is stateless then you can omit the State parameter, in which case the state type defaults to void. Props should list types for all props - even props that are optional or that have default values. If you add a defaultProps value to your component then Flow will automatically infer that fields from defaultProps are not required when your component is called. So you should not use a ? in the corresponding field in your Props type. Leaving out the ? lets you avoid unnecessary undefined checks in your component’s methods. To declare a type for props in a stateless functional component use a type annotation like this: Once again, Props can be any object type that you want, and should include types for all props, even those that have default values. The return type for a functional component is React.Element<*> - but Flow can infer that so don’t bother with a return type annotation. Type definitions for React are built into Flow. The Flow documentation includes a type reference for React types. It is useful to look at those definitions to see exactly what Flow expects. You can also go straight to the source: a lot of what I know about using Flow came from examining Flow’s type definition file for React and other files in the same directory. The Flow documentation also includes its own guide on using Flow with React. Let’s build on the code from the Unpacking JSON API data recipe, and build a simple Hacker News client. The client will fetch lists of stories from the Hacker News API to display. When the user selects a story, the client will fetch and display comments. Let’s start with a component that displays a Hacker News story as a single line, and accepts a callback to do something if the user selects that story. First we define a type for the props that this component will accept. We import the Story type from 'flow-cookbook-hacker-news', which is the example code from the Unpacking JSON API data recipe. That Story type is a ready-made type that describes everything we will want to display in the new client. Take a look at the source file to see what Story looks like. (The import { type T } bit is Flow syntax - it is not part of Javascript.) The StoryListItemProps type lists the props that will be given to our component. The props are a story, and a callback called onSelect. The type indicates that onSelect must be a function that takes zero arguments, and that returns undefined (a.k.a. void). It is not necessary to require that the return type be undefined - you could use mixed instead if you do not want to put any constraint on the callback’s return type. My opinion is that using void is a clear indication to the caller that the component will not do anything with a return value. On the other hand you might get an irritating type error if you provide a single-expression arrow function that implicitly returns a value. And here is the StoryListItem component itself: The type annotation, props: StoryListItemProps, does two things for us: when StoryListItem is rendered, Flow will check that it is given the required props of the appropriate types; and Flow will also check uses of props in the body of the StoryListItem function for consistency with StoryListItemProps. Checking props from both directions ensures that a component is in alignment with its callers. In general if a component does not have internal state, and does not use life cycle callbacks such as componentDidMount, then I prefer to use a functional component, like StoryListItem. A functional component cannot have methods that refer to this.props; so I made the selectStory event handler a top-level function that accepts a reference to the component’s props as an argument. Reusing the StoryListItemProps type in the signatures for the component and for the event handler means that we can easily keep track of available props in both functions. selectStory also takes an event argument. The Event type is built into Flow, and Flow knows about the preventDefault method. Flow’s version of the Event type is defined in Flow’s DOM type definitions file. To populate instances of the StoryListItem component, we will need to make API requests and update some state. Here is a type for that state, and the parameters for the top-level component, which will manage that state: The definition of AppState shows that the state will hold an array of stories, which will not be defined while stories are loading; a selectedStory, which will be defined when the user is viewing comments on a story; and an error, in case something goes wrong while loading stories. Because every property in AppState is optional, state can be initialized as an empty object. (The question mark at the end of a property name indicates that property might not be set.) selectedStory is optional, and its type is nullable, so there are two question marks on that line. That is because selectedStory is initially not set, and after a user views a story and then backs out to the story list selectedStory will be set to null. Since App has a constructor, we specify the props type both in the second class type parameter, and again in the type of the props argument to constructor. That is because a subclass can define a constructor with a signature that differs from the parent class’ constructor. It would not make much sense to do that in a React Component; but Flow must be able to check all sorts of classes, so it does not make assumptions about types of constructor arguments. App will fetch stories when it is mounted. So we extend its definition with a componentDidMount callback. fetchTopStories takes an argument that specifies the number of stories to fetch, and it returns a promise. Once stories are loaded we can display them via a render method. But the component will initially display while the API request is loading; so we will have to check whether stories have loaded, and display a loading indicator if they are not ready. The import piece of the JSX that is finally returned from render is content, which is assigned a different value depending on whether an error occurred while fetching stories, a specific story has been selected, or there is an array of stories available, and none has been selected. If none of those cases applies, then it means that stories are still loading. When displaying a list of stories, content is populated by a list of instances of StoryListItem, which we defined earlier. There is nothing special about rendering a type-checked component - you pass props the same way as with any component. Flow can track changes to the type of a variable over a series of statements. Flow infers that when content is first defined its type is void; and it infers that no matter which code path gets executed, by the time we get to the return statement the type has changed to either React.Element<*> or React.Element<*>[] - either of which is compatible with Flow’s expectations for JSX content. The event handling methods selectStory and deselectStory make state changes to track whether the user is looking at a specific story: Those state changes affect the output from render to switch between displaying a list of story titles, or a detail view for a single story. At this point we have made references to App’s state in componentDidMount, render, selectStory, and deselectStory. Flow checks all of those uses against the definition of AppState. For example, if we made a mistaken assumption that selectedStory holds an ID, as opposed to a value of type Story, and tried to write something like this.setState({ selectedStory: story.id }) Flow would report an error, and point out the mismatch. I have not given the implementation of StoryView, which is responsible for displaying comments on a story. It happens that StoryView is quite similar to App - except that StoryView loads comments where App loads stories. The interested reader can see the full details of StoryView in the accompanying code. Complete working code is available at. Your next assignment is to clone that code and to add some features. Some ideas to try are to add links to the original article for each story, or to display profile pages for posters and commenters. The example code here uses React’s own state features to manage app state. That helps to keep this recipe self-contained. But in my opinion the best practice is to keep state in a third-party state-management framework such as Redux. For details on using Flow with Redux and react-redux take a look at the next recipe, Flow & Redux.]]> This recipe is part of the Flow Cookbook series. Hacker News provides a public API. One of the endpoints of that API accepts an ID and responds with an item: Here is an example of a response: An “item” might be a story, a comment, a question, a job posting, a poll, or a voting option in a poll. Each item type has different properties - for example stories have a title, but comments do not. If you don’t have context for the ID, the only way to know what you have fetched is to check the type property of the response at runtime. To add type safety to a call to this API, it is necessary to describe a type that encompasses all of the possible shapes that the returned data might take. That is going to be a union type, which will look something like this: There are not a huge number of properties in the API responses - but if we list out all of the properties in every branch the result will be too big and dense for light reading. So let’s start by factoring out common properties into helper types. All of the different item types have by, id, and time properties. So we can put those all into one type: Those Username and ID types are just aliases that I defined for primitive types: I think that using aliases like these helps to provide clarity on the purpose of each property. If we had a property with the type by: string it would not be obvious whether the value of that property is an ID that happens to be a string, or a human-readable value. Using the Username type alias makes it obvious that the property will contain a value that might be suitable for display to users. Otherwise the types string and Username are interchangeable. There is more common structure in Hacker News item types: the story, ask, job, and poll response types all represent top-level submissions, which have several properties in common: With those helper types in place, we can produce a type that describes all possible items: An intersection type like { type: 'story', kids: ID[], url: URL } & ItemCommon & TopLevel is essentially a shorthand for an object type with a type property that is always equal to 'story', combined with all of the properties listed in the ItemCommon and TopLevel types. Each branch of the union type contains a type intersection that combines common properties with the properties that are particular to each item type.[^top-level union] type Item = ItemCommon & (/* union type */). That would put the union type inside of the intersection type. But due to a quirk in Flow as of version 0.36 the union type must be the outermost layer of of composition for type narrowing to work. We don’t have to do anything special to parse incoming data into that type. Flow types are duck types - Item is just an alias for plain Javascript objects with a certain structure. We just need to declare that API responses have the Item type. That is done with with the return type in this function signature: You might have noticed something a little strange about the types of the type properties in Item. We used string literals where there should have been type expressions! For example, we gave 'story' as a type in the first branch of the union type. In fact string literals are types. In a type expression, the literal 'story' is a type with exactly one possible value: the string 'story'. ( 'story' is a subtype of the more general type, string.) This is useful because it signals to Flow which branch of the union type is applicable inside the body of a case or if statement. Consider this function, which does not type-check: Flow can narrow the type of a variable in certain contexts. A runtime comparison with a static string literal does the trick: Hacker News does provide endpoints for fetching recent submissions of a specific item type (e.g., the latest stories). But to demonstrate the flexibility of the Item type, let’s write some code that fetches and displays the latest items of any type. We will need to switch on the type property of each item to display it properly: Flow is able to infer which item type is given in each case body. This is just like how type-narrowing worked in the if body in the getTitle function. Flow’s checking has an added bonus: if you have a case body with no return or break statement, execution falls through into the next case body. When switching on item.type, a fall-through would result in a situation where a case body might be executed with any of several different item types. For example: Flow allows this, because all of the types listed in that example have a title property. But if a case body did something not compatible with all of the different item types that could fall-through into it, then Flow would report an error. Next up are functions to determine which items to fetch, and to make the necessary requests: And finally, some code to set everything running: Later on we may realize that it would be useful to be able to refer to each item type individually. To do that, we can create a named alias for each item type: Then we can replace the earlier definition of Item with a simpler one: This well let us write specialized functions, such as a function that specifically formats a poll with its options. So how do we get to a point where we can call a function that accepts only polls? The answer is, once again, type-narrowing: Notice the use of flatMap in fetchPollOpts. This filters results to check that the results are actually poll options. At the same time, Flow is able to infer that the filtered results all have the PollOpt type. This uses a custom definition for flatMap: If you trust that all of the items that are fetched will be of the right type, and you do not want to bother with a runtime check, then you could use a type-cast instead: Finally, here is a function that feeds fetched items to the new-and-improved item formatting function: The code from this article is available at. I encourage you to check out the code to tinker with it. Try building more functionality, and see how type-checking affects the way you write code.]]> Type-checking can be a useful asset in a Javascript project. A type checker can catch problems that are introduced when adding features or refactoring, which can reduce the amount of time spent debugging and testing. Type annotations provide a form of always-up-to-date documentation that makes it easier for developers to understand an unfamiliar code base. But it is important to use type-checking effectively to get its full benefit. The Javascript community is fortunate to have a choice of two great type checkers. These recipes focus on Flow, and introduce patterns for using Flow effectively. To get updates when new recipes or extras are posted, subscribe to the Atom feed, or follow @FlowCookbook. I appreciate your requests, questions, and suggestions! Please send feedback by leaving comments here, or on recipes or extras; or send messages to @FlowCookbook. These are primers on practical patterns for Flow. I recommend using these patterns in any project that uses Flow. (Coming soon) Flow types are duck types - Flow is not a new, strait-jacketed OOP language. Flow is not Java or C#. Flow is a codification of previously-unwritten Javascript idioms. (Coming soon) Uses for union types introduces a pattern for managing data that comes in different shapes. Union types are helpful for describing Redux actions, for unpacking incoming JSON data, and for passing messages over a channel. If you have been tempted to use subclasses, take a look at union types to see if they might be a better fit. Unpacking JSON API data - Javascript’s flexibility is useful for handling incoming data in whatever form it may take. Flow is designed to be just as flexible when type-checking functions that process data. This is a case study that uses the Hacker News API as an example for type-safe data processing. Flow & React - This recipe demonstrates how to use Flow effectively when creating React components. Including type parameters in functional and class components provides an alternative to propTypes that can provide better safety and modularity. (Coming soon) Flow & Redux - Flow and Redux could have been made for each other. This recipe demonstrates several patterns that are useful for building Redux action creators and reducers. This is a companion to the post on React. Extras are not about practical patterns. In these articles we explore ideas just because they are interesting. Read these if you want to dig deeper into type theory, or to learn about Flow’s lesser-known capabilities. (Coming soon) What are types? The short answer is, types are sets of possible values. This post gets into what that means, and shows that Flow takes more of a purist approach to types compared to most object-oriented languages. (Coming soon) The “algebra” in “algebraic data types” - In the recipe Uses for union types I mentioned that union types are also called “sum types” or “algebraic data types”. This post gives a brief background on type algebra so that you can understand where those terms come from. (Coming soon) Advanced algebraic data types - Union types are great, but not perfect. This post introduces an alternative formulation for sum types that allows Flow to check for missing pattern matches. It also shows that GADTs are almost possible in Flow. Flow has inspired many programmers to put bits to screen. Here are some articles that I found to particularly helpful: Getting started with Flow is a tutorial from the official documentation. If you don’t know where to start, start there. Why use type-checking? And if you do, Why Use Flow? Follow that link for the answers, and learn some things that you might not know about Flow. Aria Fallah covers a lot of background, and also introduces some interesting work from Giulio Canti. Authoring and publishing JavaScript modules with Flow is a detailed guide on publishing an NPM module with Flow type annotations included, so that anyone who uses the library can benefit from those annotations if they choose to use Flow as well.]]> This is an old post - for an up-to-date guide see Flow Cookbook: Flow & React. Flow v0.11 was released recently. The latest set of changes really improve type checking in React apps. But there are some guidelines to follow to get the full benefits. React added support in version 0.13 for implementing components as native Javascript classes (more information on that here). The latest version of the React type definitions take full advantage of class-based type checking features. React.Componenttakes type parameters When creating a component, be sure to provide type parameters in your class declaration to describe the types of your props, default props, and state. Here is a modified example from the React blog: import React from 'react' type Props = { initialCount: number } type DefaultProps = { initialCount: number } type State = { count: number } export class Counter extends React.Component<DefaultProps,Props,State> { constructor(props: Props, context: any) { super(props, context) this.state = {count: props.initialCount} } tick() { this.setState({count: this.state.count + 1}) } render(): React.Element { return ( <div onClick={this.tick.bind(this)}> Clicks: {this.state.count} </div> ) } } Counter.propTypes = { initialCount: React.PropTypes.number } Counter.defaultProps = { initialCount: 0 } The parameter signature is React.Component<DefaultProps,Props,State>. This is not exactly documented; but you can see types of React features in Flow’s type declarations for React. All of the type declarations in that folder are automatically loaded whenever Flow runs, unless you use the --no-flowlib option. If you define a constructor for your component, it is a good idea to annotate the props argument too. Unfortunately Flow does not make the connection that the constructor argument has the same type as this.props. Note that I included type annotations on render() and context. This is just because Flow generally requires type annotations for class method arguments and return values. When those type parameters are given, here are some of the things that Flow can check: defaultPropsis defined) this.propsor this.stateare checked to make sure that the properties accessed exist, and have a compatible type this.setState()are declared in your state type and have the correct types I mentioned above that Flow will check that components are given required props. In my testing, there were some cases where this worked when I used JSX syntax, but did not work with the plain Javascript React.createElement option. (The case I had trouble with was with a conditionally-rendered child in a render method - my uses of of React.createElement worked fine with both syntaxes.) I suspect that engineers at Facebook tend to prefer JSX, and, and maybe test code written with JSX syntax more heavily. What is nice is that most of the features that Flow uses to support React are general-purpose. As far as I can tell, the only feature in Flow that is React-specific is support for JSX syntax. But some of the features that make Flow work so well are not yet documented. For details, see my post on Advanced features in Flow]]> Flow has some very interesting features that are currently not documented. It is likely that the reason for missing documentation is that these features are still experimental. Caveat emptor. I took a stroll through the source code for Flow v0.11. Here is what I found while reading type_inference_js.ml and react.js. Edit: It has been pointed out to me that Flow features prefixed with $ are not technically public, and that the semantics of those features may change. But they are useful enough that I plan to use some of them anyway :) Class<T> $Diff<A,B> $Shape<T> $Record<T> $Supertype<T> $Subtype<T> $Enum<T> Class<T> Type of the class whose instances are of type T. This lets you pass around classes as first-class values - with proper type checking. I use this in an event dispatch system where events are class instances, and event handlers are invoked based on whether they accept a given event type: var handlers: Array<[Class<any>, Function]> = [] function register<T:Object>(klass: Class<T>, handler: (event: T) => void) { handlers.push([klass, handler]) } function emit<T:Object>(event: T) { handlers.forEach(([klass, handler]) => { if (event instanceof klass) { handler(event) } }) } This gives me a compile-time guarantee that event handlers can handle events of the type they are invoked with. class ViewPost { id: number; author: string; constructor(id: number, author: string) { this.id = id this.author = author } } class ViewComment { id: number; postId: number; constructor(id: number, postId: number) { this.id = id this.postId = postId } } // No errors! register(ViewPost, ({ id, author }) => { /* whatever */ }) // Error: object pattern property not found in ViewComment register(ViewComment, ({ id, author }) => { /* whatever */ }) $Diff<A,B> If A and B are object types, $Diff<A,B> is the type of objects that have properties defined in A, but not in B. Properties that are defined in both A and B are allowed too. React uses this to throw type errors if components are not given required props, but to leave props with default values as optional. declare function createElement<D, P, S, A: $Diff<P, D>>( name: ReactClass<D, P, S>, attributes: A, children?: any ): ReactElement<D, P, S>; Where P is the type for component props, and D is the type for default props. Here is a simplified example: type Props = { foo: number, bar: string, } type DefaultProps = { foo: number, } function setProps<T: $Diff<Props, DefaultProps>>(props: T) { // whatever } // No errors! setProps({ bar: 'two', }) // No errors! setProps({ foo: 1, bar: 'two', }) // Error, because `bar` is required setProps({ foo: 1, }) In my testing, this worked equally well if $Diff was used directly in the type of P instead of as a type bound. But in the React type declarations, it is used in a type bound. $Shape<T> Matches the shape of T. React uses $Shape in the signatures for setProps and setState. declare class ReactComponent<D, P, S> { // ... setProps(props: $Shape<P>, callback?: () => void): void; setState(state: $Shape<S>, callback?: () => void): void; replaceProps(props: P, callback?: () => void): void; replaceState(state: S, callback?: () => void): void; // ... } Where P is the type of a component’s props, and S is the type of a component’s state. An object of type $Shape<T> does not have to have all of the properties that type T defines. But the types of the properties that it does have must match the types of the same properties in T. In React this means that you can use, e.g., setState to set some state properties, while leaving others unspecified. Note how the type of state in replaceState differs: when calling replaceState you must include a value for every property in S. Some examples: type Props = { foo: number, bar: string, } // No errors! var a: $Shape<Props> = { foo: 1 } // Error: string is incompatible with type number var b: $Shape<Props> = { foo: 'one' } An object of type $Shape<T> is not allowed to have properties that are not part of T. // Error: prop baz of Props not found in object type var c: $Shape<Props> = { foo: 1, baz: 2, } $Shape is like a supertype for objects. Consider that a type { foo: number } (when used as a type bound) represents all objects that have a foo property of type number. That includes objects that have additional properties, such as { foo: 1, bar: 'string' }. So { foo: number } is a supertype of, e.g., { foo: number, bar: string }. The type $Shape<{ foo: number, bar: string }> allows values of type { foo: number }. That is to say, $Shape<T> refers to types that are more general than T - i.e., supertypes. $Record<T> Update: $Record<T> is gone in Flow v0.12. But instead of $Record<T>, you can use the nearly equivalent construct: {[key: $Enum<T>]: U}, where U is the type of values in the record. The type of objects whose keys are those of T. This means that an object of type $Record<T> must have properties with all of the same names as the properties in T - but the types assigned to those properties may be different. React uses $Record to check the type of propTypes. Here is a simplified example: type Props = { foo: number, bar: string, } var propTypes1: $Record<Props> = { foo: React.PropTypes.number, bar: React.PropTypes.string, } // Error: string literal bar property not found in object literal var propTypes2: $Record<Props> = { foo: React.PropTypes.number, } Note that Flow does not verify that React.PropTypes.number matches the type number. It just checks that propTypes1 has all of the same keys. // No errors! var propTypes3: $Record<Props> = { foo: 'bleah', bar: 'blerg', } A $Record type might have additional keys that are not included in the original object type. // No errors! var propTypes4: $Record<Props> = { foo: React.PropTypes.number, bar: React.PropTypes.string, baz: React.PropTypes.string, } An important detail to note is that a $Record type can only use property names that are known statically. Dynamic lookups are not allowed. propTypes4.foo // No errors! // Error: computed property/element cannot be accessed on record type propTypes4['foo'] In its real definition, React actually uses $Record in combination with $Supertype so that you do not get an error if you omit some properties from propTypes. $Supertype<T> A type that is a supertype of T. React uses $Supertype in the type of propTypes: declare class ReactComponent<D, P, S> { // ... static propTypes: $Supertype<$Record<P>>; // ... } Where the type variable P is the type of the props for a component. It looks like the intent is to check that if a component defines propTypes, all of the properties listed are also in the type of props. But it should not report an error if propTypes excludes some props. I could not get a type error when testing this. It could be that interaction between $Supertype and object types is still a work in progress. If you are thinking of using $Supertype with an object type, consider $Shape - it might be a better choice. $Subtype<T> A type that is a subtype of T. This is what you get when you use a type bound. For example, these signatures are equivalent: function doSomething1<T: Object>(obj: T) { /* whatever */ } function doSomething2(obj: $Subtype<Object>) { /* whatever */ } But the second version has the disadvantage that you cannot refer to the type that obj gets in the return type of the function, or in the types of other arguments. While trying to come up with example cases for $Subtype, I came across other nice improvements to Flow that render $Subtype unnecessary in a lot of cases. In a previous version of Flow, I recall (possibly incorrectly) having to use a type bound in a function that takes on object with certain required properties, where you don’t want to prevent the caller from including additional properties. But now this works without a type bound: function getId(obj: { id: number }): number { return obj.id } getId({ id: 1, name: 'foo' }) // No errors! I also had a thought that $Subtype could be used to implement a composition pattern that previously did not work. type HasId = { id: number } type HasName = { name: string } type Widget = HasId & HasName function makeWidget(id: number, name: string): Widget { return { id, name } } var w = makeWidget(1, 'foo') But in Flow v0.11 this does work. Hooray! $Subtype could be useful if you want to define an object type that can be assigned properties that are not declared in the type: type Extensible = $Subtype<{foo: number}> var a: Extensible = { foo: 1, bar: 2 } a.baz = 3 // No errors! // Error: property foo not found in object literal var b: Extensible = { bar: 2 } However this weakens property checking on the extensible type. For example, Flow does not infer that the type of a.foo must be number. (It checks the type of foo correctly when the object is first created, but not on reads or reassignment). $Enum<T> The set of keys of T. One use for this is to write a lookup function, and have Flow check that the lookup key is valid. var props = { foo: 1, bar: 'two', baz: 'three', } function getProp<T>(key: $Enum<typeof props>): T { return props[key] } getProp('foo') // No errors! // Error: string literal nao property not found in object literal getProp('nao') The type $Enum<typeof props> is a lot like this type: type EnumProps = 'foo' | 'bar' | 'baz' But with $Enum, Flow computes the type union for you. Flow’s tests include more examples. Flow supports an “existential type”: *. When * is given as a type, it acts as a placeholder, leaving it to the type checker to infer the type for that position. Let’s generalize the getProp function from the section above. Let’s write a function that takes any object and returns a getter. The getter can be used to get arbitrary properties out of the object, without having to refer to the object itself after creating the getter. We would like to write this: // Does not work! function makeGetter<T:Object>(obj: T): <U>(key: $Enum<T>) => U { return function(key) { return obj[key] } } The use of $Enum<T> ensures that a getter can only be called to get properties that actually exist on the given object. But Flow objects to the lack of type declarations in the inner function. It reports an error: function type is incompatible with polymorphic type: function type An obvious idea is to copy types from the return type of makeGetter into the signature of the inner function. But that leads to another problem. // Still does not work! function makeGetter<T:Object>(obj: T): <U>(key: $Enum<T>) => U { return function<U>(key: $Enum<T>): U { return obj[key] } } This time the error is: identifier T, Could not resolve name The problem is that type variables in a function signature (in this case, in the signature of makeGetter) are not in scope in the function body. So we cannot refer to the type T in inner function types, or in variable types in the body of makeGetter. On the other hand, Flow might be smart enough to figure out what the argument type in the inner function should be. So we can use * to kick the problem over to Flow. // Finally, an version that does work. function makeGetter<T:Object>(obj: T): <U>(key: $Enum<T>) => U { return function <U>(key: *): U { return obj[key] } } Now we can see makeGetter in action. var someObj = { foo: 1, bar: 2 } var get = makeGetter(someObj) get('foo') // No errors! get('baz') // string literal 'baz' not found in object literal Another option would have been to use any instead of *. But that is so much less elegant! The important difference is that where * appears, Flow will fill in a specific type, which could lead to accurate type checking in other areas of the code where the value of type * appears. If you annotate a value with any, Flow will not attempt to type-check expressions where that value appears - which could lead to type errors being missed. In this case the choice of * versus any does not matter, since the outer function has the type signature that we want. React uses an existential type to define the ReactClass type: /** * Type of a React class (not to be confused with the type of instances of a * React class, which is the React class itself). A React class is any subclass * of ReactComponent. We make the type of a React class polymorphic over the * same type parameters (D, P, S) as ReactComponent. The required constraints * are set up using a "helper" type alias, that takes an additional type * parameter C representing the React class, which is then abstracted with an * existential type (*). The * can be thought of as an "auto" instruction to the * typechecker, telling it to fill in the type from context. */ type ReactClass<D, P, S> = _ReactClass<D, P, S, *>; type _ReactClass<D, P, S, C: ReactComponent<D, P, S>> = Class<C>; This allows React to pass around a polymorphic class as a first-class value without losing type information. I mentioned in the last section that type variables in a function’s signature are not in scope in the body of that function. I find it interesting that classes do not have this restriction: type variables in a class declaration are in scope in the class definition. (They are not in scope within method bodies; but you can use these variables in method signatures and class variable types). Because of this, there are some problems that do not exactly work with functions but that do work with classes. We can reimplement makeGetter from the last section as a class. class Getter<T:Object> { obj: T; constructor(obj: T) { this.obj = obj } getProp<U>(key: $Enum<T>): U { return this.obj[key] } } var someObj = { foo: 1, bar: 2 } var getter = new Getter(someObj) getter.getProp('foo') // No errors! // Error: string literal 'baz' not found in object literal getter.getProp('baz') This probably seems unremarkable - every object-oriented language with static type-checking scopes class-level type variables this way. But ES6 classes are mostly syntactic sugar for ES5 constructor functions - yet a straight translation of Getter to ES5 syntax does not work: // Does not work function Getter<T:Object>(obj: T) { this.getProp = function<U>(key: $Enum<T>): U { return obj[key] } } We get the same error: identifier T, could not resolve name. This time to fix the problem we have to refer to T indirectly using typeof obj. // No errors! function Getter<T:Object>(obj: T) { this.getProp = function<U>(key: $Enum<typeof obj>): U { return obj[key] } } The ability of classes to scope type variables over inner methods, and the ability to use instanceof for type refinement, lead me to use classes more often than I would if I were not using Flow. Edited 2015-06-01: Added notice that $ features are not public. Edited 2015-06-08: $Record<T> is gone in Flow v0.12. I. This example comes from the announcement post: function length(x) { return x.length; } var total = length('Hello') + length(null); // Type error: x might be null The presence of a use of length with a null argument informs Flow that there should be a null check in that function. This version does type-check: function length(x) { if (x) { return x.length; } else { return 0; } } var total = length('Hello') + length(null); Flow is able to infer that x cannot be null inside the if body. An alternate fix would be to get rid of any invocations of length where the argument might be null. That would cause Flow to infer a non-nullable type for x. This capability goes further - here is an example from the Flow documentation: var o = null; if (o == null) { o = 'hello'; } print(o.length); The type of o is initially null. But Flow is able to determine that the type of o changes when o is reassigned, and that its type is definitely string on the last line. In addition to null checks, Flow also narrows types when it sees dynamic type checks. This example (which passes the type checker) comes from the documentation: function foo(b) { if (b) { return 21; } else { return ''; } } function bar(b) { var x = foo(b); var y = foo(b); if (typeof x == 'number' && typeof y == 'number') { return x + y; } return 0; } var n = bar(1) * bar(2); The inferred return type of foo is string | number. That is a type union, meaning that values returned by foo might be of type string or of type number. The typeof checks in bar narrow the possible types of x and y in the if body to just number. That means that it is safe to multiply values returned by bar - the type checker knows that bar will always return a number. A coworker told me that what he would like is support for type-checked structs. That would let him add or remove properties from an object in one part of a program, and be assured that the rest of the program is using the new object format correctly. Struct types work using structural types and type aliases: type Point = { x: number; y: number } function mkPoint(x, y): Point { return { x: x, y: y } } var p = mkPoint('2', '3') // Type error: string is incompatible with number var q = mkPoint(2, 3) q.z = 4 // Type error: property `z` not found in object type var r: Point = { x: 5 } // Type error: property y not found in object literal Notice the type keyword and type annotation on mkPoint - Facebook’s literature is a little misleading, in that Flow is really a new language that compiles to JavaScript. But the only differences between Flow and regular JavaScript are the added syntax for type aliases and type annotations, and the type-checking step. Flow can be applied to regular JavaScript code without type annotations. How well that works will depend on how that code is written. If the JavaScript is cleanly written, you might get a lot of help from Flow without ever needing type annotations. But there are some valid JavaScript idioms that will not type-check (at least not at this time.) For example, optional arguments are not allowed unless you use either Flow’s syntax or ECMAScript 6’s default parameter syntax. These are early days for Flow. I am optimistic that over time it will only get better at operating on code that was not written with Flow in mind. There is a side benefit to using the Flow language: it supports ECMAScript 6, but compiling Flow programs produces ECMAScript 5 code that can run in most browsers. Edit 2016-08-19: Early in Flow’s development, Facebook recommended using their own jsx compiler to process code that used Flow. That is what produced ECMAScript 5 code, as mentioned in the previous paragraph. Currently the best practice is to use Babel with the React preset to process Flow code. You still get the benefit of transpiling ECMAScript 6 code to ECMAScript 5, if you have Babel configured to do that. One of my favorite features of Flow is that null and undefined are not treated as bottom types. A value is only allowed to be null if it has a nullable type. This makes Flow better at catching null pointer exceptions than almost any other object-oriented language. For example: var n: Object = null; // Type error: null is incompatible with object type var m: ?Object = null; // this is ok var o = null; // this is ok too - Flow infers that o has a nullable type A type expression ?T behaves pretty much like T | null | undefined. (From what I can tell, null and undefined are distinct types in Flow - but it does not seem to be possible to use them in type annotations at this time. void is allowed, which seems to be an alias for undefined.) In the past I have talked to one or two people who said that they would only be interested in type-checked JavaScript if it supported algebraic types. (These are the kind of people I work with :)) That is possible too - here is an example that I wrote: type Tree<T> = Node<T> | EmptyTree class Node<T> { value: T; left: Tree<T>; right: Tree<T>; constructor(value, left, right) { this.value = value this.left = left this.right = right }; } class EmptyTree {} function find<T>(predicate: (v: T) => boolean, tree: Tree<T>): T | void { var leftResult if (tree instanceof Node) { leftResult = find(predicate, tree.left) if (typeof leftResult !== 'undefined') { return leftResult } else if (predicate(tree.value)) { return tree.value } else { return find(predicate, tree.right) } } else if (tree instanceof EmptyTree) { return undefined; } } Thanks to type narrowing, accessing tree.value passes type-checking in the if body where tree instanceof Node is true. Without that check, the type checker would not allow accessing properties that do not exist on both Node and EmptyTree. There are some details in this example that I want to call out: classsyntax is from ECMAScript 6 - but it is extended in Flow to support type annotations for properties. Treeis a type alias. It has no runtime representation. None is needed, since Nodeand EmptyTreehave no shared behavior. And unlike a superclass, Treeis sealed, meaning that it is not possible to add more subtypes to Treeelsewhere in the codebase. predicate). findmight return a value from a tree, or it might return undefined. So the return type is T | void(where voidis the type of undefined). Writing ?Twould also work. I have not been sold on prior JavaScript type checkers. They did not seem to “get” JavaScript. Flow is a type checker that I actually plan to use.]]> tl;dr: ECMAScript 6 introduces a language feature called generators, which are really great for working with asynchronous code that uses promises. But they do not work well for functional reactive programming. ES6 generators allow asynchronous code to be written in a way that looks synchronous. This example uses a hypothetical library called Do (implementation below) that makes promises work with generators: var postWithAuthor = Do(function*(id) { var post = yield getJSON('/posts/'+id) var author = yield getJSON('/users/'+post.authorId) return _.assign(post, { author: author }) }) Do(function*() { var post = yield postWithAuthor(3) console.log('Post written by', post.author.name) })() It is possible to use generators now in Node.js version 0.11 by using the --harmony flag. Or you can use Traceur to transpile ES6 code with generators into code that can be run in any ES5-compatible web browser. I recently saw an informative talk from Jacob Rothstein on Co and Koa. Those are libraries that make full use of generators to make writing asynchronous code pleasant. The implementation of the above example in Co is almost identical. Co operates on promises and thunks, allowing them to be expanded with the yield keyword. It has nice options for pulling nested asynchronous values out of arrays and objects, running asynchronous operations in parallel, and so forth. One can even use try / catch to catch errors thrown in asynchronous code! Co is specialized for asynchronous code. But when I look at it I see something that is really close to being a monad comprehension - very much like the do notation feature in Haskell. With just a little tweaking, the use of generators that Co has pioneered can almost be generalized to work with any kind of monad. For example, libraries like RxJs and Bacon.js implement event streams, which are a lot like promises, except that callbacks on event streams can run more than once. This example uses Bacon to manage a typeahead search feature in a web interface: var searchQueries = Do(function*(searchInput) { var inputs = $(searchInput).asEventStream('keyup change') var singleInputEvent = yield inputs var query = singleInputEvent.target.value if (query.length > 2) { // passes the query through return Bacon.once(query) } else { // excludes this query from the searchQueries stream return Bacon.never() } }) var resultView = Do(function*(searchInput, resultsElement) { var query = yield searchQueries(searchInput) var results = yield Bacon.fromPromise(getJSON('/search/'+ query)) $(resultsElement).empty().append( results.map(function(r) { return $('<li>').text(r) } ) }) resultView('#search', '#results') The idea is that when the user enters more than two characters of text into a search box, a background request is dispatched and search results appear on the page automatically. This example requires a library that is a little more general than Co, that is able to operate on Bacon event streams in addition to promises and thunks. Here is a basic implementation of that library: function Do(mkGen) { return function(/* arguments */) { var gen = mkGen.apply(null, arguments) return next(); function next(v) { var res = gen.next(v) return handleResult(res) } function handleError(e) { var res = gen.throw(e) if (typeof res !== undefined) { return handleResult(res) } else { return e } } function handleResult(res) { return res.done ? res.value : flatMap(res.value, next, handleError) } } } function flatMap(m, f, e) { if (typeof m.then === 'function') { return m.then(f, e) // handles promises } else if (typeof m.flatMap === 'function') { return m.flatMap(f).onError(e) // handles Bacon event streams (or properties) } else { throw new TypeError("No implementation of flatMap for this type of argument.") } } This is the function that makes the example at the top of this post work. It is a simplified version of what Co does - the difference being that Do delegates to a flatMap function to handle yielding. We just need an implementation of flatMap that can operate on some different monad types. The one above works with promises or with Bacon event streams. An implementation that is easier to extend would be nice; but I will leave that problem for another time. Unfortunately, the Bacon example does not work. Streams - unlike promises - get many values. That means that the code in each generator has to run many times (once for each stream value). But ES6 generators are not reentrant: after resuming a generator from the point of a given yield expression, it is not possible to jump back to that entry point again (assuming the generator does not contain a loop). With the Bacon example, after the first keyup or change event the search result list will just stop updating. Getting synchronous-style functional reactive programming to work well would require immutable, reentrant generators. ES6 generators are stateful: every invocation of a generator changes the way that it will behave on the next invocation. In other words, a generated is mutated on every invocation: var gen = function*() { yield 1 yield 2 return 3 } g = gen() // initialize the generator assert(g.next().value === 1) assert(g.next().value === 1) assert(g.next().value === 3) assert(g.next().value === undefined) An immutable implementation would return a new object with a function for the next generator entry point, instead of mutating the original generator: var g = gen() var g1 = g.next() assert(g1.value === 1) var g2 = g1.next() assert(g2.value === 2) var g3 = g2.next() assert(g3.value === 3) // We can go back to previous entry points. assert(g1.next().value === 2) assert(g.next().value === 1) An immutable generator could be implemented with some simple syntactic transforms. The basic case: function*(args...) { preceding_statements var y = yield x following_statements } would transform to: function(args...) { preceding_statements return { value: x, next: function(y) { following_statements } } } The next property is returned is a generator that is used to invoke the next step. In this view generators are just functions. Not only that - a generator is a closure that has access to the results of previous steps via closure scope. There would just need to be a few cases to handle appearances of yield in a return statement, a try- catch block, or as its own statement. With that kind of stateless design, the Bacon example would work fine. But as far as I know, there is no plan for stateless, reentrant generators in ECMAScript. It is possible to make functional reactive programming work with non-reentrant generators by using loops in the generators. This approach is not as general or as composable. Asynchronous pieces would have to be declared specially at the top of the function, for example. var searchQueries = function(searchInput) { var inputs = $(searchInput).asEventStream('keyup change') frp(inputs, function*(inputs_) { var singleInputEvent while (true) { singleInputEvent = yield inputs_ query = singleInputEvent.target.value if (query.length > 2) { // passes the query through yield Bacon.once(query) } else { // excludes this query from the searchQueries stream yield Bacon.never() } } }) } Notice that yield is overloaded to accept asynchronous values and to return results - which requires some awkward logic to inspect generator values. I do not know how to implement resultView as a loop, since it requires combining two event streams: search queries and JSON responses. I do not see any advantage of loops in generators over asynchronous-style callbacks. But maybe someone more imaginative than me can come up with a more elegant solution. Edited 2014-08-04: Fixed broken link, fixed incorrect indentation in code snippets. Edited 2014-08-05: The hypothetical generators that I describe are immutable, not stateless. Thanks to Blixt for pointing out the distinction.]]> I now have a Kinesis Advantage keyboard for use at work. I have been feeling some wrist strain recently; and some of my coworkers were encouraging me to try one. So I borrowed a Kinesis for a week, and found that I really liked it. The contoured shape makes reaching for keys comfortable; I find the column layout to be nicer than the usual staggered key arrangement; and between the thumb-key clusters and the arrow keys, there are a lot of options for mapping modifier keys that are in easy reach. Kinesis Advantage, before modification But I really like the PBT keycaps on my Leopold. I would not enjoy going back to plain, old ABS. I also don’t want my keyboard to be just like every other Kinesis. So I decided to get replacement keycaps. I did some research on buying PBT keycaps with the same profiles as the stock Kinesis keys. I assumed that I would end up getting blank keycaps - putting together a set with legends appropriate for a Kinesis seemed like it would be a painful undertaking, since there don’t seem to be any sets made specifically for the Kinesis. Most keyboards - including the Kinesis Advantage - use what is called a DCS profile, where the keys in each row have different heights and angles. (That does not include laptop keyboards, or island-style keyboards such as the ones that Apple sells. Those are in their own categories.) DCS family: medium profile, cylindrical top, sculptured. Image from Signature Plastics. Input Nirvana on Geekhack has a post with a list of all necessary keycap sizes and profiles to reproduce the arrangement on a stock Kinesis. It is possible to order these individually from Signature Plastics; but their inventory for à la carte orders varies depending on what they have left over from production of large batches. When I checked, SP did not have any row 5 PBT keycaps available. I got the impression that building a custom DCS set would be somewhat difficult. Then I saw prdlm2009 on Deskthority suggest that DSA profile keycaps work well on a Kinesis. DSA is a uniform profile - every key has the same height and angle. It makes everything much simpler when dealing with unusual keyboard layouts, or unusual keyboards. DSA family medium profile, spherical top, non-sculptured. Image from Signature Plastics. DSA also features spherical tops. If you look at the keys on a typical keyboard, you can see that the top curves up on the left and right sides - as though someone had shaped them around a cylinder. The tops of DSA keys are spherical; as though shaped around a large marble. So the keys cup the fingertips from all sides. Signature Plastics sells a variety of nice, blank DSA keycap sets. I did not order the optimal combination of keycap sets; but now I have a better idea of what that combination is. The key count on an Advantage is: 1x, 2x, etc. refers to the lengths of the keys. One can get everything except the 1.25x keys with one ErgoDox Base set and two Numpad sets. The Numpad sets seem to be the cheapest way to get all 4 2x keycaps, along with additional 1x caps. The only set that includes 1.25x caps is the Standard Modifier set, which includes 7 of them. (So close!) I recommend ordering the 1.25x keycaps individually from the blank keycap inventory. stock Kinesis keycaps (left), DSA keycaps (right) The keycaps from SP are much thicker than the stock keycaps. And they are made from PBT plastic, which is denser than the more common keycap material, ABS. What I like most about PBT caps is their texture. The tops of the keys are usually slightly rough, somewhat pebbly. It gives a little bit of grippiness, and feels soothing on my fingers compared to featureless, flat plastic. I also think that the sound of PBT keys being pressed is nicer. It is slightly quieter, with a somewhat deeper tone. All of the stock keycaps have been removed, revealing Cherry MX Brown switches. The Kinesis Advantage comes with either Cherry MX Brown or Cherry MX Red switches. For anyone wondering how to remove keycaps from a keyboard with Cherry MX switches, here is a video. What the video does not mention is that it is a good idea to wiggle the keycap puller while pulling up on the keycap. That helps to avoid pulling with too much force, which could break a switch. I have another keyboard that also has Cherry MX Brown switches, and I really liked the change in key feel after installing o-rings. O-rings make typing a little quieter, and add some springiness to the bottom of the key travel. A tradeoff is that they reduce the length of key travel a bit. installing o-rings in the new keycaps I used 40A-R o-rings from WASD, which are relatively thick and soft. But when I tried these out with the DSA keycaps I could not discern any difference between a key with an o-ring and one without.. O-rings sit between those supports and the switch housing, absorbing some force from contact. But the DSA keycaps lack those supports. That means that the switch can reach the bottom of its travel before the underside of the keycap contacts the switch housing. I found that doubling up o-rings pushed the rubber high enough to be effective. But I was concerned that two o-rings shorted key travel too much and introduced too much squishiness. In the end I left the o-rings out entirely. I may take another shot using either thinner, firmer o-rings, or with small washers in place of a second o-ring. two o-rings installed in one keycap When I ordered my keycaps I got one ErgoDox Base set and one ErgoDox Modifier set. I did not do enough checking - I assumed that the 1.5x keys in the Modifier set would fit in the Kinesis. But it turns out that the keys in the leftmost and rightmost columns of the Kinesis take 1.25x keycaps. The larger keycaps do not fit. Whoops! That was supposed to be a 1.25x key, not a 1.5x. I have ordered some appropriately sized keycaps. In the meantime, I am using 1x keycaps in the 1.25x positions. stock 1.25x Tab key next to its intended, blank replacement Even though the DSA keycaps are not the same shape as the stock caps, they fit quite well on the Kinesis. There are just two slightly problematic spots. The photo below shows the one key that comes into contact with the edge of the keyboard case when it is not depressed. Thankfully the operation of the key does not seem to be affected. The fit is tight in this corner. Due to small differences in switch positioning, the key in the same position in the other well has a little bit of clearance. The other problem is that two of my 2x keys overlap very slightly. When I press the one on the right there is sometimes an extra click as it pushes past its neighbor. There is not quite enough space between these two keys. I am thinking of sanding down the corners of these keys a little bit to fix the problem. This is another case where there is no problem with the keys in the same positions on the other side of the board. It seems that the switches in the left thumb cluster just happen to be a little too close together on my board. All done! Since I had to use 1u keycaps for the leftmost and rightmost columns, I ended up not having enough keycaps to replace the two keycaps in the top of each thumb cluster. But I think that having tall keycaps there makes them easier to press - those positions are a bit difficult to reach otherwise. So I may just keep the stock caps on those keys. Or I might try to get tall, DCS profile, PBT caps for those positions. closeup of one of the wells to show key spacing The other positions where I think that DSA does not work really well are the four keys in the bottom row of each well. I curl my fingers down to reach those; and I tend to either hit the edges of the keys, or to press them with my fingernail instead of with my finger. The stock keycaps for those positions are angled toward the center of the well, making it easier to reach the tops of the keys. Those points aside, I am very pleased with how these new keycaps worked out! The DSA profile is quite comfortable. I love the texture of the PBT keycaps. And they make a more pleasant sound than the thinner ABS caps that came with the board. ]]> shoe for science! Idris is a programming language with dependent types. It is similar to Agda, but hews more closely to Haskell. The goal of Idris is to bring dependent types to general-purpose programming. It supports multiple compilation targets, including C and Javascript. Dependent types provide an unprecedented level of type safety. A quick example is a type-safe printf implementation (video). They are also useful for theorem proving. According to the Curry-Howard correspondence, mathematical propositions can be represented in a program as types. An implementation that satisfies a given type serves as a proof of the corresponding proposition. In other words, inhabited types represent true propositions. The Curry-Howard correspondence applies to every language with type checking. But the type systems in most languages are not expressive enough to build very interesting propositions. On the other hand, dependent types can express quantification (i.e., the mathematical concepts of universal quantification (∀) and existential quantification (∃)). This makes it possible to translate a lot of interesting math into machine-verified code. This post is written in literate Idris. The original markup can be compiled and type-checked. Code blocks that are prefixed with greater-than symbols (>) in the markup are evaluated. Blocks that are marked off with three backticks are given for illustrative purposes and are not evaluated. In Idris, partial functions are allowed by default. A totality requirement can be specified per-function. This line enforces totality checking by default for functions in this module. A function that is total is guaranteed to terminate and to return a well-typed output for every possible input.1 A function that does not terminate, or that throws a runtime error for some inputs, is said to be partial. A partial function can introduce a logical contradiction, which would make proofs unreliable. So totality checking is useful for theorem proving. Consider the definition of the natural number type in the Idris standard library: This defines a type, Nat, with two constructors for producing values: a number may be zero ( Z), or it may be one greater than another number ( S Nat). A type can be indexed by another type. That describes a type produced by a type constructor that takes one or more values as parameters. Here is a constructor for indexed types from the Idris standard library: This declares that LTE is a constructor that takes two Nat values as parameters, and produces a concrete Type. The types that LTE constructs also happen to be propositions which state that one natural number is less than or equal to another. It should be read, “the natural number n is less than or equal to the natural number m”. Two value constructors are given. They are written so that a value that satisfies a given LTE type be written if and only if the n in that type is less than or equal to the m. In this way, a value that satisfies a type of the form LTE n m is a proof that n really is less than or equal to m. lteZero is a singleton value - it is a constructor that takes no arguments. But its type contains a variable; so it is polymorphic. lteZero can satisfy any type of the form, LTE Z n. lteZero is effectively an axiom, stating a fundamental property of natural numbers. Given the definition of LTE it is possible to write a proposition, such as, “zero is less than or equal to every natural number”. The proposition is written as a function that takes a number as input. The value that is given is assigned to the variable n, which is used to specify the return type. Thus the return type of nonNegative depends on the input value. Wherever you see (a : A) it can be read as, “Some value of type A will be given here, and that value will be assigned to the variable a.” To write an implementation for nonNegative, it is necessary to produce a value of the appropriate LTE type without any information about what input might be given - other than the fact that it will be a natural number. Totality checking is enabled, so any implementation must be applicable to every possible input. Thus a type of the form, (x : A) -> P x describes universal quantification over the type A. nonNegative happens to be a restatement of the axiom, lteZero. So an implementation / proof is trivial: On the other hand, lteSucc maps a given proof to a proof of a related proposition. It is used in proofs-by-induction. For example, a proof that every number is less than or equal to itself: The proof that zero is equal to itself is given by the axiom. For every other number, the proof is given as an inductive step using a proof for the next-smallest number. Because the type of lteSucc is that of a function, it can be read as a proposition involving logical implication: “n <= m implies that n + 1 <= m + 1.” In general, types of the form P x -> Q y can be read as logical implication. We have seen that the input value to a function can be labelled and referenced in the output type. That is a special property of functions. For example, it is not permissible to label the value in the first position of a tuple type to reference it in the second position. But there is a special construction, the dependent pair, which does allow this. Dependent pairs are used to represent existential quantification. A dependent pair type of the form (x : A ** P x) is read as existential quantification over the type A. A proof of a proposition with existential quantification can be given as a pair of an arbitrary value and a proof that the proposition holds for that value. For example, here is a proof of the Archimedean Property of natural numbers, “For every natural number, n, there exists a natural number, m, where m > n”: The quantified proposition uses (S n) instead of just n to indicate that m must be strictly greater than n - greater-than-or-equal-to is not sufficient. The proof supplies S n as a witness - a specific value that is used to prove that the quantified proposition holds. Remember that S n is just another way of writing n + 1. The second component of the dependent pair value must be a proof that the witness is greater than or equal to S n - as is required by the type. Since S n and S n are equal, lteReflexive suffices. I have been studying Category Theory; so I decided to use that as a topic for exercises when learning about Idris. If you are wondering what Category Theory is all about, take a look at Why Category Theory Matters. There is a much more complete description of Category Theory concepts written in Agda. The definition below was an exercise for me in learning about Category Theory concepts myself. A category is a set of objects combined with a set of arrows that encode relations between objects. When talking about all possible categories, the concepts of “object” and “arrow” are very abstract. They could be pretty much anything. Descriptions of specific categories make specific statements about what objects are and what arrows are. Let’s implement a type class to capture this definition. Arrows are indexed by objects. That is, the type of an arrow carries its domain (the object that an arrow originates from) and its codomain (the object that an arrow points to). Note that obj is given as an unqualified variable. In some categories objects will be types - as in the Set category. In others they will be plain values. The methods of this type class will define the category laws. For starters, there must be an id arrow for every object. This line specifies that an instance of this type class must provide a cId implementation with the given type: As was shown above, a function type serves as a proposition with universal quantification. So the type of cId states that every object must be both the domain and codomain of at least one arrow. The implementation will also provide a means to identify that arrow. Arrows must be composable. If one arrow points from objects a to b, and another arrow points from ‘b’ to ‘c’, then it must be possible to combine them to produce an arrow from ‘a’ to ‘c’. Arguments in curly braces are implicit parameters. In most cases the compiler will infer those values. So they are generally not given as explicit arguments when invoking the function. However, it is possible to provide implicit parameters explicitly when needed. cId and cComp are the only required functions that actually produce arrows. But it is necessary to provide more specific rules about how they should behave. These propositions state that id arrows must not only have the same object as domain and codomain - they must also be identities under composition. Implementations of cIdLeft and cIdRight will never be used at runtime - they are just proofs that cId and cComp obey the category laws. Here (=) is a type constructor, very much like LTE. Its definition looks like this: The parameters to (=) can be any expressions - including plain values or types. refl is another axiom, stating that equality is reflexive. Basically, to prove that two expressions are equivalent it is necessary to demonstrate to the type checker that they have the same normal form. This implies that there might be multiple arrows pointing between the same two objects; and that those arrows are not necessarily equivalent. When talking about all possible categories, it is not possible to say what it is that makes arrows different or the same. Rather, any specific category must have its own definition of equality of arrows. Some categories will have many arrows between each pair of objects; some will have at most one. One more proof is required to complete the Category type class. Arrow composition must be associative. I have cheated slightly. In the types for cIdLeft, cIdRight, and cCompAssociative I left the implicit arguments to cComp implicit. But I was not able to get those definitions to type-check. I actually had to list out the implicit parameters when applying cComp in a type expression. The working definitions are a bit more difficult to read: It has been pointed out to me that the compiler is not able to determine which implementation of cidLeft, cIdRight, or cCompAssociative should be invoked, unless the implicit parameters are listed. If Category were implemented as a record type instead of as a type class this would probably not be necessary. With the definition of Category in place, it is possible to describe specific categories - and to prove that they obey the category laws. The LTE type constructor can be used to describe a category where arrows are LTE relations, and objects are natural numbers. In this category, there are arrows that point from each number to every other number that is larger, and also back to the number itself. An id arrow in this category is a proof that a number is less than or equal to itself. This is the same thing that was proved by lteReflexive; so the implementation is the same. Arrow composition is a proof that the less-than-or-equal-to relation is transitive. For reference, here is the type for cComp specialized for LTE: And the proof construction: In the first equation, the second input is lteZero; which implies that a is zero. a is also the domain in the LTE result that we want to prove; so the proof is trivial. The second equation takes advantage of the fact that the lteSucc constructors of input arrows can be recursively unwrapped, until reaching the base case, where the second input is lteZero. There is no pattern for a case where the first input is lteZero where the second is not. It is not required, because that case is not allowed by the type of cComp - and the type checker is able to confirm that. If it were necessary to make explicit that this case is not possible, that could be stated with a third equation: The keyword impossible is one tool available for proofs of falsehood. Now to prove the remaining category laws. Demonstrating identity under composition of proofs is a little strange. What we need to show is that composing an identity arrow with any other arrow does not introduce new information. In the base case of cIdLeft, if the given arrow, f, is lteZero then its domain must be zero. Therefore the identity arrow it is composed with must also be lteZero. Those are the same normal form, so the proof invokes refl - the axiom of reflexivity of equality. The inductive step applies cong, which is a proof of congruence of equal expressions. It is defined in the standard library: In this case the f that cong infers as its implicit parameter is lteSucc. cong is an example of a proof constructor: it takes a proof as input and returns a proof of a related proposition. Functions like cong are the building blocks of multi-step proofs. You may notice that cong takes refl as an argument and returns it. cong has equality proofs as its input and output. By definition, the only possible value of an equality type is refl. The base case of cIdRight is not as trivial as the base case of cIdLeft. the codomain of lteZero is not necessarily zero; so the identity arrow involved could be some lteSucc value. However the compiler is able to do some normalization automatically. That means that it is not necessary to spell out every step. The proof of associativity follows a similar pattern. The natural numbers form a monoid under addition. In particular: The monoid also forms a category with just one object, (which will be arbitrarily represented with ()) where the arrows are integers, and arrows are composed by addition. Since there are an unbounded number of natural numbers, in this category there are an unbounded number of arrows pointing from () back to (). This category is made a bit complicated by the requirement that arrows are indexed by domain and codomain. Those indexes will not be meaningful in a category with just one object. But for the sake of generality, a trivial higher-kinded wrapper around Nat is needed. In Idris, as in Haskell, () is a type with exactly one value, which is also called (). To make it clear that a NatArrow is really just a Nat, we can prove that the two types are isomorphic. An isomorphism is a bidirectional mapping that preserves information in both directions. to and from specify the mapping; toFrom and fromTo prove that information is preserved. Now the definition of the Nat category: This implementation uses (+) for arrow composition. It reuses proofs of identity and associativity for (+). It is only necessary to apply cong to the predefined proofs to show that applying the getNat constructor to both sides of an equality does not change anything. For another look at monoids in Idris, see Verifying the monoid laws using Idris (video). In the Set category, objects are sets and arrows are functions. The implementation here will use Type as the type of objects. In Idris, the type of every small type is Type. For example, the type of Nat is Type. The type of String is also Type. The type of Type is Type 1 - meaning that Type is not a small type itself. The definition of Category requires proofs of equivalence for arrows. But there is no predefined comparison operator for functions in Idris. All that you can really do with a function is to give it some inputs, and check what its outputs are. To produce a viable category, it is necessary to introduce the axiom of function extensionality: If two functions produce the same output for all possible inputs, then they are equivalent. funext takes as input two functions and a proof that those functions produce the same output for all inputs. Note the parentheses in that type: As function types serve as universal quantifiers, higher-order functions provide a means to nest quantification inside of larger propositions. I am told that it is not possible to prove funext in Idris - and that that limitation is not unique to Idris. Therefore, function extensionality must be given as an axiom: believe_me is a “proof” to use sparingly. Implementations for an identity function and for composition of functions are provided in the standard library. In fact, Idris includes a Control.Category module with a predefined Category type class. But that definition does not include all of the category laws. What remains to be defined are proofs of identity and associativity. Proving that id (f x) and f (id x) reduce to f x is sufficiently easy that the compiler can do most of the work on its own. To make the next step to f x = f x -> f = f is just a matter of applying funext. In order to prove associativity, it is helpful to have a helper proof that could be described as, “pointful composition”. The proof of associativity is a bit complicated. So it is broken into steps here, with proven intermediate propositions given for each step. There are two standard library functions used here that have not been introduced yet. They are: When a free, lowercase variable appears in a type expression, Idris inserts an additional implicit parameter at the beginning of the expression. It is up to the compiler to infer the types of the free variables. After carrying out that expansion, the type of trans looks like this: There may be more steps listed in compAssociative than are really required. Hopefully including them helps to clarify the proof. In Haskell, (->) is an ordinary type constructor that could be used as the arrow type in a type class like Category. It seems that is not the case in Idris. To work around that, the standard library includes a type, Morphism, that is isomorphic to the function type. The proofs above provide everything that is required to prove the validity of a category of Types and functions. But the definition here uses Morphism for arrows; so a little extra translating is necessary. The operator (~>) is an infix alias for Morphism. As with Nat and NatArrow, the correspondence between (->) and Morphism is made official with a proof of isomorphism. It is my hope that I can use these definitions to work out exercises as I continue to explore Category theory. The Halting Problem states that there are programs that cannot be proven to terminate. That does not mean that it is impossible to prove that any program terminates. Idris and other languages with totality checking put some restrictions on the forms that functions are allowed to take so that totality checking is possible.↩ I have a long-standing desire for a JavaScript library that provides good implementations of functional data structures. Recently I found Mori, and I think that it may be just the library that I have been looking for. Mori packages data structures from the Clojure standard library for use in JavaScript code. vector sorted_set_by hash_map A functional data structure (also called a persistent data structure) has two important qualities: it is immutable and it can be updated by creating a copy with modifications (copy-on-write). Creating copies should be nearly as cheap as modifying a comparable mutable data structure in place. This is achieved with structural sharing: pointers to unchanged portions of a structure are shared between copies so that memory need only be allocated for changed portions of the data structure. A simple example is a linked list. A linked list is an object, specifically a list node, with a value and a pointer to the next list node, which points to the next list node. (Eventually you get to the end of the list where there is a node that points to the empty list.) Prepending an element to the front of such a list is a constant-time operation: you just create a new list element with a pointer to the start of the existing list. When lists are immutable there is no need to actually copy the original list. Removing an element from the front of a list is also a constant-time operation: you just return a pointer to the second element of the list. Here is a slightly more-detailed explanation. Lists are just one example. There are functional implementations of maps, sets, and other types of structures. Rich Hickey, the creator Clojure, describes functional data structures as decoupling state and time. (Also available in video form.) The idea is that code that uses functional data structures is easier to reason about and to verify than code that uses mutable data structures. Clojure is a functional language that compiles to JVM bytecode. It is a Lisp dialect. Among Clojure’s innovations are implementations of a number of functional data structures, old and new. For example, other Lisps tend to place prime importance on linked lists; but a lot of Clojure code is based on PersistentVector, which supports efficient random-access operations. ClojureScript is an alternative Clojure compiler that produces JavaScript code instead of JVM bytecode. The team behind ClojureScript has ported Clojure collections to ClojureScript implementations - which are therefore within reach of JavaScript code. Mori incorporates the ClojureScript build tool and pulls out just the standard library data structures. It builds a JavaScript file that can be used as a standalone library. Mori adds some API customizations to make the Clojure data structures easier to use in JavaScript - such as helpers to convert between JavaScript arrays and Clojure structures. Mori also includes a few helpers to make functional programming easier, like identity, constant, and sum functions. These are the data structures provided in the latest version of Mori, v0.2.4: All of these data structures are immutable and can be efficiently updated via copying and structural sharing. The documentation for Mori is pretty good. But it does skip over some of the available data structures and functions. Since most of the stuff provided by Mori comes from Clojure, if you cannot find information that you need in the Mori docs you can also look at the Clojure docs. I provided links to the Clojure documentation for each data structure where more detailed descriptions are available. To get Mori, install the npm package mori. Then you can require the module 'mori' in a Node.js project; or copy the file mori.js from the installed package and drop it into a web browser. $ npm install mori $ cp node_modules/mori/mori.js my_app/public/scripts/ Let’s take a look at the particular advantages of some of these structures. vector A vector is an ordered, finite sequence that supports efficient random-access lookups and updates. Vectors are created using the vector function from the 'mori' module. Any arguments given to the function become elements of a new vector. In Node.js you can import Mori and create a vector like this: var mori = require('mori'); var v = mori.vector(1, 2, 3); assert(mori.count(v) === 3); // `count` gives the length of the vector assert(mori.first(v) === 1); Mori also works with AMD implementations (such as RequireJS) for use in browser code: define(['mori'], function(mori) { var v = mori.vector(1, 2, 3); }); Idiomatic Clojure is not object-oriented. The convention in Clojure is that instead of putting methods on objects / values, one defines functions that take values as arguments. Those functions are organized into modules to group related functions together. This approach makes a lot of sense when values are mostly immutable; and it avoids name collisions that sometimes come up in object-oriented code, since names are scoped by module instead of by object.1 Since Mori is an adaptation of Clojure code, it uses the same convention. Data structures created with Mori do not have methods. Instead all functionality is provided by functions exported by the 'mori' module. That is why the code here uses expressions like mori.count(v) instead of v.count(). Existing vectors can be modified: var v1 = mori.vector(1, 2, 3); var v2 = mori.conj(v1, 4); assert(String(v2) === '[1 2 3 4]'); assert(String(v1) === '[1 2 3]'); // The original vector is unchanged. conj is an idiom that is particular to Clojure. It inserts one or more values into a collection. It behaves differently with different collection types, using whatever insert strategy is most efficient for the given collection.2 Mori provides a number of higher-order functions. Here is an example that computes the sum of the even values in a collection: function even_sum(coll) { var evens = mori.filter(mori.is_even, coll); var sum = mori.reduce(mori.sum, 0, evens); return sum; } assert(even_sum(v2) === 6); Or, borrowing from an example in the Mori documentation, one might compute a sum for even values and a separate sum for odd values: function even_odd_sum(coll) { var groups = mori.group_by(function(n) { return mori.is_even(n) ? 'even' : 'odd'; }, coll); var evens = mori.get(groups, 'even'); var odds = mori.get(groups, 'odd'); return mori.array_map( 'even', mori.reduce(mori.sum, 0, evens), 'odd', mori.reduce(mori.sum, 0, odds) ); } assert(mori.get(even_odd_sum(v2), 'even') === 6); assert(mori.get(even_odd_sum(v2), 'odd') === 4); The example above returns a map created with array_map, which is a map implementation that works well with a small number of keys. sorted_set_by JavaScript does not have its own set implementation. (Though it looks like one will be introduced in ECMAScript 6.) Sets are a feature that I often miss. A sorted set is a heavenly blend of a sequence and a set. Any duplicate values that are added are ignored, and there is a specific ordering of elements. Unlike a list or a vector, ordering is not based on insertion, but is determined by comparisons between elements. One possible use for a sorted set is to implement a priority queue. Consider an example of a calendar application. sorted_set_by takes a comparison function that is used to to maintain an ordering of added values. With the appropriate comparison appointments are added and are automatically sorted by date: function Calendar(appts) { appts = appts || mori.sorted_set_by(compare_appts); var cal = {}; cal.add = function(appt) { var with_appt = mori.conj(appts, appt); return Calendar(with_appt); }; cal.upcoming = function(start, n) { var futureAppts = return mori.filter(function(a) { return a.date >= start; }, appts); return mori.take(n, futureAppts); }; return cal; } // Returns a number that is: // * positive, if a is larger // * zero, if a and b are equal // * negative, if b is larger function compare_appts(a, b) { if (a.date !== b.date) { return a.date - b.date; } else { return (a.title) .localeCompare (b.title); } } Like the underlying set, this calendar implementation is immutable. When an appointment is added you get a new calendar value. The comparison function for comparing appointments sorts appointments by date, and uses title as a secondary sort in case there are appointments with the same date and time. The sorted set uses this function to determine equality as well as ordering; so if it made comparisons using only the date field then the calendar would not accept multiple appointments with the same date and time. Appointments can be added to a calendar and queried in date order: var my_cal = Calendar().add({ title: "Portland JavaScript Admirers' Monthly Meeting", date: Date.parse("2013-09-25T19:00-0700") }).add({ title: "Code 'n' Splode Monthly Meeting", date: Date.parse("2013-09-24T19:00-0700") }).add({ title: "WhereCampPDX 6", date: Date.parse("2013-09-28T09:00-0700") }).add({ title: "Synesthesia Bike Tour", date: Date.parse("2013-09-22T15:00-0700") }); var now = Date.parse("2013-09-20"); // or `new Date()` for the current time var next_appts = my_cal.upcoming(now, 2); mori.map(function(a) { return a.title; }, next_appts); // ("Synesthesia Bike Tour" "Code 'n' Splode Monthly Meeting") Looks good! Now let’s add an undo feature. In case the user changes her mind about the last appointment that was added, the undo feature should recreate the previous state without that appointment. The implementation of Calendar is the same as before except that the constructor takes an additional optional argument, the add method passes a reference from one calendar value to the next, and there is a new undo method: function Calendar(appts, prev_cal) { // ... cal.add = function(appt) { var with_appt = mori.conj(appts, appt); return Calendar(with_appt, cal); }; cal.undo = function() { return prev_cal || Calendar(); }; // ... } Assuming the same set of appointments, we can use the undo method to step back to a state before the fourth appointment was added: var my_prev_cal = my_cal.undo(); var next_appts_ = my_prev_cal.upcoming(now, 2); mori.map(function(a) { return a.title; }, next_appts_); // ("Code 'n' Splode Monthly Meeting" "Portland JavaScript Admirers' Monthly Meeting") Immutability comes in handy in this scenario. It is trivial to step back in time. Actually because Calendar is immutable, you don’t necessarily need a special method to get undo behavior: function makeCalendar() { var cal_0 = Calendar(); var cal_1 = cal_0.add({ title: "Portland JavaScript Admirers' Monthly Meeting", date: Date.parse("2013-09-25T19:00-0700") }); var cal_2 = cal_1.add({ title: "Code 'n' Splode Monthly Meeting", date: Date.parse("2013-09-24T19:00-0700") }); var cal_3 = cal_2.add({ title: "WhereCampPDX 6", date: Date.parse("2013-09-28T09:00-0700") }); var cal_4 = cal_3.add({ title: "Synesthesia Bike Tour", date: Date.parse("2013-09-22T15:00-0700") }); var toReturn = cal_4; // No wait! Undo!! toReturn = cal_3; // That was close... return toReturn; } I’m sure that the Synesthesia Bike Tour is a lot of fun. It’s just that when demonstrating an undo feature, something has to take the fall. That’s just the world that we live in, I suppose. hash_map All JavaScript objects are maps. But those can only use strings as keys.3 The hash_map provided by Mori can use any values as keys. var mori = require('mori'); var a = { foo: 1 }; var b = { foo: 2 }; var map = mori.hash_map(a, 'first', b, 'second'); assert(mori.get(map, b) === 'second'); If you use plain JavaScript objects as keys they will be compared by reference identity. If you use Mori data structures as keys they will be compared by value using equality comparisons provided by ClojureScript. Mori maps are immutable; so there is never a need to create defensive copies. An update operation produces a new map. var empty = mori.hash_map(); var m1 = mori.assoc(empty, 'foo', 1); var m2 = mori.assoc(m1, 'bar', 2, 'nao', 3); var m3 = mori.dissoc(m2, 'foo'); assert(mori.get(m2, 'foo') === 1); assert(mori.get(m2, 'bar') === 2); assert(mori.get(m3, 'foo') === null); The function assoc adds any number key-value pairs to a map; and dissoc removes keys. All of this also applies to array_map, sorted_map, and sorted_map_by. See Different map and set implementations below for information about those. There is a common pattern in JavaScript of passing options objects to constructors to avoid having functions that take zillions of arguments. It is also common to have a set of default values for certain options. So code like this is pretty typical: var opts = _.extend({}, options, defaults); I usually put in an empty object as the first argument to the Underscore _.extend call so that I get a new object instead of modifying the given options object in place. Modifying the options object could cause problems if it is reused somewhere outside of my constructor. An alternative to the defensive copy could be to use immutable Mori maps: function MyFeature(options) { var opts = mori.into(MyFeature.defaults, mori.js_to_clj(options)); this.getPosition = function() { return mori.get(opts, 'position'); }; this.getDestroyOnClose = function() { return mori.get(opts, 'destroyOnClose'); }; } MyFeature.defaults = mori.into(mori.hash_map(), mori.js_to_clj({ destroyOnClose: true, position: 'below' // etc... })); var feat = new MyFeature({ position: 'above' }); assert(feat.getPosition() === 'above'); The function mori.into(coll, from) adds all of the members of from into a copy of coll. Both from and coll can by any Mori collection. That does still involve copying the input options object into a new Mori map. It is also possible to provide a Mori sequence as input to start with - js_to_clj will accept either a plain JavaScript object or a Mori collection: var feat_ = new MyFeature(mori.hash_map( 'position', 'above', 'destroyOnClose', true )); There is probably no performance gain from using Mori in this situation. It is unlikely to matter anyway, since the structures involved are small. In situations with larger data structures, or where data is copied many times in a loop, Mori’s ability to create copies faster using less memory could make a difference. But in my opinion applying immutability consistently - even where there are no significant performance gains - can simplify things. The transformations that are available in Mori - map, filter, etc. - return lazy sequences no matter what the type of the input collection is. (See Laziness below for an explanation of what laziness is). This is advantageous because the other collection implementations are not lazy. But what if you want to do something like create a new set based on an existing set? The answer is that you feed a lazy sequence into a new empty collection using the appropriate constructor or the into function, which dumps all of the content from one collection into another: var s_1 = mori.set([5, 4, 3, 2, 1]); var seq = mori.map(function(e) { return Math.pow(e, 2); }, s_1); var s_2 = mori.set(seq); console.log(s_2); // Outputs: // > #{25 16 9 4 1} var empty_s = mori.sorted_set_by(function(a, b) { return a - b; }); var s_3 = mori.into(empty_s, seq); console.log(s_3); // Outputs: // > #{1 4 9 16 25} Applying map to the first set is lazy - but building the second set with into is not. So a good practice is to avoid building non-lazy collection until the last possible moment. An odd quirk in Mori is that the set constructor takes a collection argument, but most of the other constructors take individual values or key-value pairs. The into function behaves more consistently across data structure implementations. You might want to write transformations that are polymorphic - that can operate on any type of collection and that return a collection of the same type. To do that use mori.empty(coll) to get an empty version of a given collection. This makes it possible to build a new collection without having to know which constructor was used to create the original. Here is a function that removes null values from any Mori collection and that returns a collection of the same type: function compact(coll) { return mori.into(mori.empty(coll), mori.filter(function(elem) { var value = mori.is_map(coll) ? mori.last(elem) : elem; return value !== null; }, coll)); } If the collection given is a map then the value of elem in the filter callback will be a key-value pair. So compact includes an is_map check and extracts the value from that key-value pair if a map is given. A nice advantage of empty is that if you use it on a sorted_set_by or on a sorted_map_by, the new collection will inherit the same comparison function that the original uses. In a previous post, Functional Reactive Programming in JavaScript, I wrote about functional reactive programming (FRP) using Bacon.js and RxJS. A typical assumption in FRP code is that values contained in events and properties will never be updated in place. The immutable data structures that Mori provides are a perfect fit. Linked lists are nice and simple - but become less appealing when it becomes desirable to access elements at arbitrary positions in a sequence, to append elements to the end of a sequence, or to update elements at arbitrary indexes. The running time for all of these operations on lists is linear, and the append and update operations require creating a full copy of the list up to the changed position. Clojure’s PersistentVector is a sequence, like a list. But under-the-hood it is implemented as a tree with 32-way branching. That means that any vector index can be looked up in O(log_32 n) time. Appending and updating arbitrary elements also takes place in logarithmic time. For more details read Understanding Clojure’s PersistentVector implementation. Sequences that are implemented as mutable arrays of contiguous memory support constant-time lookups and modification (not including array resizing when array length grows). If O(log_32 n) does not seem appealing in comparison, consider that if you are using 32-bit integers as keys: var max_int = Math.pow(2, 32); var log_32 = function(n) { return Math.log(n) / Math.log(32); }; assert( log_32(max_int) < 7 ); Which means that your keyspace will run out before your vector’s tree becomes more than 7 layers deep. Up to that point operations will be O(7) or faster. If your keys are JavaScript numbers, which are 64-bit floating point values, the largest integer that you can count up to without skipping any numbers is Math.pow(2, 53). The logarithm of that number is also small: assert( log_32(Math.pow(2, 53)) < 11 ); The hash_map and set implementations in Mori are also implemented as trees with 32-way branching. The sorted map and set structures are implemented as binary trees. Map and set lookups are based on either hashing or ordering comparisons, depending on the implementation. JavaScript does not have built-in hash functions - at least not that are accessible to library code. It also does not have defined ordering or equality for most non-primitive values. So Mori uses its own functions, which it gets from ClojureScript. Every Mori value has a hash that identifies its content: var v = mori.vector('foo', 1); assert( mori.hash(v) === -1634041171 ); If a value is recreated with the same content, it has the same hash: var v2 = mori.vector('foo', 1); assert( mori.hash(v2) === mori.hash(v) ); Mori’s hash function delegates to a specific hash algorithm for each of its data structures, which are ultimately based on internal algorithms that Mori uses to compute hashes for primitive JavaScript values: assert( mori.hash(2) === 2 ); assert( mori.hash("2") === 50 ); assert( mori.hash("foo") === 101574 ); assert( mori.hash(true) === 1 ); assert( mori.hash(false) === 0 ); assert( mori.hash(null) === 0 ); assert( mori.hash(undefined) === 0 ); Since Mori also accommodates arbitrary JavaScript values as map keys and set values, it also has a scheme for assigning hash values to other JavaScript objects. var obj = { foo: 1 }; assert( mori.hash(obj) === 1 ); It seems that Mori has a monotonically increasing counter for object hash values. The first object that it computes a hash for gets the value 1; the second object gets 2, and so on. To keep track of which object got which hash value, it stores the value on the object itself: Object.keys(obj); //> [ 'foo', 'closure_uid_335348264' ] obj.closure_uid_335348264; //> 1 There are obvious hash-collision issues between non-Mori objects, numbers, and true. But Mori data structures can handle hash collisions. If a collection uses all of those types as keys it could end up with one hash bucket with three entries. Mori has its own equals function, which also comes from ClojureScript. As with hash, any two mori values that have the same content are considered to be equal: assert( mori.equals(v, v2) ); It works on primitive JavaScript values: assert( mori.equals(2, 2) ); When applied to non-Mori JavaScript objects, equals works the same way that the built-in === function does: var obj_1 = { bar: 1 }; var obj_2 = { bar: 1 }; assert( !mori.equals(obj_1, obj_2) ); assert( mori.equals(obj_1, obj_1) ); ClojureScript has a compare function, which Mori uses in its sorted data structure implementations. Mori does not export the compare function. The function defines an ordering for Mori values and for primitive JavaScript values - but not for other JavaScript objects. So if you want to put non-Mori objects into a sorted structure you will have to use an implementation that accepts a custom comparison function. hash_map and set use a hash function for lookups and have O(log32 n) lookup times; the sorted variants use comparison functions for lookups and have O(log2 n) lookup times; and array_map is just an array of key-value pairs, so it uses only an equality function for lookups and has O(n) lookup times. hash and equals are provided by Mori. compare is part of ClojureScript, but is not exported by Mori. Note that the sorted structures do not perform equals checks - instead they rely on a comparison function to determine whether values or keys are the same. On the other hand, the hash structures do perform equals checks to handle hash collisions. array_map is unique among the map and set implementations in that it preserves the order of keys and values based on the order in which they were inserted. If a value is inserted into an array_map and then the map is converted to a sequence (for example, using mori.seq(m)) then the last key-value pair inserted appears last in the resulting sequence. The ordering in a new array_map is determined by the order of key-value pairs given to the constructor. array_map is a good choice for small maps that are accessed frequently. The linear lookup time looks slower than other map implementations on paper. But there is no hashing involved and only simple vector traversal - so each of those n steps is faster than each of the log_32 n steps in a hash_map lookup. The array_map implementation has an internal notion of the upper limit on an efficient size. Once the map reaches that threshold, inserting another key-value pair produces a hash_map instead of a larger array_map.4 The information here on implementations and running times mainly comes from An In-Depth Look at Clojure Collections. Many of the functions provided by Mori return what is called a lazy sequence. Being a sequence this is like a list and can be transformed using functions like map, filter, and reduce. What makes a sequence lazy is that it is not actually computed right away. Evaluation is deferred until some non-lazy function accesses one or more elements of the transformed sequence. At that point Mori computes and memoizes transformations. // Sets, maps, vectors, and lists are actually not lazy. But ranges // are. var s = mori.sorted_set_by(function(a, b) { console.log('comparing', a, b); return a - b; }, 5, 4, 3, 2, 1); // Outputs approximately n * log_2(n) lines: // > comparing 4 5 // > comparing 3 5 // > comparing 3 4 // > comparing 2 4 // > comparing 2 3 // > comparing 1 4 // > comparing 1 3 // > comparing 1 2 // `map` returns a lazy sequence of transformed values. var seq = mori.map(function(e) { console.log('processed:', e); return 0 - e; }, s); // No output yet. // Getting the string representation of a collection or applying a // non-lazy function like `reduce` forces evaluation. console.log(seq); // Outputs: // > processed: 1 // > processed: 2 // > processed: 3 // > processed: 4 // > processed: 5 // > (-1 -2 -3 -4 -5) The results of a lazy evaluation are cached. If the same sequence is forced again the map function will not be called a second time: console.log(seq); // Outputs: // > (-1 -2 -3 -4 -5) Mori runs just enough deferred computation to get whatever result is needed. It is often not necessary to compute an entire lazy sequence: var seq_ = mori.map(function(e) { console.log('processed:', e); return e * 2; }, s); // `take` returns a lazy sequence of the first n members of a // collection. var seq__ = mori.take(2, seq_); console.log(seq__); // Outputs: // > processed: 1 // > processed: 2 // > (2 4) In the above case there is an intermediate lazy sequence that theoretically contains five values: the results of doubling values in the original set. But only the first two values in that sequence are needed. The other three are never computed. Laziness means that it is possible to create infinite sequences without needing unlimited memory or time: // With no arguments, `range` returns a lazy sequence of all whole // numbers from zero up. var non_neg_ints = mori.range(); // Dropping the first element, zero, results in a sequence of all of // the natural numbers. var nats = mori.drop(1, non_neg_ints); // Let's take just the powers of 2. var log_2 = function(n) { return Math.log(n) / Math.LN2; }; var is_pow_2 = function(n) { return log_2(n) % 1 === 0; }; var pows_2 = mori.filter(is_pow_2, nats); // What are the first 10 powers of 2? console.log( mori.take(10, pows_2) ); // Outputs: // > (1 2 4 8 16 32 64 128 256 512) // What is the 20th power of 2? console.log( mori.nth(pows_2, 20) ); // Outputs: // > 1048576 If you try this out in a REPL, such as node, be aware that when an expression is entered a JavaScript REPL will usually try to print the value of that expression, which has the effect of forcing evaluation of lazy sequences. If you enter a lazy sequence you will end up in an infinite loop: non_neg_ints = mori.range(); // Loops for a long time, then runs out of memory. The solution to this is to be careful to assign infinite sequences in var statements. That prevents the REPL from trying to print the sequence: var non_neg_ints = mori.range(); // Prints 'undefined', all is well. Powers of two are actually a terrible example of a lazy sequence: any element in that sequence could be calculated more quickly using Math.pow(). It just happens that powers of two are simple to demonstrate. Algorithms that really do benefit from infinite sequences are those where computation of any element requires references to earlier values in the sequence. A good example is computing Fibonacci numbers. function fibs() { var pairs = mori.iterate(function(pair) { var x = pair[0], y = pair[1]; return [y, x + y]; }, [0, 1]); return mori.map(mori.first, pairs); } This implementation uses the iterate function, which takes a function and an initial value. It creates an infinite sequence by repeatedly applying the given function. The given starting value is [0, 1], and each invocation of the given function combines the second value in the previous pair with the sum of the values in the previous pair; so the resulting sequence is: ([0, 1] [1, 1] [1, 2] [2, 3] [3, 5] ...). The map function is applied to that, taking the first value from each pair. Using this sequence allows us to ask the questions: // What are the first ten values in the Fibonacci sequence? console.log( mori.take(10, fibs()) ); // Outputs: // > (0 1 1 2 3 5 8 13 21 34) // What is the 100th number in the Fibonacci sequence? console.log( mori.nth(fibs(), 100) ); // Outputs: // > 354224848179262000000 // What is the sum of the first 4 Fibonacci numbers that are also // powers of 2? console.log( mori.reduce(mori.sum, 0, mori.take(4, mori.filter(is_pow_2, fibs()))) ); // Outputs: // > 12 // What is the 5th Fibonacci number that is also a power of 2? console.log( mori.nth(mori.filter(is_pow_2, fibs()), 4) ); // My computer runs for a long time with no apparent answer... A lazy sequence might also contain lines from a large file or chunks of data flowing into a network server. At the time of this writing I was not able to write a program that traversed a long sequence in constant space. But I have verified that this is possible in JavaScript. I may find a solution and post an update later. In procedural code running a sequence through multiple operations that apply to every element would result in multiple iterations of the entire sequence. Because Mori operates lazily it can potentially collect transformations for each element and apply them in a single pass: var seq_1 = mori.map(function(e) { console.log('first pass:', e); return e; }, s); var seq_2 = mori.map(function(e) { console.log('second pass:', e); return e; }, seq_1); console.log( mori.take(2, seq_2); ); // Outputs: // > first pass: 1 // > second pass: 1 // > first pass: 2 // > second pass: 2 // > (1 2) If applying map to a collection twice resulted in two iterations we would expect to see: // > first pass: 1 // > first pass: 2 // > second pass: 1 // > second pass: 2 The fact that the first pass and second pass are interleaved suggests that Mori collects transformations and applies all transformations to a value at once. This is the advantage of lazy evaluation: it encourages writing code in a way that makes most logical sense rather than thinking about performance. You can write what are logically many iterations over a collection and the library will rearrange computations to minimize the actual work that is done. Updated 2013-11-12: Added section on installing Mori. You might be wondering how Clojure handles polymorphism, since the convention is to use functions instead of methods. Clojure has a feature called protocols that permit multiple implementations for functions depending on the type of a given argument. Elsewhere in the functional world, Haskell and Scala provide a similar, yet more powerful feature, called type classes.↩ When conj is used on a list it prepends elements (like cons) because prepending is much cheaper than inserting at other possible positions. Given a vector conj appends values. Appending is often desired, and appending to a vector is just as efficient as inserting at any other position. conj works on sets and maps too - but in those cases the idea of insertion position is not usually meaningful.↩ It does look like ECMAScript 6 will add a Map implementation and a WeakMap to the language spec, both of which will take arbitrary objects as keys (only non-primitives in the WeakMap case). But those implementations will not be immutable!↩ Structures-ArrayMaps↩ I had a great time at NodePDX last week. There were many talks packed into a short span of time and I saw many exciting ideas presented. One topic that seemed particularly useful to me was Chris Meiklejohn’s talk on Functional Reactive Programming (FRP). I have talked and written about how useful promises are. See Promise Pipelines in JavaScript. Promises are useful when you want to represent the outcome of an action or a value that will be available at some future time. FRP is similar except that it deals with streams of reoccurring events and dynamic values. Here is an example of using FRP to subscribe to changes to a text input. This creates an event stream that could be used for a typeahead search feature: var inputs = $('#search') .asEventStream('keyup change') .map(function(event) { return event.target.value; }) .filter(function(value) { return value.length > 2; }); var throttled = inputs.throttle(500 /* ms */); var distinct = throttled.skipDuplicates(); This creates an event stream from all keyup and change events on the given input. The stream is transformed into a stream of strings matching the value of the input when each event occurs. Then that stream is filtered so that subscribers to inputs will only receive events if the value of the input has a length greater than two. Streams can be assigned to variables, shared, and used as inputs to create more specific streams. In the example above inputs is used to create two more streams: one that limits the stream so that events are emitted at most every 500 ms and another that takes the throttled stream and drops duplicate values that appear consecutively. So when the final stream, distinct, is consumed later it is guaranteed that events 1) will be non-empty strings with length greater than two, 2) will not occur too frequently, and 3) will not include duplicates. That stream can be fed through a service via ajax calls to show a live list of); }); }); Here suggestions is a new stream that has been transformed from strings to search results using the searchWikipedia function. All of jQuery’s ajax methods return promises and Bacon.fromPromise() turns a promise into an event stream. The flatMapLatest transformer builds a new stream from an existing stream and a stream factory - and it only emits events from the last stream created. This means that if the user types slowly and a lot of ajax requests are made responses to all but the last request will be disregarded. The suggestions stream is ultimately used by calling its onValue method. That adds a subscriber that runs code for every event that makes it all the way through the stream. The result is a list of search results that is updated live as the user types. There are some other tricks available. It is possible to bind data from an event stream to a DOM element: var query = suggestions.map(function(data) { return data.query; }).toProperty('--'); query.assign($('#query'), 'text'); This creates a new stream that is pared down to just the query used to produce each set of results. Whenever a result set is rendered the corresponding query will also be output as the text content of the '#query' element. The new stream is converted to a property to make this work. A property is a value that varies over time. The main practical distinction between a property and an event stream is that a property always has a value. In other words a property is continuous while an event stream is discrete. This example provides '--' as the initial value for the new property. Notice that property binding as shown here is more general than some data binding frameworks in that the destination is not limited to DOM elements and the source is not limited to model instances. This example passes values to the text method of the given jQuery object. It is possible to push data to any method on any object. Streams can be combined, split, piped, and generally manipulated in all kinds of ways. Properties can be bound, sampled, combined, transformed, or whatever. I put this code up on JSFiddle so you can try it out and play with it: There are several FRP implementations out there. Two that seem to be prominent are Bacon.js and RxJS. The examples above are code from the RxJS documentation that I rewrote with Bacon. That gave me an opportunity to learn a bit about both libraries and to see how they approach the same problem. The original RxJS code is here. With FRP it is possible to describe complicated processes in a clean, declarative way. FRP is also a natural way to avoid certain classes of race conditions. When I wrote the initial version of the sample code above it worked perfectly on the first try. In my view that is a sign of a very well-designed library. If you are interested in further reading I suggest the series of tutorials from the author of Bacon. And there is a great deal of information on the RxJS and Bacon Github pages, including documentation and more examples.]]> This is one of the crazier workarounds that I have implemented. I was working on a web page that embeds third-party widgets. The widgets are drawn in the page document - they do not get their own frames. And sometimes the widgets are redrawn after page load. We had a problem with one widget invoking document.write(). In case you are not familiar with it, if that method is called while the page is rendering it inserts content into the DOM immediately after the script tag in which the call is made. But if document.write() is called after page rendering is complete it erases the entire DOM. When this widget was redrawn after page load it would kill the whole page. The workaround we went with was to disable document.write() after page load by replacing it with a wrapper that checks whether the jQuery ready event has fired. (function() { var originalWrite = document.write; document.write = function() { if (typeof jQuery !== 'undefined' && jQuery.isReady) { if (typeof console !== 'undefined' && console.warn) { console.warn("document.write called after page load"); } } else { // In IE before version 8 `document.write()` does not // implement Function methods, like `apply()`. return Function.prototype.apply.call( originalWrite, document, arguments ); } } })(); The new implementation checks the value of jQuery.isReady and delegates to the original document.write() implementation if the page is not finished rendering yet. Otherwise it does nothing other than to output a warning message. Disabling document.write() means that the problematic widget will not be fully functional if it is redrawn after page load. It happens that in the case of this app that is ok. The redrawn widget is only used as a preview when editing widget layouts. A particular problem came up with IE compatibility. I wanted to use the apply method that is implemented by all functions in JavaScript to invoke the original document.write() implementation, like this: return originalWrite.apply(document, arguments); But in older versions of Internet Explorer, document.write() is not really a function. There are a lot of examples in IE of native API methods and properties that do not behave like regular JavaScript values. For example if you pass too many arguments to a DOM API method in old IE you will get an exception. Normal JavaScript functions just silently ignore extra arguments. If you look at the value of typeof document.write the result is not "function". What is particularly problematic in this case is that document.write does not implement call or apply. Fortunately I found that the Function prototype does implement both call and apply and furthermore you can borrow those methods to use on function-like values like document.write. call and apply are themselves real function values - so call and apply both implement call and apply. typeof Function.prototype.apply.apply.apply // evaluates to 'function' typeof Function.prototype.apply.call.call // evaluates to 'function' In the workaround above I applied apply to document.write by taking the Function.prototype.apply value and using its call method. So this expression, Function.prototype.apply.call(originalWrite, document, arguments); is equivalent to this one, originalWrite.apply(document, arguments); Except that the first version works in IE7. If you find this difficult to follow, you are not alone. We have had this workaround in our code for a couple of years now. So far it is working nicely.]]> Promises, also know as deferreds or futures, are a wonderful abstraction for manipulating asynchronous actions. Dojo has had Deferreds for some time. jQuery introduced its own Deferreds in version 1.5 based on the CommonJS Promises/A specification. I’m going to show you some recipes for working with jQuery Deferreds. Use these techniques to turn callback-based spaghetti code into elegant declarative code. A Deferred is an object that represents some future outcome. Eventually it will either resolve with one or more values if that outcome was successful; or it will fail with one or more values if the outcome was not successful. You can get at those resolved or failed values by adding callbacks to the Deferred. In jQuery’s terms a promise is a read-only view of a deferred. Here is a simple example of creating and then resolving a promise: function fooPromise() { var deferred = $.Deferred(); setTimeout(function() { deferred.resolve("foo"); }, 1000); return deferred.promise(); } Callbacks can be added to a deferred or a promise using the .then() method. The first callback is called on success, the second on failure: fooPromise().then( function(value) { // prints "foo" after 1 second console.log(value); }, function() { console.log("something went wrong"); } ); For more information see the jQuery Deferred documentation. Note that if you are using a version of jQuery prior to 1.8 you will have to use .pipe() instead of .then(). That goes for all references to .then() in this article. Actions, such as HTTP requests, need to be sequential if input to one action depends on the output of another; or if you just want to make sure that actions are performed in a particular order. Consider a scenario where you have a post id and you want to display information about the author of that post. Your web services don’t support embedding author information in a post resource. So you will have to download data on the post, get the author id, and then make another request to get data for the author. To start with you will want functions for downloading a post and a user: function getPost(id) { return $.getJSON('/posts/'+ id).then(function(data, status, xhr) { return data; }); } function getUser(id) { return $.getJSON('/users/'+ id).then(function(data, status, xhr) { return data; }); } In jQuery 1.5 and later all ajax methods return a promise that, on a successful request, resolves with the data in the response, the response status, and the XHR object representing the request. The .then() method produces a new promise that transforms the resolved value of its input. I used .then() here just because using $.when() is simpler if each promise resolves to a single value. We will get back to that in parallel operations. Since only one argument is provided to .then() in these cases the new promises will have the same error values as the originals if an error occurs. The result is that getUser() returns a promise that should resolve to data representing the user profile for a given id. And getPost() works the same way for posts and post ids. Now, to fetch that author information: function authorForPost(id) { var postPromise = getPost(id), deferred = $.Deferred(); postPromise.then(function(post) { var authorPromise = getUser(post.authorId); authorPromise.then(function(author) { deferred.resolve(author); }); }); return deferred.promise(); } When authorForPost() is called it returns a new promise that resolves with author information after both the post and author requests complete successfully. This is a straightforward way to get the job done. Though it does not implement error handling; and it could be more DRY. More on that in a bit. Let’s say that you want to fetch two user profiles to display side-by-side. Using the getUser() function from the previous section: function getTwoUsers(idA, idB) { var userPromiseA = getUser(idA), userPromiseB = getUser(idB); return $.when(userPromiseA, userPromiseB); } The requests for userA and userB’s profiles will be made in parallel so that you can get the results back as quickly as possible. This function uses $.when() to synchronize the promises for each profile so that getTwoUsers() returns one promise that resolves with the data for both profiles when both responses come back. If either request fails, the promise that getTwoUsers() returns will fail with information about the first failed request. You might use getTwoUsers() like this: getTwoUsers(1002, 1008).then(function(userA, userB) { $(render(userA)).appendTo('#users'); $(render(userB)).appendTo('#users'); }); The getTwoUsers() promise resolves with two values, one for each profile. We now have several well-defined functions that operate on asynchronous actions. Isn’t this nicer than the big mess of nested callbacks one might otherwise see? I mentioned above that using $.when() is simpler when each of its input promises resolves to a single value. That is because if an input promise resolves to multiple values then the corresponding value in the new promise that $.when() creates will be an array instead of a single value. Performing an arbitrary number of actions in parallel is similar: function getPosts(ids) { var postPromises = ids.map(getPost); return $.when.apply($, postPromises).then(function(/* posts... */) { return $.makeArray(arguments); }); } This code fetches any number of posts in parallel. I used apply to pass the post promises to $.when() as though they are each a separate argument. The resulting promise resolves with a separate value for each post. It would be nicer if it resolved with an array of posts as one value. The use of .then() here takes those post values and transforms them into an array. Let’s take the previous examples to their logical conclusion by creating a function that, given two post ids, will download information about the authors of each post to display them side-by-side. No problem! function getAuthorsForTwoPosts(idA, idB) { return $.when(authorForPost(idA), authorForPost(idB)); } From the perspective of a function that calls authorForPost(), it does not matter that two sequential requests are made. Because authorForPost() returns a promise that represents the eventual result of both requests, that detail is encapsulated. There are a couple of problems with the implementation of authorForPost() as presented above. We had to create a deferred by hand, which should not be necessary. And the promise that is returned does not fail if any of the requests involved fail. These issues are not present in the parallel examples because $.when() does a nice job of generalizing synchronizing multiple promises. What we need is a function that does a similar job of generalizing flattening nested promises. Meet flatMap: $.flatMap = function(promise, f) { var deferred = $.Deferred(); function reject(/* arguments */) { // The reject() method puts a deferred into its failure // state. deferred.reject.apply(deferred, arguments); } promise.then(function(/* values... */) { var newPromise = f.apply(null, arguments); newPromise.then(function(/* newValues... */) { deferred.resolve.apply(deferred, arguments); }, reject); }, reject); return deferred.promise(); }; This function takes a promise and a callback that returns another promise. When the first promise resolves, $.flatMap() invokes the callback with the resolved values as arguments, which produces a new promise. When that new promise resolves, the promise that $.flatMap() returns also resolves with the same values. On top of that, $.flatMap() forwards errors to the promise that it returns. If either the input promise or the promise returned by the callback fails then the promise that $.flatMap() returns will fail with the same values. Using $.flatMap() it is possible to write a function like authorForPost() a bit more succinctly: function authorForPost(id) { return $.flatMap(getPost(id), function(post) { return getUser(post.authorId); }); } By using $.flatMap() you also get error handling for free. If the request to fetch a post fails or the request to fetch the post’s author fails the promise that this version of authorForPost() returns will also fail with the appropriate failure values. Another potential problem is that authorForPost() does not give you access to any of the information on the posts that it downloads. You can combine $.flatMap() and .then() to create a slightly different function that exposes both the post and the author: function postWithAuthor(id) { return $.flatMap(getPost(id), function(post) { return getUser(post.authorId).then(function(author) { return $.extend(post, { author: author }); }); }); } The promise that postWithAuthor() returns resolves to a post object with an added author property containing author information. It turns out that .then() leads a double life. If the return value of its callback is a promise, .then() behaves exactly like $.flatMap()! This is the sort of thing that only a dynamic language like JavaScript can do. So if you want to skip the custom function, you could write postWithAuthor() like this: function postWithAuthor(id) { return getPost(id).then(function(post) { return getUser(post.authorId).then(function(author) { return $.extend(post, { author: author }); }); }); } The examples above focus on HTTP requests. But promises can be used in any kind of asynchronous code. They even come in handy in synchronous code from time to time. Here is an example of a promise used to represent the outcome of a series of user interactions: function getRegistrationDetails() { var detailsPromise = openModal($.get('/registrations')); detailsPromise.then(function(details) { $.post('/registrations', details); }); } function openModal(markupPromise) { var deferred = $.Deferred(), modal = $('<div></div>').addClass('modalWindow'), loadingSpinner = $('<span></span>').addClass('spinner'); modal.append(loadingSpinner); // Use .always() to add a callback to a promise that runs on success // or failure. markupPromise.always(function() { loadingSpinner.remove(); }); markupPromise.then(function(markup) { modal.html(markup); }); modal.one('submit', 'form', function(event) { event.preventDefault(); var data = $(this).serialize(); modal.remove(); deferred.resolve(data); }); modal.appendTo('body'); return deferred.promise(); } $(document).ready(function() { $('#registerButton').click(function(event) { event.preventDefault(); getRegistrationDetails(); }); }); I suggest considering using promises anywhere you would otherwise pass a callback as an argument. The promise transformations .then(), $.when(), and $.flatMap() work together to build promise pipelines. Using these functions you can define arbitrary parallel and sequential operations with nice declarative code. Furthermore, small promise pipelines can be encapsulated in helper functions which can be composed to form longer pipelines. This promotes reusability and maintainability in your code. Use .then() to transform individual promises. Use $.when() to synchronize parallel operations. Use $.flatMap() or .then() to create chains of sequential operations. Mix and match as desired. I would like to thank Ryan Munro for coming up with the “pipeline” analogy. Update 2012-08-01: .pipe() was added in jQuery 1.6. And it turns out that it behaves like $.flatMap() when its callback returns a promise. In jQuery 1.8 .then() will be updated to behave exactly like .pipe(), and .pipe() will be deprecated. So there is actually no need to add a custom method - you can just use .pipe() or .then() instead of $.flatMap(). Update 2013-01-30: jQuery 1.8 has been released, so I replaced references to .pipe() with .then(). I also included a more prominent explanation that .then() can do the same thing that $.flatMap() does. Good news! If you are able to follow the examples in this post then you have a working understanding of Monads. Specifically, $.flatMap() is a monad transformation, .then() with one argument is a functor transformation, and $.when() is almost a monoid transformation. Monads, monoids, and functors are concepts from category theory that can be applied to functional programming. Really they are just generalizations of this idea of creating pipelines to transform values. I bring this up because category theory can be useful, but is difficult to explain. My hope is that seeing examples of category theory in action will help programmers to get a feel for the patterns involved. For more information on category theory in programming I recommend a series of blog posts titled Monads are Elephants. If you have read that and want to go further, I found the the book Learn You a Haskell for Great Good! to be very informative. And as a bonus it teaches you Haskell. Those who are already into category theory will note that $.flatMap() could also be defined in terms of .then() and a $.join() function: $.flatMap = function(promise, f) { return $.join(promise.then(f)); }; $.join = function(promise) { var deferred = $.Deferred(); function reject(/* arguments */) { deferred.reject.apply(deferred, arguments); } promise.then(function(nestedPromise) { nestedPromise.then(function(/* values... */) { deferred.resolve.apply(deferred, arguments); }, reject); }, reject); return deferred.promise(); }; Except that this won’t actually work because .then() will join the inner and outer promises before the result is passed to $.join(). This guide provides step-by-step instructions for installing the Virtuous Prime community ROM on your Asus Transformer Prime TF201 tablet. This guide will be useful to you if you do not have root access to your tablet. Be aware that following the instructions here will void your warranty and will wipe all of the data on your tablet. There is also a danger that you might brick your tablet. Proceed at your own risk. So, why would you want to install a custom ROM on your tablet? In my case I wanted to gain root access, which allows one to do all sorts of nifty things. Community-made ROMS are also often customized to make the Android experience more pleasant for power users. And choosing your own ROM means that you are no longer dependent on the company that sold you your device to distribute firmware updates in a timely fashion. But if you are reading this then you probably already know why you want to install a custom ROM - so let’s get on to the next step. This guide specifically covers installing Virtuous Prime, which is based on the official Asus firmware. If you like the features that Asus provides, like the ability to switch between performance profiles and to toggle IPS+ mode then this is probably the ROM for you. Virtuous also adds some features like root access, the ability to overclock the processors to 1.6 GHz, and so on. Note to the Virtuous ROM devs: it is really awesome to have you all putting in the effort to make the Android experience better for everybody. It is especially amazing that you give your ROM away for free. You are virtuous people indeed! That said, these folks do accept donations. If you would rather get a vanilla Ice Cream Sandwich experience then you might check out AOKP. If you just want root access and you do not want to install a custom ROM then there is a simpler procedure that you can follow using SparkyRoot. The catch is that SparkyRoot does not work in firmware versions v9.4.2.21 or later. Part of the reason that I went for a custom ROM is that I upgraded the firmware on my Prime as soon as I got it - so I missed my shot at using SparkyRoot. Don’t be like me: plan ahead! If you have the newest firmware version it is possible to downgrade in order to use SparkyRoot. I chose to install a custom ROM instead because it seemed to me to be a safer option. Be aware that if you follow the directions here to install a custom ROM you will not be able to use the downgrade procedure in that link. In brief, here are the steps that we are going to follow: I am not completely sure that this step is necessary. I did not try installing ClockworkMod Recovery before unlocking. But even if it is not necessary, I imagine that there may come a time when I am glad to have an unlocked bootloader. You can try skipping this step; at worst nothing will happen. The unlocking tool is provided by Asus. As you will see, Asus makes it very clear that using the unlock tool will void your warranty. But on the upside it will not wipe your data or anything like that. The only noticeable change will be that every time you boot up the tablet there will be a message in the upper-left corner of the screen that says, “The device is UnLocked”. I assume that is there so that customer service representatives can see that they are not supposed to help you. Download the unlock tool directly onto your tablet from the TF201 support section of the Asus website. Select “Android” as the OS and grab the “Unlock Device App” from the “Utilities” section. The file that you get is an apk that you will install as an app. If you have not done so already, you will have to enable unknown software sources in your tablet settings. Go to Settings > Security > Device Administration and check the box that says “Unknown Sources”. Use your file manager to find the downloaded unlock tool. It is probably in /sdcard/Download/UnLock_Device_App_V6.apk. Tap it to install the app. You will be prompted to confirm your Google account by entering your Google password. If you are using two-factor authentication on your Google account you will have to set up an application-specific password for this. You can revoke that password after your tablet is unlocked. Next you will have to agree to a license and acknowledge a warning. Again, Asus wants to make it really clear that you are about to void your warranty. After you agree to everything your tablet will reboot and your bootloader is now unlocked. ClockworkMod Recovery is a custom recovery image. The Transformer Prime comes with a recovery image provided by Asus that lets you do stuff like manually install OS updates. But the Asus recovery image will only let you install updates that are digitally signed by Asus. To install a community-made ROM you need a recovery mode that will let you install unsigned ROMs. That is what ClockworkMod does. It also provides extra features, like the ability to back up and restore your whole OS. Installing ClockworkMod will probably void your warranty - in case you somehow got to this point with an intact warranty. There is also some danger that you could brick your tablet. Proceed at your own risk. These instructions are adapted from a guide on TransformerPrimeRoot.com. I’m going to give you the slightly more complicated version that involves downloading files directly from ClockworkMod and from Google; and I will provide tips on what to do if the fastboot tool is not able to find your tablet. I personally appreciate it when I can get files from sources that I know I can trust. But if you are not convinced that is necessary then feel free to check out the TransformerPrimeRoot.com guide. For this step you will need a computer. Download the latest ClockworkMod Recovery image from ClockworkMod’s downloads page. As of this writing the latest version for the Transformer Prime is 5.8.2.0. According to TransformerPrimeRoot.com earlier versions can put your device into a reboot loop (which you can recover from but it is scary when it happens, I imagine). The Touch Recovery image should also work. It comes with a nicer touch-based UI. But the guides that I have read call for the non-touch version, so that is what I went with. You will also need the fastboot tool from the Android SDK to install the recovery image. Download the SDK from Google and extract it. Run the android executable in the tools/ directory to launch the SDK package manager and use that tool to install the Android SDK Platform-tools: check the box next to “Android SDK Platform-tools” and click “Install packages…”. After a few minutes that will add a new executable, fastboot, in the platform-tools directory in the Android SDK package. You will use the fastboot program to send commands to your tablet while the tablet is in fastboot mode. Android devices have two boot modes apart from the normal boot-into-the-OS option: recovery mode and fastboot. Fastboot is a low-level mode that is used for flashing firmware. You can use fastboot to replace the recovery mode image - which is what we will be doing to install ClockworkMod. And you can use recovery mode to install a new OS. Likewise, if your OS breaks you can fix it from recovery mode and if recovery mode breaks you may be able to fix it from fastboot. What happens if fastboot breaks? Try not to let that happen! The Android devs have not yet provided us with an extra-fast-boot. If you are on Windows then you will have to install a USB driver before proceeding. Linux and Mac users do not need any special drivers. Make sure that your battery is charged to at least 50%. Bad things will happen if your battery dies while you are flashing a recovery image. Boot your tablet into fastboot by holding down the power and volume-down buttons. The tablet will power off and reboot. Wait until you see several lines of white text in the upper-left corner of the screen, then let go of the power and volume buttons. Then wait for five seconds and you will see the fastboot options. Press volume-down to highlight the USB icon and then press volume-up to select it. You have ten seconds to do this - after that the tablet will cold-boot Android instead. If that happens, don’t worry. Just start over by holding down the power and volume-down buttons. Plug the tablet into your computer using the USB cable that came with your tablet. On your computer open a terminal. Assuming that you have the ClockworkMod Recovery image and the extracted Android SDK in the same downloads folder, cd to that folder. Run this fastboot command to make sure that your computer is talking to your tablet: android-sdk_r18/platform-tools/fastboot -i 0x0b05 The -i 0x0b05 part tells fastboot which USB device to communicate with. The number 0b05 is the Asus vendor id for USB interfaces. If you want to double-check that vendor id you can use the lsusb command on Linux. On my machine the output includes a line that looks like this: Bus 002 Device 018: ID 0b05:4d01 ASUSTek Computer, Inc. The vendor id is the portion of the ID before the colon. Anyway, if the fastboot command that you ran worked you should see output that looks like this: finished. total time: 1336881627.143s On the other hand, if you see a message that says < waiting for device >, and you wait a minute or two and nothing happens, then hit Ctrl-c to cancel. If you are in Linux you can fix this problem by creating a udev rule. Create a new file, /etc/udev/rules.d/99-android.rules and add this line to it: SUBSYSTEM=="usb", ATTRS{idVendor}=="0b05", MODE="0666", OWNER="yourusername" But make sure to replace “yourusername” with your user name. Then restart udev with this command: sudo restart udev Now try the fastboot command again. Ok, is fastboot talking to your tablet? Now for the next step: flashing ClockworkMod. I recommend checking the md5 checksum on the ClockworkMod Recovery image to make sure that it has not been corrupted. On Linux you can use this command to do that: md5sum recovery-clockwork-5.8.2.0-tf201.img It appears that ClockworkMod does not list md5 checksums on its downloads page. But here is the checksum that I got for version 5.8.2.0: 08009bd8fa324116e71982945390cdde You should proceed only if the checksums match. Run this command - and again make sure that the paths match the locations of the fastboot and ClockworkMod Recovery image files: android-sdk_r18/platform-tools/fastboot -i 0x0b05 flash recovery recovery-clockwork-5.8.2.0-tf201.img If all goes well you should see some output like this: sending 'recovery' (5378 KB)... OKAY [ 1.891s] writing 'recovery'... OKAY [ 1.571s] finished. total time: 3.462s Now you have ClockworkMod Recovery installed. Following the instructions here will wipe everything on your tablet. And you will void your warranty - again. Proceed at your own risk. There are instructions on RootzWiki for installing Virtuous Prime. I’m going to give you the same instructions but with a bit more detail. But I recommend reading the information on RootzWiki too as there is a lot of useful background there. Download the latest version of Virtuous Prime directly onto your tablet. As of this writing that is Virtuous Prime 9.4.2.21 v1, which is based on the Transformer Prime v9.4.2.21 firmware from Asus. You will get a zip file - don’t unzip it! Next to the download link there will be an MD5 checksum. We will refer back to that in a moment. Use your file manager to move the zip file, virtuous_prime_s_9.4.2.21_v1.zip from /sdcard/Download/ to /sdcard/. I think that this step is superfluous; but it makes me feel better. This is optional, but highly recommended: install the free MD5 Checker app. You can use this app to check the MD5 checksum of the file that you downloaded to make sure that it was not corrupted. Open MD5 Checker, click on the button labelled “Load File 1”, browse to the Virtuous Prime zip file, and wait for MD5 Checker to compute the file’s checksum. Make sure that the checksum that you see in MD5 Checker is the same as the one from the Virtuous Prime downloads page. If the checksums do not match then do not proceed! Download the file again and check the checksum again. Shut down your tablet. But make sure that your battery is charged to at least 50% first. And make sure that the USB cable is unplugged. Boot into recovery mode by holding both the power and volume-down buttons. As with fastboot, when you see several lines of white text in the upper-left corner of the screen let go of both buttons. But this time press volume-up right away. If you do not press volume-up within five seconds then the tablet will go into fastboot. If that happens then just start over by holding the power and volume-down buttons again. After a moment you should see the ClockworkMod menu. You can use the volume-up and volume-down buttons to highlight the different menu options and the power button to select the option that you want. Make a backup of your current ROM. Select “backup and restore”, then “backup”. This will create a timestamped backup directory on your tablet under /sdcard/clockwork/backup/. There is a lot of information on backing up and restoring your tablet here. The backup process will take a few minutes. When it is done you will see the ClockworkMod menu again. Select “wipe data/factory reset”. According to RootzWiki this step is optional, but is highly recommended. You will have to complete an elaborate confirmation step to start the wipe. Once all of your data has been wiped, select “install zip from sdcard”, then “choose zip from sdcard”. Browse to the Virtuous Prime ROM and select it. And confirm that you are really sure about this. You will be taken through a guided install process in which you will be prompted to choose between Typical, Complete, or Minimal install modes. There is a list of the differences between the three modes on RootzWiki. When the installer is finished your tablet will reboot and you are done! Congratulations! Enjoy your new ROM! There is some useful information collected on TransformerPrimeRoot.com. Much of the information in my guide comes from that site. If the worst should happen and your tablet becomes a brick, you may still be able to recover. Check out the recovery guide on XDA-Developers. After about a week of use, the Virtuous Prime ROM is working very well. It does everything that the Asus firmware did and more. But I did run into some problems that I wanted to report along with some workarounds. The Hulu Plus app does not work for me anymore. When I try to play a video I get this message: Streaming Unavailable [91] Sorry, we are unable to stream this video. Please check your Internet connection, ensure you have the latest official update for your device, and try again. The Hulu app did work for me before I unlocked my tablet. There are reports that unlocking the bootloader is what causes this problem. This may not have anything to do with Virtuous Prime directly. A helpful community member created a modified version of the Hulu Plus app that does work. From the first post in that thread you can download and install the Landscape Mod HuluPlus.apk package. You will need to enable “Unknown Sources” to install the package. Before you install this version I suggest wiping the data of the original Hulu app and uninstalling it. The home view in the app is distorted; but the queue view works fine. This mod is based on a phone version of the original Hulu app rather than a tablet version. Video quality seems a bit low - I don’t know whether that is due to my connection or to the app. With those caveats, the modified app works great for me. Netflix works perfectly. Hooray for Netflix! The Amazon Kindle app crashes when I try to open a book. I have tried wiping the app’s data and reinstalling multiple times. I have also tried different books. And I have confirmed that I am running version 3.5.1.1, which is the latest version available in the Play Store right now. I managed to fix the Kindle app by following instructions to fix Machinarium, which simply involves installing a missing font. An alternative workaround is to use the Cloud Reader. Note that the Cloud Reader will work in Chrome for Android Beta, but will refuse to run in the default Android browser. You will not be able to install the extension that allows Cloud Reader to work offline since the mobile version of Chrome does not support extensions yet. So you will have to be connected to the internet to use the Cloud Reader. Someone on the XDA Developers forum asked whether the game Machinarium would install under Virtuous Prime. I tested this and found that the game will install - but it crashes on startup. I did not test this game before installing Virtuous Prime. All other games that I have tested have worked fine. It turns out that the problem with Machinarium is that there is a missing font in Virtuous Prime. Specifically the Droid Sans and Droid Sans Bold fonts are missing. There is a fix reported in the XDA Developers forum. So with some digging it seems that I did not encounter any problems that I could not fix. Also, having root access to my tablet is excellent.]]> Most web applications today use browser cookies to keep a user logged in while she is using the application. Cookies are a decades-old device and they do not stand up well to security threats that have emerged on the modern web. In particular, cookies are vulnerable to cross-site request forgery. Web applications can by made more secure by using OAuth for session authentication. This post is based on a talk that I gave at Open Source Bridge this year. The slides for that talk are available here. When a user logs into a web application the application server sets a cookie value that is picked up by the user’s browser. The browser includes the same cookie value in every request sent to the same host until the cookie expires. When the application server receives a request it can check whether the cookies attached to it contain a value that identifies a specific user. If such a cookie value exists then the server can consider the request to be authenticated. There are many types of attacks that can be performed against a web application. Three that specifically target authentication between the browser and the server are man-in-the-middle (MITM), cross-site request forgery (CSRF), and cross-site scripting (XSS). Plain cookie authentication is vulnerable to all three. In a MITM attack the attacker is in a position to watch traffic that passes between some user’s browser and an application server. If that traffic is not encrypted the attacker could steal private information. One of the most dangerous things that an attacker can do in this position is to hijack the user’s session by reading cookie data from an HTTP request and including that cookie data in the attacker’s own requests to the same server. This is a form of privilege escalation attack. Using this technique an attacker can convince an application server that the attacker is actually the user who originally submitted a given cookie. Thus the attacker gains access to all of the user’s protected resources. Last year a Firefox extension called Firesheep made some waves when it was released. The purpose of Firesheep was to raise awareness of the danger of MITM attacks. Most web applications, at that time and today, use cookie authentication without an encrypted connection between browser and server. Firesheep makes it easy to spy on anybody who is using well known applications like Facebook and Twitter on a public network. With the click of a button you can perform a MITM attack yourself, steal someone’s cookies, and gain access to that person’s Facebook account. MITM attacks can be effectively blocked by using HTTPS to encrypt any traffic that contains sensitive information or authentication credentials. When using HTTPS you will almost certainly want to set the “secure” flag on any cookies used for authentication. That flag prevents the browser from transmitting cookies over an unencrypted connection. More and more web applications are offering HTTPS - often as on opt-in setting. Any web site that requires a login should offer HTTPS - and ideally it should be enabled by default. XSS attacks involve an attacker pushing malicious JavaScript code into a web application. When another user visits a page with that malicious code in it the user’s browser will execute the code. The browser has no way of telling the difference between legitimate and malicious code. Injected code is another mechanism that an attacker can use for session hijacking: by default cookies stored by the browser can be read by JavaScript code. The injected code can read a user’s cookies and transmit those cookies to the attacker. Just like in the MITM scenario, the attacker can use those cookies to disguise herself as the hapless user. There are other ways that XSS be used can be used to mess with a user - but session hijacking is probably the most dangerous. Session hijacking via XSS can be prevented by setting an “httpOnly” flag on cookies that are used for authentication. The browser will not allow JavaScript code to read or write any cookie that is flagged with “httpOnly”; but those cookies will still be transmitted in request headers. CSRF attacks authentication indirectly. A malicious web page can trick a browser into making cross-domain requests to another web site. If a user visiting the malicious page is already logged in to that web site then the malicious page can access the site resources as though it were logged in as the unsuspecting user. For example, if a malicious page can trick the browser into making POST requests to a microblogging site it can post updates with spam links that appear to have been written by the victim. If you use Facebook you might have encountered attacks like this yourself. You see a post on a friend’s wall with a button that says “Don’t click the button!” When you click on it you are taken to another site and the same message ends up posted on your wall. This works because the browser automatically sends cookies set on a given domain with every request made to that domain, regardless of where those requests originated. The browser has no way of knowing that the requests initiated by the malicious page are made without the user’s knowledge. The malicious page could create a cross-domain request by including an image with a src attribute pointing to a URL on the site that it is trying to hack into. The URL does not have to be an image - the browser will make a GET request to that URL and will discard the response when it determines that the response is not image data. If that GET request produced any side-effects, like posting a microblogging update, then the malicious page has successfully performed an attack. To make a cross-domain POST request the malicious site might include a hidden HTML form with an action attribute pointing at the site to be hacked. The malicious page can use JavaScript to submit the form without any interaction from the user. This is another case where the attacker cannot read the response that comes back but can trigger some action in the user’s account. In some cases CSRF attacks can also be used to read data. Because JSON is a strict subset of JavaScript, HTTP responses that contain JSON data can be loaded into script tags and executed. In some browsers a malicious page can override the Object and Array constructors to capture data from the JSON response as it is executed so that it can be sent to an attacker. The biggest problem with CSRF is that cookies provide absolutely no defense against this type of attack. If you are using cookie authentication you must also employ additional measures to protect against CSRF. The most basic precaution that you can take is to make sure that your application never performs any side-effects in response to GET requests. To protect against cross-domain POST requests a commonly used option is to use an anti-forgery token that must be submitted with every POST, PUT, or DELETE request. The token is generally injected into the HTML code for forms in such a way that malicious code on another site does not have any way to access it. JSON responses can be protected by pre-pending the JSON response with some code that makes the response non-executable. For example, you could place a JavaScript loop at the beginning of the response that never terminates. Or you could put in a statement that throws an exception. Putting the whole JSON response inside of a comment block also works. The only way for a browser to read JSON data that has been obfuscated like this is to fetch the resource using XHR and to remove the extra code before parsing the actual JSON data. XHR is limited by the same-origin policy; so a malicious page cannot make a cross-site XHR request. Such multi-layered approaches to CSRF defense work but are a pain to implement. I know from experience that the stateful nature of anti-forgery tokens make them a constant source of bugs in Ajax-driven applications where users might submit several requests to the server without ever loading a new page. It is too easy for the client and server to get out of sync and to disagree about which anti-forgery tokens are fresh. And great care must be taken to include the anti-forgery feature in every form and Ajax call in an application or a security hole appears. JSON obfuscation is easier to apply to every JSON response as a blanket policy thanks to server-side filters and client-side hooks, such as those in jQuery’s Ajax stack. But then you are not really serving JSON - you are serving a JSON-like type with a proprietary wrapper. I find that I spend a lot of time instructing people on the existence of obfuscation, explaining why it is there, and explaining how to set up hooks to remove it on the client side. By combining the “secure” and “httpOnly” flags and using HTTPS you can make your application authentication proof against MITM attacks and against some XSS attacks. But there is nothing that will make cookie authentication resistant to CSRF attacks. The only way to protect against CSRF is to apply additional security measures. Often multiple measures are required to combat different possible CSRF vectors. And those measures are not always simple or transparent. In my opinion CSRF stifles innovation on the web. Because cross-domain requests cannot be trusted, even if they appear to be authenticated, web applications have to be thoroughly locked down to reject any cross-origin traffic. There is a relatively new specification for making cross-origin XHR requests called Cross-Origin Resource Sharing (CORS). This specification could allow for exciting new mashups involving rich JavaScript applications and public APIs. Most modern browsers support CORS too - including Internet Explorer 8. But CORS is rarely used because it opens up a big hole that could be exploited by CSRF. Existing CSRF countermeasures rely on limiting XHR requests to the same-origin policy. For most web developers the risk is too great to justify experimenting with new technology. The way to make the web a safer place is to switch to authentication mechanisms that provide strong protection against CSRF at the most basic level. The key is to choose a mechanism that is controlled by the web application, not the browser. The web browser has no way of distinguishing legitimate requests from forged ones - it will attach cookies to both. On the other hand, application code can be written to be smarter. There are many authentication schemes that would work well. I lean toward OAuth 2.0. OAuth has some nice advantages: it is standardized; there are numerous server implementations; and the simplest form of the OAuth 2.0 draft specification is pretty easy to implement. In a traditional OAuth setup there are three parties: the authorization server / resource server, the client and the resource owner. Through a series of steps the resource owner, typically a user working through a web browser, submits a password to the authorization server and the authorization server issues an access token to the client. You can read more about the OAuth protocol flow on the OAuth 2.0 web site. When applying OAuth to session authentication the picture becomes simpler: the browser acts as both the resource owner and the client; so some of the indirection of three-legged OAuth can be skipped. Instead, a web application can use a protocol flow that the OAuth 2.0 specification calls Resource Owner Password Credentials in which the user enters her password into a login form, the password is submitted to the application server directly, and the server responds to that request with an access token. You can think of this as “two-legged” OAuth. In both the two- and three-legged flows requests are signed by adding an “Authorization” header with one of two possible formats. In the bearer scheme the authorization header value is just the access token that was given to the client. For example: GET /resource HTTP/1.1 Host: server.example.com Authorization: Bearer vF9dft4qmT The HMAC scheme is a bit more complicated: in that case the client is given an access token id in addition to the token itself and the authorization header includes the token id and an HMAC-signed hash of the request URL, the request method, a nonce, and possibly a nested hash of the request body. The OAuth access token is used as the key in the HMAC algorithm. POST /request HTTP/1.1 Host: example.com Content-Type: application/x-www-form-urlencoded Authorization: MAC id="jd93dh9dh39D", nonce="273156:di3hvdf8", bodyhash="k9kbtCly0Cly0Ckl3/FEfpS/olDjk6k=", mac="W7bdMZbv9UWOTadASIQHagZyirA=" hello=world%21 The advantage of the HMAC scheme is that it can provide some protection against MITM attacks even if signed requests are not encrypted with HTTPS. I propose a design in which the browser submits credentials from a login form to the server via XHR, gets an access token back, and uses that access token to sign subsequent requests. Full page requests and form posts are difficult to sign with OAuth - hyperlinks and form tags do not provide a way to specify an “Authorization” header. So OAuth-signed requests would probably be limited to XHR. The browser could store the OAuth access token in a persistent client-side store to give the user an experience that is indistinguishable from a cookie-based application - but that is more secure. It is entirely possible for JavaScript code running in a web browser to sign requests with HMAC. There are pure JavaScript implementations available of many cryptographic functions, including SHA-1 and SHA-256, which are the hash functions that are used for OAuth HMAC signing. However, if your application uses HTTPS to protect every request then the simpler bearer scheme is entirely sufficient. In this design form posts would be eliminated. Instead form data would be serialized in JavaScript and submitted using Ajax. That way all requests that produce side-effects would be channeled through OAuth-signed XHR. I am not suggesting eliminating form tags though - form tags are an essential tool for semantic markup and for accessibility. I recommend that JavaScript be used to intercept form “submit” events. There are a couple of options for dealing with full page loads. One possibility is to not require any authentication for requests for HTML pages and to design your application so that HTML responses do not include any protected information. Such an application would serve pages as skeletons, with empty areas that to be filled in with dynamic and protected content after page load using Ajax. The dynamic responses could be HTML fragments that are protected by OAuth, or they could be JSON responses that are rendered as HTML using client-side templates. Facebook uses a process like this which they call BigPipe. Facebook’s rationale for BigPipe is actually performance, not security. In my opinion the BigPipe approach gives a best-of-both-worlds blend of performance and security. Plus, it lets you put caching headers on full page responses, even in apps with lots of dynamic content. A downside of BigPipe is that content that is loaded via Ajax generally cannot be indexed by search engines. Google’s recently published specification for making Ajax applications crawlable may provide a solution to that problem. Or you might choose to use the BigPipe approach everywhere in your application except for publicly accessible pieces of content. Another way to handle full page loads would be to continue using cookie authentication for HTML resources. HTML responses are less vulnerable to CSRF snooping than JSON because HTML is not executable in script tags. In this case you should still require OAuth signing on requests for JSON resources and on any requests that could produce side-effects. But allowing cookie authentication on non-side-effect-producing GET requests for HTML resources should be safe. Using JavaScript to manage access tokens rather than relying on a built-in browser function makes CSRF attacks impractical. A malicious third-party site can no longer rely on browsers to automatically attach authentication credentials to requests that it triggers. Client-side storage implementations are generally protected by the same origin policy - so only code running in your application can retrieve an access token and produce an authenticated request. And if you combine OAuth with HTTPS then you are also protected against MITM attacks. A drawback is that you lose the XSS protection that the “httpOnly” cookie flag provides with cookie authentication. An application that uses OAuth will have to use other methods to block XSS. But in my opinion there are better options for dealing with XSS than there are for dealing with CSRF. By consistently sanitizing user-generated content you can effectively block XSS at the presentation layer of your application. That would be necessary anyway, since “httpOnly” only prevents XSS-based privilege escalation attacks and by itself does not prevent other XSS shenanigans. To track a session using OAuth applications will need some way to store access tokens for the duration of a user’s session. There are various ways to do that: In the simplest case you can store the token in memory by assigning it to a JavaScript variable. This might be useful in a single page application. The user will have to log in again if she goes to another page or opens your app in a new window. localStorage can be used to store a token so that is persistent even if the user closes and re-opens the browser. Data stored in localStorage is available to all windows on the same domain. You will probably want to include a hook to clear local storage when the user logs out of your application. sessionStorage works like localStorage, except that data is only accessible from the same window that stored it and the whole store for a given window is wiped when the user closes that window. So the user does not have to log in again if she goes to another page; but she does have to log in again if she opens your app in a new window. sessionStorage can be a more secure option than localStorage - especially on a shared or a public computer. If you decide to use a storage option that does not expire automatically when the browser is closed I suggest including a “remember me” checkbox in your login form and using sessionStorage instead when the user does not check that box. Although I have been arguing that cookies are not the best option for authentication, storing an access token in a cookie works just fine. The key is that the server should not consider the cookie to be sufficient for authentication. Instead it should require that the access token be copied from the cookie value into an OAuth header. For the cookie option to be secure you should set the “secure” flag so that it is not transmitted over a connection that could be read via a MITM attack. You should not set the “httpOnly” flag because the cookie needs to be accessible from JavaScript. A nice advantage of the cookie option is that users have been trained that they can delete cookies to reset a session. On the other hand, most users do not know about localStorage and most browsers do not provide an obvious way to clear localStorage. So the cookie option is likely to conform best to user expectations. Cookies can also be configured to expire when the browser is closed or to persist for a long period of time. Other options include IndexedDB, which is a more sophisticated store that is similar to localStorage, Flash cookies, and userData in IE. There is a good summary of client-side storage implementations and how to use them on Dive Into HTML5. Or if you want a pre-built solution that avoids most cross-browser headaches you can use PersistJS or a similar tool. Web applications that rely on cookie authentication can often be designed to degrade gracefully, so that if JavaScript is disabled or is not available the application will still work. With OAuth that is not possible. I can imagine this being a major objection to ditching cookie authentication. Some people prefer to disable JavaScript for security or for privacy reasons. Many of the more basic mobile and text-only web browsers do not support JavaScript. And in the past screen readers have not handled JavaScript-driven web apps well. In my opinion the requirement that JavaScript be enabled to use an application is generally worthwhile. Mobile browsers that do support JavaScript are rapidly pushing out those that do not. Text-only browsers will have to start supporting JavaScript sooner or later to keep up. The people who designed your web browser took great care to ensure that your security and privacy are protected even when JavaScript is enabled. Screen readers are much better than they used to be at making JavaScript-driven web sites accessible. You should consider your target audience, your application requirements, and your security needs and decide for yourself whether dropping the noscript option is the right choice for your application. No security protocol is bulletproof. Do lots of research and use common sense whenever you are working on an application that needs to be secure. Image credits: The OAuth logo by Chris Messina is licensed under the Creative Commons Attribution-Share Alike 3.0 Unported license. Other images used in diagrams are from the Open Clip Art Library and are in the public domain. tags: osb11]]> When. Recently I gave a talk at Portland Ruby Brigade meeting on CouchDB, a document-oriented database. I thought I would share my notes from that talk. In some respects this was a followup to an earlier talk that Igal Koshevoy gave comparing various post-relational databases. Igal also wrote some additional notes on my talk. In summary, some of the distinguishing features of CouchDB are: More detailed information on all of the above points can be found in CouchDB’s technical overview. Some of the downsides: I also talked about some of the high-level interfaces to CouchDB that are available for Ruby. As ActiveRecord did for SQL, the idea behind these libraries is to abstract away as much of the database behavior as possible without sacrificing the powerful features that CouchDB provides. The term “ORM” does not quite apply to CouchDB because it is not relational. The term I am using for the time being is “object-document mapping”. The code examples I showed are all available in a gist. Sadly I don’t think I can say that any of these libraries are production ready as is. If you use one expect to write some patches as you go. That said I think that all three show some exciting potential. And they all provide a better starting point for your CouchDB project than writing your own ODM or using a low-level interface. I plan to submit a few patches to CouchPotato as I get to know it better. With some more help I imagine we can turn one or more of these interfaces into a nicely polished library. The winner in my mind is CouchPotato. The philosophy behind CouchPotato is to do things differently than ActiveRecord does. Though it does borrow features from ActiveRecord, for example dirty attribute tracking, life cycle callbacks, and validations. The biggest innovation in CouchPotato in my opinion is the extensible system for defining views. As with the other libraries, support for declaring simple views is built in: class User include CouchPotato::Persistence property :name view :by_name, :key => :name end But similar shortcuts for more sophisticated types of views can be added by creating new view classes and passing a :type option to the view declaration method. For example, it might be possible to declare views like this: class Invoice ... property :ordered_at, :type => Time property :items view(:total_sales, :type => :aggregate, :key => :ordered_at, :sum => 'items[].qty * items[].price_per_unit') view(:average_sale, :type => :aggregate, :key => :ordered_at, :average => 'items[].qty * items[].price_per_unit') end My runner-up is CouchRest. CouchRest is a widely used low-level interface to CouchDB. But it also includes a high-level interface called CouchRest::ExtendedDocument. A neat feature of this library is that you can declare a different database to use for each model. It also supports declaring simple views with dynamic methods for querying those views: class Comment < CouchRest::ExtendedDocument property :post_id view_by :post_id end Comment.by_post_id :key => 'foo' CouchFoo is another strong contender. The goal of CouchFoo is to provide an API that is as close to ActiveRecord’s as possible. The project may even be porting a large amount of ActiveRecord code for this purpose. The intention is to make migrating to CouchDB as painless as possible. An interesting feature is that CouchFoo will create views automatically on demand. For example this query will automatically create a view that indexes Post documents by title: post = Post.find(:first, :conditions => { :title => "First Post" }) On-demand view creation could be convenient. But my instinct is that it is a bad thing to do. Adding a new view to a large database comes with an expensive initial build step. It seems to me that that type of thing should only be done explicitly. I mentioned a case where one team found that they got great performance improvements by pushing some data reporting tasks from a SQL database to CouchDB. That story was written up in a series of blog posts. An explanation of why this team went with CouchDB is presented in part 3 of that series. There is a list on the CouchDB Wiki of sites that are currently using CouchDB in production. A couple of notable examples not on the list that have used CouchDB are the BBC and possibly Meebo. Of note for Ubuntu fans: Canonical is working on a project called Desktop Couch which will be installed by default in Karmic Koala. The idea is to create a portable store for stuff like browser bookmarks, contacts, music playlists and ratings, and so on. There are already plugins to allow Firefox and Evolution to store bookmarks and contact data in CouchDB. Desktop Couch will provide CouchDB databases for every user to store this information, and will include tools for “pairing” computers on the same network. Desktop Couch will use CouchDB’s built-in replication features to automatically replicate data between paired computers; so you will get the same bookmarks and contacts on all of your computers. This will all integrate with Ubuntu One too. Desktop Couch will be able to replicate your data to Ubuntu One’s servers so that you can replicate that data back down to computers on a different network. The best resource for learning more about CouchDB is probably CouchDB: The Definitive Guide. This is a book that J. Chris Anderson, Jan Lehnardt, and Noah Slater are writing for O’Reilly. It is still a work in progress, but the latest draft is available online. For API reference my source is the CouchDB Wiki. Finally, as the CouchDB developers will tell you, the most up-to-date reference for the latest CouchDB features is the included test suite. This is a set of tests written in JavaScript that you can run from CouchDB’s web interface to verify that your build of the latest SVN checkout is working correctly. These tests are run externally and access the database server via its HTTP API; so you don’t have to know any nitty gritty Erlang stuff to understand what the tests are doing. When any changes to the API are introduced this test suite is updated accordingly.]]> Just.
http://feeds.feedburner.com/hallettj
CC-MAIN-2018-17
refinedweb
31,203
64.51
Created on 2011-03-17 15:51 by John.Didion, last changed 2019-11-07 02:24 by iforapsy. Just as some options are mutually exclusive, there are others that are "necessarily inclusive," i.e. all or nothing. I propose the addition of ArgumentParser.add_necessarily_inclusive_group(required=True). This also means that argparse will need to support nested groups. For example, if I want to set up options such that the user has to provide an output file OR (an output directory AND (an output file pattern OR an output file extension)): output_group = parser.add_mutually_exclusive_group(required=True) output_group.add_argument("-o", "--outfile") outdir_group = output_group.add_necessarily_inclusive_group() outdir_group.add_argument("-O", "--outdir") outfile_group = outdir_group.add_mutually_exclusive_group(required=True) outfile_group.add_argument("-p", "--outpattern") outfile_group.add_argument("-s", "--outsuffix") The usage should then look like: (-o FILE | (-O DIR & (-p PATTERN | -s SUFFIX)) I think this is a great suggestion. Care to work on a patch? I am subscribing to this idea as I've just fall into such use case where I need it. I would like to submit a patch, but I still have difficulties to understand argparse code not much spare time to spent on this. The. Regarding a usage line like: (-o FILE | (-O DIR & (-p PATTERN | -s SUFFIX)) The simplest option is to just a custom written 'usage' parameter. With the existing HelpFormatter, a nested grouping like this is next to impossible. It formats the arguments (e.g.'-O DIR'), interleaves the group symbols, and then trims out the excess spaces and symbols. is a request to allow overlapping mutually_exclusive_groups. It loops on the groups, formatting each. It would be easier with that to format several different types of groups, and to handle nested ones. What would it take to convert a usage string like that into a logical expression that tests for the proper occurrence (or non-occurrence) of the various arguments. It might, for example be converted to exc(file, inc(dir, exc(pattern, suffix))) where 'exc' and 'inc' are exclusive and inclusive tests, and 'file','dir' etc are booleans. And what would be the error message(s) if this expression fails? I can imagine a factory function that would take usage line (or other expression of groupings), and produce a function that would implement a cross_test (as outlined in my previous post). It would be, in effect, a micro-language compiler. This. This. python, argparse: enable input parameter when another one has been specified $ python myScript.py --parameter1 value1 $ python myScript.py --parameter1 value1 --parameter2 value2 $ python myScript.py --parameter2 value2 # error This is an example where a 'mutually inclusive group' wouldn't quite do the job. The proposed answers mostly use a custom Action. I'd lean toward an after-the-parse test of the namespace. With the patch I proposed this could be implemented with: a1 = parser.add_argument("--parameter1") a2 = parser.add_argument("--parameter2") def test(parser, seen_actions, *args): if a2 in seen_actions and a1 not in seen_actions: parser.error('parameter2 requires parameter1') parser.register('cross_tests', 'test', test) One poster on that thread claimed that the use of 'a1 = parser.add_argument...' is using an undocumented feature. The fact that `add_argument` returns an `action` object, should be illustrated in the documentation, and may be explicitly noted. I'll have to review the documentation to see if this is the case. The addition of a simple decorator to the 'ArgumentParser' class, would simplify registering the tests: def crosstest(self, func): # decorator to facilitate adding these functions name = func.__name__ self.register('cross_tests', name, func) which would be used as: @parser.crosstest def pat_or_suf(parser, seen_actions, *args): if 2==len(seen_actions.intersection([a_pat, a_suf])): parser.error('only one of PATTERN and SUFFIX allowed') A. A. I. asks about implementing a 'conditionally-required-arguments' case in `argparse`. The post-parsing test is simple enough: if args.argument and (args.a is None or args.b is None): # raise argparse error here I believe the clearest and shortest expression using Groups is: p = ArgumentParser(formatter_class=UsageGroupHelpFormatter) g1 = p.add_usage_group(kind='nand', dest='nand1') g1.add_argument('--arg', metavar='C') g11 = g1.add_usage_group(kind='nand', dest='nand2') g11.add_argument('-a') g11.add_argument('-b') The usage is (using !() to mark a 'nand' test): usage: issue25626109.py [-h] !(--arg C & !(-a A & -b B)) This uses a 'nand' group, with a 'not-all' test (False if all its actions are present, True otherwise). Attached.) Another issue requesting a 'mutually dependent group' Just voicing my support for this. I was also looking for a solution on StackOverflow and ended up here.
https://bugs.python.org/issue11588
CC-MAIN-2019-47
refinedweb
751
51.44
>>: (Score:3) The solution is just to attach a hub. It isn't meant to be a production SBC. They can't meet their price point by adding more connectors to a larger board. Re:Open source platform for Voice control (Score:5, Interesting) My experience is the rasp pi just isn't stable enough in that kind of configuration for serious use (other experiences may vary). When you get higher USB traffic or eth traffic, it fails, and when it fails spectacularly and usually takes the board down with it. There are better boards out there are a slightly higher price range that can handle this no problem. Don't get me wrong, I love the rasp pi and I think it's awesome what they've done and more importantly what they've started (this kinda ultra cheap computer was a dream just a little while ago, now you've got a wide variety, and I believe the rasp pi was directly responsible for this). The reality is however that a good number of alternatives have popped up at a variety of price points, many better suited for a lot of the purposes we originally were salivating over for the pi. Definitely worth looking around before trying to force a pi to do it. Re: (Score:2) Yikes! Terrible grammar, even for me. Sorry folks :( Re: (Score:2) isn't mono already open source cross platform and run on the same platforms as espeak including rasp pi... system.speech namespace... [go-mono.com] Re:Open source platform for Voice control (Score:4, Informative) Sounds like a crap powersupply. Re: (Score:2). Re: (Score:3) Compiled on my system, libsphinxbase.a is 298KB after being stripped, and the shared library is 302KB. That sounds like it's pretty far out of the size range that you're looking for. Re: (Score:2) No, I don't magically know what they mean given no context. Thats the point. It won't run on any device, hell, it won't even run on any RaspberryPi since ... some of the licenses for those libraries themselves are potentially conflicting. I'm not sure what magical fairy world 'any' device belongs to, but not a single one I can think of applies here. But hey, why let reality cloud your inner fanboy, eh? Re: (Score:2) ... with a RaspberryPi (Score:2) With a RaspberryPi you don't say? Quick, get a patent on this innovative technology that would be so mundane if it were implemented on a desktop machine running Debian or something. Re: (Score:1) Just don't use a USB mic ... unless you want the RaspberryPi's awesome USB hardware to randomly drop words on you. For the life of my I can't understand why people think using the RaspberryPi is a good idea. Its shit hardware, its not the cheapest, at best its one of many in its price range and its a steaming pile of shit hardware wise. For fucks sake, they can make a god damn camera add on but can't make freaking revision of the board that has FUNCTIONAL USB. Re: (Score:2) FWIW the USB and Ethernet problems are all Broadcom's fault for making shitty SoC. Re: (Score:2) Uh oh. (Score :( I don't even have to look (Score:2) interesting (Score:1) I find this very interesting. I was looking for an easy way of setting up always-on microphones with speech synthesis for intelligent home use. I didn't plan on using a Pi though, but a few of the always-on full blown linux pc I have around. Aziz, light! Exciting (Score:2) I really like the way that these types of programs are taking us. It's about time that my computer starts listening to me while I'm yelling at it! I've been using Blather [gitorious.org] myself, and really enjoy the results. Seems annoying (Score:2) After saying the trigger word, you have to pause .. that's a bit ridiculous and annoying .. I doubt this would catch on .. for it to catch on, it needs to allow you to say a continuous sentence without pausing. The latest chip from audience.com has this feature (called VoiceQ). Their chip is for phones, so it should be possible to implement the same technology in software on a desktop CPU. Not usable outside research (Score:1) jasper depends on the "CMU-Cambridge Statistical Language Modeling Toolkit V2" which is released under the condition that it will only be used for research purposes. Therefore, their setup can't be used for non-research purposes. I doubt that setting up my own home-automation system counts as research... Re: (Score:1)
https://hardware.slashdot.org/story/14/04/09/1432244
CC-MAIN-2016-40
refinedweb
790
72.97
- Defining Classes and Objects - Importing a Class - Instantiating Objects - Working with External Code Importing a Class You must import classes in ActionScript before you can construct objects and utilize methods, properties, and events of a class. Classes are imported at the beginning of the code, so unqualified class names can be used throughout the code. If a class is not imported, all references to a class need to be qualified. An example of using a qualified class name for constructing a MovieClip object would be as follows: var mc:MovieClip = new flash.display.MovieClip(); The import directive for a class allows the use of unqualified (or shortened) class names in the code without indicating the package each and every time, thus saving lots of typing. However, because the approach of this book is tailored to users who are new to ActionScript, all of the ActionScript code that you will construct is timeline based, which means you don’t have to import many of the classes that we use (Flash will automatically do this for us). If you were to take a class-based approach to ActionScript, or if you were a developer using Flex, then you would need to import all of the classes used in your code. So that you can become aware of what a more advanced ActionScript developer would do, and to help you see the big picture, I will include import statements whenever possible in the timeline, even though you don’t need to construct them. If you do need to import a class, you would use the import statement followed by the class package path and the subclass that you wish to import. To import classes: To import the DisplayObject, Graphics, and Shape subclasses of the flash.display class package, add the following ActionScript: import flash.display.DisplayObject; import flash.display.Graphics; import flash.display.Shape; These classes are required to construct a Shape object, draw the shape on the stage, fill and stroke it with methods of the Graphics class, and add it to the display list on the stage using methods of the DisplayObject class.
http://www.peachpit.com/articles/article.aspx?p=1246986&seqNum=2
CC-MAIN-2019-43
refinedweb
352
55.37
Hi all, huge noob here. Ive only ever used one scripting language prior to my jump, and these are my early days of C++, please excuse my ignorance. I have been reading the brilliant tuts on your site, and decided to register on the forums to try and find out a way to convert a long type var to a string. After reading the FAQs I found a solution which worked fine on its own, and highly delighted me. However: This hurled me into another problem which I cannot find the answer to at my present level of experience with C++. My problem is that when I tried to use the code I found in my own project it failed to output anything at all. I have stripped it down to its bare bones to demonstrate my problem, and hope someone can help me understand my error(s). std::cout<< "Hi World" << "\n"; shows nothing at all.std::cout<< "Hi World" << "\n"; shows nothing at all.Code: #include <iostream> #include <sstream> #include <string> #include <Windows.h> std::string IntToString ( int number ) { std::ostringstream oss; // Works just like cout oss<< number; // Return the underlying string return oss.str(); } int APIENTRY WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nCmdShow) { std::cout<< "Hi World" << "\n"; system("Pause"); return 0; } I would really appreciate any help.
http://cboard.cprogramming.com/cplusplus-programming/128440-no-output-std-cout-printable-thread.html
CC-MAIN-2015-18
refinedweb
223
70.53
#include <inlinenote.h> Detailed Description Describes an inline note. This class contains all the information required to deal with a particular inline note. It is instantiated and populated with information internally by KTextEditor based on the list of notes returned by InlineNoteProvider::inlineNotes(), and then passed back to the user of the API. - Note - Users of the InlineNoteInterface API should never create a InlineNote themselves. Maybe it helps to think of a InlineNote as if it were a QModelIndex. Only the internal KTextEditor implementation creates them. - Since - 5.50 Definition at line 50 of file inlinenote.h. Constructor & Destructor Documentation Constructs an inline note. User code never calls this constructor, since notes are created internally only from the columns returned by InlineNoteProvider::inlineNotes(), and then passed around as handles grouping useful information. Definition at line 327 of file ktexteditor.cpp. Member Function Documentation The font of the text surrounding this note. This can be used to obtain the QFontMetrics or similar font information. Definition at line 376 of file ktexteditor.cpp. The index of this note, i.e. its index in the vector returned by the provider for a given line Definition at line 381 of file ktexteditor.cpp. The height of the line containing this note. Definition at line 386 of file ktexteditor.cpp. The cursor position of this note. Definition at line 391 of file ktexteditor.cpp. The provider which created this note. Definition at line 366 of file ktexteditor.cpp. Returns whether the mouse cursor is currently over this note. - Note - This flag is useful when in InlineNoteProvider::paintInlineNote(). Definition at line 337 of file ktexteditor.cpp. The View this note is shown in. Definition at line 371 of file ktexteditor.cpp. Returns the width of this note in pixels. Definition at line 332 of file ktexteditor.cpp..
https://api.kde.org/frameworks/ktexteditor/html/classKTextEditor_1_1InlineNote.html
CC-MAIN-2019-13
refinedweb
301
52.66
💬 Water Meter Pulse Sensor This thread contains comments for the article "Water Meter Pulse Sensor" posted on MySensors.org. I get error on compiling. "exit status 1 call of overloaded 'set(volatile long unsigned int&)' is ambiguous" The following line gets red marked in Arduino IDE send(lastCounterMsg.set(pulseCount)); // Send pulsecount value to gw in VAR1 Compiles fine here in 1.6.12.. Running 1.6.11, will try and update. Should have said that I was trying to run it on a Node MCU 0.9. I can compile fine for Arduino Nano but not for Node MCU. Also I got another error now when I upgraded to 1.6.12. In file included from C:\Users\xxxxx\Documents\Arduino\libraries\MySensors-development/MySensors.h:337:0, from C:\Users\xxxxxxx\AppData\Local\Temp\untitled921979828.tmp\sketch_oct14a\sketch_oct14a.ino:44: C:\Users\xxxxxxx\Documents\Arduino\libraries\MySensors-development/core/MyMainESP8266.cpp:4:22: fatal error: Schedule.h: No such file or directory #include "Schedule.h" ^ compilation terminated. exit status 1 Error compiling for board NodeMCU 0.9 (ESP-12 Module).``` Please update NodeMCU in board manager to rc3. Hmm .. I can see the "overloaded 'set(volatile long unsigned int&)' is ambiguous" error here as well... I wonder why it behaves differently from Arduino... Works if you replace volatile unsigned long pulseCount = 0; with volatile uint16_t pulseCount = 0; Great! Thanks for the help Now I just need to figure out a good placement for it and get values to Domoticz. But this helped me a lot to get started. - vikram0228 last edited by It is not clear to me from the picture if the water meter pulse output leads go to gnd and VCC or VCC and DO? The water-meter pulse output is only two leads. I am going to MySensors with great hope on this water meter sensor. I have the Vera gateway working fine. Now the test with my first and most important sensor! Thanks in advance @vikram0228 I haven't built this node, but the pictures and the connections table on the page describes three leads. Do you have a different sensor? - vikram0228 last edited by Water Meters with pulse output have two leads. They generate a simple pulse. The MySensors circuit also should also work with two leads - just need to know which two. The three leads are for water meters with no pulse output and where you need an optical sensor to sense the moving wheel. Hi. Cant get my watersensor to send any values. I have debug enabled and it seems like it communicates fine with the gw but no flow data are beeing reported to the gw or the serial monitor. TSP:MSG:SEND 4-4-0-0 s=1,c=2,t=24,pt=0,l=0,sg=0,ft=0,st=ok: Anyone else experienced this problem? I wanted to operate my water pulse meter on batteries and also get the water flow. The original design had the following issues with that: - Incorrect flow calc: micros() was used to calculate the flow, however micros() wraps every 70 minutes which looks like a huge flow (which is then discarded in code) - Volume calc: millis() wraps every 50 days which is not handled correctly either -. We now simply calculate the number of pulses per minute and deduct the flow - I also had issued with the data transport reliability, so I added error counters (which show up on the Gateway as distance sensors) - I also wanted to provide a measurement counter to the gateway (that counts up each time a message is sent) - The sensor will reboot itself when too many errors occur So I modified the circuit of the IR sensor: - Assumption that the wheel of the water meter turns slowly (takes at least a few seconds to turn around) - We will wake up every 500 millisecond to turn on the IR LED connected to PIN 8. Pin 8 also powers the photo transistor that measures the reflection - I removed the power from the opamp circuit that is linked to the photo transistor - The voltage from the photo transistor is then read using an analog read on A1. Based on a threshold value we will deduct if the mirror on the water meter is in view - Pin 7 is connected to a learning switch which will turn the device in a specific mode and the min/max values on A1 are used to calculate the value of the threshold (which is then stored in the EEPROM) - After 30 seconds in learning mode, the new threshold is established and the LED on Pin 6 will show the actual on/off mirror signals, so you can see the pulses are correctly counted - switch back the DIP switch on Pin 7 to bring back normal mode - The circuit also contains the battery voltage sensor circuit (I am using a 1.5V battery and step up circuit). So the resistors used are 470k from + pole of battery to the A0 input and 1 M ohm from A0 to ground /** * * Version 1.2 - changed BM: using low power separate circuit for infra red on pin 8 + analog A1 * * ISSUES WITH ORIGINAL CODE * Incorrect flow calc: micros() was used to calculate the flow, however micros() is wraps every 70 minutes which looks like a huge flow (which is discarded) * Volume calc: millis() wraps every 50 days which is not handled correctly * * * MODIFIED CIRCUIT IR SENSOR * Assumption that the wheel of the water meter turns slowly (takes at least a few seconds to turn around) * We will wake up every second to turn on the IR LED (connected to PIN 8). Pin 8 also powers the photo transistor that measures the reflection * The voltage from the photo transistor is then read using an analog read on A1. Based on a treshold value we will deduct if the mirror is in view * Pin 7 is connected to a learning switch which will turn the device in continous mode and the min/max values on A1 are used to recalc the treshold * during a 30 second period. After this period the new treshold is established and the LED on Pin 6 will show the actual on/off mirror signals * * */ // BOARD: PRO MINI 3.3V/ 8Mhz ATMEGA328 8Mhz // Enable debug prints to serial monitor #define MY_DEBUG // Enable and select radio type attached #define MY_RADIO_NRF24 //#define MY_RADIO_RFM69 #define MY_NODE_ID 10 // hard code the node number #include <SPI.h> #include <MySensors.h> #define SENSOR_POWER 8 // pin that will provide power to IR LED + sense circuit #define IR_SENSE_PIN A1 // input for IR voltage #define BATTERY_SENSE_PIN A0 // select the input pin for the battery sense point #define LEARN_SWITCH_PIN 7 // switch (SW1 on battery module) to turn on learning mode (low==on) #define LEARN_LED_PIN 6 // LED feedback during learning mode (LED on battery module) #define LEARN_TIME 30 // number of seconds we will keep learn loop #define PULSE_FACTOR 1000 // Nummber of blinks per m3 of your meter (One rotation/1 liter) #define MAX_FLOW 80 // Max flow (l/min) value to report. This filters outliers. #define CHILD_ID 1 // Id of the sensor child (contains 3 subs: V_FLOW, V_VOLUME, VAR1) #define CHILD_PINGID 2 // ID of ping counter #define CHILD_ERRID 3 // ID of error counter #define CHECK_FREQUENCY 500 // time in milliseconds between loop (where we check the sensor) - 500ms #define MIN_SEND_FREQ 60 // Minimum time between send (in multiplies of CHECK_FREQUENCY). We don't want to spam the gateway (30 seconds) #define MAX_SEND_FREQ 1200 // Maximum time between send (in multiplies of CHECK_FREQUENCY). We need to show we are alive (600 sec/10 min) #define IR_ON_SETTLE 2 // number of milliseconds after we turned on the IR LED and we assume the receive signal is stable (in ms) #define EE_TRESHOLD 10 // config addresses 0 + 1 used for treshold from learning (loadState() returns only uint8 value) #define TRESHOLD_MARGIN 3 // additional margin before we actually see a one or zero #define RESETMIN 5 // number of cycle times (either 30 sec of 10 min) we consistently need to have transmission errors before we perform hard reset MyMessage volumeMsg(CHILD_ID,V_VOLUME); // display volume and flow on the same CHILD_ID MyMessage flowMsg(CHILD_ID,V_FLOW); // flow MyMessage lastCounterMsg(CHILD_ID,V_VAR1); MyMessage pingMsg(CHILD_PINGID,V_DISTANCE); // use distance to keep track of changing value MyMessage errMsg(CHILD_ERRID,V_DISTANCE); // use distance to keep track of changing value double ppl = ((double)PULSE_FACTOR / 1000.0); // Pulses per liter unsigned int oldBatteryPcnt = 0; // check if changed unsigned int minsendcnt = MIN_SEND_FREQ; // counter for keeping minimum intervals between sending unsigned int maxsendcnt = MAX_SEND_FREQ; // counter for keeping maximum intervals between sending unsigned int treshold = 512; // threshold value when to swap on/off for pulse unsigned long pulseCount = 0; // total volume of this pulse meter (value stored/received on gateway on pcReceived) unsigned long oldPulseCount = 0; // to see if we have received something boolean pcReceived = false; // received volume from prior reboot boolean onoff = false; // sensor value above/below treshold unsigned int intervalcnt = 0; // number of cycles between last period (for flow calculation) double flow = 0; // maintain flow double oldflow = 0; // keep prior flow (only send on change) unsigned int learntime=LEARN_TIME*2; // timer for learning period unsigned int learnlow = 1023; // lowest value found during learning unsigned int learnhigh = 0; // highest value found during learning boolean learnsaved = false; // have saved learned value unsigned long pingcnt = 0; unsigned long errcnt = 0; // error count unsigned int errcnt2 = 0; // error counter set to 0 when sending is ok void(* resetFunc) (void) = 0;//declare reset function at address 0 (for rebooting the Arduino) void setup() { // make sure a few vars have the right init value after software reboot pingcnt = 0; pcReceived = false; pulseCount = oldPulseCount = 0; // setup hardware pinMode(SENSOR_POWER, OUTPUT); digitalWrite(SENSOR_POWER, LOW); pinMode(LEARN_SWITCH_PIN, INPUT_PULLUP); pinMode(LEARN_LED_PIN, INPUT); // default is input because this pin also has SW2 of battery block // Fetch last known pulse count value from gateway request(CHILD_ID, V_VAR1); // Fetch threshold value from EE prom treshold = readEeprom(EE_TRESHOLD); if (treshold<30 || treshold>1000) treshold = 512; // wrong value in EEprom, take default Serial.print("Treshold: "); Serial.println(treshold); // use the 1.1 V internal reference for the battery and IR sensor #if defined(__AVR_ATmega2560__) analogReference(INTERNAL1V1); #else analogReference(INTERNAL); #endif analogRead(IR_SENSE_PIN); // settle analogreference value wait(CHECK_FREQUENCY); // wait a bit } void presentation() { // Send the sketch version information to the gateway and Controller sendSketchInfo("Water Meter", "1.2"); // Register this device as Waterflow sensor present(CHILD_ID, S_WATER); present(CHILD_PINGID, S_DISTANCE); present(CHILD_ERRID, S_DISTANCE); } void loop() { if (digitalRead(LEARN_SWITCH_PIN)==LOW) { pinMode(LEARN_LED_PIN, OUTPUT); digitalWrite(SENSOR_POWER, HIGH); intervalcnt = 0; learn_loop(); } else { learntime=LEARN_TIME*2; learnlow = 1023; learnhigh = 0; pinMode(LEARN_LED_PIN, INPUT); normal_loop(); } } void learn_loop() { // will run into this loop as long as we are learning wait(500); unsigned int sensorValue = analogRead(IR_SENSE_PIN); Serial.print("IR: "); Serial.print(sensorValue); if (learntime>0) { // still learning learntime--; learnsaved = false; digitalWrite(LEARN_LED_PIN, !digitalRead(LEARN_LED_PIN)); // blink led if (sensorValue < learnlow) { learnlow = sensorValue; Serial.println(" Lowest"); } else if (sensorValue > learnhigh) { learnhigh = sensorValue; Serial.println(" Highest"); } else Serial.println(); } else { if (!learnsaved) { treshold = (learnhigh + learnlow)/2; Serial.print("Treshold: "); Serial.println(treshold); storeEeprom(EE_TRESHOLD, treshold); } learnsaved = true; // just display using LED digitalWrite(LEARN_LED_PIN, sensorValue>treshold); Serial.println((sensorValue>treshold ? " on" : " off")); } } void normal_loop() { unsigned long start_loop = millis(); // to allow adjusting wait time intervalcnt++; // we start doing a measurement digitalWrite(SENSOR_POWER, HIGH); wait(IR_ON_SETTLE); unsigned int sensorValue = analogRead(IR_SENSE_PIN); digitalWrite(SENSOR_POWER, LOW); #ifdef MY_DEBUG_DETAIL Serial.print("IR: "); Serial.println(sensorValue); #endif boolean nowvalue = onoff; if (onoff && (sensorValue<treshold-TRESHOLD_MARGIN)) nowvalue = false; if (!onoff && (sensorValue>treshold+TRESHOLD_MARGIN)) nowvalue = true; if (nowvalue != onoff) { // we have a pulse, only count on upwards pulse onoff = nowvalue; if (onoff) { pulseCount++; #ifdef MY_DEBUG Serial.print("p: "); Serial.println(pulseCount); #endif } } // Only send values at a maximum frequency or woken up from sleep if (minsendcnt>0) minsendcnt--; if (maxsendcnt>0) maxsendcnt--; // send minimum interval when we have pulse changes or if we had some flow the prior time or send on timeout if ((minsendcnt==0 && (pulseCount != oldPulseCount)) || (minsendcnt==0 && oldflow != 0) || maxsendcnt==0) { if (!pcReceived) { //Last Pulsecount not yet received from controller, request it again Serial.print("Re-request var1 .."); request(CHILD_ID, V_VAR1); // Prevent flooding the gateway with re-requests,,, wait at least 1000 ms for gateway (cannot be sleep or smartSleep wait(2*CHECK_FREQUENCY); return; } minsendcnt = MIN_SEND_FREQ; maxsendcnt = MAX_SEND_FREQ; pingcnt++; sensorValue = analogRead(BATTERY_SENSE_PIN); int batteryPcnt = sensorValue / 10; // 1M, 470K divider across battery and using internal ADC ref of 1.1V // Sense point is bypassed with 0.1 uF cap to reduce noise at that point // ((1e6+470e3)/1e6)*1.1 = Vmax = 1.67 Volts // 1.67/1023 = Volts per bit = 0.00158065 Serial.print("Battery %: "); Serial.println(batteryPcnt); if (oldBatteryPcnt != batteryPcnt) { sendBatteryLevel(batteryPcnt); oldBatteryPcnt = batteryPcnt; } double volume = ((double)pulseCount/((double)PULSE_FACTOR)); flow = ((double) (pulseCount-oldPulseCount)) * (60000.0 / ((double) intervalcnt*(double) CHECK_FREQUENCY)) / ppl; // flow in liter/min #ifdef MY_DEBUG Serial.print("pulsecount:"); Serial.println(pulseCount); Serial.print("volume:"); Serial.println(volume, 3); Serial.print("l/min:"); Serial.println(flow); #endif bool b = send(lastCounterMsg.set(pulseCount)); // Send pulsecount value to gw in VAR1 if (b) errcnt2=0; else { errcnt++; errcnt2++; } b = send(volumeMsg.set(volume, 3)); // Send volume (set function 2nd argument is resolution) if (b) errcnt2=0; else { errcnt++; errcnt2++; } b = send(flowMsg.set(flow, 2)); // Send flow value to gw if (b) errcnt2=0; else { errcnt++; errcnt2++; } b = send(pingMsg.set(pingcnt)); // ensure at least this var has a different value if (b) errcnt2=0; else { errcnt++; errcnt2++; } b = send(errMsg.set(errcnt2+((float) errcnt2/100),2)); // ensure we always send error count if (b) errcnt2=0; else { errcnt++; errcnt2++; } oldPulseCount = pulseCount; intervalcnt = 0; oldflow = flow; if (errcnt2>= (5*RESETMIN)) { Serial.println("Reset"); wait(300); resetFunc(); //call reset to reboot the Arduino } } // calculate how long it took to process all of this. then go to sleep for the remaining period unsigned long end_loop = millis(); if (end_loop - start_loop < CHECK_FREQUENCY) sleep(CHECK_FREQUENCY - (end_loop > start_loop ? end_loop - start_loop : 0)); } void receive(const MyMessage &message) { if (message.type==V_VAR1) { unsigned long gwPulseCount=message.getULong(); pulseCount += gwPulseCount; oldPulseCount += gwPulseCount; flow=oldflow=0; Serial.print("Received last pulse count from gw:"); Serial.println(pulseCount); pcReceived = true; } } void storeEeprom(int pos, int value) { // function for saving the values to the internal EEPROM // value = the value to be stored (as int) // pos = the first byte position to store the value in // only two bytes can be stored with this function (max 32.767) saveState(pos, ((unsigned int)value >> 8 )); pos++; saveState(pos, (value & 0xff)); } int readEeprom(int pos) { // function for reading the values from the internal EEPROM // pos = the first byte position to read the value from int hiByte; int loByte; hiByte = loadState(pos) << 8; pos++; loByte = loadState(pos); return (hiByte | loByte); } Great work @bart59 ! Do you have any indication on how long battery life you will get with this setup? @mfalkvidd - I did measure the average current consumption at the time, but I not remember the exact value. I believe it was well below the 0.5 mA. The sensor has been up and running on the same single 1.5V AA battery for 30 days now and the batt percentage still shows 93%. I hope this is not off topic but I'm trying to read our gas meter - but....I cannot use a photo sensor or a hall sensor or a reed switch (the meter is outside and there is no magnet in it). I was able to get some good data using a magnetometer () using an arduino. But I tink from what I am told is the arduino isn't big enough to handle the code I need to use to change the data (x axis, y axis, z axis) into a pulse but will work on a pi. My question is am I missing something (hardware guy, not software)? Can I use a Pi for a sensor (it has the inputs and room), all the code on this site is for arduinos. Could I have the Pi output a pulse to an arduino? Am I over thinking this? @dpcreel. I would be surprised the Arduino could not handle the HMC5883L magnetometer from Sparkfun. The I2C protocol is natively supported and you only need to analyse numbers coming from the 3-Axis to decide when the wheels inside the gas meter turn. I think the position of the sensor will be very critical, but the code should not be too complex. Arduino's are typically limited in handling much data (there is only 2000 bytes of RAM in the ATmega328), but your code should not need much RAM space. The program size can be 32 KB which should be enough. If you want to go for the PI, there are I2C libraries out there you could use and I would then bypass the Mysensors gateway alltogether and connect an ethernet cable to the PI and use the MQTT protocol to talk to your home controller. regards Bart @bart59 The Arduino works fine with the HMC5883L, I got some good data from it and was able to "see" the gas meter movements very well. I am not able to write code (hardware guy) to change this data to a pulse for MySensors or whatever it needs. I just want to be able to read my gas meter with the HMC5883L. I did find some code in python that works on the pi, that's why I mentioned it. I'm a hack at software. Hi I am trying to use the subject code with pulse water meters and hope someone can help to figure out what needs to be adjusted to get more accurate data. My setup: Gateway ESP8266 (NodeMCU) + NRF24 -> Connected to Domoticz Sensor node: Arduino Uno + NRF24 Default codes from Build. Test sensors so far work great. Task: Need to connect Siemens WFK2 water meters (four of them actually) with pulse outputs (2 line). According to data sheet (link text) there are two types: reed output or NAMUR. To start with, I connected the reed output of the water meter via 10k resistor to +5V, GND and D3. Again, according to data sheet, for every 10l the water meter should give an impulse (e.g. connect the switch). Taking this into account I have adjusted pulse factor to 100 and based on Nominal Flow Rate (Max Flow Rate impossible in my case) limited Max Flow to 25 l/min. This setup works, but I definitely get wrong flow values (e.g. with constant flow of 6l/min serial monitor and domoticz report anything between 12-15l/min) and also wrong water usage m3 and litre usage in Domoticz. When trying to debug, found out following behaviour (must be connected to Pulse length an Qn from data sheet IMHO): with each turn it indeed switches on, e.g. shortens the contacts which generates pulse for the sensor, however it takes up to 2-4 litres until switch is in the off state. As a result you might have a situation when meter switches on, one closes the tap, and the signal is on for minutes/hours until tap is again opened and 2-4 litres have been used, after which signal will switch off. Do I understand correctly that the debouncer which should take care of similar situations is not ready for this? thanks in advance for support Hi Aram The original code from the mysensors site does not handle your situation very well (indeed because the switch staying on or off for a long time). You can use my code (see my post further up this discussion). In my case I have a pulse every 1 liter. In your case you only have 1 pulse every 10 liters, which means you have to take a much longer period to calculate the flow correctly. Basically you have to set MIN_SEND_FREQ to a higher value. The flow is calculated based on the number of pulses in a given time period. Example: with 6 l/min you have to calculate this value only once every 5 minutes (=30 liter = 3 pulses from your Siemens meter) instead of every 30 seconds as I do. So if MIN_SEND_FREQ = 600 (every 5 minutes) your flow is calculated as: flow = ((double) (pulseCount-oldPulseCount)) * (60000.0 / ((double) intervalcnt*(double) CHECK_FREQUENCY)) / ppl; In the example above (pulseCount-oldPulseCount) = 3 pulses ppl = 0.1 intervalcnt = MIN_SEND_FREQ = 600 CHECK_FREQUENCY = 500 ==> flow is 6 l/min regards Bart bart59, thanks for quick reply. I will try to adjust MIN_SEND_FREQ and use your code. however, if I understand correctly, with the current logic used its impossible to avoid misinterpretations of pulses in case of very very long on or off state. It will approximate the flow rate to more correct value during usage of water (this is good enough) and should report total usage somehow correctly (this one I would better get as precise as possible). I wonder if the code will capture the correct number of pulses in the case of very long on state. BTW, I was not able to find a readily available sketch to connect NAMUR output, which is basically 5kOhm off state and 1.5795 kOhm on state. I believe, I will have to calculate required pull up resistance to get a proper voltage divider for 5\3.3v, right? My code basically measures the time between two upward pulses. You can modify the code to also count the downward pulses. The net effect is that you will get a count every 5 liter (on average), but if there is no flow, the first pulse will always be off by 1-4 liter because you do not know how far the rotation is completed. On NAMUR: you can actually use my code here too: I use analog input A1 to measure the voltage on the infra red sensor (which varies between 0 and 1.1 Volt). During the learn mode (set with a seaprate DIP switch) the code measures the input voltage for a period of 30 seconds while you turn open the water tap (you may want to increase the timing in your case) and then calculates the average between the lowest and highest voltage as the currect point there is a 1 or 0 coming from the pump (in my case it is an IR LED that is reflecting from a mirror into a photo sensor and the position of the mirror may change - resulting in different voltages). regards Bart - Curtis Dobrowolski last edited by Would anyone be able to help me get the hall sensor to work to work directly connected to an ESP8266 MQTT gateway? I was able to created the MQTT gateway, appended this sketch to the MQTT gateway sketch and connect the hall sensor DO to D12 (D3 is occupied), but when I subscribe to my mosquitto server no values are published. I am able to see the prefixes and they get published every 20 seconds as expected, but there are no sensor values. I plan on using this with home assistant, incase that helps with the final setup. If anyone has any recommendations it would be greatly appreciated. - jagadesh waran last edited by Can you please roughly say - what is the current consumption overall - what is the current consumption when measuring a pulse - what is the current consumed when the data is transmitted @jagadesh-waran welcome to the MySensors community. The current consumption depends on which Arduino you are using and which radio you are using. Could you describe what your goal is? Maybe the page on battery power can be useful. - jagadesh waran last edited by @mfalkvidd im using mini at 8mhz with a 3V battery, No LDO and an ESP8266 I want to calculate the battery life say im using 3V 19000mah battery and if im consuming 100 gallons per day Could you please update me the life of the battery? Could you please update me the current consumptions at various intervals? @jagadesh-waran The easiest ways is to either measure the consumption on your devices, or look at the datasheets. I am trying this node. I have it set up. but I am having the same problem as Dirtbag. I am not getting any values. I debugged and I am getting 1 and 0 for my sensor output, so my sensor is working when I trigger it with a magnet. Does this work with MQTT gateway?? am I missing something. Communication is fine between by ESP gateway and my node.? Thanks ahead of time for any help with this. Hi. i'm having a strange problem using a arduino nano connecting a hall sensor to read my water meter. My water meter is dated from 1996 and i can't use the TCRT5000 sensor so i'm trying my luck with the hall sensor. My problem is that my arduino is always sending data.... even if i have the water turned off the most strange thing is that even when the arduino is not connected to the hall sensor it send's data. How can i fix this problem ? @mrc-core did you read this part of the instructions? You can also set the frequency that the sensor will report the water consumption by updating the SEND_FREQUENCY. The default frequency 3 times per minute (every 20 seconds). @mfalkvidd Yes i did but has you can see even when the hall sensor is not connected the arduino sends data and the water increases in the the gateway. I can work on the SEND_FREQUENCY and see if it fix this problem. Thnaks for the replay Have been working with the code and have found one strange thing. When my sensor sends data to the gateway "domoticz" the gateway sends a value to the sensor. The strange thing is that my arduino does not have any sensor connected and sow the data send is zero but my gateway sends akways a positive value and increases this value every time it sends data to the arduino. Even if i go to the arduino code and set the volume and pulseCount to 0 flash it to the arduino, load the value of zero to the gateway and then e flash the same code but this time i remove the volume and pulseCount to 0 the first time the arduino sends data to the gateway it always receive a value insted of zero since i dont have the hall sensor connected to the arduino. I'm using a arduino mini pro 3.3v on a easy pcb by soundberg81 and i have setup the digital pin2 to connect the hall sensor. Here's some log from my arduino: 0 MCO:BGN:INIT NODE,CP=RNNNA--,VER=2.1.1 3 TSM:INIT 4 TSF:WUR:MS=0 11 TSM:INIT:TSP OK 13 TSF:SID:OK,ID=1 14 TSM:FPAR 51 TSF:MSG:SEND,1-1-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 1032 TSF:MSG:READ,0-0-1,s=255,c=3,t=8,pt=1,l=1,sg=0:0 1037 TSF:MSG:FPAR OK,ID=0,D=1 2058 TSM:FPAR:OK 2059 TSM:ID 2060 TSM:ID:OK 2062 TSM:UPL 2065 TSF:MSG:SEND,1-1-0-0,s=255,c=3,t=24,pt=1,l=1,sg=0,ft=0,st=OK:1 2172 TSF:MSG:READ,0-0-1,s=255,c=3,t=25,pt=1,l=1,sg=0:1 2178 TSF:MSG:PONG RECV,HP=1 2181 TSM:UPL:OK 2182 TSM:READY:ID=1,PAR=0,DIS=1 2187 TSF:MSG:SEND,1-1-0-0,s=255,c=3,t=15,pt=6,l=2,sg=0,ft=0,st=OK:0100 2320 TSF:MSG:READ,0-0-1,s=255,c=3,t=15,pt=6,l=2,sg=0:0100 2327 TSF:MSG:SEND,1-1-0-0,s=255,c=0,t=17,pt=0,l=5,sg=0,ft=0,st=OK:2.1.1 2335 TSF:MSG:SEND,1-1-0-0,s=255,c=3,t=6,pt=1,l=1,sg=0,ft=0,st=OK:0 3517 TSF:MSG:READ,0-0-1,s=255,c=3,t=6,pt=0,l=1,sg=0:M 3526 TSF:MSG:SEND,1-1-0-0,s=255,c=3,t=11,pt=0,l=11,sg=0,ft=0,st=OK:Water Meter 3535 TSF:MSG:SEND,1-1-0-0,s=255,c=3,t=12,pt=0,l=5,sg=0,ft=0,st=OK:2.4.B 3544 TSF:MSG:SEND,1-1-0-0,s=1,c=0,t=21,pt=0,l=11,sg=0,ft=0,st=OK:Hall Sensor 3551 MCO:REG:REQ 3589 !TSF:MSG:SEND,1-1-0-0,s=255,c=3,t=26,pt=1,l=1,sg=0,ft=0,st=NACK:2 5596 TSF:MSG:SEND,1-1-0-0,s=255,c=3,t=26,pt=1,l=1,sg=0,ft=1,st=OK:2 5665 TSF:MSG:READ,0-0-1,s=255,c=3,t=27,pt=1,l=1,sg=0:1 5670 MCO:PIM:NODE REG=1 5673 MCO:BGN:STP 5677 TSF:MSG:SEND,1-1-0-0,s=1,c=2,t=25,pt=0,l=0,sg=0,ft=0,st=OK: 5683 MCO:BGN:INIT OK,TSP=1 6484 TSF:MSG:READ,0-0-1,s=1,c=2,t=25,pt=0,l=1,sg=0:0 Received last pulse count from gw:2 pulsecount:2 35686 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=25,pt=5,l=4,sg=0,ft=0,st=OK:2 volume:0.003 35694 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=35,pt=7,l=5,sg=0,ft=0,st=OK:0.003 l/min:2.05 65687 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=34,pt=7,l=5,sg=0,ft=0,st=OK:2.05 pulsecount:4 65695 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=25,pt=5,l=4,sg=0,ft=0,st=OK:4 volume:0.004 65704 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=35,pt=7,l=5,sg=0,ft=0,st=OK:0.004 l/min:0.00 95688 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=34,pt=7,l=5,sg=0,ft=0,st=OK:0.00 pulsecount:5 95696 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=25,pt=5,l=4,sg=0,ft=0,st=OK:5 volume:0.005 95706 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=35,pt=7,l=5,sg=0,ft=0,st=OK:0.005 pulsecount:5 125689 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=25,pt=5,l=4,sg=0,ft=0,st=OK:5 volume:0.006 125698 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=35,pt=7,l=5,sg=0,ft=0,st=OK:0.006 l/min:2.00 155691 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=34,pt=7,l=5,sg=0,ft=0,st=OK:2.00 pulsecount:7 155699 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=25,pt=5,l=4,sg=0,ft=0,st=OK:7 volume:0.007 155708 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=35,pt=7,l=5,sg=0,ft=0,st=OK:0.007 l/min:0.00 185691 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=34,pt=7,l=5,sg=0,ft=0,st=OK:0.00 pulsecount:8 185699 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=25,pt=5,l=4,sg=0,ft=0,st=OK:8 volume:0.008 185708 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=35,pt=7,l=5,sg=0,ft=0,st=OK:0.008 pulsecount:8 215696 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=25,pt=5,l=4,sg=0,ft=0,st=OK:8 volume:0.009 215707 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=35,pt=7,l=5,sg=0,ft=0,st=OK:0.009 l/min:2.00 245693 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=34,pt=7,l=5,sg=0,ft=0,st=OK:2.00 pulsecount:10 245701 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=25,pt=5,l=4,sg=0,ft=0,st=OK:10 volume:0.010 245710 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=35,pt=7,l=5,sg=0,ft=0,st=OK:0.010 l/min:0.00 275694 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=34,pt=7,l=5,sg=0,ft=0,st=OK:0.00 pulsecount:11 275702 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=25,pt=5,l=4,sg=0,ft=0,st=OK:11 volume:0.011 275714 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=35,pt=7,l=5,sg=0,ft=0,st=OK:0.011 pulsecount:11 305695 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=25,pt=5,l=4,sg=0,ft=0,st=OK:11 volume:0.012 305703 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=35,pt=7,l=5,sg=0,ft=0,st=OK:0.012 l/min:2.00 335698 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=34,pt=7,l=5,sg=0,ft=0,st=OK:2.00 pulsecount:13 335707 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=25,pt=5,l=4,sg=0,ft=0,st=OK:13 volume:0.013 335718 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=35,pt=7,l=5,sg=0,ft=0,st=OK:0.013 l/min:0.00 365732 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=34,pt=7,l=5,sg=0,ft=0,st=OK:0.00 pulsecount:14 365776 !TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=25,pt=5,l=4,sg=0,ft=0,st=NACK:14 volume:0.014 365788 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=35,pt=7,l=5,sg=0,ft=1,st=OK:0.014 376929 TSF:MSG:READ,0-0-255,s=255,c=3,t=20,pt=0,l=0,sg=0: 376934 TSF:MSG:BC 377041 TSF:MSG:SEND,1-1-0-0,s=255,c=3,t=21,pt=1,l=1,sg=0,ft=0,st=OK:0 l/min:5.36 395735 !TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=34,pt=7,l=5,sg=0,ft=0,st=NACK:5.36 pulsecount:16 Again since i'm geting this problem i don't have my sensor connected to the arduino. @mrc-core if nothing is connected to the sensor pin, the pin will float and might create spurious interrupts. Connect the pin to gnd to make sure it doesn't get any false triggers. @mfalkvidd Thanks. Have now connected the digital pin2 to gnd and in the last 1h the values are always 0.000 going to leave it this way until night since now i'm at work. I would like to find out what was creating the spurious interrupts?? Other thing that ill find out tonight is when i connect the sensor to the arduino will it create rong data or will it only send real data only when the water meter starts running water... One more thing today at 8:00 when i did the pin2 to gnd the first "boot" over domoticz i got this value as you can see on the image below. Is this normal? Have been trying to deleted but it wont go away. Once again thanks for your help. @mrc-core The spurious interrups are caused by the open line. The Arduino has high impedance inputs and anything from a WiFi signal or the signal from a close by circuit can cause the value to swing between 0 and 3 Volt, triggering your input. See On your high value in the graph: Domoticz water sensors require the sensor to post the total water volume. This means that the sensor needs to "know" the total of volumes from all the past measurements. In fact all the (wrong) past pulses you generated with the open input are stored by the sensor. There are 2 ways this storage mechanism can be realized in Arduino code: (1) keep the value in the Arduino EEPROM and (2) use a build in feature of Domoticz to store values on behalf of sensors. Mysesnsors uses method 2 as method (1) has 2 disadvantages: The code needs to continuously write to the EEPROM, because you never know when the Arduino will be rebooted. The EEPROM on the Arduino chip does not allow you to write to it that often (max 100,000 times or so) and the EEPROM is cleared when you update the software. The sketch used by MySensors uses method (2) by sending the pulsecount to the gateway using send(lastCounterMsg.set(pulseCount)) statement at the same time the volume is sent to Domoticz with send(volumeMsg.set(volume, 3)); At each reboot the sensor requests the value of VAR1 from the gateway using request(CHILD_ID, V_VAR1); The sensor does not send any data to the gateway until the gateway has received the counter past value. The receive() function is called by the Mysensor library when data comes back from the gateway. There the pulseCount += gwPulseCount statement adds the value to the pulseCount. This means the sensor will not be able to "forget" the pulses that came from the period your digital input was not connected. There are 3 ways to fix this problem: - you can delete your sensor at the Domoticz side (throwing away all history): First power down your Arduino sensor, the go into Domoticz screen and remove the sensor from the Utility screen and then remove the sensor from the Setup->Hardware->MysensorsGW->Setup->Click on your water meter-> delete all Children-> delete the water meter sensor itself. Then power up your Arduino and you will see the sensor show up again. - as above: remove your sensor from the Utilities tab and change the code to give your sensor another new ID. At the top of your code you can put a statement like #define MY_NODE_ID 10 This will be the ID number that shows in the hardware setup screen in Domoticz for your sensor. If you omit this code MySensors will create a new (unique) code for you. However in my system I prefer to allocate the numbers myself to each sensor. So a quick way to create a brand new sensor history in Domoticz is to simply change the MY_NODE_ID number (change from 10 to 11). - change yuor Arduino code to force a 0 in the VAR1 holding variable for your sensor. You can do that by adding a statement send(lastCounterMsg.set(0)); inside your loop() function (best place is here): // Only send values at a maximum frequency or woken up from sleep if (SLEEP_MODE || (currentTime - lastSend > SEND_FREQUENCY)) { lastSend=currentTime; send(lastCounterMsg.set(0)); // <--- keep here shortly and remove later if (!pcReceived) { //Last Pulsecount not yet received from controller, request it again request(CHILD_ID, V_VAR1); return; } You will compile and upload this code to your Arduino and let it run for a minute or so, then remove the line and upload the orginal code. You should now be able to remove the data point in Domoticz (by using ctrl-mouseclick on the graphic item) Hope this helps Bart @bart59 Thanks have done like you said and did clean the data from the gateway. All day until 1h ago i had left my arduino connected on my pc and i did like mfalkvidd said connecting the digital pin 2 to gnd and my arduino did not send any strange value to the gateway always seend volume 0.00 this was perfect. Now that i'm at home i had connect my arduino to the sensor 3.3v gnd and digital pin2 and in the first log there it was value increase on volume when my sensor was in front off me... I have a arduino nano pro 3.3v on easy pcb board and i'm using the hall sensor i dont see why i'm getting this problem... I have a WiFi AP inside home and my sensor is outside. Even the water flow says i have a 2.00 L/min when the sensor is not near the water meter. New update.... have change the arduino mini pro for another one flash a new code a new sensor and again i'm getting volume data when the sensor is not near the water meter. I dont understand what's happening. @mrc-core Just to make sure: are you connecting/disconnecting the data pin to your sensor when the Arduino is powered off and are you sure the connection is solid? If you connect things with power on you may accidently trigger a pulse a 100 times.... which will be sent to the gateway 20 secs later. Always power off stuff first and use a solid connection (soldering is always better) when making modifications. How did you power the hall sensor? Should be from the 3.3V VCC connector of the Arduino and not from the higher voltage or something separate. Can you upload a photo of your setup to allow us to see how you connect things? Bart In addition to what bart59 said, make sure the hall sensor isn't near anything magnetic. It will be triggered by any magnetic material, not just the water meter. @bart59 Yes i'm using the 3,3v from the arduino and i always connect everything with the arduino power off. Give me mor 5 minutes and i'll upload a photo from my sensor going to bring it inside home. @mfalkvidd i think i don't have anything magnetic on the place were i'm putting the arduino and the sensor at this time. Thanks for the replays. Ok here's the photo off my sensor. On my code i'm using the digital pin2 since digital pin3 has a resistor for Dallas and dht sensors but i'm not using them at this time. This arduino is only for water meter. I think i have fix my problem. I have been playing with the code and the sensor and notice that the power led and data led on the sensor were always on no mater the digital pin i was trying to use. This also happened with the analog pin A0. In one last attempt i decided to use the digital pin 3 with the resistor soldered on the board for sensors like dallas and dht11 or dht22. Now the first thing i had noticed was the data led was not on and now it only comes on when i passe a magnet under my sensor... it does not count any pulsecount if i passe the magnet over the sensor only under it. Counted the times i had passed the magnet under the sensor and my gateway received te exact number 30 times = 0.030 volume and now the volume is stop at this number no more ghost encrease numbers. Tomorrow morning i'm going to mount the sensor over the water meter to see if this finaly works. The only problem i'm getting now is some NACK over the transmissions... like this: 6604747 TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=25,pt=5,l=4,sg=0,ft=3,st=OK:30 volume:0.030 604794 !TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=35,pt=7,l=5,sg=0,ft=0,st=NACK:0.030 pulsecount:30 634781 !TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=25,pt=5,l=4,sg=0,ft=1,st=NACK:30 volume:0.030 634828 !TSF:MSG:SEND,1-1-0-0,s=1,c=1,t=35,pt=7,l=5,sg=0,ft=2,st=NACK:0.030 @mrc-core The NACK may be bad transmission. I typically connect a 5 cm piece of wire to the antenna of the send/receive module to increase the reception of data @bart59 and @mfalkvidd Thanks for all the help. Today i toke the sensor to the water meter and for my luck my water meter is too old 1997 and no mater the position i put the hall sensor it just doesn't get any pulse at all at this time i really don't now what to use to get the data from my water meter... I have already tried also the TCRT5000 and also does not work. Here's an image from my water meter The TCRT5000 when i put over the glass the green led stays always on but when i remove it from the glass and point it to the black part of my meter the green led goes off the sensor is working ok but the glass from my meter does not help at all. Any sugestions off other sensors i can try or use ? @mrc-core You are right. This is the wrong type of water meter. I have been using 2 other brands watermeters: the Honeywell C7195x2001B (see) and the Caleffi series 316 (). You local central heating installation guy may have them as they are used in boiler systems of central heating for the warm water supply. They are also sold on eBay. Both work more or less the same and can be operated on 5V. The number of pulses per liter are much higher (something like 500 pulses per liter), so they are more accurate. You will need to modify your code to work with this. Below the code of my sensor (which also measures multiple temperatures at the same Arduino chip): /** *. * * (c) 2017 Bart M - last edits: 15 May 2017 * * Note: using timer0 to generate a second interrupt for our 1 ms counters. timer0 is still also used for delay() * * Functions WTW Flow and Temperature * * WTW flow * - Flow of shower cold water * - Flow of boiler cold water entry * * Temperature * - Temperature of outgoing water (Dallas with cable) * - Temperature of shower head (Dallas) * * * * If we use 250 m3 per year we come to 105 x 10^6 pulses/year *`this is stored in an unsigned long that can hold 4295 x 10^6 -> volume overflow after 41 years * ***************************************************************************************************** */ // BOARD: PRO MINI 5V V/ 16Mhz ATMEGA328 16Mhz // type of flow meter #define CALEFFI // #define HONEYWELL // Enable debug prints to serial monitor #define MY_DEBUG 1 // Enable and select radio type attached #define MY_RADIO_NRF24 // No repeater // node ID's #define MY_NODE_ID 27 // start naming my own nodes at number (set in comments if you want automatic) #define FLOW_ID 1 // flow meter 1 (start here if more) #define NFLOWS 2 // number of flow meters #define TEMP_ID 3 // Temperature (start here if there are more linked) #include <SPI.h> #include <MySensors.h> #include <DallasTemperature.h> #include <OneWire.h> // PIN connections where the flow meters are connected. We have 2 flow meters, so our array has 2 entries uint8_t FlowPins[NFLOWS] = {2, 3}; #define TEMP_PIN 4 // temp sensor connected to pin4 #ifdef CALEFFI // #define PULSE_FACTOR 528000 // Number of blinks per m3 of your meter Caleffi (from data sheet) #define PULSE_FACTOR 406154 // Nummber of blinks per m3 of your meter Caleffi (measured in my installation) #else #define PULSE_FACTOR 420000 // Nummber of blinks per m3 of your meter Honeywell #endif // configs #define MAXFLOWERROR 50 // maximum number of l/min that we accept // delay times #define CHECK_FREQUENCY 1000 // time in milliseconds between loop (where we check the sensor) - 1000ms #define MIN_SEND_FREQ 10 // Minimum time between send (in multiplies of CHECK_FREQUENCY). We don't want to spam the gateway (10 seconds) #define MIN_FLOW_SEND_FREQ 20 // Minimum time between send (in multiplies of CHECK_FREQUENCY). We don't want to spam the gateway (30 seconds) #define MAX_SEND_FREQ 600 // Maximum time between send (in multiplies of CHECK_FREQUENCY). We need to show we are alive (600 sec/10 min) // one wire config #define ONE_WIRE_BUS TEMP_PIN #define MAX_ATTACHED_DS18B20 8 // Motion message types MyMessage volumeMsg(FLOW_ID,V_VOLUME); MyMessage flowMsg(FLOW_ID,V_FLOW); MyMessage lastCounterMsg(FLOW_ID,V_VAR1); MyMessage tempmsg(TEMP_ID, V_TEMP);]; volatile unsigned int numSensors = 0; double ppl = ((double)PULSE_FACTOR / 1000.0); // Pulses per liter boolean pcReceived[NFLOWS]; // received volume from prior reboot double oldflow[NFLOWS]; // keep prior flow (only send on change) unsigned long oldflow_cnt[NFLOWS]; // only send when changed // updated in ISR volatile unsigned int mcnt = CHECK_FREQUENCY; // decremented in ISR at 1000Hz. Cycles at one per second to update send counters volatile unsigned int tempsendcnt[MAX_ATTACHED_DS18B20]; volatile unsigned int maxtempsendcnt[MAX_ATTACHED_DS18B20]; volatile unsigned int flowsendcnt[NFLOWS]; volatile unsigned int maxflowsendcnt[NFLOWS]; volatile bool flow_status[NFLOWS]; // status of flow (on or off cycle) volatile unsigned long flow_cnt[NFLOWS]; // counter volume for each flow sensor volatile unsigned int intervalcnt[NFLOWS]; // keep track of number of milliseconds since we had previous flow info void before() { for (uint8_t i=0; i<NFLOWS; i++) { pinMode(FlowPins[i], INPUT); } // Startup up the OneWire library sensors.begin(); for (uint8_t i=0; i<NFLOWS; i++) { oldflow[i] = 0; flow_status[i] = false; flow_cnt[i] = 0; oldflow_cnt[i] = 0; pcReceived[i] = false; flowsendcnt[i] = MIN_FLOW_SEND_FREQ; maxflowsendcnt[i] = MAX_SEND_FREQ; intervalcnt[i] = 0; } for (uint8_t i=0; i<MAX_ATTACHED_DS18B20; i++) { lastTemperature[i]=0; tempsendcnt[i] = 0; maxtempsendcnt[i] = MAX_SEND_FREQ; } } void setup() { Serial.println("setup()"); // Timer0 is already used for millis() - we'll just interrupt somewhere // in the middle and call the TIMER0_COMPA_vect interrupt OCR0A = 0xAF; TIMSK0 |= _BV(OCIE0A); sensors.setWaitForConversion(true); // Fetch last known pulse count value from gw for (uint8_t i=0; i<NFLOWS; i++) { request(FLOW_ID+i, V_VAR1); } } void presentation() { // Send the sketch version information to the gateway and Controller sendSketchInfo("WTW flow sensor", "1.2"); // Register all sensors to gw (they will be created as child devices) numSensors = sensors.getDeviceCount(); Serial.print("# temp sensors: "); Serial.println(numSensors); DeviceAddress add; for (uint8_t i=0; i<numSensors && i<MAX_ATTACHED_DS18B20; i++) { present(TEMP_ID+i, S_TEMP); Serial.print(i); Serial.print("="); sensors.getAddress(add, i); printAddress(add); Serial.println(); } for (uint8_t i=0; i<NFLOWS; i++) { present(FLOW_ID+i, S_WATER); } } // function to print a device address of a Dallas temp sensor void printAddress(DeviceAddress deviceAddress) { for (uint8_t i = 0; i < 8; i++) { // zero pad the address if necessary if (deviceAddress[i] < 16) Serial.print("0"); Serial.print(deviceAddress[i], HEX); } } void loop() { // we come here every 1000 ms (defined in CHECK_FREQUENCY) // now handle temperature if (numSensors>0) { sensors.requestTemperatures(); for (uint8_t i=0; i<numSensors && i<MAX_ATTACHED_DS18B20; i++) { // Fetch and round temperature to one decimal float temperature = static_cast<float>(static_cast<int> (sensors.getTempCByIndex(i) * 10.)) / 10.; // Only send data if temperature has changed and no error if (((lastTemperature[i] != temperature && tempsendcnt[i]==0) || maxtempsendcnt[i]==0) && temperature != -127.00 && temperature != 85.00) { // Send in the new temperature send(tempmsg.setSensor(TEMP_ID+i).set(temperature,1)); // Save new temperature for next compare lastTemperature[i]=temperature; tempsendcnt[i] = MIN_SEND_FREQ; maxtempsendcnt[i] = MAX_SEND_FREQ; } } for (uint8_t i=0; i<NFLOWS; i++) { if ((flowsendcnt[i]==0 && (oldflow_cnt[i] != flow_cnt[i])) || (flowsendcnt[i]==0 && oldflow[i] != 0) || maxflowsendcnt[i]==0) { if (!pcReceived[i]) { //Last Pulsecount not yet received from controller, request it again Serial.print("Re-request var1 for sensor "); Serial.println(FLOW_ID+i); request(FLOW_ID+i, V_VAR1); wait(2*CHECK_FREQUENCY); // wait at least 1000 ms for gateway (cannot be sleep or smartSleep) return; } flowsendcnt[i] = MIN_FLOW_SEND_FREQ; maxflowsendcnt[i] = MAX_SEND_FREQ; double volume = ((double)flow_cnt[i]/((double)PULSE_FACTOR)); double flow = (((double) (flow_cnt[i]-oldflow_cnt[i])) * ((double) 60000.0 / ((double) intervalcnt[i]))) / ppl; // flow in liter/min Serial.print("Flow meter:"); Serial.println(FLOW_ID+i); Serial.print("pulsecount:"); Serial.println(flow_cnt[i]); Serial.print("volume:"); Serial.println(volume, 3); Serial.print("l/min:"); Serial.println(flow); intervalcnt[i] = 0; oldflow[i] = flow; oldflow_cnt[i] = flow_cnt[i]; send(lastCounterMsg.setSensor(FLOW_ID+i).set(flow_cnt[i])); // Send pulsecount value to gw in VAR1 send(volumeMsg.setSensor(FLOW_ID+i).set(volume, 3)); // Send volume (set function 2nd argument is resolution) if (flow<MAXFLOWERROR) send(flowMsg.setSensor(FLOW_ID+i).set(flow, 2)); // Send flow value to gw } } } // Serial.print(end_loop-start_loop); wait(CHECK_FREQUENCY); } // Receive data from gateway void receive(const MyMessage &message) { for (uint8_t i=0; i<NFLOWS; i++) { if (message.type==V_VAR1 && message.sensor==FLOW_ID+i) { unsigned long gwPulseCount=message.getULong(); flow_cnt[i] += gwPulseCount; oldflow_cnt[i] += gwPulseCount; oldflow[i] = 0; Serial.print("Received last pulse count for "); Serial.print(FLOW_ID+i); Serial.print(" from gw:"); Serial.println(gwPulseCount); pcReceived[i] = true; } } } // Interrupt on timer0 - called as part of timer0 - already running at 1ms intervals SIGNAL(TIMER0_COMPA_vect) { if (mcnt>0) mcnt--; for (uint8_t i=0; i<NFLOWS; i++) { if (mcnt==0) { if (flowsendcnt[i]>0) flowsendcnt[i]--; if (maxflowsendcnt[i]>0) maxflowsendcnt[i]--; } intervalcnt[i]++; bool val = digitalRead(FlowPins[i]); if (val != flow_status[i]) { flow_status[i] = val; if (!val) flow_cnt[i]++; // we increment counter on down flank } } if (mcnt==0) { mcnt = CHECK_FREQUENCY; for (uint8_t i=0; i<numSensors && i<MAX_ATTACHED_DS18B20; i++) { if (tempsendcnt[i]>0) tempsendcnt[i]--; if (maxtempsendcnt[i]>0) maxtempsendcnt[i]--; } } } Good luck Bart @mrc-core If I do a search for "B93 315.04 lisboa" I get MSV Janz company turn up, but I don't understand Portugese. It is probably a magnetic drive even at 1997 fabrication, but perhaps some searching will yield clues or contact the manufacturer? @zboblamont I have already read that pdf there they say this: "The design of the Magnetic Transmission reduces the number of components Operating in the water, increasing the reliability of the meter." They also say this in the pdf: "Any of these models can be supplied ready to receive the Pulse transmission (see tele-count catalog). Ex .: MSV 1520t" In this last information i made a search for MSV 1520t were i found again another pdf that talks about my water meter. Here's the link: You can see 5 water meters on that link all off them say's Magnetic Transmission "Transmissão magnética" but has you can see none off them look like mine. Has i can understand mine is the more basic off them all i do belive that i have the first generation off this water meters. I have done one last test yesterday leaving a water tap open and passed the hall sensor all over the water meter from side to side and top to bottom and never got any impulse digital led light turning on. The led did turned on when i put my finger in the top off the sensor or in cables near the pins of the sensor. @mrc-core Well, I did suggest contacting the manufacturer with the information on your meter, they are better able to advise or may even sell a sensor head to retrofit. Usually these manufacturers are very helpful, and at least you speak the language. I know that some manufacturers insist on factory building the sensor arrangement inside the meter (Zenner?) but you may be lucky. The magnetic drive is more to avoid mechanical connection between the metering section and the water flow, so no axle or sealing ring to leak ! I have a plastic Elster, it has the same magnetic coupling as yours, but I was unable to sense any changing magnetic field when I checked it, but I had already ordered the specific read head for it so was not unduly concerned, and it should arrive in next few days. This sensor pulses when a small metal arc on the small dial passes beneath the sensor every 1 litre. It was around 30 euro from memory, so not a mad price. Hello, i have got water meter with pulse output. So I have just arduino and RFM69W. Sleep mode false/true works well with standard bootloader. Optiboot with sleep mode false works also well. But I would like to run it on battery optiboot with true sleep mode which doens work correctly. Sensor doesnt receiceve last pulse count from gw. Any idea how to fix it? 0 MCO:BGN:INIT NODE,CP=RRNNA--,VER=2.1.1 4 TSM:INIT 4 TSF:WUR:MS=0 8 TSM:INIT:TSP OK 10 TSM:INIT:STATID=3 12 TSF:SID:OK,ID=3 14 TSM:FPAR 145 TSF:MSG:SEND,3-3-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 743 TSF:MSG:READ,0-0-3,s=255,c=3,t=8,pt=1,l=1,sg=0:0 747 TSF:MSG:FPAR OK,ID=0,D=1 2152 TSM:FPAR:OK 2152 TSM:ID 2154 TSM:ID:OK 2156 TSM:UPL 2164 TSF:MSG:SEND,3-3-0-0,s=255,c=3,t=24,pt=1,l=1,sg=0,ft=0,st=OK:1 2179 TSF:MSG:READ,0-0-3,s=255,c=3,t=25,pt=1,l=1,sg=0:1 2185 TSF:MSG:PONG RECV,HP=1 2189 TSM:UPL:OK 2191 TSM:READY:ID=3,PAR=0,DIS=1 2201 TSF:MSG:SEND,3-3-0-0,s=255,c=3,t=15,pt=6,l=2,sg=0,ft=0,st=OK:0100 2254 TSF:MSG:READ,0-0-3,s=255,c=3,t=15,pt=6,l=2,sg=0:0100 2269 TSF:MSG:SEND,3-3-0-0,s=255,c=0,t=17,pt=0,l=5,sg=0,ft=0,st=OK:2.1.1 2283 TSF:MSG:SEND,3-3-0-0,s=255,c=3,t=6,pt=1,l=1,sg=0,ft=0,st=OK:0 2336 TSF:MSG:READ,0-0-3,s=255,c=3,t=6,pt=0,l=1,sg=0:M 2351 TSF:MSG:SEND,3-3-0-0,s=255,c=3,t=11,pt=0,l=11,sg=0,ft=0,st=OK:Water Meter 2367 TSF:MSG:SEND,3-3-0-0,s=255,c=3,t=12,pt=0,l=3,sg=0,ft=0,st=OK:1.1 2381 TSF:MSG:SEND,3-3-0-0,s=3,c=0,t=21,pt=0,l=0,sg=0,ft=0,st=OK: 2387 MCO:REG:REQ 2398 TSF:MSG:SEND,3-3-0-0,s=255,c=3,t=26,pt=1,l=1,sg=0,ft=0,st=OK:2 2451 TSF:MSG:READ,0-0-3,s=255,c=3,t=27,pt=1,l=1,sg=0:1 2457 MCO:PIM:NODE REG=1 2461 MCO:BGN:STP 2469 TSF:MSG:SEND,3-3-0-0,s=3,c=2,t=24,pt=0,l=0,sg=0,ft=0,st=OK: 2476 MCO:BGN:INIT OK,TSP=1 2486 TSF:MSG:SEND,3-3-0-0,s=3,c=2,t=24,pt=0,l=0,sg=0,ft=0,st=OK: 2500 TSF:MSG:SEND,3-3-0-0,s=3,c=2,t=24,pt=0,l=0,sg=0,ft=0,st=OK: 2514 TSF:MSG:SEND,3-3-0-0,s=3,c=2,t=24,pt=0,l=0,sg=0,ft=0,st=OK: 2527 TSF:MSG:SEND,3-3-0-0,s=3,c=2,t=24,pt=0,l=0,sg=0,ft=0,st=OK: 2541 TSF:MSG:SEND,3-3-0-0,s=3,c=2,t=24,pt=0,l=0,sg=0,ft=0,st=OK: 2555 TSF:MSG:SEND,3-3-0-0,s=3,c=2,t=24,pt=0,l=0,sg=0,ft=0,st=OK: 2570 TSF:MSG:SEND,3-3-0-0,s=3,c=2,t=24,pt=0,l=0,sg=0,ft=0,st=OK: 2707 !TSF:MSG:SEND,3-3-0-0,s=3,c=2,t=24,pt=0,l=0,sg=0,ft=0,st=NACK: Has it ever received a pulse count? When its about 2 metres far from gateway its received. Afterthat can be moved 10 metres away and it works. But after reset has to be moved close to gateway again. I run also power meter pulse sensor. This has got different issue. It falls asleep before receiving pulse count from gw. @ladislav Sounds like a radio problem. Are you using a capacitor on the radio power supply pins? A capacitor on all radios in your network. I have a an Ethernet gateway in our basement and a node in our attic that is two floors above it and it works fine using a NRF24 for all radios and the radio power is on the default setting and it communicates fine. I having problem to place the tcrt5000 on the correct place. Can anyone please show where to put it? Is it over the black (that spins every 0.5 l)? I have this type of water meter @smilvert I am afraid your water meter does not work. On many other watermeters the black spinning wheel is somewhat bigger and has a small mirror attached. The light from the IR LED is reflected by the mirror and the IR sensor picks up the reflection as a pulse every rotation (in your case 0.5 L). I suggest you buy another water meter that has a sensor build in and provides you with a direct signal. In my home I have separate water meters for each water consumer (such shower, hot water, kitchen, etc.). I am using a Honeywell C7195A2001B which has a hall sensor that pulses at 7 Hz per liter/min, so you will get 420 pulses per liter. These meters are typically used in boiler or central heating systems that also can provide hot water for your shower. You need to modify the source code a bit to handle the high pulse frequency, but the nice thing is that the measurement is very accurate. regards Bart @smilvert You could try a magnometer. I successfully used one on my gas meter that didn't have a magnet in it. Look up "gas meter using a magnometer" in this forum. The code is much different than using the standard water meter sketch. @smilvert @dpcr I really doubt this type of water meter having a magnet to sense. Gas meters often are prepared to use a special reed swich to be mounted somewhere outside on the enclosure, and the magnet comes pretty close to the enclosure to be sensed. I somewhere found a different solution approach using a modified TCRT5000 board with green LED and a specific lightsensor (see here for details, german). The idea behind it is to use complementary (green) light to one of the red pointer wheels to improve contrast when the small pointer passes. I recently did some first test wrt. to this, but different to the mentioned solution, I used the original LED/sensor places to connect these two parts (and also changed the resistors values). Unfortunately, I wasn't able to test it "at the right place" until now. As far as I can see, the TCRT5000 inside just also consist of two seperate parts inside a housing. So you may try to do it like that: just pull of the plastic housing, change the LED (see TCRT datasheet which one) with a green one, focus LED and sensor a little more than normal and see, if you get reasonable results whith the trimming resistor. Glad for feedback, if this works... @rejoe2 A magnetometer doesn't need a magnet to work, my gas meter doesn't have a magnet and it works fine. Most all smartphones have magnetometers in them to sense direction. However your solution looks to work as well and probably with less code. @dpcr Thanks for clarification. Today there was a new post that may be of interest wrt. to the "green" LED sensing modification:;quote=702342;topic=71341.0;last_msg=702342 This one seems to be close to a "professional" solution also wrt. to the other parts used (but most likely not on a TCRT5000-Base)... I have a question and need some advise, is it possible to expand the sketch to two meters. In my case I want to combine a this Water Meter with a Gas Meter. Can both meters use an interrupt, each? @rpunkt welcome to the MySensors community! it depends on which microcontroller you use, and what type of interrupt. Atmega328 can use pin 2 and 3 at the same time by merging the sketches. More/other pins can be used but that will require some code changes. @smilvert I also have same meter as the picture. Yesterday I installed my sensor I took a TCRT5000 IR sensor, A cap from a soda bottle, cut it so it fits above left red wheel(X0,0001) which means one lap i 1 liter It works but it counts little bit wrong, I have change the if (interval<500000L) to if (interval<2500000L) but anyway it counts about 3 times to much. I will check it later today @flopp This didn't worked so well, I got a lot of errors everytime nRF was sending data, then I got one pulse. Anyone know how to protect the digital input to NOT fall when nRF sends? Wait, when I was writing this text I just remember that nRF is using Pin 2, is that correct? I will try to use pin 3 instead, as interrupt pin @flopp Nice. You don't use a green led? I tried that and it seems to work better but then I struggle with the mounting. Need to try this again! @smilvert said in Water Meter Pulse Sensor: You don't use a green led? I tried that and it seems to work better but then I struggle with the mounting. I am using IR to detect movements. Green LED is flashing eveytime the IR detects movement and Red LED is power for PCB. I am using Digital Output from PCB to pin 2 or 3 on my UNO. I have tried both with INPUT_PULLUP and without, also tried 20K between Digital Output and GND. nothing is helping How do you use green LED with water meter? Hi all i just wanna see The OUTPUT of Serial Monitor for this project sow i can see results . Just enable the my_debug How can i get the pulses from SonOff.... i cannot find any digital pin 3 in sonoff... im new to this please guide me Any one used this approach? From the text I see that the node sleeps! How does it measures the consumption if the node is sleeping? Thank you @soloam could you clarify what you refer to when saying "this"? Earlier posts discuss infrared, led, magnetometer and other solutions so it is a bit hard to answer your question. @mfalkvidd hello! I was referring to this statement in the site: "Use this mode if you power the sensor with a battery. In this mode the sensor will sleep most of the time and only report the cumulative water volume." Thank you according to the sensor you use, each pulse should wake the node and add a count, then back to sleep. That is nice! But I would have to test it out! Probably that would make the node all the time awake during a long bath! Ok, it would not use the radio all the time, but I would like to know who that would affect the battery! Thank you all for the feedback @soloam We sometimes forgot about other circuit than Arduino. Use CMOS counter IC and wake up your Arduino for example every 20 impulse and read counter status. If you want Safe battery. - bjornhallberg Hero Member last edited by @flopp Did you ever manage to stabilize the readings? Am I understanding you correctly that the readings were fine but the transmission got the reading scrambled? Did you try to find a magnetic field with the meter instead? I have a similar meter and I'm wondering how best to approach the problem. I've seen people hook up Raspberries and cameras to do OCR basically but that seems like way too complex for an easy problem. @flopp said in Water Meter Pulse Sensor: TCRT5000 IR senso I have not had good results using TCRT5000 IR sensor, did you? @bjornhallberg well I still think this is the best approach to use RPI + OCR - bjornhallberg Hero Member last edited by While looking into the water meter I realized that we are getting a "smart" meter replacement soon. I'll see if I can speed up the replacement schedule. Anyhow, the replacement is a Kamstrup Multical 21 () which has several options for reading: - Requesting the data via optical interface? - Enabling the pulse function via optical interface, and then reading the IR pulse at 1imp/10lit. - Reading the wireless mbus signal? (e.g.) @bjornhallberg Suggest you discuss with your water supplier, and see what THEY intend to deploy for comms and explain what your own objectives are, that may refine what you are looking at, and they MIGHT actually help rather than be play "stupid" which is unfortunately common nowadays. In all probability they will be looking at wireless m-bus for drive-by readings, this is the predominant method of retrieval. I admit to surprise at them deploying ultrasonics, they are on the expensive end of the market but they are extremely reliable and accurate. @bjacobse said in Water Meter Pulse Sensor: @flopp said in Water Meter Pulse Sensor: TCRT5000 IR senso I have not had good results using TCRT5000 IR sensor, did you? I didn’t get it to work. I was so lucky that my water company change the meter to a meter with wireless m-bus. So I bought a box for this and now I have 100% correct readings. @bjacobse Another option perhaps to consider (if it is physically viable), is to insert a meter and sensor of your choice within your property, they are not expensive nowadays and easy enough to fit ? A simple meter and reed switch such as this link text or similar perhaps. @zboblamont In Sweden you need a certified installer to exchange your pipes, else in case of water damage your insurance won't cover. so cheapest for me is a RPI with camera - but yes I would prefer a "real" measuring from a dedicated sensor - zboblamont last edited by zboblamont @bjacobse Pardon my laughter, insurers look for any excuse for sure, but I have never heard yet where a water meter or any other competent insertion damaged a building, let alone an insurance company refused to compensate for a building which burned to the ground (99.9%) on the basis the water meter was not a verified install. For sure some loss adjusters will use any excuse, but really? To clarify, in many countries a certified inspector or Engineer must certify that work is carried out within the regulations, it does not state that HE/SHE has carried out the work, only that it has been inspected and verified as compliant. You know any certified local plumbers with 5 minutes to spare, because that is how long it takes me to fit one, and about the time it takes a certified pipe-jockey to verify it's right and sign it off, if it really concerns you ? I have 2 self fitted water meters with sensors, gas meter sensor etc, and a huge amount of DIY stuff any smartass insurer could IMPLY was a contributory factor to the disaster which befell my house, but frankly it wouldn't stand 1 second in Court before being laughed out... Place hasn't burned down yet, fallen over in earthquakes, or been subjected to landslide, but luckily I don't have Swedish Insurers.... PS- I should clarify that the standing regulations are framed to quite rightly protect consumers as well as the service provider against cowboys interfering with apparatus. Changing light switches or sockets falls under the same overall umbrella despite everyone and their mother changing them. @bjacobse I believe you can replace the meter yourself if you own it yourself and have the necessary skills. I live in such an area and was told I could mount it myself if I was confident enough. But of course, the fault will be yours if your bad job causes damages. In reality it is quite unlikely that you can mount it badly and not notice the problem immediately. A more critical issue is that water meters are usually owned by the municipality or water company and they are sealed. It is impossible to replace the meter without breaking the seal and when the company notices they won't be happy at all. - zboblamont last edited by zboblamont @fredswed And by extension (Possibly Swedish water suppliers differ from UK or Romanian counterparts?) the data retrieved from their devices is often regarded as their property also, and brick walls begin to appear ino what should be readily shared data. If they will not share, fitting a downstream device within your own control can often be the only solution, don't interfere, augment... As a perverse example, my own gas and electricity suppliers are the German monolith EON who provide and enable access to their 'graphs' online, updated with 1 or 2 month readings (gas and electricity). Having checked the base data for their graphs, I realised they were presenting a lovely graph based on complete bunkum, and developed and maintained my own ever since, which IS accurate. I checked recently and their graphs are still pretty but complete rubbish. Installing a gas meter sensor caused EON palpitations until they realised it was the commercial device for the meter and could not object on technicalities then quietly dropped objections, I don't care how they respond when I fit meters to the Consumer box, it is nowhere near their SMART meter which tells me nothing but tells them much, mainly that I halved their 2 monthly bill . If the service provider will allow detailed sharing of YOUR data, all good and well as it is mutually beneficial, but if not, easy enough to solve at your own expense. I fitted two replacement upgraded radiators in the last month, somewhere a Romanian regulation lurks that I should not have done so, but the insurer doesn't give a damn unless it is found to have caused the demise of the insured property.. Is it worth the risk? Hell yes... It looks very interesting. I complied and uploaded successful, but it ran without run the loop function at all. infrared sensor lighted up but no print out attached Serial.print. Can you give us the url to the library #include <MySensors.h>?. I am using MySensors 2.3.1 loaded from Adruino IDE->Tools->Manage Libary->search My Sensors from 4:55:53.476 -> 60127 TSM:FAIL:RE-INIT 14:55:53.476 -> 60129 TSM TSM:FAIL:DIS 14:55:53.476 -> 900384 TSF:TDI:TSL 14:55:54.962 -> 14:55:54.962 -> __ __ ____ 14:55:54.962 -> | / |_ / | ___ _ __ ___ ___ _ __ ___ 14:55:54.962 -> | |/| | | | _ \ / _ \ _ \/ __|/ _ \|/ | 14:55:54.962 -> | | | | || || | / | | _ \ _ | | _ 14:55:54.962 -> || ||_, |/ _|| ||/_/|| |/ 14:55:54.962 -> |_/ 2.3.1 14:55:54.962 -> 14:55:54.962 -> 16 MCO:BGN:INIT NODE,CP=RNNNA---,REL=255,VER=2.3.1 14:55:54.962 -> 26 TSM:INIT 14:55:54.962 -> 27 TSF:WUR:MS=0 14:55:54.997 -> 33 !TSM:INIT:TSP FAIL 14:55:54.997 -> 35 TSM:FAIL:CNT=1 14:55:54.997 -> 37 TSM:FAIL:DIS it looks like it is can't find the radio module. Check cables and pins numering - executivul last edited by Sorry. Don't you have another sensor to try? - Alehandro06 last edited by @flopp which box did you buy for m-bus readings? did you work it out? ''I was so lucky that my water company change the meter to a meter with wireless m-bus. So I bought a box for this and now I have 100% correct readings.'' Water Meter shows up in mysensors.json and homeassistant logs but fails to appear in Homeassistant GUI. I have a dozen Nodes already successfully operating I used the default sketch on this page. Just added Node 6 Looks like values are not getting through Thank you for your help this is HA log: 2019-07-04 23:24:05 DEBUG (MainThread) [homeassistant.components.mqtt] Received message on mygateway1-out/6/255/3/0/11: b'Water Meter', 2019-07-04 23:24:05 DEBUG (MainThread) [mysensors.gateway_mqtt] Receiving 6;255;3;0;11;Water Meter, 2019-07-04 23:24:23 DEBUG (MainThread) [homeassistant.components.mqtt] Received message on mygateway1-out/6/255/3/0/11: b'Water Meter', 2019-07-04 23:24:23 DEBUG (MainThread) [mysensors.gateway_mqtt] Receiving 6;255;3;0;11;Water Meter here is the sketch: // Enable debug prints to serial monitor #define MY_DEBUG // Enable and select radio type attached #define MY_RADIO_RF24 #define MY_NODE_ID 6 //++; }``` looks like the problem is the node is NOT sending initial value to gw need your help modifying the sketch accordingly thank you Is it possible to get any help on this page or not? @bereska said in Water Meter Pulse Sensor: Is it possible to get any help on this page or not? Crying out loud most likely will not help... Seems your setup is a little special, so just some assumptions from one using a serial GW and not MyS-MQTT: Your controller is asked for sending an initial value, but has none yet. So no answer is sent out. Triggering the counter on Node side could help to send one (after waiting time has passed). Then have a look at your controller, if there's a value available. If, you might set the correct value, restart your node afterwards and see, if everything now works as expected? ...just let the node count some pulses (your code states: FALLING). So just pull the counter PIN (here: D3) to ground several times. @rejoe2 i did like you said, still no show in HA here is the serial log: __ __ ____ | \/ |_ _/ ___| ___ _ __ ___ ___ _ __ ___ | |\/| | | | \___ \ / _ \ `_ \/ __|/ _ \| `__/ __| | | | | |_| |___| | __/ | | \__ \ _ | | \__ \ |_| |_|\__, |____/ \___|_| |_|___/\___/|_| |___/ |___/ 2.3.0 16 MCO:BGN:INIT NODE,CP=RNNNA---,VER=2.3.0 26 TSM:INIT 28 TSF:WUR:MS=0 34 !TSM:INIT:TSP FAIL 36 TSM:FAIL:CNT=1 38 TSM:FAIL:DIS 40 TSF:TDI:TSL __ __ ____ | \/ |_ _/ ___| ___ _ __ ___ ___ _ __ ___ | |\/| | | | \___ \ / _ \ `_ \/ __|/ _ \| `__/ __| | | | | |_| |___| | __/ | | \__ \ _ | | \__ \ |_| |_|\__, |____/ \___|_| |_|___/\___/|_| |___/ |___/ 2.3.0 16 MCO:BGN:INIT NODE,CP=RNNNA---,VER=2.3.0 26 TSM:INIT 28 TSF:WUR:MS=0 34 TSM:INIT:TSP OK 36 TSM:INIT:STATID=6 38 TSF:SID:OK,ID=6 40 TSM:FPAR 77 TSF:MSG:SEND,6-6-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 532 TSF:MSG:READ,0-0-6,s=255,c=3,t=8,pt=1,l=1,sg=0:0 538 TSF:MSG:FPAR OK,ID=0,D=1 624 TSF:MSG:READ,31-31-6,s=255,c=3,t=8,pt=1,l=1,sg=0:1 1267 TSF:MSG:READ,21-21-6,s=255,c=3,t=8,pt=1,l=1,sg=0:1 1546 TSF:MSG:READ,41-41-6,s=255,c=3,t=8,pt=1,l=1,sg=0:1 2088 TSM:FPAR:OK 2088 TSM:ID 2091 TSM:ID:OK 2093 TSM:UPL 2097 TSF:MSG:SEND,6-6-0-0,s=255,c=3,t=24,pt=1,l=1,sg=0,ft=0,st=OK:1 2103 TSF:MSG:READ,0-0-6,s=255,c=3,t=25,pt=1,l=1,sg=0:1 2109 TSF:MSG:PONG RECV,HP=1 2113 TSM:UPL:OK 2115 TSM:READY:ID=6,PAR=0,DIS=1 2119 TSF:MSG:SEND,6-6-0-0,s=255,c=3,t=15,pt=6,l=2,sg=0,ft=0,st=OK:0100 2127 TSF:MSG:READ,0-0-6,s=255,c=3,t=15,pt=6,l=2,sg=0:0100 2138 TSF:MSG:SEND,6-6-0-0,s=255,c=0,t=17,pt=0,l=5,sg=0,ft=0,st=OK:2.3.0 2148 TSF:MSG:SEND,6-6-0-0,s=255,c=3,t=6,pt=1,l=1,sg=0,ft=0,st=OK:0 2242 TSF:MSG:READ,0-0-6,s=255,c=3,t=6,pt=0,l=1,sg=0:M 2250 TSF:MSG:SEND,6-6-0-0,s=255,c=3,t=11,pt=0,l=11,sg=0,ft=0,st=OK:Water Meter 2260 TSF:MSG:SEND,6-6-0-0,s=255,c=3,t=12,pt=0,l=3,sg=0,ft=0,st=OK:1.1 2273 TSF:MSG:SEND,6-6-0-0,s=1,c=0,t=21,pt=0,l=0,sg=0,ft=0,st=OK: 2281 MCO:REG:REQ 2289 TSF:MSG:SEND,6-6-0-0,s=255,c=3,t=26,pt=1,l=1,sg=0,ft=0,st=OK:2 2297 TSF:MSG:READ,0-0-6,s=255,c=3,t=27,pt=1,l=1,sg=0:1 2304 MCO:PIM:NODE REG=1 2306 MCO:BGN:STP 2310 TSF:MSG:SEND,6-6-0-0,s=1,c=2,t=24,pt=0,l=0,sg=0,ft=0,st=OK: 2318 MCO:BGN:INIT OK,TSP=1 32319 TSF:MSG:SEND,6-6-0-0,s=1,c=2,t=24,pt=0,l=0,sg=0,ft=0,st=OK: @bereska said in Water Meter Pulse Sensor: 32319 TSF:MSG:SEND,6-6-0-0,s=1,c=2,t=24,pt=0,l=0,sg=0,ft=0,st=OK: Logparser states: there was nothing counted (empty payload). So make sure, there really was counted anything. (I didn't check your sketch, just assuming, it's the default one and everything is wired correctly; if that's the case, you should be able to see a different payload than nothing or "0", that your controller might treat as non existent).
https://forum.mysensors.org/topic/4820/water-meter-pulse-sensor/46
CC-MAIN-2019-39
refinedweb
13,936
61.36
The Obligatory Hello World Since every programming paradigm needs to solve the tough problem of printing a well-known greeting to the console we’ll introduce you to the actor-based version. import akka.actor.Actor import akka.actor.Props class HelloWorld extends Actor { override def preStart(): Unit = { // create the greeter actor val greeter = context.actorOf(Props[Greeter], "greeter") // tell it to perform the greeting greeter ! Greeter.Greet } def receive = { // when the greeter is done, stop this actor and with it the application case Greeter.Done ⇒ context.stop(self) } } receive method where we can conclude the demonstration by stopping the HelloWorld actor. You will be very curious to see how the Greeter actor performs the actual task: object Greeter { case object Greet case object Done } class Greeter extends Actor { def receive = { case Greeter.Greet ⇒ println("Hello World!") sender ! Greeter.Done } } This is extremely simple now: after its creation this actor will not do anything until someone sends it a message, and if that happens to be an invitation to greet the world then the Greeter complies and informs the requester that the deed has been done. As a Scala developer you will probably want to tell us that there is no main(Array[String]) method anywhere in these classes, so how do we run this program? The answer is that the appropriate main method is implemented in. Thus you will be able to run the above code with a command similar to the following: java -classpath <all those JARs> akka.Main com.example.HelloWorld This conveniently assumes placement of the above class definitions in package com.example and it further assumes that you have the required JAR files for scala-library and akka-actor available. The easiest would be to manage these dependencies with a build tool, see Using a build tool. Contents
http://doc.akka.io/docs/akka/2.2.3/scala/hello-world.html
CC-MAIN-2014-35
refinedweb
303
61.16
◕ A new product. Popular Google Pages: This article is regarding Standard Library & Namespaces of C++. Last updated on: 24th November 2016. ◕ Let a simple C++ program: #include <iostream> using namespace std; int main() { cout << "Sky is blue!" << endl; return 0; } ◕ Here the iostream file is a part of the standard C++ library. Standard library is a set of pre-written codes in C++. These have been written to carry many common tasks to run the program. Such as: mathematical calculation, inputs and outputs of a program etc. These pre-written codes are very large. As a result we have to give the particular file name which we want to include in our program. ◕ What is Namespaces? Let in the above program we use another variable with the same name iostream. As a result there will be name clashes of iostream. The Namespace is a mechanism or a system in C++ to avoid problems that can arise when duplicate names are used in a program. Let explain this. As mentioned above Standard Library has a long routines or pre-written codes. And as usual it has so many names. So it is quite possible that we might accidentally use the same name of the Standard Library files or operators in our program. So there might be name clashes. To avoid this duplicate situation of name, a mechanism is there in C++. The name of this mechanism is called Namespaces. ◕ How Namespaces works? The Namespaces does its work by associating a given Set of Names from the standard library. These sorts of Names are called Namespace Name. So, every item in the Standard Library has its own Name, plus the Namespace Name. For an example: std::cout; std::endl; Here, the names cout and endl are there in the standard library. As a result their full names are std::cout and std::endl. The two colons sign ( :: ) that separate the Namespace Name from the Name is called the Scope Resolution Operator ( SRO ). This Scope Resolution Operator ( SRO ) has also different functions in C++. ◕ Using the full names of the operators in our program again and again look so uncomfortable. That means if we use the full name std::endl again and again in our programs then it looks so ugly, confusing and time consuming. As a result there is a solution of this. The solution is, just to declare once the full name bellow the line #include <iostream> in our main program. Example: #include <iostream> using namespace std; Here with the declaration, using namespace std; we tell the compiler that I am going to use the Names from the Namespace std without their Namespace Name or the full name. Popular Google Pages: Top of the page
http://riyabutu.com/cpp-articles/standard-library-in-cplus.php
CC-MAIN-2017-51
refinedweb
454
75.5
SegFault in OpenCV 2.4.2 and MinGW on WinXP I am working on a WinXP machine. I downloaded and installed the prebuilt binaries OpenCV-2.4.2.exe. I am trying to build a very simple program using MinGW: #include <opencv2/core/core.hpp> #include <opencv2/highgui/highgui.hpp> using namespace cv; int main() { Mat im = imread("lena.png"); if (im.empty()) { return -1; } imshow("image", im); waitKey(0); return 0; } This is how I am compiling: g++ loadimg.cpp -I"${OPENCV_DIR}/include" -L"${OPENCV_DIR}/x86/mingw/lib" -lopencv_core242 -lopencv_highgui242 -lopencv_imgproc242 -o loadimg where OPENCV_DIR is an environment variable that points to OpenCV location: $ echo $OPENCV_DIR C:\Program Files\OpenCV\2.4.2\build It compiles just fine, but I get a segfault when I try to run it: I am using the the most recent MinGW ( mingw-get update && mingw-get upgrade): $ g++ --version g++.exe (GCC) 4.7.0 Copyright (C) 2012 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. For what it's worth, I can compile and run the above just fine in Visual Studio 10. My problem is using MinGW.... Any help is appreciated Here is the output from GDB: (more)(more) $ gdb ./loadimg:\loadimg.exe...(no debugging symbols found)...done. (gdb) r Starting program: c:\loadimg.exe [New Thread 2404.0xb9c] Program received signal SIGSEGV, Segmentation fault. 0x6fc65dd8 in libstdc++-6!_ZNKSs7_M_dataEv () from C:\MinGW\bin\libstdc++-6.dll (gdb) bt #0 0x6fc65dd8 in libstdc++-6!_ZNKSs7_M_dataEv () from C:\MinGW\bin\libstdc++-6.dll #1 0x6fc65d0b in libstdc++-6!_ZNKSs6_M_repEv () from C:\MinGW\bin\libstdc++-6.dll #2 0x6fc65abb in libstdc++-6!_ZNKSs4sizeEv () from C:\MinGW\bin\libstdc++-6.dll #3 0x6fc8ab0c in libstdc++-6!_ZNSs6assignEPKcj () from C:\MinGW\bin\libstdc++-6.dll #4 0x63bb972a in cv::BmpDecoder::BmpDecoder() () from c:\Program Files\OpenCV\2.4.2\build\x86\mingw\bin\libopencv_highgui242.dll #5 0x63bc470d in cv::ImageCodecInitializer::ImageCodecInitializer() () from c:\Program Files\OpenCV\2.4.2\build\x86\mingw\bin\libopencv_highgui242.dll #6 0x63c3d9d3 in _GLOBAL__sub_I__ZN2cv6imreadERKSsi () from c:\Program Files\OpenCV\2.4.2\build\x86\mingw\bin\libopencv_highgui242.dll #7 0x63b81d07 in __do_global_ctors () at ../mingw/gccmain.c:59 #8 0x63b810f3 in DllMainCRTStartup@12 (hDll=0x63b80000, dwReason=1, lpReserved=0x23fd30) at ../mingw/dllcrt1.c:83 #9 0x7c90118a in ntdll!LdrSetAppCompatDllRedirectionCallback () from C:\WINDOWS\system32\ntdll.dll #10 0x63b80000 in ?? () #11 0x7c91d98a in ntdll!LdrHotPatchRoutine () from C:\WINDOWS\system32\ntdll.dll #12 0x7c921d8c in ntdll!RtlMapGenericMask () from C:\WINDOWS\system32\ntdll.dll #13 0x7c921c87 in ntdll!RtlMapGenericMask () from ... @DaniilOsokin: thanks but using namedWindowdidn't change anything. I'm still getting a segfault.. @cuda.geek: thank you for the fix. I will have to wait for the next release to test it out, unless you know of a way to get the new version of the binaries affected, without building all of OpenCV myself :) I tried gcc-4.6.2 and gcc-4.7.2 gcc-4.6.2 works fine but gcc-4.7.2 crash how did u fix this problem . please help @arpit88: the ideal solution is to build OpenCV from sources using your own version of MinGW (I had to do it for v2.4.3 to work with gcc-4.7.2)
https://answers.opencv.org/question/172/segfault-in-opencv-242-and-mingw-on-winxp/
CC-MAIN-2020-40
refinedweb
553
55.5
Hi, I just released perf 0.3. Major changes: compare_to. Compare commands says if the difference is significant (I copied the code from perf.py) arguments and more of the worker processes to isolated CPUs --json-filecommand line option responsible to measure the elapsed time, useful for microbenchmarks Writing a benchmark now only takes one line: "perf.text_runner.TextRunner().bench_func(func)"! Full example: import time import perf.text_runner def func(): time.sleep(0.001) I looked at PyPy benchmarks: Results can also be serialized to JSON, but the serialization is only done at the end: the final result is serialized. It's not possible to save each run in a JSON file. Running multiple processes is not supported neither. With perf, the final JSON contains all data: all runs, all samples even warmup samples. perf now also collects metadata in each worker process. So it is more safer to compare runs since it's possible to manually check when and how the worker executed the benchmark. For example, the CPU affinity is now saved in metadata. For example, "python -m perf.timeit" now saves the setup and statements in metadata. With perf 0.3, TextRunner now also includes a builtin calibration to compute the number of outter loop iteartions: repeat each sample so it takes between 100 ms and 1 sec (min/max are configurable). Victor
https://mail.python.org/archives/list/speed@python.org/thread/JPMY62FZUCYQMI5CEN6MVOA5ADRBCLMA/
CC-MAIN-2022-05
refinedweb
226
58.89
How to Warm Up the JVM Last modified: April 15, 2018 1. Overview The JVM is one of the oldest yet powerful virtual machines ever built. In this article, we have a quick look at what it means to warm up a JVM and how to do it. 2. JVM Architecture Basics Whenever a new JVM process starts, all required classes are loaded into memory by an instance of the ClassLoader. This process takes place in three steps: - Bootstrap Class Loading: The “Bootstrap Class Loader” loads Java code and essential Java classes such as java.lang.Object into memory. These loaded classes reside in JRE\lib\rt.jar. - Extension Class Loading: The ExtClassLoader is responsible for loading all JAR files located at the java.ext.dirs path. In non-Maven or non-Gradle based applications, where a developer adds JARs manually, all those classes are loaded during this phase. - Application Class Loading: The AppClassLoader loads all classes located in the application class path. This initialization process is based on a lazy loading scheme. 3. What Is Warming up the JVM Once class-loading is complete, all important classes (used at the time of process start) are pushed into the JVM cache (native code) – which makes them accessible faster during runtime. Other classes are loaded on a per-request basis. The first request made to a Java web application is often substantially slower than the average response time during the lifetime of the process. This warm-up period can usually be attributed to lazy class loading and just-in-time compilation. Keeping this in mind, for low-latency applications, we need to cache all classes beforehand – so that they're available instantly when accessed at runtime. This process of tuning the JVM is known as warming up. 4. Tiered Compilation Thanks to the sound architecture of the JVM, frequently used methods are loaded into the native cache during the application life-cycle. We can make use of this property to force-load critical methods into the cache when an application starts. To that extent, we need to set a VM argument named Tiered Compilation: -XX:CompileThreshold -XX:TieredCompilation Normally, the VM uses the interpreter to collect profiling information on methods that are fed into the compiler. In the tiered scheme, in addition to the interpreter, the client compiler is used to generate compiled versions of methods that collect profiling information about themselves. Since compiled code is substantially faster than interpreted code, the program executes with better performance during the profiling phase. Applications running on JBoss and JDK version 7 with this VM argument enabled tend to crash after some time due to a documented bug. The issue has been fixed in JDK version 8. Another point to note here is that in order to force load, we've to make sure that all (or most) classes that are to going be executed need to be accessed. It's similar to determining code coverage during unit testing. The more code is covered, the better the performance will be. The next section demonstrates how this can be implemented. 5. Manual Implementation We may implement an alternate technique to warm up the JVM. In this case, a simple manual warm-up could include repeating the creation of different classes thousands of times as soon as the application starts. Firstly, we need to create a dummy class with a normal method: public class Dummy { public void m() { } } Next, we need to create a class that has a static method that will be executed at least 100000 times as soon as application starts and with each execution, it creates a new instance of the aforementioned dummy class we created earlier: public class ManualClassLoader { protected static void load() { for (int i = 0; i < 100000; i++) { Dummy dummy = new Dummy(); dummy.m(); } } } Now, in order to measure the performance gain, we need to create a main class. This class contains one static block that contains a direct call to the ManualClassLoader's load() method. Inside the main function, we make a call to the ManualClassLoader's load() method once more and capture the system time in nanoseconds just before and after our function call. Finally, we subtract these times to get the actual execution time. We've to run the application twice; once with the load() method call inside the static block and once without this method call: public class MainApplication { static { long start = System.nanoTime(); ManualClassLoader.load(); long end = System.nanoTime(); System.out.println("Warm Up time : " + (end - start)); } public static void main(String[] args) { long start = System.nanoTime(); ManualClassLoader.load(); long end = System.nanoTime(); System.out.println("Total time taken : " + (end - start)); } } Below the results are reproduced in nanoseconds: As expected, with warm up approach shows much better performance than the normal one. Of course, this is a very simplistic benchmark and only provides some surface-level insight into the impact of this technique. Also, it's important to understand that, with a real-world application, we need to warm up with the typical code paths in the system. 6. Tools We can also use several tools to warm up the JVM. One of the most well-known tools is the Java Microbenchmark Harness, JMH. It's generally used for micro-benchmarking. Once it is loaded, it repeatedly hits a code snippet and monitors the warm-up iteration cycle. To use it we need to add another dependency to the pom.xml: > We can check the latest version of JMH in Central Maven Repository. Alternatively, we can use JMH's maven plugin to generate a sample project: mvn archetype:generate \ -DinteractiveMode=false \ -DarchetypeGroupId=org.openjdk.jmh \ -DarchetypeArtifactId=jmh-java-benchmark-archetype \ -DgroupId=com.baeldung \ -DartifactId=test \ -Dversion=1.0 Next, let's create a main method: public static void main(String[] args) throws RunnerException, IOException { Main.main(args); } Now, we need to create a method and annotate it with JMH's @Benchmark annotation: @Benchmark public void init() { //code snippet } Inside this init method, we need to write code that needs to be executed repeatedly in order to warm up. 7. Performance Benchmark In the last 20 years, most contributions to Java were related to the GC (Garbage Collector) and JIT (Just In Time Compiler). Almost all of the performance benchmarks found online are done on a JVM already running for some time. However, However, Beihang University has published a benchmark report taking into account JVM warm-up time. They used Hadoop and Spark based systems to process massive data: Here HotTub designates the environment in which the JVM was warmed up. As you can see, the speed-up can be significant, especially for relatively small read operations – which is why this data is interesting to consider. 8. Conclusion In this quick article, we showed how the JVM loads classes when an application starts and how we can warm up the JVM in order gain a performance boost. This book goes over more information and guidelines on the topic if you want to continue. And, like always, the full source code is available over on GitHub.
https://www.baeldung.com/java-jvm-warmup
CC-MAIN-2020-40
refinedweb
1,179
53
Functions This material was written by Aasmund Eldhuset; it is owned by Khan Academy and is licensed for use under CC BY-NC-SA 3.0 US. Please note that this is not a part of Khan Academy's official product offering. Declaration. Calling Functions are called the same way as in Python: val greeting = happyBirthday("Anne", 32) If you don't care about the return value, you don't need to assign it to anything. Returning). Overloading). Varargs and optional/named parameters). A parameter with a default value must still specify its type explicitly. Like in Python, the named arguments can be reordered at will at the call site: fun foo(decimal: Double, integer: Int, text: String = "Hello") { ... } foo(3.14, text = "Bye", integer = 42) foo(integer = 12, decimal = 3.4) In Python, the expression for a default value is evaluated once, at function definition time. That leads to this classic trap, where the developer hopes to get a new, empty list every time the function is called without a value for numbers, but instead, the same list is being used every time: def tricky(x, numbers=[]): # Bug: every call will see the same list! numbers.append(x) print numbers In Kotlin, the expression for a default value is evaluated every time the function is invoked. Therefore, you will avoid the above trap as long as you use an expression that produces a new list every time it is evaluated: fun tricky(x: Int, numbers: MutableList<Int> = mutableListOf()) { numbers.add(x) println(numbers) } For this reason, you should probably not use a function with side effects as a default value initializer, as the side effects will happen on every call. If you just reference a variable instead of calling a function, the same variable will be read every time the function is invoked: numbers: MutableList<Int> = myMutableList. If the variable is immutable, each call will see the same value (but if the value itself is mutable, it might change between calls), and if the variable is mutable, each call will see the current value of the variable. Needless to say, these situations easily lead to confusion, so a default value initializer should be either a constant or a function call that always produces a new object with the same value..
https://kotlinlang.org/docs/tutorials/kotlin-for-py/functions.html
CC-MAIN-2019-13
refinedweb
381
55.68
If you want to schedule you software components then it must implement the Job interface which override the execute() method. Here is the interface: package org.quartz; public interface Job { public void execute(JobExecutionContext context) throws JobExecutionException; } The JobExecutionContext object which is passed to execute() method provides the job instance with information about its "run-time" environment - a handle to the Scheduler that executed it, a handle to the Trigger that triggered the execution, the job's JobDetail object, and a few other items. The JobDetail object is created at the time the Job is added to the scheduler. The JobDetail object various property settings for the Job, as well as a JobDataMap, which can be used to store state information for a given instance of your job class. Trigger objects are used to start the execution of jobs. When you want to schedule a job, you instantiate a trigger and set' its properties to provide the scheduling according to your need. There are currently two types of triggers: SimpleTrigger and CronTrigger. Generally, SimpleTrigger is used if you need just single execution of a job at a given moment in time or if you need to start a job at a given time, and have it repeat N times, with a delay of T between executions. CronTrigger is used when you want to triggering based on calendar-like schedules - such as "every Saturday, at noon" or "at 12:35 on the 15th day of every month." Why Job & Triggers Many job schedulers do not have separate notions of jobs and triggers. Some job Schedulers define a 'job' as simply an execution time with some small job identifier. And some others are much like the combination of Quartz's job and trigger objects. While developing Quartz, we decided that it made sense to create a separation between the schedule and the work to be performed on that schedule. Identifiers Jobs and Triggers are predefined identifying names as they are registered with the Quartz scheduler. You can placed jobs and triggers into 'groups' also, for organizing the jobs and triggers into categories for later maintenance. The name of a job or trigger must be unique within its group. More about Job & JobDetail In this section you will understand some more things about nature of jobs, about the execute() method of the Job interface, and about the JobDetails. While a class implementing the job interface that is the actual 'job', and you have to inform to Quartz about some attributes that you may want job to have. That can be done by the JobDetail class. The JobDetail instance refers to the job to be executed by just providing the job's class. When scheduler executes the job, it creates the new instance of the job class before invoking the execute() method. The jobs must have a no-argument constructor that is the ramification of this behaviour. And it is not useful to define data members on the job class - as their values would be cleared every time job executes. The JobDataMap, which is part of the JobDetail object. It is useful to provide properties/configuration for Job instance and to keep track of a job's state between executions. The JobDataMap can be hold any number of (serializable) objects which you want that available to the job instance when it executes. JobDataMap is an implementation of the Java Map interface, and has some added convenience methods for storing and retrieving data of primitive types Here is a code of putting data into the JobDataMap before adding the job to the Scheduler: jobDetail.getJobDataMap().put("name", "Rose India"); jobDetail.getJobDataMap().put("floatValue", 5.141f); Here is a of getting data from the JobDataMap during the job's execution: JobDataMap databMap = context.getJobDetail().getJobDataMap(); String name = dataMap.getString("name"); float fvalue = dataMap.getFloat("floatValue"); Description of the following example: In the following example we are going to develop a simple Quartz Scheduler application with the help of Quartz framework. To make a Quartz application we need to make two java classes. In one class (job class) we provide the job that we want to execute and in another class (schedule class) we provide the schedule to this class. Job class (NewJob.java) is a implementation of Job interface and it overrides the execute() method that contains the job which we want to execute and throws JobExecutionException. And in schedule class (NewSchedule.java) we just provide the schedule to this job. That program displays a simple message, date, time, job name, group name and float value indefinite times after the specified time. Description of Code: getName() ; By this method we get the job name that specified in Schedule class in JobDetail properties. getGroup() ; By this method we get job group name that specified in Schedule class in JobDetail properties. getJobDataMap() ; This method just return the JobDataMap object. And by JobDataMap object we can invoke the getString() and getFloat() method to retrieve any String or any float value that specified in Schedule class. put() ; This method is used to just insert the object into the JobDataMap object. Here is the code of Job Class (NewJob.java) : import java.util.Date; import org.quartz.*; import org.quartz.Job; import org.quartz.JobExecutionContext; import org.quartz.JobExecutionException; public class NewJob implements Job { public void execute(JobExecutionContext jcontext) throws JobExecutionException { System.out.println("Welcome to RoseIndia.Net :"+new Date()); String jname = jcontext.getJobDetail().getName(); String jgroup = jcontext.getJobDetail().getGroup(); System.out.println("job Name :"+jname+" Job Group Name :"+jgroup); JobDataMap jdMap = jcontext.getJobDetail().getJobDataMap(); String name = jdMap.getString("name"); float fval=jdMap.getFloat("floatValue"); System.out.println("Name :"+name+" Float value is :"+fval); } } Here is code of Schedule Class (NewSchedule.java) : import java.util.Date; import org.quartz.JobDetail; import org.quartz.SchedulerFactory; import org.quartz.impl.StdSchedulerFactory; import org.quartz.*; public class NewSchedule { public NewSchedule()throws Exception{ SchedulerFactory sf = new StdSchedulerFactory(); Scheduler sched = sf.getScheduler(); JobDetail jd = new JobDetail("myjob","group",NewJob.class); jd.getJobDataMap().put("name", "Rose India"); jd.getJobDataMap().put("floatValue",5.14f); SimpleTrigger simpleTrigger = new SimpleTrigger("mytrigger",sched.DEFAULT_GROUP, new Date(),null,SimpleTrigger.REPEAT_INDEFINITELY,30L*1000L); sched.scheduleJob(jd, simpleTrigger); sched.start(); } public static void main(String args[]){ try{ new NewSchedule(); }catch(Exception e){} } } Output of the program : Stateful vs. Non-Stateful Jobs A Job instance can be defined as Stateful or Non-Stateful. Non-Stateful jobs only have their JobDataMap and it stored at the time when the jobs are added to the scheduler. This means during execution of the job any changes are made to the job data map will be lost and a Stateful job is just opposite - its JobDataMap is re-stored after every execution of the job. One disadvantage of Stateful job is that it cannot be executed concurrently. Or in other words: In Stateful job, and a trigger attempts to 'fire' the job while it is already executing, the trigger will block (wait) until the previous execution completes. You can specify a job as Stateful by implementing the StatefulJob interface instead of Job interface. Other Attributes of Jobs Some other properties which can be defined for a job instance through the JobDetail object: The Job execute() Method The only JobExecutionException (including RunTimeExceptions) are allowed to throw from the execute() method. That's why, you should wrap the entire body of this method in 'try-catch' block.: Jobs & Triggers Post your Comment
http://www.roseindia.net/quartz/jobs-triggers.shtml
CC-MAIN-2016-30
refinedweb
1,231
56.96
On Mon, 8 Jul 2002, Nicola Ken Barozzi wrote: > >>>- Better expression usage. See Jexl. Access to java objects rather than > >>>just flat string properties. > >> > >>Possible in myrmidon but will never be possible in ant1.x due to backwards > >>compatability. > > > > > > What has 'backward compatibility' to do with that ? > > > > I actually have a working ProjectHelperImpl for ant1 that supports > > expersions in ${properties}, using ${lang:expression} style ( lang: is > > used to locate the evaluator ). I'm trying to integrate JXPath and few > > other EL. > > > > The only possible problem may be that someone may have a build file > > with a variable with that name. However the 'dynamic' properties will > > be enabled only by setting a magic property, so the impact is absolutely > > zero. > > Cool! :-) > > Keep us informed :-) > > If you get this out soon Ant 1.6 will have imports, antlibs, > expressions! :-D Antlib and imports can also be done using ProjectHelper hooks - and all that should work fine with ant1.5 ( at least that's my target ). The actual implementation is trivial ( ProjectHelper reads the XML and calls the ${} substitution ) - finding a good way to plug different evaluators and more important a good story for namespaces is the bigger problem. ( and of course, finding time ). The code is already checked in proposals/sandbox/embed, look at RuntimeConfigurable2. ( most of the changes are to support sax2 attributes, the actual 'dynamic properties' is just the last method - I'm still working on the plugin mechanism ). Costin -- To unsubscribe, e-mail: <mailto:ant-dev-unsubscribe@jakarta.apache.org> For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>
http://mail-archives.eu.apache.org/mod_mbox/ant-dev/200207.mbox/%3CPine.LNX.4.44.0207080942020.1693-100000@costinm.sfo.covalent.net%3E
CC-MAIN-2021-10
refinedweb
263
50.23
I’m not a big fan of programming puzzles. They seem to be less about solving a puzzle and more about finding the exact trick the puzzle writer wants you to find. I love Project Euler for programming challenges because you aren’t trying to outwit the puzzle writer, you’re trying to outwit yourself. A link to Colossal Cue Adventure showed up on HN the other day. It’s a text game (like Zork) where you’re presented with a series of puzzles to solve by programming (or by hand if you’re crazy). The first one took me over an hour (closer to two probably) of basically guessing at what the puzzle writer wanted me to do before finally stumbling across the solution. I was kind of irritated while I was trying to solve it, but in hindsight I was over-thinking the whole thing. There are a lot of numbers it throws at you in the context of the game, and only a few are important. EDIT: I don’t mean to seem so critical of the puzzles. Certainly someone more experienced in programming or better at math found them to be much more intuitive. Sometimes you just get naturally irked at something you have to fight so hard! The puzzles are really quite well presented. Kudos to Cue for making something so compelling that even a puzzle hater had to try it. Don’t read on if you want to try the puzzle yourself. The first puzzle presents a roulette wheel that’s special because it’s “VAX MTH%RANDOM % 36” roulette wheel. Other clues in the game basically state that you have to replicate how the VAX random number generator works, and finding the solution seems to have to do with taking %36 of the result of the generator. The number sequence 6, 19, 16 shows up in a few places, too. VAX’s MTH%RANDOM is a linear congruential generator that has a specific multiplier (the value for ‘a’ in the formula the link brings you to) of 69069. You pick a starting seed to feed to the formula, and the result is the next seed to feed to the formula. This provides a sequence that’s supposed to seem random. My first guess was that you’re supposed to find the starting seed that provides a series of results that if you take those results %36 you get 6, 19, and 16. I was sort of on the right track, but because of the way I wrote the test program I never figured it out. The test program output this… Initial Seed: N, first result % 36 = X, second result % 36 = y, third result % 36 = Z …and I wrote tests to see if X, Y, and Z were 6, 19, and 16. I didn’t do anything silly like send %36 of the resulting seed back to the generator. This avenue might have discovered the results if I had been paying attention to the output. What you’re really supposed to do is start with the seed being 6. The result %36 is 19, and the next result %36 is 16. Ok, so there is a familiar number sequence. The next result %36 is 29, which you give back to the game (you place a bet on 29). 29 was correct, but you’re supposed to place two bets one after the other. What really threw me for a loop is that the game gives you more numbers (the numbers the ball temporarily lands on) before landing on 29. I started the number generator over again to find the next bet I’m supposed to place with those numbers, but nothing came of it. After much banging away I (completely on a whim) went back to the original sequence and played the number that came after 29, which was the correct answer. So it was a “find the next two numbers in the sequence” puzzle wrapped up in a lot of confusing misinformation. Here’s my small program that lists the first ten numbers in the sequence: #include <stdio.h> #include <math.h> int VAXrand(unsigned int seed) { unsigned int s = ((69069 * seed + 1) % (unsigned int)pow(2,32)); return s; } int main() { unsigned int tempseed = 0; //starting seed unsigned int res = 0; //store result unsigned int n = 0; tempseed = 6; for (n = 0; n < 10; n++) { res = VAXrand(tempseed); printf("Starting seed: %u, seed mod 36: %u, result: %u, result mod 36: %u\n", tempseed, tempseed%36, res, res%36); tempseed = res; } return 0; } There are two more puzzles in the game. I might tackle the next one next weekend. Thanks! I pasted the second puzzle into a code editor and tried to untangle it. In the end I “solved” it through guessing supported bruteforce. The third one left me clueless for now. Now I get it. Easier than I thought. “You arrive at an old fire road. There is a troll there, who takes 8 of your chips, and then resumes moderating offensive subreddits.”
https://chrisheydrick.com/2013/01/20/my-solution-to-the-first-colossal-cue-adventure-puzzle/
CC-MAIN-2017-34
refinedweb
842
78.59
(Analysis by Mark Gordon) This problem asks us to find the largest cycle in a directed graph going through node 1 where one of the edges may be traversed backwards. Suppose the optimal solution follows the edge v->u backwards, instead going from u to v. Then it must be the case that node 1 can reach node u and node v can reach node 1. This immediately suggests an algorithm; loop over all edges v->u that satisfy this property and quickly compute the number of nodes that can be reached along a path from v to 1 to u. Doing this directly on the graph could appear a bit difficult given that Bessie may need to return to the same node several times to visit the maximum number of distinct nodes. However, after finding the Strongly Connected Components of the graph this problem becomes tractable. Tarjan's algorithm, among others, is one algorithm that can be used to do this in $O(V + E)$ time. Once we compute the Strongly Connected Components (SCCs) of the graph we can create a new Directed Acyclic Graph (DAG) where each node is weighted by the number of nodes in the corresponding strongly connected component. Now we can use dynamic programming to compute the maximum path weight of any path going from an SCC ending in the SCC containing node 1. Because the graph is acyclic this recurrence relation is well defined. We can do the same thing to find the maximum path weight from the SCC containing node 1 to any other SCC. After calculating each of these values we simply need to iterate over all edges in the SCC graph and find the one that maximizes the sum of these two paths (making sure to only count the nodes in the SCC containing 1 once). Additionally, we should make sure to handle the edge cases where the SCC containing 1 cannot reach any other SCCs or cannot be reach by any other SCCs or both. Here's my solution that implements these ideas using Tarjan's algorithm for SCC computation. #include <iostream> #include <vector> #include <set> #include <algorithm> #include <cstring> #include <cstdio> #define MAXN 100010 using namespace std; /* Given a graph (represented by the adjacency list E) and a labelling of nodes * into components, returns a new graph (as an adjacency list) where there is an * edge between components if there was an edge that crossed the components in * the original graph. Useful after computing SCCs to obtain the SCC DAG. * ~O(V + E) */ vector<vector<int> > collapse(const vector<vector<int> >& E, const vector<int>& L) { int N = E.size(); vector<vector<int> > R(*max_element(L.begin(), L.end()) + 1, vector<int>()); for(int i = 0; i < N; i++) { int x = L[i]; for(int j = 0; j < E[i].size(); j++) { int y = L[E[i][j]]; if(x != y) R[x].push_back(y); } } for(int i = 0; i < R.size(); i++) { sort(R[i].begin(), R[i].end()); R[i].resize(unique(R[i].begin(), R[i].end()) - R[i].begin()); } return R; } int scc_nidx; int scc_idx[MAXN]; int scc_lnk[MAXN]; int scc_lbl; int scc_sp; int scc_stk[MAXN]; /* Helper function used by scc implementing Tarjan's SCC algorithm */ void scc_dfs(int u, const vector<vector<int> >& E, vector<int>& L) { int idx = scc_idx[u] = scc_nidx++; int& lnk = scc_lnk[u]; lnk = idx; scc_stk[scc_sp++] = u; for(int i = 0; i < E[u].size(); i++) { int v = E[u][i]; if(scc_idx[v] == -1) { scc_dfs(v, E, L); lnk = min(lnk, scc_lnk[v]); } else { lnk = min(lnk, scc_idx[v]); } } if(idx == lnk) { for(int y = -1; y != u; ) { y = scc_stk[--scc_sp]; scc_idx[y] = E.size(); L[y] = scc_lbl; } scc_lbl++; } } /* Return a labelling of the M SCCs. * The ith vertex is part of the L[i]-th SCC. O(V + E) */ vector<int> scc(const vector<vector<int> >& E) { int N = E.size(); vector<int> L(N, -1); memset(scc_idx, -1, sizeof(int) * N); scc_nidx = scc_lbl = scc_sp = 0; for(int i = 0; i < N; i++) { if(L[i] == -1) { scc_dfs(i, E, L); } } return L; } int memo[2][100010]; /* Computes the maximum weight path from s to t. * Doesn't include the weight of node t. Returns -2 if s cannot reach t. */ int solve(int cid, const vector<int>& W, const vector<vector<int> >& E, int s, int t) { if (s == t) { return 0; } int& ref = memo[cid][s]; if (ref != -1) { return ref; } ref = -2; for (int i = 0; i < E[s].size(); i++) { int res = solve(cid, W, E, E[s][i], t); if (res >= 0) { ref = max(ref, W[s] + res); } } return ref; } int main() { int N, M; cin >> N >> M; vector<vector<int> > E(N); for (int i = 0; i < M; i++) { int u, v; cin >> u >> v; u--; v--; E[u].push_back(v); } /* Compute the SCC graph and its reverse */ vector<int> L = scc(E); E = collapse(E, L); int st = L[0]; vector<vector<int> > RE(E.size()); for (int i = 0; i < E.size(); i++) { for (int j = 0; j < E[i].size(); j++) { RE[E[i][j]].push_back(i); } } /* Compute the weight of each node in the SCC graph. */ vector<int> W(E.size(), 0); for (int i = 0; i < N; i++) { W[L[i]]++; } /* Try each edge in the SCC graph. */ int result = W[st]; memset(memo, -1, sizeof(memo)); for (int i = 0; i < E.size(); i++) { /* Compute the max path weight from node i to st. */ int r1 = solve(0, W, E, i, st); if (r1 < 0) { continue; } for (int j = 0; j < E[i].size(); j++) { /* Compute the max path weight from node st to E[i][j]. */ int r2 = solve(1, W, RE, E[i][j], st); if (r2 >= 0) { result = max(result, W[st] + r1 + r2); } } } cout << result << endl; return 0; }
http://usaco.org/current/data/sol_grass_gold.html
CC-MAIN-2018-17
refinedweb
976
69.82
About about c and java about c and java i need java and c language interview and objective... visit the following links: java - Servlet Interview Questions java servlet interview questions Hi friend, For Servlet interview Questions visit to : Thanks about session about session hey i want to insert userid and username of the user who have currently loggedin in servlet using prepared statement Please visit the following link: Confuse about Quartz or Thread. - JSP-Servlet Confuse about Quartz or Thread. Hi, Thanx for reply. Is it make... productivity? Please help me. I am too confuse about this topic. Thanx... process. In Java Programming language, thread is a sequential path of code about developing a website about developing a website hi i want to create a website of on online shopping in java with database connectivity in oracle .so what... the following links: Struts Shopping Cart Application JSP Servlet Shopping Cart About Java About Java Hi, Can anyone tell me the About Java programming language? How a c programmer can learn Java development techniques? Thanks Hi, Read about java at. Thanks About running the Tomcat Server About running the Tomcat Server HI I want to run a simple program on servlet and the application is a simple program Hello world to print on Internet browser. And the directory for servlet is, Please explain in detail. Read for more information. http About configuring Servlet About configuring Servlet Hi I culdn't run Apache Tomcat (i already installed Tomcat 5.0 version) on Internet Browser.when i finished installing Tomcat i typed host:8080/ in the internet Browser Java Servlet - Servlet Interview Questions Java Servlet My Servlet Program is generating Compile time errors... be that you have not set the classpath of your java-servlet-api.jar in the environment variables. Visit the following link to know about setting classpath About java About java how we insert our database data into the jTable in java or how we show database content into the JTable in java Hi Friend, Try the following code: import java.io.*; import interview question - Servlet Interview Questions interview question What is Servlet? Need interview questions on Java Servlet Servlet is one of the Java technologies which is used for developing server side web application.There are two types of Java Servlet Generic Java - JSP-Servlet cmd + (Enter Key) 2. Change the directory to the Servlet file(i.e .java) and 3...Java What a the steps to compile a Servlet Programe. Hi Anoop, Here we are sending you a link where you can know about how Introduction To Java Servlet Technology Introduction To Java Servlet Technology In this tutorial you will learn about the Java servlet technology and why it came into existence, what are its features etc. Java Servlet is a technology to generate the dynamic content on web Java : Servlet Tutorials - Page 2 Java : Servlet Tutorials Context attributes in Servlet All Servlets... to a servlet. Quick Introduction to Java Servlets java - JSP-Servlet java getting 404 status (resource not found)wana know about direcrty structure and whats servlet mapping and hw to do it Hi Friend, Please visit the following links: about a program about a program hi can anyone suggest program for this question.. it wil really be helpful.its based on *servlet programming* 1. First page should display a dropdown of mathematical operation (Add, Subtract, Multiply, Divide about J2EE. - Java Beginners about J2EE. I know only core Java ... what chapter I will be learn to know about J2EE Servlet - Java Beginners Servlet i'm a new boy in java. i have a question which is about the servlet. i have make a simple web application which is user can input data... javax.servlet.http.*; public class Servlet extends HttpServlet{ public void do Map | Business Software Services India Java Servlet Tutorial Section... | Snooping Headers | Dice Roller in Java Servlet | Getting Init Parameter... value Using Servlet | Hit Counter Servlet Java Servlet Tutorial Section Java - JSP-Servlet Java, JSP vs Servlet If anyone have idea about how to use all these technologies in one project ..please share with me. Thanks about banking application - Servlet Interview Questions about banking application i put 2+ fake on banking application... asking about the how you r using jdbc (rdbms oracle). tell about this problem  ... and servlet, then visit the following link: About Constructor About Constructor How many objects are create when this code will execute... String string = new String("Java is best Lang."); tell me the number of object of string which will create . All are those are eligible for garbage About tld files - JSP-Interview Questions About tld files What are tag library descriptor files & what is the difference between tld files and java beans? Hi Friend, The .tld files are the XML document that contains information about the whole library Java Servlet : Hello World Example Java Servlet : Hello World Example In this tutorial, we are discussing about Servlet with simple Hello World Example. Java Servlet : A servlet is web... across HTTP. Servlet is configured in configuration file that is web.xml. Servlet Servlet Why is Servlet so popular? Because servlets are platform-independent Java classes that are compiled to platform-neutral byte code that can be loaded dynamically into and run by a Java technology-enabled Web servlet servlet I want a fully readymade project on online voting system with code in java servlet and database backend as msaccess.can u plz send me as soon as possible Java servlet Java servlet What is servlet - JSP-Servlet java hi friends plz give basic information about Taglibraries,Jstl,CoustamTags with ex? Hi friend, Read for more information. amardeep   Servlet the same error <web-app> <servlet> <servlet-name>InsertServlet</servlet-name> <servlet-class>InsertServlet</servlet-class> </servlet> <servlet-mapping> <servlet-name> About inheritanance in JAVA About inheritanance in JAVA What is need foe the Inheritance in though we can access any method of any class declared publicly in simple class calling java (servlet) - JSP-Servlet java (servlet) how can i disable back button in brower while using servlet or JSP java - JSP-Servlet and deployment process.Read more at about maven at java - JSP-Servlet When to use servlert and when to use JSP? Hi, i am confuse about when to use servlert and when to use JSP? When to use servlert and when to use JSP:JSPUse JSP where the complexity of the HTML is the most servlet ); } } } this is the code for .java servlet am able to run sucessful but when i give wrong Java(Servlet) - Servlet Interview Questions Java Servlet examples Java and Servlet programming examples Java - Java Server Faces Questions Java I want complete details about Java Server Faces. Hi friend, Java Server Faces is also called JSF. JavaServer Faces is a new framework for building Web applications using JSP and Servlet. Java Server java - JSP-Servlet then also this program running. So sure about this. Thanks Rajanikant About RoseIndia.net About RoseIndia.Net RoseIndia.Net is global services .... Our technical teams skills include Java (J2EE) programming, ASP, C#, PHP... Framework, Web Services, Languages Java 1.5, Jakarta Torque, Ant Deploying Servlet in Weblogic 9.2 - Servlet Interview Questions type of request, it invokes the servlet, passing to it details about the request...Deploying Servlet in Weblogic 9.2 Hi Friends, I am new to web.... Generic servlets A servlet extends a server's functionality by offering Java Servlet : Reading Form Data Example Java Servlet : Reading Form Data Example In this tutorial, we are discussing about reading form data of a servlet. Reading Form Data : There are three methods of servlet to handle the form data. These are listed below Java Example projects about STRUTS Java Example projects about STRUTS Hai... I completed MCA but i have no job in my hands. But i do some small projects about STRUTS. Please send me some example projects about STRUTS. Please visit the following link Servlets - JSP-Servlet Servlets How can we differentiate the doGet() and doPost() methods in Servlets Hi friend, Difference between doGet() and doPost(). mvc:default-servlet-handler In this section, you will learn about configuring tag using Java config or XML Namespace Servlet - JSP-Servlet Servlet and Java Code Example and source code in Servlet and JSP servlet - IDE Questions Java Servlet Programming What is Java Servlet Programming? ... to the right customer.To know more about servlet click on the link: http... limitations of CGI programs.Please learn Servlet at desing patterns - Struts About desing patterns How many Design Patterns are there supported by Java? and what is an Application Controller? what is the difference between Front Controller & Application Contorller? Hi Friend, Ask Questions? If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for. Ask your questions, our development team will try to give answers to your questions.
http://www.roseindia.net/tutorialhelp/comment/21517
CC-MAIN-2013-20
refinedweb
1,474
64.41
Navigate front-end codebases in Sublime Text $ which node /home/tvba5179/Documents/Build/git/public/nvm/versions/node/v6.9.2/bin/node Hi, Joel, nice to e-meet you. I want to add a new feature to all of your dependents repos. It is kind of a tree shaking, but not exactly. Let's say I have the following file structure src/myFile.js src/utils/isString.js src/utils/isBoolean.js src/utils/index.js The index in the utils folder is only import everything from the utils folder and just export it. So in myFile.js i can do something like: import { isString } from './utils'; (without referring to the actual file, in this case isString.js) This will create a dependency tree like this: myFile.js -> index.js -> (isString.js, isBoolean.js) but actually, myFile is not importing anything from isBoolean so it's not a real dependency. This pattern is very popular, and the index files may contain a lot of dependencies which make my dependencies trees looks very ugly and verbose (and also creates circular trees sometimes). What I want to do, is walk through the index.js file to the real dependency and add the real dependency only. This can be done in theory by identifying that the index file is only import and export stuff (without any real logic/change to them). along with the analyzing of the specific object I imported. What do you think will be the best way to implement this within your packages? Thanks a lot, Gilad.
https://gitter.im/mrjoelkemp/Dependents
CC-MAIN-2019-51
refinedweb
258
58.99
Reading time: 5 – 8 minutes Nowadays last version of browsers support websockets and it’s a good a idea to use them to connect to server a permanent channel and receive push notifications from server. In this case I’m going to use Mosquitto (MQTT) server behind lighttpd with mod_websocket as notifications server. Mosquitto is a lightweight MQTT server programmed in C and very easy to set up. The best advantage to use MQTT is the possibility to create publish/subscriber queues and it’s very useful when you want to have more than one notification channel. As is usual in pub/sub services we can subscribe the client to a well-defined topic or we can use a pattern to subscribe to more than one topic. If you’re not familiarized with MQTT now it’s the best moment to read a little bit about because that interesting protocol. It’s not the purpose of this post to explain MQTT basics. A few weeks ago I set up the next architecture just for testing that idea: The browser Now it’s time to explain this proof of concept. HTML page will contain a simple Javascript code which calls mqttws31.js library from Paho. This Javascript code will connect to the server using secure websockets. It doesn’t have any other security measure for a while may be in next posts I’ll explain some interesting ideas to authenticate the websocket. At the end of the post you can download all source code and configuration files. But now it’s time to understand the most important parts of the client code. client = new Messaging.Client("ns.example.tld", 443, "unique_client_id"); client.onConnectionLost = onConnectionLost; client.onMessageArrived = onMessageArrived; client.connect({onSuccess:onConnect, onFailure:onFailure, useSSL:true}); Last part is very simple, the client connects to the server and links some callbacks to defined functions. Pay attention to ‘useSSL’ connect option is used to force SSL connection with the server. There are two specially interesting functions linked to callbacks, the first one is: function onConnect() { client.subscribe("/news/+/sport", {qos:1,onSuccess:onSubscribe,onFailure:onSubscribeFailure}); } As you can imagine this callback will be called when the connections is established, when it happens the client subscribes to all channels called ‘/news/+/sports’, for example, ‘/news/europe/sports/’ or ‘/news/usa/sports/’, etc. We can also use, something like ‘/news/#’ and it will say we want to subscribe to all channels which starts with ‘/news/’. If only want to subscribe to one channel put the full name of the channel on that parameter. Next parameter are dictionary with quality of service which is going to use and links two more callbacks. The second interesting function to understand is: function onMessageArrived(message) { console.log("onMessageArrived:"+message.payloadString); }; It’s called when new message is received from the server and in this example, the message is printed in console with log method. The server I used an Ubuntu 12.04 server with next extra repositories: # lighttpd + mod_webserver deb precise main deb-src precise main # mosquitto deb precise main deb-src precise main With these new repositories you can install required packages: apt-get install lighttpd lighttpd-mod-websocket mosquitto mosquitto-clients After installation it’s very easy to run mosquitto in test mode, use a console for that and write the command: mosquitto, we have to see something like this: # mosquitto 1379873664: mosquitto version 1.2.1 (build date 2013-09-19 22:18:02+0000) starting 1379873664: Using default config. 1379873664: Opening ipv4 listen socket on port 1883. 1379873664: Opening ipv6 listen socket on port 1883. The configuration file for lighttpd in testing is: server.modules = ( "mod_websocket", ) websocket.server = ( "/mqtt" => ( "host" => "127.0.0.1", "port" => "1883", "type" => "bin", "subproto" => "mqttv3.1" ), ) server.document-root = "/var/www" server.upload-dirs = ( "/var/cache/lighttpd/uploads" ) server.errorlog = "/var/log/lighttpd/error.log" server.pid-file = "/var/run/lighttpd.pid" server.username = "www-data" server.groupname = "www-data" server.port = 80 $SERVER["socket"] == ":443" { ssl.engine = "enable" ssl.pemfile = "/etc/lighttpd/certs/sample-certificate.pem" server.name = "ns.example.tld" } Remember to change ‘ssl.pemfile’ for your real certificate file and ‘server.name’ for your real server name. Then restart the lighttpd and validate SSL configuration using something like: openssl s_client -host ns.example.tld -port 443 You have to see SSL negotiation and then you can try to send HTTP commands, for example: “GET / HTTP/1.0” or something like this. Now the server is ready. The Test Now you have to load the HTML test page in your browser and validate how the connections is getting the server and then how the mosquitto console says how it receives the connection. Of course, you can modify the Javascript code to print more log information and follow how the client is connected to MQTT server and how it is subscribed to the topic pattern. If you want to publish something in MQTT server we could use the CLI, with a command mosquitto_pub: mosquitto_pub -h ns.example.tld -t '/news/europe/sport' -m 'this is the message about european sports' Take a look in your browser Javascript consle you have to see how the client prints the message on it. If it fails, review the steps and debug each one to solve the problem. If you need help leave me a message. Of course, you can use many different ways to publish messages, for example, you could use python code to publish messages in MQTT server. In the same way you could subscribe not only browsers to topics, for example, you could subscribe a python code: import mosquitto("the_client_id") mqttc.on_message = on_message mqttc.on_connect = on_connect mqttc.on_publish = on_publish mqttc.on_subscribe = on_subscribe mqttc.connect("ns.example.tld", 1883, 60) mqttc.subscribe("/news/+/sport", 0) rc = 0 while rc == 0: rc = mqttc.loop() Pay attention to server port, it isn’t the ‘https’ port (443/tcp) because now the code is using a real MQTT client. The websocket gateway isn’t needed. The files - mqtt.tar.gz – inside this tar.gz you can find all referenced files
http://oriolrius.cat/blog/2013/09/25/server-send-push-notifications-to-client-browser-without-polling/
CC-MAIN-2019-13
refinedweb
1,016
58.18
I can't wrap my head around how I would implement the following code using a dynamic array. Two stacks from this class will be used to make a queue class. I know how dynamic arrays work, but they're not exactly my strong suit. How would I make them work for this? Code: class stack { public: static const int CAPACITY = 30; // Constructor stack () { used = 0; } // Modification Member Functions void push(const int& entry); void pop(); // Constant member functions bool empty() const { return (used == 0);} int size() const { return used; } int top() const; private: int data[CAPACITY]; // Partially filled array int used; // How much of the array is being used };
http://cboard.cprogramming.com/cplusplus-programming/142462-making-stack-via-dynamic-array-printable-thread.html
CC-MAIN-2015-35
refinedweb
110
58.42
.NET Controls: The Date Picker Overview of the Date Picker Introduction Picker To support the Date Picker control, the .NET Framework provides the DateTimePicker class. To create a Date Picker, declare a DateTimePicker variable, use the new operator to initialize it and call the Controls.Add() method to add the control to its container. In reality, the DateTimePicker control can be considered as two controls in one: you just have to choose which one of both controls you want to use. After adding the DateTimePicker control to a container, to allow the user to set the dates and not the times on the control, set its Format property either to Long or Short. Here is an example: using System; using System.Drawing; using System.Windows.Forms; class Exercise : Form { DateTimePicker dtpDate; public Exercise() { this.InitializeComponent(); } private void InitializeComponent() { dtpDate = new DateTimePicker(); dtpDate.Location = new Point(10, 10); this.Controls.Add(dtpDate); } static int Main() { Application.Run(new Exercise()); return 0; } } Characteristics of the Date Picker The Format of the Date After adding a DateTimePicker control and setting its Format to either Long (the default) or Short, the control becomes a combo box (the default). The UpDown Part of the Date Picker: The Drop-Down Alignment of the Calendar Part If the control displays a combo box and if the user clicks the arrow on the Date control, a calendar object similar to the MonthCalendar control. A Check Box for the Control be changed individually. To change either the day, the month, or the year, the user must click the desired section and use either the arrows of the button or the arrow keys on the keyboard to increase or decrease the selected value. The Range of Allowed Dates If you want to control the range of dates the user can select, use the MinDate and the MaxDate properties as we mentioned them from the MonthCalendar control. The Value of the Control When you add the DateTimePicker control to your form or container, it displays the date of the computer at the time the control was added. If you want the control to display a different date, assign the desired date to Value property. At any time, you can find out what value the Date Picker has by retrieving the value of the Value property. Custom Date Formats. Events of the Date Picker The Value Has Changed Whenever the user changes the date or time value of the control, a ValueChanged event fires. You can use this event to take some action such as indicating to the user that the new date is invalid. Drop Down. Close Up On the other hand, if the user clicks the arrow to retract the calendar, an CloseUp event fires. Both events are of EventArgs type.
http://www.functionx.com/csharp1/controls/datepicker.htm
CC-MAIN-2015-35
refinedweb
461
61.77
This two-part article is aimed at experienced C# .NET programmers who wish to write their own little computer languages (see part two here). Historically, this has been reasonably difficult due to requiring in-depth knowledge of compilation theory and/or the use of one or more tools, each of which had its own learning curves. Recently though, there has been somewhat of a revolution in this area, with tools being developed which greatly simplify the writing of compilers. The Irony Compiler Construction Toolkit for .NET is used in this tutorial due to the fact that it requires no configuration files etc. (Just drop the Irony DLL into your project) and it simplifies many aspects of compiler construction. Imagine you are writing a content-management system for websites where your users can upload their own images. Now, imagine you have a client who wants to upload a large image, and then display only part of the image, but have the image scrolling around, like so: And oh, here's the next thing: they want to be able to set up the way the "camera" scrolls across the image, and change it themselves. So, it is decided that the users will type instructions into a textbox to control the scrolling of the images. The language will look something like this: Set camera size: 400 by 300 pixels. Set camera position: 100, 100. Move 200 pixels right. Move 100 pixels up. Move 250 pixels left. Move 50 pixels down. It's a far cry from C#, but having a language which basically reads like English will (hopefully) be appreciated by the users. This language is so simple that you could easily write your own parser that extracts the data from the string; however, as soon as the language gets a little more complicated (for example, if you introduce "if" statements and variables, as in part II of this article), then writing a bona-fide compiler will pay dividends. string if So, how do we write a compiler for this language? Well, the first step is to formally describe the language. Looking at the language example above, we can say that a program starts with a line to set the camera size, then a line to set the initial position, and then one or more lines to move the camera. Each line ends with a '.' character. Most of the text is just fixed keywords (such as "Move" and "camera"), with the exception of numbers and directions ("up", "down", "left", "right"). The language can be written in upper-case or lower-case (or a combination). The paragraph above explains the grammar; however, it is always a good idea to write this description in a more formal manner. A very common way to describe a grammar is using Backus–Naur Form, and the following is a slightly non-standard version of BNF describing the program: <Program> ::= <CameraSize> <CameraPosition> <CommandList> <CameraSize> ::= "set" "camera" "size" ":" <number> "by" <number> "pixels" "." <CameraPosition> ::= "set" "camera" "position" ":" <number> "," <number> "." <CommandList> ::= <Command>+ <Command> ::= "move" <number> "pixels" <Direction> "." <Direction> ::= "up" | "down" | "left" | "right" You can read "::=" as something like "is made up of", and "|" as "or". So, for example, a "Direction" is made up of one of four strings. ::= Direction If you have written in BNF previously, you may be surprised to see "<Command>+", which uses the regular-expression convention to mean "one or more commands". This is not standard in grammars (or in BNF); however, Irony lets you do this (I will not go into the more complicated traditional way to achieve the same thing). <Command>+ A grammar always ends up as a tree with a single root. For any (valid) program that we input into the compiler, a tree will be created with "Program" as the root node. This will have three children: "CameraSize", "CameraPosition", and "CommandList". This will continue down into the tree until the leaf nodes, which will be the keywords, numbers, and directions. The most important job of the compiler then is to convert the source code into a tree which is termed as an "Abstract Syntax Tree" (AST). So, based on the grammar above, with the following program... Program CameraSize CameraPosition CommandList Set camera size: 400 by 300 pixels. Set camera position: 100, 100. Move 200 pixels right. Move 100 pixels up. ...we should get the following Abstract Syntax Tree: Note that the blue nodes are called "Non-terminals" whereas the orange nodes are called "Terminals". The terminals correspond to the actual code the user has entered. While conventionally terminals such as "set", "camera", and "size" would come under the "CameraSize" node, when using Irony, you can ignore these non-useful terminals (more on this later). set camera size Once we have a tree, we can then generate the code to execute the program. So, how do we do all this with Irony? After you have downloaded Irony, create a new project in Visual Studio, and add a reference to Irony.dll. Then, add a new class to define the grammar: CameraControlGrammar.cs will do. After referencing the correct Irony namespace (using Irony.Compiler;), make your class inherit from the abstract "Grammar" class: using Irony.Compiler; Grammar public class CameraControlGrammar : Grammar The grammar of the language is defined in the constructor. The first part is to do some preparation for the actual grammar, and set a few options, for example, making it case-insensitive: this.CaseSensitive = false; Then, define all the terminals and non-terminals needed: var program = new NonTerminal("program"); var cameraSize = new NonTerminal("cameraSize"); var cameraPosition = new NonTerminal("cameraPosition"); var commandList = new NonTerminal("commandList"); var command = new NonTerminal("command"); var direction = new NonTerminal("direction"); var number = new NumberLiteral("number"); And finally, specify which non-terminal is the root node in the abstract syntax tree: this.Root = program; OK, with the ingredients all cut up and prepared, we can start cooking. Defining the grammar in Irony is surprisingly similar to writing it in BNF form: // <Program> ::= <CameraSize> <CameraPosition> <CommandList> program.Rule = cameraSize + cameraPosition + commandList; // <CameraSize> ::= "set" "camera" "size" ":" <number> "by" <number> "pixels" "." cameraSize.Rule = Symbol("set") + "camera" + "size" + ":" + number + "by" + number + "pixels" + "."; // <CameraPosition> ::= "set" "camera" "position" ":" <number> "," <number> "." cameraPosition.Rule = Symbol("set") + "camera" + "position" + ":" + number + "," + number + "."; // <CommandList> ::= <Command>+ commandList.Rule = MakePlusRule(commandList, null, command); // <Command> ::= "move" <number> "pixels" <Direction> "." command.Rule = Symbol("move") + number + "pixels" + direction + "."; // <Direction> ::= "up" | "down" | "left" | "right" direction.Rule = Symbol("up") | "down" | "left" | "right"; Irony has overloaded the "+" and "|" operators so that you can join together the different parts of the grammar in a very natural way. The only exception is where the first part of the rule is a string: in general, you should wrap the first string in a Symbol() method call so that the C# compiler knows that the string is actually a special Irony construct. Also note, rather than having "set camera size:" in a single string, we add each word separately, which allows any whitespace (including new lines) to go between each word. + | string Symbol() Finally - and this is optional, but recommended - you can specify certain strings as "punctuation". On each line, there are lots of keywords that we don't actually care about once we are using the generated AST (for example, on each "move" line, we only care about the number of pixels and the direction). We can tell Irony that we don't want the AST cluttered with keywords by registering all the "punctuation": punctuation move this.RegisterPunctuation("set", "camera", "size", ":", "by", "pixels", ".", "position", ",", "move"); This means a "Command" will have only two children (number and direction) instead of five children ("move", number, "pixels", direction, and "."). Command number pixels direction . We are now ready to parse some code. This is done by passing an instance of your grammar to a LanguageCompiler object and getting a reference to the root node of the AST: LanguageCompiler CameraControlGrammar grammar = new CameraControlGrammar(); LanguageCompiler compiler = new LanguageCompiler(grammar); AstNode program = compiler.Parse("the source code as a string"); Assuming the source code successfully compiled, you can run this in debug mode and browse through the ChildNodes property of each node in the tree to view it. (See the attached project to see one way to handle invalid source code.) ChildNodes An elegant way to generate code from an AST is to write a class for each non-terminal node in the tree, and then each node in the tree simply generates the piece of code that it is responsible for. This is a very good pattern to use, especially when dealing with more complex languages; however, to keep things relatively simple, I will simply act directly on the returned AST (for an example which uses classes to generate code, see JSBasic which converts from BASIC to JavaScript). Examining the tree above, we know that the first child node of the tree is the camera size declaration, which should have two children itself: the width and the height of the camera: width height AstNode cameraSizeNode = program.ChildNodes[0]; Token widthToken = (Token)cameraSizeNode.ChildNodes[0]; int width = (int)widthToken.Value; Token heightToken = (Token)cameraSizeNode.ChildNodes[1]; int height = (int)heightToken.Value; Note that the actual number entered is considered a Token (in fact, each piece of text in the source code is a Token); however, not all ChildNodes are Tokens (e.g., "CommandList" is a ChildNode of Program; however, it is a non-terminal, so not a token). This is why we must convert the children to Token objects before accessing their values. Token ChildNode A similar deal is used to get the initial position. These camera sizes and positional values are used in the demo project to create some JavaScript which initialises the photo. (The actual JavaScript is not explained here as it is outside the scope of this article.) Next, we know that the third child of the program is a list of Command nodes, which we can then loop through: Command // loop through the movement commands foreach (AstNode commandNode in program.ChildNodes[2].ChildNodes) { // get the number of pixels to move Token pixelsToken = (Token)commandNode.ChildNodes[0]; int pixelsToMove = (int)pixelsToken.Value; // get the direction Token directionToken = (Token)commandNode.ChildNodes[1]; string directionText = directionToken.Text.ToLower(); } Using the pixelsToMove and directionText values, JavaScript is generated for each command in the program. Again, this is left out as it isn't important in terms of how to write your language. pixelsToMove directionText And that's all there is to it, really. Of course, once you introduce variables, branch and conditional statements etcetera, you would probably want to look into creating your own AST node classes and look at the AstNode.Evaluate method; however, that is for another tutorial, along with many other Irony features which have been left out in this tutorial. Hopefully though, this should give you enough information to allow you to write your own simple little languages. AstNode.Evaluate And don't forget to try the online demo..
http://www.codeproject.com/Articles/26975/Writing-Your-First-Domain-Specific-Language-Part-1?fid=1410619&df=90&mpp=10&sort=Position&spc=None&tid=3228374
CC-MAIN-2017-17
refinedweb
1,812
54.42
Re: [soaplite] Preventing package name traversal attacks Expand Messages - On Tue, 2002-04-09 at 15:28, David Wright wrote: >More than that, you need some level of access control for the object. > What we need is a way to just turn off autodispatch at the server side. This should be done at the SOAP level before the object is ever called. Basically need to set up something like this %access_control_list = ( 'public' => qw(method1 method2 ... methodN class1 class2 ... classN), 'restricted' => { 'restricted_method1' => { 'users' => qw(user1 user2 ... userN), 'hosts' => qw(host1 host2 ... hostn domain1 domain2 ... domainN), 'logging' => "logfile" } ); SOAP::Lite->set_access_control('object' => 'name', 'acl' => %access_control_list); Or something similar. > > > > To unsubscribe from this group, send an email to: > soaplite-unsubscribe@yahoogroups.com > > > > Your use of Yahoo! Groups is subject to > - Hi, Ilya! Yes, this patch may work and thanks for bringing this up. > I've sent Paul private email with source code of exploit I've wroteI'm offline since Saturday and will have only occasional online > but I haven't got any response yet. access till the end of this week. I wasn't aware about the possibility of using phrack's exploit in such way, yet it seems like it shouldn't work with -T option used on server side. Unfortunately -T option doesn't stop you from using $object->$method() even if $method string is tainted, which allows accessing already loaded modules. To disable it on server side you may use on_action handler: ->on_action(sub { die "Access denied\n" if $_[2] =~ /:|'/ }) There is also patch that adds checking of method name against methods and classes allowed in dispatch_to(). Will go into the next release. Sorry for the inconvenience. Best wishes, Paul. --- Ilya Martynov <ilya@...> wrote: > >>>>> On Tue, 09 Apr 2002 17:24:48 -0000, "theonetowhommyrefers"__________________________________________________ > <theonetowhommyrefers@y..> said: > > T> There is an article at Use::Perl which discusses a serious > security > T> hole in SOAP::Lite - > T> > > T> This article is based on another article at Phrack: > T> > > >> From what I can tell the security hole is that autodispatch > allows > T> direct access to fully qualified package names and thus > arbitrary > T> commands can be executed on the remote machine. > > T> How can we stop such attacks? > > I've sent Paul private email with source code of exploit I've wrote > but I haven't got any response yet. > > For now you may try to use this patch (diff against latest > SOAP::Lite). It is 'unofficial', I haven't tested it too much but > it > does seem to protect against attacks which use fully qualified > package > names. It least it seems to stop my exploit. > > Of course there is NO WARRANTY that it does fix a problem or that > it > doesn't cause any damage. > > --- /home/ilya/tmp/Lite.pm Tue Apr 9 21:27:07 2002 > +++ /usr/share/perl5/SOAP/Lite.pm Tue Apr 9 21:40:10 2002 > @@ -2068,6 +2068,11 @@ > ($method_uri, $method_name) = ($request->namespaceuriof || '', > $request->dataof->name) > unless $method_name; > > + # don't allow method names which contain package names > + # i.e package::method or package'method (old deprecated syntax) > + die "Denied access to method ($method_name)" > + if $method_name =~ /[:']/; > + > $self->on_action->(my $action = $self->action, $method_uri, > $method_name); > > my($class, $static); > > > -- > Ilya Martynov () > > ------------------------ Yahoo! Groups Sponsor > > To unsubscribe from this group, send an email to: > soaplite-unsubscribe@yahoogroups.com > > > > Your use of Yahoo! Groups is subject to > > > Do You Yahoo!? Yahoo! Tax Center - online filing with TurboTax >>>>>.
https://groups.yahoo.com/neo/groups/soaplite/conversations/topics/1396?unwrap=1&var=1&l=1
CC-MAIN-2015-22
refinedweb
569
66.13
Maximizing NVIDIA DGX with Kubernetes NVIDIA GPU Cloud (NGC) provides access to a number of containers for deep learning, HPC, and HPC visualization, as well as containers with applications from our NVIDIA partners – all optimized for NVIDIA GPUs and DGX systems. These downloadable containers execute their application without having to setup a custom environment with numerous dependencies, such as framework, libraries, and apps. Now NVIDIA has added Kubernetes to its containerization toolbox. Leveraging other tools to help with provisioning and batch scheduling extends the power of containers, especially when you have multiple and/or shared resources. Kubernetes represents one such open-source tool adopted by many developers to help deploy, scale, and manage containerized applications such as those available from the NVIDIA GPU Cloud. Kubernetes’ schedule GPUs feature supports managing NVIDIA GPUs spread across nodes. Getting Started with Kubernetes This quick start guide demonstrates how to set up a Kubernetes environment to help your organization deploy and manage containers on single- or multiple-GPU system. You need a system with at least one NVIDIA GPU and a CPU only system, though the CPU system can be a virtual machine (VM). You’ll learn about the following: - Setting up a standalone Kubernetes master node without GPUs - Setting up a GPU worker node with the updated NVIDIA Container Runtime for Docker on NVIDIA DGX Station - Connecting to your NGC container registry account for NVIDIA GPU-optimized containers As a minimum you need to be comfortable with the following: - Administering Linux - Docker, including knowledge of Docker networking - Basic Kubernetes knowledge We will use the kubeadm and kubectl CLI commands as the method for setting up and administering the Kubernetes environment for this particular install. NVIDIA DGX Station running DGX OS Desktop version 3.1.6 will be used as the GPU worker node used in this guide. Master Node Installation This introduction uses a VM with two vCPUs, 8GB RAM, 64GB disk and Ubuntu 16.04 LTS for the master node. Newer OS versions should work with these instructions, but older versions of Ubuntu may be unsupported. You need to disable swap for Kubernetes, which is a requirement for the Kubernetes section of the installation. If you inadvertently configure swap, you’ll see an error similar to the following during kubeadm init: [preflight] WARNING: Running with swap on is not supported. Please disable swap or set kubelet's --fail-swap-on flag to false. Installation Of Docker First, you need to make sure Docker is up to date. (Please refer to the Docker documentation for more detailed instructions). Before you begin, first check for any OS updates: sudo apt update sudo apt -y upgrade Ensure the following packages (apt-transport-https, ca-certificates, curl, software-properties-common) are installed. Install them with if they are not present with sudo apt install apt-transport-https ca-certificates curl software-properties-common. Next, enter the following commands to install Docker: curl -fsSL | sudo apt-key add - sudo add-apt-repository "deb [arch=amd64] $(lsb_release -cs) stable" sudo apt update sudo apt install -y docker-ce Installation Of Kubernetes In this section, we show you how to install Kubernetes and initialize the master node with kubeadm. (Refer to installing kubeadm for more information). Issue the following commands to install Kubernetes:” you will notice that the service has failed. This is expected behavior as the CA certificate has not been created yet. The certificate will be created during the cluster initialization. The next command “kubeadm init…” initializes and configures your Kubernetes cluster: sudo kubeadm init --ignore-preflight-errors=all --config /etc/kubeadm/config.yml Take note of the output from the sudo kubeadm init --ignore-preflight-errors=all --config /etc/kubeadm/config.yml command. Look for the kubeadm join --token in the output as you will use this token to join all worker nodes (GPU or CPU) to the Kubernetes cluster. Here is an example of a “kubeadm join –token” command, that is used to join worker nodes to the Kubernetes cluster: kubeadm join --token 672601.5db1d8d05f0a9c14 192.168.2.95:6443 --discovery-token-ca-cert-hash sha256:f3ed02134f0043577dbb78395ea2a2cc2780e4f70d3c21798e17d69b12258474 Each token remains valid for only 24 hours. Starting with Kubernetes 1.9, the “kubeadm token create” command added the “–print-join-command” flag. If you need a new token, login to the master node and issue: sudo kubeadm token create --print-join-command Note that kubeadm looks for a configuration file named ‘config’ in the ‘.kube’ directory of the current users to know who is allowed to execute the command. To setup your user account to administer your Kubernetes cluster, issue the following: mkdir -p $HOME/.kube sudo cp /etc/kubernetes/admin.conf $HOME/.kube/config sudo chown $(id -u):$(id -g) $HOME/.kube/config Each and every Kubernetes cluster needs a Container Network Interface installed. We have chosen to use Flannel CNI for this deployment: kubectl apply -f Refer to Installing a pod network in the Kubernetes documentation for more information as well as other networking options. It will take a minute or two for the above commands to download and run the pod networking containers. Issue the following command to check the status in case you are waiting for the “Status” of the containers to all be “Running”: kubectl get pods --all-namespaces Your output should be similar to figure 1: Check the following Kubernetes logs if you are having issues: - Examine the “/var/log/syslog” file for Kubernetes related errors. - Issue the “systemctl status kubelet” command to check the current state of the service. - Issue the “journalctl -xeu kubelet” command to review the messages from the journal. At this point, you should have a functional Kubernetes master node. The Kubernetes master node does not have any installed GPUs in this environment. However, your master node could also be the NVIDIA DGX Station. If so, you will want to run jobs on the master node. Issue the following command to enable Kubernetes to allow local jobs to run: kubectl taint nodes --all node-role.kubernetes.io/master- If you are running Kubernetes as an all-in-one system deployment and you taint your DGX station so that master and worker node are a single system, you need to be aware of the following issue: kube-dns keeps restarting #381 and/or Liveness probe for containers in Kube-DNS pod fails intermittently #408 DGX Station Worker Node Installation Now that you have a Kubernetes master node setup, prepare your DGX Station to join the cluster. You will not need to install Docker on your DGX station since it comes pre-installed as part of the Base OS. You will, however, need to update and install some needed packages before joining your Kubernetes cluster. You must update the version of NVIDIA Container Runtime for Docker and install Kubernetes for NVIDIA GPUs. Now you are ready to join the DGX Station to the Kubernetes cluster. If you want to issue Docker commands as a user (without sudo), add your user to the docker group with the following command: sudo usermod -aG docker $USER Logout and log back in. Then, from this point on you can execute any Docker command without “sudo”. NVIDIA Container Runtime for Docker The NVIDIA Container Runtime for Docker has been updated and is now the recommended way of running containers on DGX systems. For DGX systems follow the Upgrading to the NVIDIA Container Runtime for Docker process. Once updated nvidia-docker version will look similar to the following: Install Kubernetes On The DGX Station Worker Node Now let’s install the Kubernetes components on the DGX Station worker node. This resembles what we did on the master node. However, instead of initializing the Kubernetes installation as a master node we will “join” the DGX Station worker node to the Kubernetes master node.” will reveal that the service has failed. This is expected behaviour as the CA certificate has not been created yet. The certificate will be created during the cluster join command. If you created your Master node over 24 hrs earlier you will need to create a new join token, login to the master node and issue the following to see if your “kubeadm init” token has expired: sudo kubeadm token list If the token has expired issue: sudo kubeadm token create --print-join-command Using either the “token” obtained earlier in the master node “Installation Of Kubernetes” section or a newly created token on the DGX Station worker node issue a “kubeadm join” command on the DGX Station to join the Kubernetes Cluster: # example join command, this token will not work for your installation, you may have to create a new token if it has been longer than 24hrs since you “sudo kudeadm init” the master node. sudo kubeadm join --token e8c937.21e8470b7bff0fd5 10.33.3.21:6443 --discovery-token-ca-cert-hash sha256:752a095e73629a0b0fe7cd8c1da2e9e070511c8421ff4fe58d1e48b508e05e2f You should see output similar to figure 3. Check the following Kubernetes logs if you are having issues: - Check the “/var/log/syslog” file for Kubernetes related errors. - Issue the “systemctl status kubelet” command to check the current state of the service. - Issue the “journal ctl –xeu kubelet” command to review the messages from the journal. Now on the master node issue the following commands to confirm your Kubernetes installation: kubectl get nodes kubectl describe nodes kubectl get all --all-namespaces Review the output of the above commands. For “kubectl get all –all-namespaces” check the “Status” of the running containers, for “kubectl get nodes” check the “Status” of the nodes. For “kubectl describe nodes”, become familiar with the output. NVIDIA GPU Cloud In this section we will connect your newly installed Kubernetes cluster to the NVIDIA GPU Cloud and use an optimized GPU-enabled container. The NVIDIA GPU Cloud Container User Guide has all the information you need to get logged into NGC and covers how to obtain an API Key. Login to NVIDIA Container Registry (nvcr.io) Once you have your API Key, as an initial test on any one of your system issue “docker login” and provide the credentials. After the initial “docker login” has been established we can go ahead and perform a test using an optimized GPU-enabled container. The login prompts are as follows: docker login nvcr.io Username: $oauthtoken Password: <your-api-key> Once the login has been completed, verify that your Docker credentials have been updated: cat .docker/config.json Confirm that the login works by a docker pull of the latest Cuda container image. At the time of writing this article the latest version is “cuda:9.0-cudnn7.1”: docker pull nvcr.io/nvidia/cuda:9.0-cudnn7.1-devel-ubuntu16.04 Once the container image has been downloaded locally, run the container using the NVIDIA Container Runtime for Docker. Run the command nvidia-smi within the container: docker run -it --rm --runtime nvidia nvcr.io/nvidia/cuda:9.0-cudnn7.1-devel-ubuntu16.04 nvidia-smi Your output should be similar to that shown in figure 4: Create Kubernetes login to NVCR.IO Using your NGC API Key you will create a Kubernetes “secret” on the master node, this secret enables Kubernetes to log into NGC and download an optimized GPU-enabled container when specified: kubectl create secret docker-registry <your-secret-name> --docker-server=<your-registry-server> --docker-username=<your-registry-username> --docker-password=<your-registry-apikey> --docker-email=<your-email> Use the following parameters in the above command: - docker-registry <your-secret-name> – the name you will use for this secret - docker-server <your-registry-server> – nvcr.io is the container registry for NGC - docker-username <your-registry-username> – for nvcr.io this is ‘$oauthtoken’ (including quotes) - docker-password <your-registry-apikey> – this is the API Key you obtained earlier - docker-email <your-email> – your NGC email address (Note: For more information, refer to Pull an Image from a Private Registry.) Verify that the secret creation has completes: kubectl get secrets You should see output similar to figure 5: Launching a Container though Kubernetes Now you can use your very first optimized GPU-enabled container. Kubernetes uses the “.yaml” file format. (For more information on yaml files, refer to Understanding Kubernetes Objects). Let’s look at an example of a CUDA container that will run one time using the Kubernetes secret (called ngc) that we just created and will issue “nvidia-smi’: apiVersion: v1 kind: Pod metadata: name: cuda-ngc namespace: default labels: environment: dev app: cuda spec: containers: - name: cuda-container image: nvcr.io/nvidia/cuda:9.0-cudnn7.1-devel-ubuntu16.04 imagePullPolicy: IfNotPresent Args: ["nvidia-smi"] extendedResourceRequests: ["nvidia-gpu"] extendedResources: - name: "nvidia-gpu" resources: limits: nvidia.com/gpu: 1 # change value to appropriate number of GPU(s) affinity: required: - key: "nvidia.com/gpu-memory" operator: "Gt" values: ["8000"] # change value to appropriate mem for GPU(s) restartPolicy: Never imagePullSecrets: - name: ngc # specifying the secret/credentials to use when connecting to NGC The creation of a container that hasn’t yet run will take a little longer since the required optimized GPU-enabled container image is pulled locally to the DGX Station worker node. On the master node create the “yaml” file, then issue the following commands to confirm the file is correct, then create the container, and lastly view the status of the container: your-yaml-filename.yaml kubectl create -f <your-yaml-filename>.yaml kubectl get pods --show-all You should see output similar to the following: After the NGC CUDA container shows “Completed” status, “describe” the pod to see the steps performed by Kubernetes to run the requested container. kubectl describe po/<your-pod-name> Figures 7 and 8 show an example of what you will see after you describe the container: Now if we check the pod logs we should see the “nvidia-smi” output. Issue the following: kubectl logs <your-pod-name> You should see output similar to that shown in figure 9: Next Steps You now have a functional Kubernetes environment which allows you to test and develop a deeper knowledge of using a GPU enabled Kubernetes installation. Consider installing Kubernetes Web UI (Dashboard). Kubernetes also has monitoring tools that can be leveraged; for more information, see Tools for Monitoring Compute, Storage, and Network Resources. Udemy has a Learn DevOps: The Complete Kubernetes Course that is a great place to start learning more about Kubernetes. Here are some additional useful links: Kubernetes on NVIDIA GPUs Installation Guide NVIDIA device plugin for Kubernetes Upgrading to the NVIDIA Container Runtime for Docker Schedule GPUs If you are on a DGX Station, consider updating as per DGX OS Desktop v3.1.6 Release Notification, or for DGX-1 refer to DGX OS Server v2.1.3 and v3.1.6 Release Notification.
https://developer.nvidia.com/blog/maximizing-nvidia-dgx-kubernetes/
CC-MAIN-2021-10
refinedweb
2,453
50.57
In VS2013 RTM, we shipped a not well known feature for _references.js file: /// <autosync enabled="true" />. If we specify /// <autosync enabled="true" /> in the beginning of ~/scripts/_references.js, then any addition, rename, deletion of JavaScript files in the project will automatically change the content in this file. You can disable this feature by removing the line or put assign false to enabled attribute. For example, create a new MVC project, open scripts/_references.js file and you will see the following if you are using VS2013 with update 3. Drag and drop bootstrap.js file to the Scripts folder to make a copy, and all the missing “.js” files and the newly added “.js” files are automatically referenced in the _references.js file. Note, we ignore the “.min.js” files if the non-minified “.js” file exists. You can enable and disable the auto sync feature via editor’s context menu button “Auto-sync JavaScript References”. You can always manually update the project’s JavaScript references using the context menu button “Update JavaScript References”. For more details in _references.js, please visit Mads’ blog The story behind _references.js. Join the conversationAdd Comment Does this work with TypeScript files too? @VengefulSpaniard, NO, we only add .js file with this feature. This file is a pain. It doesn't use relative paths for linked files (add existing file, add as link) and sometimes when I'm wrangling with that issue I open the file up only to find the file is full of Chinese characters which I assume means somewhere along the line there was some problem writing the file in the correct encoding. This only seem to work for JS files in the SCRIPTS folder !? Javascript files in other dirs don't get added to _references.js 🙁 Does it have to be a /scripts/ folder though other folder structures are available e.g. /assets/js/libs ? Cheers! Ali @Martin Kirk, thanks for reporting the problem. Monitor js script file changes will be available in the next VS update. @Ali Russell, currently the _references.js file has to be in ~/Scripts folder. We'll consider your suggestion. Thanks! If you want to improve Visual Studio, in prove WPF. If you REALLY want to help JS developers (and you are not screwing with us), make a new JS version that discards all JS history (buggy functions, stupid syntax demands to avoid errors, trend of using lower camel case, fix 'this' permanently, include the namespace concept in a built-in manner, etc). In other words, create a new language, because this one sucks. Preferably, having JS objects named EXACTLY and functioning EXACLTY (at the degree possible) like the ones in .NET, would (I believe) draw serious support for your effort. So, just create a new better JavaScript. I will work almost like JS, but with C# syntax and C# class/function names. Just look how excitement this little project brought to people: That is not an accident. That is 100% natural. JS built-in functions and naming conventions simply suck at every level. So, if you at M$ want to have a future as a company, just make developers happy again, just like you used to make them feel back in the good old days (before Balmer found thee 'advertisement' tree and lost the 'developers' forest). Freezing WPF development and investing in this crappy HTML5/JS tech will not get you far. Then drop JsViews (I cannot say it more politely) and support AngularJS by making improvements to it (or make a similar library). Google is on to something VERY good with this library. @Me, thanks for all the suggestions. TypeScript is Microsoft's work of the language you mentioned. And our team is adding more support for AngularJS in every public release of VS these days, check out VS"14" CTPs. What if i don't see _references.js, file in my script folder? @Monika, You can just create one by adding a JavaScript file and name it "_references.js". That will give you the context menu buttons when you right-click it. @Mads, I added a _references.js to my scripts folder. When I right click, the context menu does not have the auto sync or update options. How do I enable these options? Microsoft Visual Studio Professional 2015 Version 14.0.24720.00 Update 1 Microsoft .NET Framework Version 4.6.01038 .NET Reflector Visual Studio Extension 9.0.1.318 JetBrains ReSharper Ultimate 2015.2 Build 103.0.20150818.200216 how to use _references.js file in .net Apache Cordova project. References of jQuery 3.x and jQuery-UI in the _references.js will disable javascript intellisense in the latest VS15. Downgrading jQuery to 2.2.4 solved the problem. Please refer here: I found a better solution to this! Simple rename jquery-ui-1.12.1.js (or similar) to _jquery-ui-1.12.1.js. This will cause it to appear at the top BEFORE the conflicting jQuery 3 references in the _references.js file that cause intellisense to not work. Be sure to also update any script tag or BundleConfig.cs references you have to include the new underscore character prefix! The update will not pick up .js files generated through a T4 template. If they are added manually to _references.js, the next update deletes the references.
https://blogs.msdn.microsoft.com/webdev/2014/10/10/_references-js-files-auto-sync-feature/
CC-MAIN-2018-47
refinedweb
894
78.04
Not sure it's a proper category for a question... When I run certbot: certbot certonly --webroot -w /path/to/docroot -d domain.com -d I get: Traceback (most recent call last): File "/usr/bin/certbot", line 9, in <module> load_entry_point('certbot==0.9.3', 'console_scripts', 'certbot')()/__init__.py", line 2235, in resolve module = __import__(self.module_name, fromlist=['__name__'], level=0) File "/usr/lib/python2.7/dist-packages/certbot/main.py", line 19, in <module> from certbot import client File "/usr/lib/python2.7/dist-packages/certbot/client.py", line 10, in <module> from acme import client as acme_client File "/usr/lib/python2.7/dist-packages/acme/client.py", line 29, in <module> requests.packages.urllib3.contrib.pyopenssl.inject_into_urllib3() AttributeError: 'module' object has no attribute 'pyopenssl' Versions of relevant packages: $ dpkg -l | grep python- | egrep '(ssl|urllib|requests)' ii python-openssl 16.0.0-1~bpo8+1 all Python 2 wrapper around the OpenSSL library ii python-requests 2.11.1-1~bpo8+1 all elegant and simple HTTP library for Python2, built for human beings ii python-urllib3 1.16-1~bpo8+1 all HTTP library with thread-safe connection pooling for Python Corresponding bug report on GitHub. I'm running Debian 8 (jessie). I have access to root account on the server, and there no any control panel there. Thanks in advance. hi x-yuri you have posted in the correct forum can you please run the following command pip freeze you should get something that looks like the below (working copy of certbot) depending on your python install this may not work i suspect the issue you are facing is due to the fact the pyopenssl has not be installed as a module can you also articulate how you installed the certbot package? This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
https://community.letsencrypt.org/t/requests-packages-urllib3-contrib-pyopenssl-inject-into-urllib3-module-object-has-no-attribute-pyopenssl/28091
CC-MAIN-2017-43
refinedweb
313
58.38
retrieve full comiler options in qmake I want to retrive full compiler option in qmake including all -Ioptions and -Doptions. I've tried $$join(DEFINES, " -D") $$join(INCLUDEPATH, " -I")but it doesn't contain Qt module informations such as -DQT_CORE_LIBnor -IC:\Qt\5.8\msvc2015_64\include\QtCore How can I get full compiler flags/options in qmake? - SGaist Lifetime Qt Champion Hi, Out of curiosity, what is your use case for that information ? I need the information to run clang-tidybecause it requires compile options to analyze source code. For instance, without include path for QtCore headers, it prints some kind of erros similar with 'header file not found' whenever it sees #include <QVector>. Although I can write it one by one, I'd like to make general method to run clang-tidyfor my project. - SGaist Lifetime Qt Champion You should check the qmake variable reference page. It contains all the variables that you likely need.
https://forum.qt.io/topic/79606/retrieve-full-comiler-options-in-qmake
CC-MAIN-2017-34
refinedweb
156
55.54
This is the mail archive of the libc-alpha@sources.redhat.com mailing list for the glibc project. Bruno Haible <bruno@clisp.org> writes: > Hi, > > Since FreeBSD's native sendfile() system call is not the same as the Linux > one (works only on sockets), here is a patch that adds an emulation of it > using read/write to sysdeps/posix/. The Linux one has limitations as well (for example you cannot currently sendfile() with a src of a TCP socket and a dst of a local file). The interface for telling you something is wrong is return -1, errno = EINVAL. The only other difference is the addition of iovec's at the beginning and the end ... and that is worthless and can be just ignored. For autoconf on projects I've used... #ifndef HAVE_SENDFILE ssize_t FIX_SYMBOL(sendfile)(int out_fd, int in_fd, off_t *offset, size_t nbytes) { #ifdef HAVE_FREEBSD_SENDFILE ssize_t ret = 0; /* don't get caught by the #define sendfile ... butcher all the arguments */ ret = (sendfile)(in_fd, out_fd, offset ? *offset : 0, nbytes, NULL, offset, 0); return (ret); #else errno = EINVAL; /* pretend the in_fd isn't in the page cache in Linux * as they have to fall back to read()/write() in that case * anyway */ return (-1); #endif } #endif > The emulation is multithread-safe if the platform has a pread() system call, > like FreeBSD does, otherwise it is not multithread-safe (but better than > the stub in sysdeps/generic). No it isn't, it's completely broken. If you pass NULL as the off_t then it's supposed to use the off_t associated with the fd (just like read and write) ... your version will just silently drop data when reading from a non-file as the src. Just returning ENOSYS, would be _much_ better. -- James Antill -- james@and.org The Hurd itself is aggressively multi-threaded and all of the locking has been done with an eye towards multi-processor systems. That said, we have not yet used a microkernel that stably supports multiple cpus.
http://www.sourceware.org/ml/libc-alpha/2002-07/msg00143.html
CC-MAIN-2019-47
refinedweb
332
63.7
Where's the trash? We need to put the same weight in the thermal range from the first and second. It's like it's taken, but when the third mass is removed, it's made of "musorous values." #include <iostream> #include <time.h> using namespace std; void main() { const int size = 10, size1 = 20; int massA[size], massB[size], massC[size1]; srand(time(NULL)); for (int i = 0; i < size; i++) { massA[i] = rand() % 10; cout << massA[i] << " "; } cout << endl; for (int i = 0; i < size; i++) { massB[i] = rand() % 10; cout << massB[i] << " "; } for (int z=0, i = 0; z<size, i < size; i++,z++) { for (int j = 0; j < size; j++) { if (massA[i] != massB[j]) { massC[z] = massA[i]; cout << massA[i] << " "; } } } for (int i = 0; i < size1; i++) { cout << massC[i] << " "; } system("pause"); Your massC is filled with values in if (massA[i] != massB[j]) { massC[z] = massA[i]; cout << massA[i] << " "; } Consequently, it will not always have debris in it, because you have declared, but did not injure, the masses in the remaining areas, you rewrite your data. the initialization of the zeros
https://software-testing.com/topic/891082/where-s-the-trash
CC-MAIN-2022-21
refinedweb
189
68.1
Managing Object Lifetimes in D The D Programming Language is a modern version of C. It adds productivity features to the performance power of C, features like object oriented programming and garbage collection. It may seem strange that a language with focus on performance utilizes automatic memory management. A GC equals overhead, right? Well, actually that is a common misconception. These days implicitly memory managed code is generally faster than code where the programmer handles deallocations. One reason for this counter-intuitive fact is that a number of optimizations can be done by the GC, especially on short-lived objects. But garbage collection isn’t a problem free feature. For one thing, it is indeterministic. Normally, an object that uses external resources acquires them in a constructor and releases them in the destructor. import std.stream; class LogFile { File f; this() { f = new File("c:\\log.txt", FileMode.Out); } ~this() { f.close; } // Logging methods goes here } But with a GC there is no way to know when or even if the destructor is run. This may be a problem if you’re dealing with scarce resources like window handles, or file locks. So how can we control object destructions in a GC capable language? One possibility is to trigger a GC sweep explicitly in your code. In D this is done with the fullCollect function. import std.gc; fullCollect(); Explicit trigging of garbage collection is usually a bad idea, for several reasons. For one thing, it’s like killing an ant with a bazooka, and still you risk missing the target. Therefore, the normal approach to deal with the problem of indeterminism is to use a dispose method. class LogFile { File f; this() { f = new File("c:\\log.txt", FileMode.Out); } ~this() { dispose(); } void dispose() { if (f !is null) { f.close; f = null; } } // Logging methods here } LogFile log = new LogFile(); try { // Do some logging } finally { log.dispose; } We don’t have to use the dispose pattern though because in D we have the luxury of choosing between implicit and explicit memory management. We can either free the object ourselves with the delete operator, or leave it for the GC to dispose later. LogFile log = new LogFile(); try { // Do some logging } finally { delete log; // Explicit memory management } D has another construct which is very convenient when you need to control the lifetime of an object. With the scope attribute, an object is automatically destroyed when the program leaves the scope in which the object was created. void function some_func() { scope LogFile log = new LogFile(); : // log will be freed on exit } The ability to mix explicit and implicit memory management is a simple, yet great feature. It is one of many examples where D provides us with the best of two worlds. Convenience and control, as well as productivity and performance, is blended in a way that has no equivalence in any other language I know. Cheers! You’ve read my mind today! ; ) This is the only thing I don’t like of D. I’ve been fighting with the fact that we cannot trust in the destructors of D, sometimes are called and sometimes aren’t… This breaks an essential rule in OOP. The GC “knows” that the O.S. will deallocate the memory reserved on exit, then why worry deleting all objects? My solution to this problem is: 1.- Never trust in D destructors, they are unsafe. Assume that the GC won’t call them. (In medium/big-sized projects in D the GC don’t call a lot of destructors!). 2.- If you have a class that needs to execute always its destructor to release something then declare it as: scope class Foo {} This will force you to declare as scope every instance of Foo, if you don't do it, you'll get a compiler error: "reference to scope class must be scope". 3.- When you need it, use "delete". Cheers! Javi Ah! I forgot the 4th point… 4.- Do not trust in fullCollect(), it won’t always collect the unreferenced objects. After reading this and the comments above, I am definitely at a loss for when to trust Garbage Collection and when to call delete. I understand the scope keyword, but does it always work? Argh! I like a set of rules that are never broken (don’t we all?). BTW, I really enjoy your stuff (especially the D related articles). Very helpful for those of us that are trying to pick up the language. I’m working on a D blog as well - a tutorial based blog for beginner and intermediate D programmers. ’scope’ always works. Generally you use it when you need to release a resource (like closing a file) right after you’re done using it. When an app exits, the GC calls the destructors of all objects that are still alive. But not if the app crashes, so you can’t rely on important stuff like closing files to happen that way. No, when the app exits the GC doesn’t call the destructors of all objects because it doesn’t collect all object (no matter if the app exits without errors)… This can be true with small programs, but if you program a large app in D you’ll see what happen… One of the reasons is that the data on the stack is scanned by the GC, if you have, for example, a simple local byte array, and some of its values look like any reference in the GC list, then that reference is not collected. And this happens! I have this rule: If you’ve implemented the destructor of a class then, you must always delete it yourself: - If the instanced object is local; define it with “scope” attribute, and it’ll always be destroyed on exit of its scope. - If the instanced object is global, static or a member of a class then you must use “delete”. If your class doesn’t need to release any handle, etc, on exit and you’ve not implemented its destructor, then your work is done, forget it. If the GC doesn’t collect it, it’ll be collected by the O.S. when the app exits. Thanks for your help - that clarifies things a bit. It’s going to take me a while to get good at memory management again (still not nearly as bad as C++). I was a C guy back in school, but I’ve been doing C#, Java, Perl, and TCL at work for the past 8 years! It’s nice to get back to lower level programming - I’m having a lot of fun with D. Can’t argue with this one Well, I’ve come to realize that I don’t really need a deterministic destruction of objects very often. But when I do need it, the D solution to support both implicit and explicit destruction is really convenient. Good thing you pointed out scope classes. They are great if you need to make sure the object never escapes the scope it was created in. Man you are dumb. If you don’t trust the garbage collector, then use C or C++ like everybody else. Thank you for your nice comment. I too am “trying to pick up the language”. I’ll keep an eye on your blog as well, especially the low-level stuff, something I haven’t done too much myself. Ohhh! What a constructive comment! Bravo! And how do you know that I don’t use them??? Relax a bit and enjoy life man Not only is the D garbage collector non-deterministic, but you can’t reference members in the destructor. Therefore, your first example may give a runtime error because f may have be collected before the LogFile’s destructor is called. ~this() { f.close; // f should not be used } Ah, that is important information. Thank you for bringing attention to it.
http://www.hans-eric.com/2008/02/07/managing-object-lifetimes-in-d/
crawl-002
refinedweb
1,321
72.36
Brian K. Justice (bjustice@fallschurch.esys.com) Thu, 10 Sep 1998 11:35:00 -0400 (EDT) Andrew, On Thu, 10 Sep 1998, Andrew Scherpbier wrote: >Looks like configure missed the fact that your system needs to pass '-lsocket >-lnsl' to the loader. >Change the LIBS= line in Makefile.config and run make again. That should take >care of it. Excellent!! Worked like a charm, thanks for the help....... Brian ============================================================================ Brian K. Justice Software Engineer Raytheon Systems Company email: bjustice@fallschurch.esys.com 7700 Arlington Blvd., M/S N102 phone: (703) 560-5000 x 2840 Falls Church, VA 22046-1572 ---------------------------------------------------------------------------- #include <raytheon/policy/95-1002-110> ============================================================================ This archive was generated by hypermail 2.0b3 on Sat Jan 02 1999 - 16:27:46 PST
http://www.htdig.org/mail/1998/09/0142.html
CC-MAIN-2015-35
refinedweb
122
77.94
In this tutorial we will learn how to convert an image to black and white, using Python and OpenCV. Introduction). Otherwise, we assign to it the value 255 (white). Note whoever that this is a very simple approach, which may not give the best results if, for example, the image has different light conditions in different areas [1]. You can read here about more advanced operations that we can do in OpenCV to obtain better results. This tutorial was tested on Windows 8.1, with version 4.0.0 of OpenCV. The Python version used was 3.7.2. The code The first thing we need to do is importing the cv2 module, so we have access to all the functions that will allow us to convert the image to black and white. import cv2 Then we will need to obtain the image that we want to convert. So, to read an image from the file system, we simply need to call the imread function, passing as input the path to the file we want to read. Note that the image will be read as a numpy ndarray. originalImage = cv2.imread('C:/Users/N/Desktop/Test.jpg') In order for us to be able to apply the thresholding operation, the image should be in gray scale [2], as already mentioned in the introductory section. Thus, after reading the image, we will convert it to gray scale with a call to the cvtColor function. For a detailed explanation on how to convert an image to gray scale using OpenCV, please check here. So, as first input of the cvtColor, we will pass the original image. As second input we need to pass the color space conversion. grayImage = cv2.cvtColor(originalImage, cv2.COLOR_BGR2GRAY) Now, to convert our image to black and white, we will apply the thresholding operation. To do it, we need to call the threshold function of the cv2 module. For this tutorial we are going to apply the simplest thresholding approach, which is the binary thresholding. Note however that OpenCV offers more types of thresholding, as can be seen here. As already mentioned, the algorithm for binary thresholding corresponds to the following: for each pixel of the image, if the value of the pixel is lesser than a given threshold, then it is set to zero. Otherwise, it is set to a user defined value [3]. Note that since we are operating over a gray scale image, pixel values vary between 0 and 255. Also, since we want to convert the image to black and white, when the pixel is greater than the threshold, the value to which we want it to be converted is 255. Naturally, the threshold function allows us to specify these parameters. So, the first input of the function is the gray scale image to which we want to apply the operation. As second input, it receives the value of the threshold. We will consider the value 127, which is in the middle of the scale of the values a pixel in gray scale can take (from 0 to 255). As third input, the function receives the user defined value to which a pixel should be converted in case its value is greater than the threshold. We will use the value 255, which corresponds to white. Recall that we want to convert the image to black and white, which means that at the end we want a image having pixels with either the value 0 or 255. As fourth input, the function receives a constant indicating the type of thesholding to apply. As already mentioned, we are going to use a binary threshold, so we pass the value THRESH_BINARY. As output, this function call will return a tuple. The first value can be ignored, since it is relevant only for more advanced thresholding methods. The second returned value corresponds to the resulting image, after applying the operation. (thresh, blackAndWhiteImage) = cv2.threshold(grayImage, 127, 255, cv2.THRESH_BINARY) After this, we will show the black and white image in a window, by calling the imshow function. cv2.imshow('Black white image', blackAndWhiteImage) For comparison, we will create two more windows to display the original image and the gray scale version. cv2.imshow('Original image',originalImage) cv2.imshow('Gray image', grayImage) To finalize, we will call the waitKey function with a value of zero, so it blocks indefinitely waiting for a key press. So, until the user presses a key, the windows with the images will be shown. After the user presses a key, the function will return and unblock the execution. Then, we will call the destroyAllWindows function to destroy the previously created windows. cv2.waitKey(0) cv2.destroyAllWindows() The final code can be seen below. import cv2 originalImage = cv2.imread('C:/Users/N/Desktop/Test.jpg') grayImage = cv2.cvtColor(originalImage, cv2.COLOR_BGR2GRAY) (thresh, blackAndWhiteImage) = cv2.threshold(grayImage, 127, 255, cv2.THRESH_BINARY) cv2.imshow('Black white image', blackAndWhiteImage) cv2.imshow('Original image',originalImage) cv2.imshow('Gray image', grayImage) cv2.waitKey(0) cv2.destroyAllWindows() Testing the code To test the code, simply run the previous Python script in an environment of your choice. Naturally, you should use as input of the imread function a path pointing to an image in your file system. You should get an output similar to figure 1, which shows the three versions of the image being displayed in different windows. As can be seen, the image was converted to black and white, as expected. Related Posts References [1] [2] [3]
https://techtutorialsx.com/2019/04/13/python-opencv-converting-image-to-black-and-white/
CC-MAIN-2019-35
refinedweb
917
65.01
We have a new docs home, for this page visit our new documentation site! This example introduces machine learning for Treasure Data using Python by making use of the Chicago Energy Benchmarking dataset to predict future energy consumption. The city of Chicago provides measured energy efficiency for each building to encourages participants to improve the efficiency. Through the energy consumption prediction problem, you will learn how to: - fetch a dataset on Arm Treasure Data with Python - write back a prediction result to Arm Treasure Data with Python Prerequisites This example assumes you are familiar with: - Python - Treasure Data - TD Toolbelt - Pandas-TD - Kaggle - Microsoft's LightGBM - Treasure Data machine learning - Contact support@treasure-data.com. - Ask for the steps to install Pandas-TD, the instructions out on the open source page are not complete or current. - Ask for the steps to install Python in your environment. - Ask for instructions and guidance for how to make sure that you can use LightGBM. For example, are there any special configuration steps i need to do after i follow the install instructions at the following links? : Install by following guide for the command line program, Python-package or R-package. Then please see the Quick Startguide. You can use Google Colaboratory or you must complete: - Setting Up a Python Development Environment - Installation and configuration of a Jupyter Notebook environment Contact TD Support Your account must have a plazma_api role - Contact support@treasure-data.com and ask them for the steps to verify whether you have this account or not. - Optionally, contact sales@treasure-data.com to obtain the plazma_api role. Ingesting the sample data To ingest CSV version of foodmart dataset to Treasure Data: - Download customer.csv and sales.csv to your local machine. - Open the TD Console. - Navigate to Integrations > Source. - At the top-right of the page, select Upload File. - Browse to the customer.csv file. - Open the file within Treasure Data. - Save and select Next. foodmartdatabase. - Check "Create new database?" Optionally, change the database name to avoid conflict. - Check "Create new table?" Input customeras the table name. - Select Start Upload. - Verify that the data uploaded by navigating to Databases > foodmart > customer. - Upload sales.csv. Do NOT "Create new database?" . - The table name is sales. Fetch data from Treasure Data You can run the necessary code snippets from the following Google Colaboratory page. - Open the Google Colaboratory page. - Switch to Playground mode. - Navigate to and run each of the following code snippets: !pip install --quiet git+[spark] # For outside of Google Colaboratory, you should install the following packages !pip install --quiet matplotlib scikit-learn pandas seaborn lightgbm import numpy as np import pandas as pd import seaborn as sns import matplotlib.pyplot as plt import warnings warnings.simplefilter(action='ignore', category=FutureWarning) - Open the TD Console. - Navigate to My Settings > API Keys. - Copy the value of your Write-only key. For example, 1/257c8ce6d39afa0c7b8b79505837e997c7a8xe3x. - Paste it into the <' ... '> part of the following code snippet on the Google Colaboratory page. For example: import os from getpass import getpass td_api_key = getpass('1/257c8ce6d39afa0c7b8b79505837e997c7a8xe3x') os.environ['TD_API_KEY'] = td_api_key print("Succeeded to set the API key") - Run the code snippet. Set your Treasure Data API key as an environment variable Before launching Jupyter notebook, set your master API key as an environment variable on your terminal. Your TD API key can be found in the TD Console profile page. For macOS and Linux: export TD_API_KEY="1234/abcde..." # Replace to your appropriate key For Windows: set TD_API_KEY="1234/abcde..." For PowerShell: $env:TD_API_KEY="1234/abcde..." Prepare Python packages To connect to Treasure Data with Python, you have to install the following Python package. Running the following code, to install Python packages for this article from your terminal. pip install git+[spark] pip install matplotlib scikit-learn pandas seaborn lightgbm jupyter notebook Launch Jupyter notebook from a terminal by the following command: jupyter notebook Open the browser for Jupyter notebook, then create a Python 3 notebook. Load packages for data science and the library for the Treasure Data connection on Jupy Connect to Treasure Data ******these steps all fail regardless of if i run it from the colab notebook or straight up on my local machine. Pandas-TD install instructions are impossible to follow without calling support --- even after getting several tips about how it should work, it still errors. This should really be a lo easier. It is just a tiny little open source project after all.************************************************* - Make sure Pandas TD is installed. - Open Python. For example: $ python - Specify the engine with create_enginefunction. For example: engine = td.create_engine('presto:sample_datasets') - Retrieve TD data with SQL using the read_tdfunction. For example: df = td.read_td('select * from www_access', engine) - Optionally, to load a small table to Pandas, you can use read_td_tablefunction. For example: df = td.read_td_table('nasdaq', engine, limit=10000) - Change db_nameif you haven't ingested to foodmartdatabase. # Replace db_name to your database name db_name = 'foodmart' engine = td.create_engine('presto:{}'.format(db_name)) # `read_td_table` limits row number as 10000 by default. sales = td.read_td_table("sales", engine, limit=270000) customer = td.read_td_table("customer", engine, limit=11000) Check the overview of data *********We get sales and customer data as pandas DataFrame, let's see the snippet, stats, and column names for customer data.*********How do we get it? and where do i review it? from my local file system? through TD Console? why do you want me to look at it? Why should i care about this at all? ************************************** Here is an example of sales data. Here is the example of customer data. Note that, column number is too many to show up with. customer.head() *****************what is thiscode sample for? where am i running it? from TD Console? from my local cmd line? from Visual basic? from within my automated scripts? Why is this syntax even included? What? where? why? # Show customer table column names. print("Columns of customer") list(customer)'] **************what? where? why? How? who runs this? why is it here? what do you want me to do ? should i print this page and post it on my office wall? send it in email?********************************** # Show sales table stats sales.describe() *********what is this? why are you showing me? why do i care? who needs this? when am I going to want to care?******************************** # Show customer table stats customer.describe() Build a purchase number prediction model Get aggregated data for feature with SQL Executing SQLs is good for joining and aggregating multiple tables. Let's make a feature table with SQL. purchase_cnt is the target column for prediction. *********what is this? why are you showing me? why do i care? who needs this? when am I going to want to care?******************************** df = td.read_td(""" select() Additionally, we will create children_at_home_ratio. ************who cares? why should they care? how do i create this? Do i drop it in my javascripts? Run it from a REST command? throw it on the wall to see if it sticks like good pasta? **************** # Add aggregated feature df['children_at_home_ratio'] = (df.num_children_at_home / df.total_children).fillna(0.0) Build a predictive model with LightGBM LightGBM is an open source framework for machine learning, which enables classification or regression with a gradient boosting algorithm. It is one of the most popular framework in Kaggle for solving the problem with structured data.) Starting training... [1] valid_0's l2: 1190.73 Training until validation scores don't improve for 20 rounds. [2] valid_0's l2: 1156.76 ...(snip)... [19] valid_0's l2: 1013.1 [20] valid_0's l2: 1013.15 Did not meet early stopping. Best iteration is: [19] valid_0's l2: 1013.1 Starting predicting... The rmse of prediction is: 31.829242777866064 We got RMSE as a prediction evaluation for regression. ***************You did? I want to too, but at every step of this article i am only ever half successful. I am frustrated and you are bragging. Now i don't want to be your friend or buy your product************************ It is helpful to know the feature importance of each column. ********helpful? why and how?********************** sns.set(style="white", font_scale=1.5) #() Upload prediction result to Treasure Data You can upload pandas DataFrame with using to_td function with running the following code. If your account doesn't have plazma_api role, you have to contact sales@treasure-data.com first, otherwise you'll fail with 403 error. X_pred = df_test['customer_id'].to_frame() X_pred['pred'] = y_pred X_pred.reset_index(drop=True, inplace=True) # Upload prediction result to Treasure Data con = td.connect() td.to_td(X_pred, '{}.sales_pred'.format(db_name), con, if_exists='replace', index=False) print("Uploaded") read_tdfunction. # Check uploaded data td.read_td('select * from sales_pred limit 10', engine) *********what is this? why are you showing me? why do i care? who needs this? when am I going to want to care?******************************** ****************Now what? Am i done? what did I learn? what did i accomplish? how can i use this for other projects?**************************** Please sign in to leave a comment.
https://support.treasuredata.com/hc/en-us/articles/360012745914-Machine-Learning-Example-for-Python
CC-MAIN-2020-29
refinedweb
1,483
62.14