Preface |
|
xv | |
|
|
1 | (14) |
|
|
1 | (1) |
|
|
2 | (1) |
|
This Book Will Show You How |
|
|
3 | (2) |
|
|
5 | (1) |
|
Some Notes About the Perl Versions Used for This Book |
|
|
6 | (1) |
|
|
6 | (1) |
|
What About Strawberry Perl? |
|
|
6 | (1) |
|
|
6 | (1) |
|
Some Notes About Using Vista with the Code in This Book |
|
|
7 | (1) |
|
Locating and Installing Modules |
|
|
8 | (2) |
|
Installing Modules on Unix |
|
|
9 | (1) |
|
Installing Modules on Win32 |
|
|
9 | (1) |
|
It's Not Easy Being Omnipotent |
|
|
10 | (3) |
|
|
10 | (1) |
|
Drop Your Privileges As Soon As Possible |
|
|
10 | (1) |
|
Be Careful When Reading Data |
|
|
11 | (1) |
|
Be Careful When Writing Data |
|
|
12 | (1) |
|
|
12 | (1) |
|
|
13 | (1) |
|
References for More Information |
|
|
13 | (2) |
|
|
15 | (34) |
|
|
15 | (1) |
|
|
16 | (5) |
|
|
16 | (1) |
|
Windows-Based Operating Systems |
|
|
16 | (2) |
|
|
18 | (1) |
|
Filesystem Differences Summary |
|
|
19 | (1) |
|
Dealing with Filesystem Differences from Perl |
|
|
19 | (2) |
|
Walking or Traversing the Filesystem by Hand |
|
|
21 | (5) |
|
Walking the Filesystem Using the File::Find Module |
|
|
26 | (10) |
|
Walking the Filesystem Using the File::Find::Rule Module |
|
|
36 | (2) |
|
|
38 | (7) |
|
Editing Quotas with edquota Trickery |
|
|
40 | (4) |
|
Editing Quotas Using the Quota Module |
|
|
44 | (1) |
|
Editing NTFS Quotas Under Windows |
|
|
45 | (1) |
|
Querying Filesystem Usage |
|
|
46 | (2) |
|
Module Information for This Chapter |
|
|
48 | (1) |
|
References for More Information |
|
|
48 | (1) |
|
|
49 | (50) |
|
|
50 | (9) |
|
The Classic Unix Password File |
|
|
50 | (7) |
|
Changes to the Password File in BSD 4.4 Systems |
|
|
57 | (1) |
|
|
58 | (1) |
|
Windows-Based Operating System User Identities |
|
|
59 | (12) |
|
Windows User Identity Storage and Access |
|
|
59 | (2) |
|
|
61 | (2) |
|
Windows Passwords Don't Play Nice with Unix Passwords |
|
|
63 | (1) |
|
|
63 | (5) |
|
|
68 | (3) |
|
Building an Account System to Manage Users |
|
|
71 | (26) |
|
|
73 | (5) |
|
The Low-Level Component Library |
|
|
78 | (11) |
|
|
89 | (5) |
|
|
94 | (3) |
|
Module Information for This Chapter |
|
|
97 | (1) |
|
References for More Information |
|
|
97 | (2) |
|
|
97 | (1) |
|
Windows User Administration |
|
|
98 | (1) |
|
|
99 | (38) |
|
|
100 | (25) |
|
Windows-Based Operating System Process Control |
|
|
100 | (19) |
|
|
119 | (6) |
|
File and Network Operations |
|
|
125 | (10) |
|
Tracking File Operations on Windows |
|
|
125 | (3) |
|
Tracking Network Operations on Windows |
|
|
128 | (1) |
|
Tracking File and Network Operations in Unix |
|
|
129 | (6) |
|
Module Information for This Chapter |
|
|
135 | (1) |
|
Installing Win32::Setupsup |
|
|
135 | (1) |
|
References for More Information |
|
|
136 | (1) |
|
TCP/IP Name and Configuration Services |
|
|
137 | (48) |
|
|
137 | (14) |
|
|
140 | (3) |
|
Error-Checking the Host File Generation Process |
|
|
143 | (1) |
|
Improving the Host File Output |
|
|
144 | (4) |
|
Incorporating a Source Code Control System |
|
|
148 | (3) |
|
|
151 | (4) |
|
|
154 | (1) |
|
Windows Internet Name Server (WINS) |
|
|
154 | (1) |
|
Domain Name Service (DNS) |
|
|
155 | (19) |
|
Generating DNS (BIND) Configuration Files |
|
|
156 | (9) |
|
DNS Checking: An Iterative Approach |
|
|
165 | (9) |
|
|
174 | (9) |
|
Active Probing for Rogue DHCP Servers |
|
|
176 | (5) |
|
Monitoring Legitimate DHCP Servers |
|
|
181 | (2) |
|
Module Information for This Chapter |
|
|
183 | (1) |
|
References for More Information |
|
|
184 | (1) |
|
Working with Configuration Files |
|
|
185 | (54) |
|
Configuration File Formats |
|
|
188 | (47) |
|
|
188 | (1) |
|
|
189 | (1) |
|
|
190 | (2) |
|
|
192 | (43) |
|
|
235 | (1) |
|
Advanced Configuration Storage Mechanisms |
|
|
236 | (1) |
|
Module Information for This Chapter |
|
|
236 | (1) |
|
References for More Information |
|
|
237 | (2) |
|
|
237 | (2) |
|
SQL Database Administration |
|
|
239 | (26) |
|
Interacting with a SQL Server from Perl |
|
|
240 | (3) |
|
|
243 | (6) |
|
Using ODBC from Within DBI |
|
|
249 | (2) |
|
|
251 | (7) |
|
|
252 | (2) |
|
|
254 | (1) |
|
Microsoft SQL Server via ODBC |
|
|
255 | (3) |
|
|
258 | (2) |
|
Monitoring Space Usage on a Database Server |
|
|
260 | (3) |
|
Module Information for This Chapter |
|
|
263 | (1) |
|
References for More Information |
|
|
263 | (2) |
|
|
263 | (1) |
|
|
264 | (1) |
|
|
264 | (1) |
|
|
264 | (1) |
|
|
265 | (48) |
|
|
265 | (8) |
|
Getting sendmail (or a Similar Mail Transport Agent) |
|
|
266 | (1) |
|
Using the OS-Specific IPC Framework to Drive a Mail Client |
|
|
266 | (2) |
|
Speaking the Mail Protocols Directly |
|
|
268 | (5) |
|
Common Mistakes in Sending Email |
|
|
273 | (12) |
|
Overzealous Message Sending |
|
|
273 | (9) |
|
|
282 | (1) |
|
Insufficient Information in the Message Body |
|
|
282 | (3) |
|
|
285 | (6) |
|
Talking POP3 to Fetch Mail |
|
|
285 | (2) |
|
Talking IMAP4rev1 to Fetch Mail |
|
|
287 | (4) |
|
|
291 | (19) |
|
Dissecting a Single Message |
|
|
291 | (5) |
|
Dissecting a Whole Mailbox |
|
|
296 | (1) |
|
|
297 | (8) |
|
Support Mail Augmentation |
|
|
305 | (5) |
|
Module Information for This Chapter |
|
|
310 | (1) |
|
References for More Information |
|
|
311 | (2) |
|
|
313 | (64) |
|
|
313 | (1) |
|
Finger: A Simple Directory Service |
|
|
314 | (4) |
|
The WHOIS Directory Service |
|
|
318 | (3) |
|
LDAP: A Sophisticated Directory Service |
|
|
321 | (33) |
|
LDAP Programming with Perl |
|
|
322 | (1) |
|
The Initial LDAP Connection |
|
|
323 | (2) |
|
|
325 | (4) |
|
Entry Representation in Perl |
|
|
329 | (2) |
|
|
331 | (2) |
|
Adding Entries with Standard LDAP Operations |
|
|
333 | (1) |
|
|
334 | (1) |
|
|
335 | (2) |
|
Modifying Entry Attributes |
|
|
337 | (2) |
|
|
339 | (9) |
|
|
348 | (6) |
|
Active Directory Service Interfaces |
|
|
354 | (19) |
|
|
355 | (2) |
|
|
357 | (2) |
|
Dealing with Container/Collection Objects |
|
|
359 | (1) |
|
Identifying a Container Object |
|
|
360 | (1) |
|
So How Do You Know Anything About an Object? |
|
|
360 | (3) |
|
|
363 | (3) |
|
Performing Common Tasks Using the WinNT and LDAP Namespaces |
|
|
366 | (1) |
|
Working with Users via ADSI |
|
|
367 | (2) |
|
Working with Groups via ADSI |
|
|
369 | (1) |
|
Working with File Shares via ADSI |
|
|
369 | (1) |
|
Working with Print Queues and Print Jobs via ADSI |
|
|
370 | (1) |
|
Working with Windows-Based Operating System Services via ADSI |
|
|
371 | (2) |
|
Module Information for This Chapter |
|
|
373 | (1) |
|
References for More Information |
|
|
373 | (4) |
|
|
373 | (1) |
|
|
374 | (3) |
|
|
377 | (56) |
|
|
377 | (1) |
|
|
378 | (7) |
|
|
378 | (5) |
|
Calling an OS (or Someone Else's) Binary |
|
|
383 | (1) |
|
Using the OS's Logging API |
|
|
384 | (1) |
|
Structure of Log File Data |
|
|
385 | (3) |
|
Dealing with Log File Information |
|
|
388 | (37) |
|
Space Management of Logging Information |
|
|
388 | (7) |
|
|
395 | (30) |
|
Writing Your Own Log Files |
|
|
425 | (4) |
|
Logging Shortcuts and Formatting Help |
|
|
425 | (1) |
|
Basic/Intermediate Logging Frameworks |
|
|
426 | (2) |
|
Advanced Logging Framework |
|
|
428 | (1) |
|
Module Information for This Chapter |
|
|
429 | (1) |
|
References for More Information |
|
|
430 | (3) |
|
|
433 | (36) |
|
Noticing Unexpected or Unauthorized Changes |
|
|
434 | (8) |
|
|
434 | (6) |
|
Changes in Data Served Over the Network |
|
|
440 | (2) |
|
Noticing Suspicious Activities |
|
|
442 | (7) |
|
|
442 | (2) |
|
Finding Problematic Patterns |
|
|
444 | (5) |
|
Danger on the Wire, or ``Perl Saves the Day'' |
|
|
449 | (11) |
|
Preventing Suspicious Activities |
|
|
460 | (6) |
|
|
460 | (1) |
|
|
461 | (5) |
|
Module Information for This Chapter |
|
|
466 | (1) |
|
References for More Information |
|
|
467 | (2) |
|
|
469 | (20) |
|
|
469 | (17) |
|
Sending and Receiving SNMP Traps, Notifications, and Informs |
|
|
480 | (4) |
|
Alternative SNMP Programming Interfaces |
|
|
484 | (2) |
|
Module Information for This Chapter |
|
|
486 | (1) |
|
References for More Information |
|
|
486 | (3) |
|
Network Mapping and Monitoring |
|
|
489 | (40) |
|
|
489 | (14) |
|
|
490 | (9) |
|
Discovering Network Services |
|
|
499 | (2) |
|
|
501 | (2) |
|
Presenting the Information |
|
|
503 | (19) |
|
Textual Presentation Tools |
|
|
503 | (4) |
|
Graphical Presentation Tools |
|
|
507 | (15) |
|
|
522 | (4) |
|
Extending Existing Monitoring Packages |
|
|
524 | (2) |
|
|
526 | (1) |
|
Module Information for This Chapter |
|
|
527 | (1) |
|
References for More Information |
|
|
527 | (2) |
|
|
529 | (28) |
|
|
530 | (7) |
|
|
530 | (1) |
|
|
531 | (2) |
|
Writing Out the Correct XML File |
|
|
533 | (1) |
|
|
534 | (2) |
|
Summary: What Can We Learn from This? |
|
|
536 | (1) |
|
|
537 | (7) |
|
Geocoding from Postal Addresses |
|
|
537 | (4) |
|
Geocoding from IP Addresses |
|
|
541 | (3) |
|
Summary: What Can We Learn from This? |
|
|
544 | (1) |
|
Playing with an MP3 Collection |
|
|
544 | (2) |
|
Summary: What Can We Learn from This? |
|
|
546 | (1) |
|
|
546 | (9) |
|
Retrieving the Wiki Page with WWW::Mechanize |
|
|
547 | (3) |
|
|
550 | (1) |
|
Geocoding and Mapping the Data |
|
|
551 | (3) |
|
Summary: What Can We Learn from This? |
|
|
554 | (1) |
|
|
555 | (1) |
|
Module Information for This Chapter |
|
|
555 | (1) |
|
Source Material for This Chapter |
|
|
556 | (1) |
The Eight-Minute XML Tutorial |
|
557 | (6) |
The 10-Minute XPath Tutorial |
|
563 | (10) |
The 10-Minute LDAP Tutorial |
|
573 | (6) |
The 15-Minute SQL Tutorial |
|
579 | (14) |
The Five-Minute RCS Tutorial |
|
593 | (4) |
The Two-Minute VBScript-to-Perl Tutorial |
|
597 | (6) |
The 20-Minute SNMP Tutorial |
|
603 | (14) |
Index |
|
617 | |