aboutsummaryrefslogtreecommitdiffstats
path: root/lib
AgeCommit message (Collapse)Author
2017-05-19[ct] Add ct_ssh:shell/2,3Siri Hansen
2017-05-17Merge branch 'ferd/kernel/shell-history-storage/OTP-14409'Dan Gudmundsson
* ferd/kernel/shell-history-storage/OTP-14409: Add persistence to history of the non-legacy shell add option 'quiet' to disk_log Fix type declaration for disk_log.hrl
2017-05-17Merge branch 'hans/ssh/cuddle_tests'Hans Nilsson
2017-05-17Merge branch 'hans/ssh/ext-info_bug_fixes'Hans Nilsson
2017-05-17ssh: update testcase in ssh_to_opensshHans Nilsson
2017-05-17ssh: test case didn't set preferred_algorithmsHans Nilsson
2017-05-17ssh: update property test for sign-algorithmHans Nilsson
2017-05-17ssh: fix end_per_suite in property testcaseHans Nilsson
2017-05-17ssh: disable rsa-sha2-* for clientsHans Nilsson
because there is a bug in the client verification code for those algorithms
2017-05-17ssh: select server-sig-algs from configured algos (preferred_algorithms)Hans Nilsson
2017-05-17ssh: Use 'server-sig-algs' for client's selection of algsHans Nilsson
2017-05-17ssh: fix broken preferred_algorithms and pref_public_key_algs optionsHans Nilsson
2017-05-17ssh: make ssh_algorithms_SUITE test public user and host keysHans Nilsson
Conflicts: lib/ssh/src/ssh_transport.erl
2017-05-17ssh: Enable rsa-sha2-*Hans Nilsson
Conflicts: lib/ssh/src/ssh_transport.erl
2017-05-17Merge branch 'dgud/observer/chunk-proc-info'Dan Gudmundsson
* dgud/observer/chunk-proc-info: observer: Fix alpabetic ordering when sorting on Name observer: Handle crash when node goes down observer: listen on correct notebook change observer: chunk process list info
2017-05-17Merge branch 'dgud/wx/fix-msvc-2015'Dan Gudmundsson
* dgud/wx/fix-msvc-2015: wx: Fix builds on VS-2017
2017-05-17Add persistence to history of the non-legacy shellFred Hebert
This patch adds a mechanism by which shell history gets stored persistently on disk and gets loaded whenever a new shell session begins. The log files are added to the user's cache directory, with multiple files in it, although the location is configurable. All Erlang instances on a given host will share the same log file. There are two hook points in group.erl that are used: when instantiating the buffer, where we fetch from disk, and when adding a line to the buffer (gets stored). This allows all shell instances to use the same base set of lines when loaded, but to keep their history separate after the fact. As lines are added as you go, a new shell session (with ^G -> s -> c) will have access to previous sessions' lines. The implementation makes use of the disk_log library with a rotating log in order to store data, and allow automated repairs. By default, the feature is disabled and must be turned on through OTP environment variable part of the kernel application. The options include: | Option | Accepted values | Default | Description | | ------------------------ | ----------------- |---------- | -------------------- | | shell_history | enabled, disabled | disabled | turn feature on/off | | shell_history_path | any string | user cache| where to put files | | shell_history_file_bytes | 51200..N bytes | 512kb | max data size (>50kb)| | shell_history_drop | ["q().", ...] | [] | blacklisted lines | A version header is added to the disk_log configuration, allowing changes in the storage format to be enacted in the future (i.e. adding segmentation by node name in the same file, or encoding) without conflict. Log rotation is used with multiple log files to ensure proper enforcement of resizing without too much data loss. Because disk_log does not allow to just flush bits of content on rewrite (it truncates any full file), we instead use a wrap log and try to divide the configured size into up to 10 log files so that every time we rotate a log, we lose only 10% of the data. This remains true for corrupted files that cannot fully be repaired. This many-logs-based approach in turn forces the use of a minimal log size for the `shell_history_file_bytes` configuration, since it has to be divided by 10. The shell history is not loaded for the `user` process which, despite running the group.erl module, does not actually require history as it mostly just forwards IO protocol information.
2017-05-17add option 'quiet' to disk_logFred Hebert
This option allows to suppress output of info_msgs to error_logger when recoverable errors are encountered in disk_log by setting the value to 'true'. Defaults to 'false', the backwards compatible behaviour.
2017-05-17Fix type declaration for disk_log.hrlFred Hebert
A specific type was given as an atom rather than an actual type defintion.
2017-05-17Merge pull request #1465 from bjorng/bjorn/tools/fix-lcnt-docBjörn Gustavsson
Fix a few minor issues in the lcnt documentation
2017-05-17Merge pull request #1463 from bjorng/bjorn/simplify-building-lcnt/OTP-14407Björn Gustavsson
Simplify building a lock-counting emulator
2017-05-17Fix a few minor issues in the lcnt documentationBjörn Gustavsson
We generally avoid abbreviations such as "e.g." and "i.e." in the documentation. We write "Erlang", not "erlang" (except when referring to the erlang module).
2017-05-16Merge branch 'ingela/dtls/opts'Ingela Anderton Andin
* ingela/dtls/opts: ssl: Adopt setopts and getopts for DTLS
2017-05-16ssl: Adopt setopts and getopts for DTLSIngela Anderton Andin
2017-05-16Merge pull request #1452 from niku/patch-1Ingela Andin
Revise minor notation in httpc:request/[4,5]
2017-05-16Merge branch 'ingela/remove-debug'Ingela Anderton Andin
* ingela/remove-debug: ssl: Remove debug printout
2017-05-16ssl: Remove debug printoutIngela Anderton Andin
2017-05-16Merge branch 'hans/ssh/ssh_file_user_key_checks_ec_size/OTP-14410'Hans Nilsson
2017-05-16Merge branch 'hans/ssh/test_ext_info_extension/OTP-14361'Hans Nilsson
2017-05-16Merge branch 'hans/ssh/enable_auth_methods_for_clients/OTP-14399'Hans Nilsson
2017-05-16lcnt_SUITE: Add a smoke test for running lock-countingBjörn Gustavsson
2017-05-16Update instructions for how to start the lock-counting VMBjörn Gustavsson
2017-05-16Merge branch 'ingela/dtls/replay-protect/OTP-14077'Ingela Anderton Andin
* ingela/dtls/replay-protect/OTP-14077: dtls: Implement replay protection
2017-05-16dtls: Implement replay protectionIngela Anderton Andin
See RFC 6347 section 3.3
2017-05-16Merge pull request #1453 from bjorng/bjorn/catch-warning/OTP-14401Björn Gustavsson
Warn for potentially unsafe use of get_stacktrace/0
2017-05-15ssh: ssh_file:user_key/2 checks ec keytypeHans Nilsson
2017-05-15Merge pull request #1407 from eltex-ecss/auto_hibernate_timeoutIngela Andin
Add option hibernate_after to gen_server, gen_statem and gen_event. Also added to the deprecated gen_fsm behaviour. OTP14405
2017-05-15Merge pull request #1322 from tsloughter/binary_uri_encodeIngela Andin
Add unicode binary support to http_uri functions OTP-14404
2017-05-15Merge branch 'ingela/ssl/bench-certs'Ingela Anderton Andin
* ingela/ssl/bench-certs: ssl: Disable Server Name verification in bench tests for now
2017-05-15ssl: Disable Server Name verification in bench tests for nowIngela Anderton Andin
2017-05-15Fix minor typo and notation in httpc:request/[4,5]niku
2017-05-12ssh: Tests for ext-info extension (ext-info-c)Hans Nilsson
2017-05-12ssh: Tests for ext-info extension (ext-info-s)Hans Nilsson
2017-05-12ssh: Better error checking for option 'auth_methods'Hans Nilsson
2017-05-12ssh: Doc option 'auth_methods' for clientHans Nilsson
2017-05-12ssh: Option 'auth_methods' available not only in server but also in clientHans Nilsson
2017-05-12Merge branch 'maint'Hans Nilsson
Conflicts: OTP_VERSION lib/inets/vsn.mk lib/ssl/vsn.mk
2017-05-12Merge branch 'maint-19' into maintHans Nilsson
2017-05-12Warn for potentially unsafe use of get_stacktrace/0Björn Gustavsson
erlang:get_stacktrace/0 returns the stacktrace for the latest exception. The problem is that the stacktrace is kept until the next exception occurs. If the last exception was a 'function_clause' or a 'badarg', the arguments for the call are also kept forever. The arguments can be terms of any size (potentially huge). In a future release, we would like to only allow erlang:get_stacktrace/0 from within a 'try' expression. That would make it possible to clear the stacktrace when the 'try' expression is exited. The 'catch' expression has no natural end where the stacktrace could be cleared. The stacktrace could be cleared at the end of the function that the 'catch' occurs in, but that would cause problems in the following scenario (from real life, but simplified): try ... catch _:_ -> io:format(...), io:format("~p\n", [erlang:get_stacktrace()]) end. %% In io.erl. format(Fmt, Args) -> Res = case ... of SomePattern -> catch... ...; SomeOtherPattern -> %% Output the formatted string here ... end, clear_stacktrace(), %% Inserted by compiler. Res. The call to io:format() would always clear the stacktrace before it could be retrieved. That problem could be solved by tightning the scope in which the stacktrace is kept, but the rules for how long erlang:get_stacktrace/0 would work would become complicated. Therefore, the solution we suggest for a future major release of OTP is that erlang:get_stacktrace/0 will return [] if it is called outside the 'catch' part of a 'try' expression. To help users prepare, introduce a warning when it is likely that erlang:get_stacktrace/0 will always return an empty list, for example in this code: catch error(foo), Stk = erlang:get_stacktrace() or in this code: try Expr catch _:_ -> ok end, Stk = erlang:get_stacktrace()
2017-05-11Prepare releaseErlang/OTP