Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(749)

Delta Between Two Patch Sets: openpgp/packet/one_pass_signature.go

Issue 5564059: code review 5564059: go.crypto: initial code (Closed)
Left Patch Set: diff -r b50a7fb49394 https://code.google.com/p/go.crypto Created 12 years, 2 months ago
Right Patch Set: diff -r b50a7fb49394 https://code.google.com/p/go.crypto Created 12 years, 2 months ago
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
Left: Side by side diff | Download
Right: Side by side diff | Download
« no previous file with change/comment | « openpgp/packet/literal.go ('k') | openpgp/packet/packet.go » ('j') | no next file with change/comment »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
LEFTRIGHT
1 // Copyright 2011 The Go Authors. All rights reserved. 1 // Copyright 2011 The Go Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style 2 // Use of this source code is governed by a BSD-style
3 // license that can be found in the LICENSE file. 3 // license that can be found in the LICENSE file.
4 4
5 package packet 5 package packet
6 6
7 import ( 7 import (
8 "code.google.com/p/go.crypto/openpgp/errors"
9 "code.google.com/p/go.crypto/openpgp/s2k"
8 "crypto" 10 "crypto"
9 "crypto/openpgp/errors"
10 "crypto/openpgp/s2k"
11 "encoding/binary" 11 "encoding/binary"
12 "io" 12 "io"
13 "strconv" 13 "strconv"
14 ) 14 )
15 15
16 // OnePassSignature represents a one-pass signature packet. See RFC 4880, 16 // OnePassSignature represents a one-pass signature packet. See RFC 4880,
17 // section 5.4. 17 // section 5.4.
18 type OnePassSignature struct { 18 type OnePassSignature struct {
19 SigType SignatureType 19 SigType SignatureType
20 Hash crypto.Hash 20 Hash crypto.Hash
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
64 if ops.IsLast { 64 if ops.IsLast {
65 buf[12] = 1 65 buf[12] = 1
66 } 66 }
67 67
68 if err := serializeHeader(w, packetTypeOnePassSignature, len(buf)); err != nil { 68 if err := serializeHeader(w, packetTypeOnePassSignature, len(buf)); err != nil {
69 return err 69 return err
70 } 70 }
71 _, err := w.Write(buf[:]) 71 _, err := w.Write(buf[:])
72 return err 72 return err
73 } 73 }
LEFTRIGHT

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b