aboutsummaryrefslogtreecommitdiffstats
path: root/lib
AgeCommit message (Collapse)Author
2014-05-27Merge branch 'maint-17' into maintIngela Anderton Andin
Conflicts: OTP_VERSION lib/ssh/test/ssh_basic_SUITE.erl lib/ssh/vsn.mk
2014-05-27Update release notesErlang/OTP
2014-05-27Merge branch 'hans/ssh/patch-17.0.2' into maint-17Erlang/OTP
* hans/ssh/patch-17.0.2: ssh: Prepare for release ssh: Use correct timeout value for the connection timeout ssh: Add max_session parameter to ssh:daemon
2014-05-27Merge branch 'ia/inets/prep' into maint-17Erlang/OTP
* ia/inets/prep: inets: Prepare for release
2014-05-27Merge branch 'ia/inets/maint-17/string-lengths/OTP-11925' into maint-17Erlang/OTP
* ia/inets/maint-17/string-lengths/OTP-11925: inets: httpd - Behave well on not so long but wrong request lines inets: httpc - update test suite framwork to adopt to change in httpd inets: httpd - Reject incorrect large request lines early
2014-05-27inets: Correct distirbing mode for httpd:reload_config/2Ingela Anderton Andin
config_reload tests are not enough to test httpd "block/unblock" used by config_reload, so renable some test cases in the old_httpd_SUITE after making them work with the new code. Should be cleaned up and moved to httpd_SUITE.
2014-05-27Merge branch 'anders/diameter/Failed-AVP/OTP-11936' into maintAnders Svensson
* anders/diameter/Failed-AVP/OTP-11936: Do best-effort decode of Failed-AVP Add a testcase that expects a decoded value in Failed-AVP
2014-05-27Merge branch 'anders/diameter/5014/OTP-11946' into maintAnders Svensson
* anders/diameter/5014/OTP-11946: Fix handling of AVP length errors (5014) in unknown AVPs Add testcases that send unknown AVPs with a bad AVP Length
2014-05-27Merge branch 'anders/diameter/hardening/OTP-11721' into maintAnders Svensson
* anders/diameter/hardening/OTP-11721: Simplify example server Make example server answer unsupported requests with 3001 Make example code quiet Don't count messages on arbitrary keys Replace traffic-related log reports with no-op function calls
2014-05-26Do best-effort decode of Failed-AVPAnders Svensson
Commit 4ce2d3a6 (diameter-1.4.2, OTP-11007) disabled the decode of values in Failed-AVP components since any error caused the decode of Failed-AVP itself to fail. This is less than useful since (1) we should be able to decode it given that we've sent it (modulo mangling on the way to the peer and back), and (2) it's not unheard of to examine Failed-AVP to see what the peer objected to. This commits adds a best-effort decode: decode if possible, otherwise not, using the same abuse of the process dictionary as commit bbdb027c.
2014-05-26Add a testcase that expects a decoded value in Failed-AVPAnders Svensson
This isn't currently the case, but soon will be.
2014-05-26Fix handling of AVP length errors (5014) in unknown AVPsAnders Svensson
Commit 4ce2d3a6 added the insertion of a single bit into binary AVP data to induce an encode error in the case of a header length that pointed past the available bytes: a 5014 = DIAMETER_INVALID_AVP_LENGTH error. Commit 838856b fixed this for stringish Diameter types, but both commits neglected the case in which the offending AVP isn't known to the dictionary in question. Unless the AVP was regarded as erroneous for other reasons (eg. an M-bit resulting in 5001) it would be happily be packed into an 'AVP' field. If it was regarded as an error, the record could be passed back to diameter_codec:pack_avp/1, and if the record contained header data then there was no clause to deal with the unpleasantry. Deal with it by having the dictionary module strip the extra bit and flag the AVP as 5014, and by having diameter_codec handle any extra bit coming from an dictionary compiled against an old diameter_gen. An old dictionary won't detect 5014 however, so dictionaries should be recompiled. Change most of the guards in diameter_codec from is_bitstring/1 to is_binary/1. What's being passed to the decode functions are binaries received other the network. The only case in which a non-binary bitstring is when we've placed an extra bit there ourselves. (Modulo someone doing something they shouldn't.)
2014-05-26Add testcases that send unknown AVPs with a bad AVP LengthAnders Svensson
In particular, a length that points past the end of the message. This goes undetected there is some other problem with the AVP (eg. M-bit), which is a problem we're about to fix.
2014-05-26Merge branch 'saa/add_default_value_for_maps_get/OTP-11951' into maintBjörn-Egil Dahlberg
* saa/add_default_value_for_maps_get/OTP-11951: stdlib: Fix indentation of maps doc Add docs and test for maps:get/3 Add default value for maps:get
2014-05-26ssh: Prepare for releaseHans Nilsson
2014-05-26ssh: Use correct timeout value for the connection timeoutIngela Anderton Andin
2014-05-26ssh: Add max_session parameter to ssh:daemonHans Nilsson
2014-05-26stdlib: Fix indentation of maps docBjörn-Egil Dahlberg
2014-05-26Merge branch 'dgud/observer/tests/OTP-11949' into maintDan Gudmundsson
* dgud/observer/tests/OTP-11949: observer: Let wx create statusbar observer: Destroy the wx env observer: Fix range check Test Tweaks Enable tests
2014-05-26Simplify example serverAnders Svensson
In particular, remove the unnecessary list-or-record answer.
2014-05-26Make example server answer unsupported requests with 3001Anders Svensson
As it should. The previous discard (surely) pre-dated being able to return {answer_message, 3001} from a handle_request callback.
2014-05-26Make example code quietAnders Svensson
The output could make it impossible to use the shell. Counters returned diameter:service_info/2 can be used to check for expected happenings.
2014-05-26Don't count messages on arbitrary keysAnders Svensson
That is, don't use a key constructed from an incoming Diameter header unless the message is known to the dictionary in question. Otherwise there are 2^32 application ids, 2^24 command codes, and 2 R-bits for an ill-willed peer to choose from, each resulting in new keys in the counter table (diameter_stats). The usual {ApplicationId, CommandCode, Rbit} in a key is replaced by the atom 'unknown' if the message in question is unknown to the decoding dictionary. Counters for messages sent and received by a relay are (still) not implemented.
2014-05-26Replace traffic-related log reports with no-op function callsAnders Svensson
The former were a little over-enthusiastic and could cause a node to be logged to death if a peer Diameter node was sufficiently ill-willed. The function calls are to diameter_lib:log/4, the arguments of which identify the happening in question, and which does nothing but provide a function to trace on. Many existing log calls have been shrunk. The only remaining traffic-related report (hopefully) is that resulting from {answer_errors, report} config, and this has been slimmed.
2014-05-26Merge branch 'dgud/mnesia/timing-issue' into maintDan Gudmundsson
* dgud/mnesia/timing-issue: mnesia: Fix timing issue
2014-05-26Merge branch 'dgud/testcasecuddling' into maintDan Gudmundsson
* dgud/testcasecuddling: mnesia: Improve tests
2014-05-26Merge branch 'dgud/mnesia/force-load-hangs/OTP-11948' into maintDan Gudmundsson
* dgud/mnesia/force-load-hangs/OTP-11948: mnesia: Handle failed net_loads better
2014-05-26Merge branch 'egil/fix-maps-pretty-layout/OTP-11947' into maintBjörn-Egil Dahlberg
* egil/fix-maps-pretty-layout/OTP-11947: dialyzer: Add Maps type mismatch test hipe,compiler: Fix Map literals pretty printing
2014-05-26Merge branch 'nox/maps-cerl-ann_make_tree' into maintBjörn-Egil Dahlberg
* nox/maps-cerl-ann_make_tree: Support maps in cerl:ann_make_tree/3
2014-05-26inets: Prepare for releaseIngela Anderton Andin
Do application restart as old soft upgrade was not correct
2014-05-26Merge branch 'anders/diameter/dpr/OTP-11938' into maintAnders Svensson
* anders/diameter/dpr/OTP-11938: Ensure watchdog dies with transport if DPA was sent
2014-05-26Merge branch 'anders/diameter/sctp/OTP-11901' into maintAnders Svensson
* anders/diameter/sctp/OTP-11901: Fix diameter_sctp function_clause Anchor path regexps in examples suite Run examples suite over both TCP and SCTP
2014-05-26Merge branch 'hb/hipe/field_with_remote/OTP-11918' into maintHans Bolinder
* hb/hipe/field_with_remote/OTP-11918: hipe: fix a bug concerning typed record fields
2014-05-25Merge branch 'anders/diameter/rc_counters/OTP-11937' into maintAnders Svensson
* anders/diameter/rc_counters/OTP-11937: Count encode errors in outgoing messages Count decode errors in incoming requests Count decode errors independently of result codes
2014-05-25Merge branch 'anders/diameter/rc_counters/OTP-11891' into maintAnders Svensson
* anders/diameter/rc_counters/OTP-11891: Count result codes in CEA/DWA/DPA
2014-05-25Merge branch 'anders/diameter/watchdog_leak/OTP-11934' into maintAnders Svensson
* anders/diameter/watchdog_leak/OTP-11934: Simplify sending of 'close' to watchdog Fix watchdog table leak
2014-05-25Merge branch 'anders/diameter/request_leak/OTP-11893' into maintAnders Svensson
* anders/diameter/request_leak/OTP-11893: Fix leaking request table Add check that request table is empty to failover suite Comment fix
2014-05-25Fix diameter_sctp function_clauseAnders Svensson
Introduced in commit ed6395a6. The {stream, Id} transport_data set upon reception is passed back to us by default when receiving the answer to a request message, so even capabilities exchange failed.
2014-05-25Anchor path regexps in examples suiteAnders Svensson
They match emacs backup files and more without the anchor, although this doesn't stop the matches from finding files the suite isn't (yet) intended to test: files under development, not yet commited, etc.
2014-05-25Run examples suite over both TCP and SCTPAnders Svensson
This was supposed to already be the case (in what passes for my memory), and detects that commit ed6395a6 is horrifically broken: diameter is unable to send CEA over SCTP.
2014-05-23inets: httpd - Behave well on not so long but wrong request linesIngela Anderton Andin
2014-05-23inets: httpc - update test suite framwork to adopt to change in httpdIngela Anderton Andin
2014-05-23inets: httpd - Reject incorrect large request lines earlyIngela Anderton Andin
2014-05-23Ensure watchdog dies with transport if DPA was sentAnders Svensson
A DPR/DPA exchange should always cause the watchdog process in question to die with the transport, so that a subsequent connection with the same peer doesn't result in a 3 x DWR/DWA exchange. Commit 5903d6db saw to this for the sending of DPR but neglected the corresponding problem for DPA. In the case of sending DPR (the aforementioned commit), note that there's no distinction between receiving DPA as expected and not: the watchdog dies with the transport regardless. diameter_watchdog must be loaded first at upgrade.
2014-05-23Count encode errors in outgoing messagesAnders Svensson
Only decode errors were counted previously. Keys are of the form {Id, send, error}, where Id is: {ApplicationId, CommandCode, Rbit} | unknown The latter will be the case if not even a #diameter_header{} can be constructed.
2014-05-23hipe: fix a bug concerning typed record fieldsHans Bolinder
2014-05-22Merge branch 'scrapinghub/stream_for_chunked_single_message' into maintMarcus Arendt
* scrapinghub/stream_for_chunked_single_message: inets: Fix streaming with single chunk body
2014-05-22Merge branch 'jv/ssh-io-binary' into maintMarcus Arendt
* jv/ssh-io-binary: Support binary standard_input in ssh_io
2014-05-22Merge branch 'dz/fix_ssl_max_seq_num' into maintMarcus Arendt
* dz/fix_ssl_max_seq_num: ssl: fix max sequence number so it does not overflow
2014-05-22Count decode errors in incoming requestsAnders Svensson
Errors were only counted in incoming answers. Counters are keyed on tuples of the same form: {{ApplicationId, CommandCode, Rbit}, recv, error}