Merge pull request #304 from guggero/user-agent-string

Send user agent string with each swap
pull/305/head
Oliver Gugger 4 years ago committed by GitHub
commit 649976fa48
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -174,7 +174,15 @@ type ServerLoopOutRequest struct {
// The requested absolute block height of the on-chain htlc. This is
// subjected to min and max constraints as reported in the LoopOutTerms
// response.
Expiry int32 `protobuf:"varint,6,opt,name=expiry,proto3" json:"expiry,omitempty"`
Expiry int32 `protobuf:"varint,6,opt,name=expiry,proto3" json:"expiry,omitempty"`
// The user agent string that identifies the software running on the user's
// side. This can be changed in the user's client software but it _SHOULD_
// conform to the following pattern:
// Agent-Name/semver-version(/additional-info)
// Examples:
// loopd/v0.10.0-beta/commit=3b635821
// litd/v0.2.0-alpha/commit=326d754
UserAgent string `protobuf:"bytes,7,opt,name=user_agent,json=userAgent,proto3" json:"user_agent,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
@ -247,6 +255,13 @@ func (m *ServerLoopOutRequest) GetExpiry() int32 {
return 0
}
func (m *ServerLoopOutRequest) GetUserAgent() string {
if m != nil {
return m.UserAgent
}
return ""
}
type ServerLoopOutResponse struct {
SwapInvoice string `protobuf:"bytes,1,opt,name=swap_invoice,json=swapInvoice,proto3" json:"swap_invoice,omitempty"`
PrepayInvoice string `protobuf:"bytes,2,opt,name=prepay_invoice,json=prepayInvoice,proto3" json:"prepay_invoice,omitempty"`
@ -598,11 +613,19 @@ type ServerLoopInRequest struct {
SwapInvoice string `protobuf:"bytes,4,opt,name=swap_invoice,json=swapInvoice,proto3" json:"swap_invoice,omitempty"`
LastHop []byte `protobuf:"bytes,5,opt,name=last_hop,json=lastHop,proto3" json:"last_hop,omitempty"`
/// The protocol version that the client adheres to.
ProtocolVersion ProtocolVersion `protobuf:"varint,6,opt,name=protocol_version,json=protocolVersion,proto3,enum=looprpc.ProtocolVersion" json:"protocol_version,omitempty"`
ProbeInvoice string `protobuf:"bytes,7,opt,name=probe_invoice,json=probeInvoice,proto3" json:"probe_invoice,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
ProtocolVersion ProtocolVersion `protobuf:"varint,6,opt,name=protocol_version,json=protocolVersion,proto3,enum=looprpc.ProtocolVersion" json:"protocol_version,omitempty"`
ProbeInvoice string `protobuf:"bytes,7,opt,name=probe_invoice,json=probeInvoice,proto3" json:"probe_invoice,omitempty"`
// The user agent string that identifies the software running on the user's
// side. This can be changed in the user's client software but it _SHOULD_
// conform to the following pattern:
// Agent-Name/semver-version(/additional-info)
// Examples:
// loopd/v0.10.0-beta/commit=3b635821
// litd/v0.2.0-alpha/commit=326d754
UserAgent string `protobuf:"bytes,8,opt,name=user_agent,json=userAgent,proto3" json:"user_agent,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *ServerLoopInRequest) Reset() { *m = ServerLoopInRequest{} }
@ -679,6 +702,13 @@ func (m *ServerLoopInRequest) GetProbeInvoice() string {
return ""
}
func (m *ServerLoopInRequest) GetUserAgent() string {
if m != nil {
return m.UserAgent
}
return ""
}
type ServerLoopInResponse struct {
ReceiverKey []byte `protobuf:"bytes,1,opt,name=receiver_key,json=receiverKey,proto3" json:"receiver_key,omitempty"`
Expiry int32 `protobuf:"varint,2,opt,name=expiry,proto3" json:"expiry,omitempty"`
@ -1202,89 +1232,91 @@ func init() {
func init() { proto.RegisterFile("server.proto", fileDescriptor_ad098daeda4239f7) }
var fileDescriptor_ad098daeda4239f7 = []byte{
// 1309 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x56, 0xcd, 0x52, 0xdb, 0xd6,
0x17, 0xff, 0x4b, 0xfe, 0xc2, 0xc7, 0x36, 0x88,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e6, 0xc7, 0xb3, 0x85, 0xbc, 0xde, 0x5c, 0x46,
0x64, 0xab, 0xed, 0x73, 0x09, 0x51, 0xd8, 0xcc, 0x16, 0xc7, 0x4f, 0xc8, 0xf3, 0x65, 0x76, 0x9e,
0x25, 0x7d, 0x7d, 0x2e, 0x1d, 0x17, 0xf9, 0x3b, 0xf1, 0xf5, 0xbf, 0x01, 0x00, 0x00, 0xff, 0xff,
0xbd, 0x37, 0x63, 0xb1, 0xfe, 0x0f, 0x00, 0x00,
}
// Reference imports to suppress errors if they are not otherwise used.

@ -83,6 +83,15 @@ message ServerLoopOutRequest {
// subjected to min and max constraints as reported in the LoopOutTerms
// response.
int32 expiry = 6;
// The user agent string that identifies the software running on the user's
// side. This can be changed in the user's client software but it _SHOULD_
// conform to the following pattern:
// Agent-Name/semver-version(/additional-info)
// Examples:
// loopd/v0.10.0-beta/commit=3b635821
// litd/v0.2.0-alpha/commit=326d754
string user_agent = 7;
}
message ServerLoopOutResponse {
@ -163,6 +172,15 @@ message ServerLoopInRequest {
ProtocolVersion protocol_version = 6;
string probe_invoice = 7;
// The user agent string that identifies the software running on the user's
// side. This can be changed in the user's client software but it _SHOULD_
// conform to the following pattern:
// Agent-Name/semver-version(/additional-info)
// Examples:
// loopd/v0.10.0-beta/commit=3b635821
// litd/v0.2.0-alpha/commit=326d754
string user_agent = 8;
}
message ServerLoopInResponse {

@ -17,6 +17,8 @@ This file tracks release notes for the loop client.
to replenish multiple channels via a single Loop In request and a single on-chain htlc.
This has to potential to greatly reduce chain fee costs. Note that it is not yet possible
to select specific peers to loop in through.
* The daemon now sends a user agent string with each swap. This allows
developers to identify their fork or custom implementation of the loop client.
##### Updated Swap Suggestions
* The swap suggestions endpoint has been updated to be fee-aware. Swaps that

@ -233,6 +233,7 @@ func (s *grpcSwapServerClient) NewLoopOutSwap(ctx context.Context,
SwapPublicationDeadline: swapPublicationDeadline.Unix(),
ProtocolVersion: loopdb.CurrentRPCProtocolVersion,
Expiry: expiry,
UserAgent: UserAgent(),
},
)
if err != nil {
@ -287,6 +288,7 @@ func (s *grpcSwapServerClient) NewLoopInSwap(ctx context.Context,
SwapInvoice: swapInvoice,
ProtocolVersion: loopdb.CurrentRPCProtocolVersion,
ProbeInvoice: probeInvoice,
UserAgent: UserAgent(),
}
if lastHop != nil {
req.LastHop = lastHop[:]

@ -29,11 +29,37 @@ const (
// appPreRelease MUST only contain characters from semanticAlphabet per
// the semantic versioning spec.
appPreRelease = "beta"
// defaultAgentName is the default name of the software that is added as
// the first part of the user agent string.
defaultAgentName = "loopd"
)
// AgentName stores the name of the software that is added as the first part of
// the user agent string. This defaults to the value "loopd" when being run as
// a standalone component but can be overwritten by LiT for example when loopd
// is integrated into the UI.
var AgentName = defaultAgentName
// Version returns the application version as a properly formed string per the
// semantic versioning 2.0.0 spec (http://semver.org/).
// semantic versioning 2.0.0 spec (http://semver.org/) and the commit it was
// built on.
func Version() string {
// Append commit hash of current build to version.
return fmt.Sprintf("%s commit=%s", semanticVersion(), Commit)
}
// UserAgent returns the full user agent string that identifies the software
// that is submitting swaps to the loop server.
func UserAgent() string {
// Assemble full string, including the commit hash of current build.
return fmt.Sprintf(
"%s/v%s/commit=%s", AgentName, semanticVersion(), Commit,
)
}
// semanticVersion returns the SemVer part of the version.
func semanticVersion() string {
// Start with the major, minor, and patch versions.
version := fmt.Sprintf("%d.%d.%d", appMajor, appMinor, appPatch)
@ -46,9 +72,6 @@ func Version() string {
version = fmt.Sprintf("%s-%s", version, preRelease)
}
// Append commit hash of current build to version.
version = fmt.Sprintf("%s commit=%s", version, Commit)
return version
}

Loading…
Cancel
Save