Documentation

Swift_Signers_HeaderSigner extends Swift_Signer, Swift_InputByteStream

Header Signer Interface used to apply Header-Based Signature to a message.

Tags
author

Xavier De Cock xdecock@gmail.com

Table of Contents

addSignature()  : self
Add the header(s) to the headerSet.
bind()  : mixed
Attach $is to this stream.
commit()  : mixed
For any bytes that are currently buffered inside the stream, force them off the buffer.
endBody()  : self
Give the signal that the body has finished streaming.
flushBuffers()  : mixed
Flush the contents of the stream (empty it) and set the internal pointer to the beginning.
getAlteredHeaders()  : array<string|int, mixed>
Return the list of header a signer might tamper.
ignoreHeader()  : self
Exclude an header from the signed headers.
reset()  : mixed
setHeaders()  : self
Give the headers already given.
startBody()  : self
Prepare the Signer to get a new Body.
unbind()  : mixed
Remove an already bound stream.
write()  : int
Writes $bytes to the end of the stream.

Methods

commit()

For any bytes that are currently buffered inside the stream, force them off the buffer.

public commit() : mixed
Tags
throws
Swift_IoException
Return values
mixed

endBody()

Give the signal that the body has finished streaming.

public endBody() : self
Return values
self

flushBuffers()

Flush the contents of the stream (empty it) and set the internal pointer to the beginning.

public flushBuffers() : mixed
Tags
throws
Swift_IoException
Return values
mixed

getAlteredHeaders()

Return the list of header a signer might tamper.

public getAlteredHeaders() : array<string|int, mixed>
Return values
array<string|int, mixed>

ignoreHeader()

Exclude an header from the signed headers.

public ignoreHeader(string $header_name) : self
Parameters
$header_name : string
Return values
self

reset()

public reset() : mixed
Return values
mixed

startBody()

Prepare the Signer to get a new Body.

public startBody() : self
Return values
self

unbind()

Remove an already bound stream.

public unbind(Swift_InputByteStream $is) : mixed

If $is is not bound, no errors will be raised. If the stream currently has any buffered data it will be written to $is before unbinding occurs.

Parameters
$is : Swift_InputByteStream
Return values
mixed

write()

Writes $bytes to the end of the stream.

public write(string $bytes) : int

Writing may not happen immediately if the stream chooses to buffer. If you want to write these bytes with immediate effect, call after calling write().

This method returns the sequence ID of the write (i.e. 1 for first, 2 for second, etc etc).

Parameters
$bytes : string
Tags
throws
Swift_IoException
Return values
int

Search results