Commit Graph

46 Commits

Author SHA1 Message Date
Felipe Pena
4e19825281 - Year++ 2012-01-01 13:15:04 +00:00
Boris Lytochkin
bc3d5d668f merge from trunk
added SNMPException class, enabling ability to throw exceptions
when a known SNMP error has occured
FR #55542
2011-09-02 10:13:30 +00:00
Boris Lytochkin
8c5fa2ba56 merge from trunk:
remove php_snmp_get_ce()
2011-09-02 08:09:23 +00:00
Boris Lytochkin
1c88dcf39f merge from trunk:
set ERRNO_OID_PARSING_ERROR on OID parse error
2011-08-30 14:24:00 +00:00
Boris Lytochkin
02bf16db03 s/noOIDIncreasingCheck/oid_increasing_check/ 2011-07-21 12:48:47 +00:00
Boris Lytochkin
85edf25143 new propery noOIDIncreasingCheck allowing to skip
OID increasing check (userful for bogus SNMP agents)
2011-07-17 19:47:24 +00:00
Boris Lytochkin
2b8026cfff merging from trunk (r312088...r312092):
move SNMP VERSION constants into SNMP class itself
fix typo in comment
no more method open
fix method names in header
2011-06-12 12:10:01 +00:00
Boris Lytochkin
ee0d7f3207 * new option for SNMP::get: force keys of return array be as in request array
* new option for SNMP::walk: use suffix of OID for keys in return array, not full OID
2011-05-08 13:58:37 +00:00
Boris Lytochkin
cab643f615 * added detection and walkaround for net-snmp library bug (net-snmp BUGid 2027834)
* drop UCD-SNMP support, R.I.P.
2011-04-05 12:20:35 +00:00
Boris Lytochkin
14eaa5ac58 follow CS:
- method set_security should be named as setSecurity
 - SNMP_VERSION_2C constant
2011-03-20 20:07:33 +00:00
Boris Lytochkin
3c0f1d5b95 * fix warning about redefining REGISTER_PDO_CLASS_CONST_LONG (damn copy'n'paste)
* tuned two unit test that failed at gcov.php.net/PHP_HEAD
2011-03-04 18:58:01 +00:00
Boris Lytochkin
1c65920819 * new methods get_errno, get_error to get errno and error string
of last SNMP-related error
* formatting markup
* some fixes in max_oids logic: NULL will set it to default value,
    do not allow non-positive user-supplied values
* unit tests for changes
2011-02-26 08:27:26 +00:00
Boris Lytochkin
dc781e2520 - Improved SNMP extension:
. Allow ~infinite OIDs in GET/GETNEXT/SET queries. Autochunk them to max_oids
    upon request.
2011-02-01 07:45:30 +00:00
Boris Lytochkin
5e82e334dd Improved SNMP extension. FR #53594 2011-01-31 11:41:33 +00:00
Felipe Pena
0203cc3d44 - Year++ 2011-01-01 02:17:06 +00:00
Sebastian Bergmann
9ba1e81665 sed -i "s#1997-2009#1997-2010#g" **/*.c **/*.h **/*.php 2010-01-03 09:23:27 +00:00
Sebastian Bergmann
08659c2dcd MFH: Bump copyright year, 3 of 3. 2008-12-31 11:15:49 +00:00
Sebastian Bergmann
d1dded8751 MFH: Bump copyright year, 2 of 2. 2007-12-31 07:17:19 +00:00
Sebastian Bergmann
4223aa4d5e MFH: Bump year. 2007-01-01 09:36:18 +00:00
foobar
f58da213ff MFH: - Fixed bug #37164 (snmp_set_oid_numeric_print() misbehaves)
MFH:   . Renamed the function to snmp_set_oid_output_format() which describes
MFH:     it's behaviour better. Old one was left as an alias for it.
MFH:   . Added 2 new constants: SNMP_OID_OUTPUT_FULL and SNMP_OID_OUTPUT_NUMERIC
MFH: - Fixed some memleaks
2006-07-27 05:17:34 +00:00
foobar
5bd93221a8 bump year and license version 2006-01-01 12:51:34 +00:00
foobar
23e671a51e - Bumber up year 2005-08-03 14:08:58 +00:00
Harrie Hazewinkel
e6ae6fc62d Adding SNMPv2 community based (i.e. protocol version) functions. 2005-03-16 14:29:40 +00:00
foobar
9ea10c5cec - Fix some memory leaks 2005-01-08 12:02:22 +00:00
foobar
ccfc46b0aa - Happy new year and PHP 5 for rest of the files too..
# Should the LICENSE and Zend/LICENSE dates be updated too?
2004-01-08 17:33:29 +00:00
foobar
704a7e5653 - Added snmp_read_mib() which reads a MIB file into the active MIB tree. 2003-07-16 09:28:47 +00:00
Harrie Hazewinkel
a8d156177f Adding an SNMP GETNEXT.
This is a basic SNMP operation that retrieves the next value as the
one provided to the command.
NOTE: snmpgetnext does not follow the official naming convetions of
functions, but now it is equal to it version 1 equivalents snmpget
and snmpset.
I also would like to reserve the snmp_getnext for a function to
which a session can be given instead of the multiple values to
create the session internally. (Work in progress).
2003-07-14 18:10:22 +00:00
Harrie Hazewinkel
6dd04c368e (RE-)Applying the contributed patch of Johan Hanne to the main tree.
The patch enables control on the way the values are returned
into the PHP script, instaed of always strings. Also the
type of the value is now returned when configured to do so.
This enables better management scripts to do more automatic
processing and value calculations.
(By default the values are returned as strings, as was before)
2003-07-14 17:11:04 +00:00
James Cox
f68c7ff249 updating license information in the headers. 2003-06-10 20:04:29 +00:00
foobar
7d256c1ae1 MFB 2003-02-21 10:43:32 +00:00
Sebastian Bergmann
b506f5c8f8 Bump year. 2002-12-31 16:08:15 +00:00
Derick Rethans
83741be445 - Renamed snmpv3_* to snmp3_*
- Conversion to php_error_docref
- Whitespace fixes
2002-12-05 19:33:03 +00:00
Harrie Hazewinkel
6a14b16e34 Adding a more detail print functions, that assist/make it easier for
creating SNMP scripts.
They are only supported when you have NET-SNMP.
Need to be documented still though.
2002-11-11 21:37:19 +00:00
Harrie Hazewinkel
957f651708 Adding SNMPv3 support.
This splits the old php_snmp function into an argument parsing part and
a data retrieval part. The data retrieval part is reused for SNMPv3.
SNMPv3 has only a different argument parsing.

THe code is not extremely beautiful, but having NET-SNMP and
UCD-SNMP support creates this. :-(
Documentation must still be done.
2002-11-11 21:09:19 +00:00
Sebastian Bergmann
90613d2282 Maintain headers. 2002-02-28 08:29:35 +00:00
Sebastian Bergmann
38933514e1 Update headers. 2001-12-11 15:32:16 +00:00
Andi Gutmans
eb6ba01d1c - Fix copyright notices with 2001 2001-02-26 06:11:02 +00:00
Sascha Schumann
16017f6d78 Change header protection macros to conform to standard.
Draft 3 of IEEE 1003.1 200x, "2.2 The Compilation Environment"

  All identifiers that begin with an underscore and either an uppercase
  letter or another underscore are always reserved for any use by the
  implementation.
2000-07-02 23:46:51 +00:00
Andi Gutmans
a9d4cf9023 - Nuke COMPILE_DL. Modules that need to be compiled as dll's in Windows
- need to define both COMPILE_DL_MODULE and HAVE_MODULE=1
2000-06-10 08:48:01 +00:00
Zeev Suraski
e043439ff6 Update the license with the new clause 6 2000-05-18 15:34:45 +00:00
Sterling Hughes
a9f0e0176b - snmpwalkoid is an alias now
- small optimizations
- delete that switch case in php_snmp
  =The different functions are now in the PHP_FUNCTION declaration thingies
- If-else blocks have brackets
2000-03-25 19:58:19 +00:00
Zeev Suraski
86fa2aade2 the pipe is breaking all the time 2000-02-19 23:41:32 +00:00
Sascha Schumann
43ae2bffbb Happy Y2K patch! Happy new year (or the new millennium, depending on whether
you start counting at 0 or 1).
2000-01-01 01:32:05 +00:00
Zeev Suraski
83fef4866d More php3_ cleanup 1999-12-18 04:08:03 +00:00
Zeev Suraski
fb1c77bd4f - Made PHP_VERSION and PHP_OS work again
- More php3_ cleanup
@- Restored the PHP_VERSION and PHP_OS constants (Zeev)
1999-12-17 20:55:31 +00:00
Sascha Schumann
5b983c944f Clean up php3.*\.h files. The files itself are renamed, and references in all
.*\.[ch] files were changed. There is a slight chance that my script missed
a few changes, please correct them manually.
1999-12-04 19:19:57 +00:00