BIO Series 8 in openssl --- read/write error control, openssl8 ---
Read/write error control
--- Based on openssl doc/crypto/bio/bio_should_retry.pod translation and your own understanding, write
By DragonKing Mail: wzhah@263.net published on: open http://gdwzh.126.com
Ssl Professional Forum)
When the BIO_read or BIO_wr
pointer to the structure of a file type BIO_METHOD. Its function implementation is as follows:
BIO_METHOD * BIO_s_file (void)
{
Return ( methods_filep );
}
In fact, from this structure, we can see the first class of BIO implementation, that is, all BIO actions are based on its BIO _
METHOD (the first parameter) to determine its action and behavior, so as to real
storage space, and maximum length.
Block memory storage data. However, it is worth noting that the memory of the memory Type BIO can be infinitely expanded, that is, no
And how much data you write to it.
Generally, any data written into the memory Type BIO can be read, unless the memory Type BIO is
,
Buffer_puts,
Buffer_gets,
Buffer_ctrl,
Buffer_new,
Buffer_free,
Buffer_callback_ctrl,
};
The structure definition shows that this type of BIO supports all bio I/O functions. Write buffer BIO data
Stored in the buffer and regularly written to the next BIO of the BIO chain.
Feed raw material price rises, labor cost increases, hog raising cost further is pulled high, the breed enters the high cost time, in the industry already is indisputable fact. How to reduce the cost of feeding has become the industry's most concerned topic. Farmers can only improve feed utilization rate and reduce feed waste in case the feed price cannot be left or right. The use of fermented feed is one of the effective methods to improve feed utilization.Hope that red functional
BIO series of openssl 12 --- file descriptor (fd) Type BIO, openssl12 ---
File descriptor (fd) Type BIO
--- Based on openssl doc \ crypto \ bio_s_fd.pod translation and your own understanding, write
(Author: DragonKing Mailwzhah@263.net released in: httpgdwzh.126.com openssl proprietary)
Industry Forum)
The file descriptor Type
as follows:
Static BIO_METHOD methods_sockp =
{
BIO_TYPE_SOCKET,
"Socket ",
Sock_write,
Sock_read,
Sock_puts,
NULL,/* sock_gets ,*/
Sock_ctrl,
Sock_new,
Sock_free,
NULL,
};
As you can see, it is basically the same as that of fd Type BIO. Only the prefix name and type
The field names are different. In fact, in a system like Linux, the Socket type is the same as the fd type. They are
But why do we need to implement it separately? Some systems, such as
14 of BIO series of openssl --- source type null bio, openssl14 ---
--- Based on openssl doc \ crypto \ bio_s_null.pod translation and your own understanding, write
(Author: DragonKing, Mail: wzhah@263.net, published in: httpgdwzh.126.com openssl Professional Forum)
This is an empty source/sink Type BIO. The data written to this
*ctx);
BIO *bio_new_buffer_ssl_connect (Ssl_ctx *ctx);
int bio_ssl_copy_session_id (BIO *to,bio *from);
void Bio_ssl_shutdown (BIO *bio);
#define Bio_do_handshake (b) Bio_ctrl (B,bio_c_do_state_machine,0,null)
The implementation file for this type of
BIO Series 21 of openssl --- Base64 BIO, openssl21 --- base64
Base64 Type BIO
--- Based on openssl doc \ crypto \ bio_f_base64.pod translation and your own understanding, write
(Author: DragonKing, Mail: wzhah@263.net, published on: http://gdwzh.126.com o
Penssl Professional Forum)
This type is filter Type BIO, which i
Original Address: BIO and block device driverdevices in the system that have random access to fixed-size data slices (chunk) are called block devices, which are called blocks. Block device files are used in a way that installs the file system, which is also a common way for block devices to access them. Block devices are accessed randomly, which means they can jump from one location to another at random when accessing a device. The access location of
structure as needed. The bio structure contains all the information about the request executed by the driver, instead of being associated with the process that initializes the user space of the request.The basic container for block I/O operations in the kernel is represented by the bio struct, which is defined in Bio is the main data structure of the General lay
Tags: CGI notification java prefix requires EFI log home asynchronous IOI. BIO, NIO, AIOLearn Four Concepts first:Sync: Personally take the bank card to the bank to withdraw money (when using sync io, Java handles IO read and write itself).Asynchronous: Entrust a little brother to take the bank card to the bank to withdraw money, and then give you (using asynchronous IO, Java will
/write operation is completed.
Bio is a connection to a thread.
NIO is a request for a thread.
AIO is a valid request for a thread.
Let's start with an example to understand the concept of bank withdrawals as an example: Sync: Personally take the bank card to the bank to withdraw money (when using synchronous io, Java handles IO read and write itself); asynchronous: Entrust a little brother to take a bank c
channels, mainly under the Java.nio.channels package: Asynchronoussocketchannel Asynchronousserversocketchannel Asynchronousfilechannel Asynchronousdatagramchannel
The Read/write method, which returns an object with a callback function, calls the callback function directly when the read/write operation is completed. Bio is a connection to a thread. NIO is a requ
Sync_request is not necessarily the case. You can call other functions.
Submit_bio
// Bio and bio_vec are local variables.
Static intSync_request(Struct page * page, struct block_device * bdev, int rw){Struct bio;Struct bio_vec;Struct completion complete;
Bio_init ( bio );Bio. bi_io_vec = bio_vec;Bio_vec.bv_page = pa
characteristics. In the following, NiO does not refer to the entire new I/O library, but non-blocking I/O.NIO provides two different socket channel implementations for Socketchannel and Serversocketchannel that correspond to sockets and serversocket in the traditional bio model.The new two channels support both blocking and non-blocking modes.Blocking mode use is as simple as traditional support, but not performance and reliability, and non-blocking
Original address: Mina User Guide Getting Started1.1.1. NiO Review 1.1.1.1. NiO Review The NIO API was introduced in Java 1.4 and has been adopted by most application systems. The NIO API contains non-blocking non-blocking application operations. The following key structures are included in the java.nio.* package:
L Buffers-Data container
L chartsets-bytes and Unicode translation containers
L Channels-Represents the IO operational capability of the connection and entity
L S
About Bio | NIO |the discussion of AIO is always there, and sometimes it's easy to confuse, as I understand it, to give an explanation: BIO| NIO |AIO, the description of itself is based on the Java language. While describing IO, we need to start from two levels: the programming language implements the underlying fundamentals from the programming language level bio
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.