MCPcopy Create free account

hub / github.com/dcrodman/archon / functions

Functions570 in github.com/dcrodman/archon

↓ 98 callersMethodwriteError
writeError writes an HTTP response with a valid Twirp error format, and triggers hooks. If err is not a twirp.Error, it will get wrapped with twirp.In
internal/shipgate/shipgate.twirp.go:1048
↓ 42 callersMethodError
()
internal/shipgate/shipgate.twirp.go:3083
↓ 41 callersMethodSend
Send converts a packet struct to bytes and encrypts it before using the server's session key before sending the data to the client.
internal/core/client/client.go:126
↓ 36 callersFunctionwrapInternal
wrapInternal wraps an error with a prefix as an Internal error. The original error cause is accessible by github.com/pkg/errors.Cause.
internal/shipgate/shipgate.twirp.go:3074
↓ 27 callersMethodhandleRequestBodyError
handleRequestBodyError is used to handle error when the twirp server cannot read request
internal/shipgate/shipgate.twirp.go:1053
↓ 25 callersFunctionStructFromBytes
StructFromBytes populates the struct pointed to by targetStruct by reading in a stream of bytes and filling the values in sequential order.
internal/core/bytes/util.go:76
↓ 24 callersMethodWrite
Write directly sends data to the client over its TCP connection.
internal/core/client/client.go:82
↓ 19 callersFunctioncallError
Call twirp.ServerHooks.Error if the hook is available
internal/shipgate/shipgate.twirp.go:3307
↓ 19 callersFunctioncallResponseSent
Call twirp.ServerHooks.ResponseSent if the hook is available
internal/shipgate/shipgate.twirp.go:3299
↓ 18 callersFunctioncallClientError
(ctx context.Context, h *twirp.ClientHooks, err twirp.Error)
internal/shipgate/shipgate.twirp.go:3328
↓ 18 callersFunctioncallClientResponseReceived
(ctx context.Context, h *twirp.ClientHooks)
internal/shipgate/shipgate.twirp.go:3314
↓ 18 callersFunctioncallRequestRouted
Call twirp.ServerHooks.RequestRouted if the hook is available
internal/shipgate/shipgate.twirp.go:3283
↓ 18 callersFunctioncallResponsePrepared
Call twirp.ServerHooks.ResponsePrepared if the hook is available
internal/shipgate/shipgate.twirp.go:3291
↓ 18 callersFunctionensurePanicResponses
for github.com/pkg/errors ensurePanicResponses makes sure that rpc methods causing a panic still result in a Twirp Internal error response (status 500
internal/shipgate/shipgate.twirp.go:3090
↓ 16 callersMethodIPAddr
()
internal/core/client/client.go:73
↓ 13 callersFunctionbadRouteError
badRouteError is used when the twirp server cannot route a request
internal/shipgate/shipgate.twirp.go:3139
↓ 12 callersMethodString
()
internal/core/proto/archon.pb.go:44
↓ 11 callersFunctionfile_internal_shipgate_shipgate_proto_rawDescGZIP
()
internal/shipgate/shipgate.pb.go:739
↓ 11 callersFunctiongenerateAccount
(t *testing.T)
internal/core/data/account_test.go:22
↓ 10 callersMethodDecrypt
Decrypt decrypts bytes in place with the encryption key for the client.
internal/core/client/crypto.go:19
↓ 10 callersMethodRead
Read consumes the available bytes directly the client's TCP connection.
internal/core/client/client.go:77
↓ 10 callersFunctionmalformedRequestError
malformedRequestError is used when the twirp server cannot unmarshal a request
internal/shipgate/shipgate.twirp.go:3134
↓ 10 callersFunctionsetUpDatabase
Creates a database for testing. For the sake of simplicity, this only uses the SQLite engine and creates a new database on every invocation since it i
internal/core/data/data_test.go:15
↓ 9 callersFunctionConvertToUtf16
ConvertToUtf16 converts a UTF-8 string to UTF-16 LE and return it as an array of bytes.
internal/core/bytes/util.go:11
↓ 9 callersFunctionStripPadding
StripPadding returns a slice of b without the trailing 0s.
internal/core/bytes/util.go:27
↓ 9 callersFunctiondoJSONRequest
doJSONRequest makes a JSON request to the remote Twirp service.
internal/shipgate/shipgate.twirp.go:3219
↓ 9 callersFunctiondoProtobufRequest
doProtobufRequest makes a Protobuf request to the remote Twirp service.
internal/shipgate/shipgate.twirp.go:3170
↓ 8 callersMethodClose
Close the TCP connection.
internal/core/client/client.go:87
↓ 8 callersMethodIdentifier
Name returns a uniquely identifying string.
internal/backend.go:13
↓ 7 callersFunctionBytesFromStruct
BytesFromStruct serializes the fields of a struct to an array of bytes in the order in which the fields are declared and returns total number of bytes
internal/core/bytes/util.go:39
↓ 7 callersMethodDo
(req *http.Request)
internal/shipgate/shipgate.twirp.go:2786
↓ 7 callersMethodSendRaw
SendRaw writes all data contained in the slice to the client as-is (e.g. without encrypting it first).
internal/core/client/client.go:93
↓ 7 callersMethodWithMeta
(key string, val string)
internal/shipgate/shipgate.twirp.go:3131
↓ 6 callersMethodAuthenticateAccount
AuthenticateAccount verifies an account. A password should be provided via the rpc call metadata.
internal/shipgate/shipgate.twirp.go:50
↓ 6 callersMethodClientVector
ClientVector returns the key used to initialize the client's's block cipher.
internal/core/client/crypto.go:25
↓ 6 callersMethodEncrypt
Encrypt encrypts bytes in place with the encryption key for the server.
internal/core/client/crypto.go:16
↓ 6 callersMethodServerVector
ServerVector returns the key used to initialize the server's block cipher.
internal/core/client/crypto.go:22
↓ 6 callersMethodbuildAddress
(port int)
internal/controller.go:148
↓ 6 callersFunctiontoLittleEndian
Condense four bytes into a LE 32-bit value.
internal/core/encryption/encryption.go:94
↓ 5 callersFunctionDecompress
(src []byte, size int)
internal/core/prs/prs.go:3
↓ 5 callersFunctionDecompressSize
(src []byte)
internal/core/prs/prs.go:8
↓ 5 callersFunctionFindCharacter
FindCharacter returns the Character associated with the account in the given slot or nil if none exists.
internal/core/data/character.go:62
↓ 5 callersMethodFindCharacter
FindCharacter looks up character in a slot on an account.
internal/shipgate/shipgate.twirp.go:53
↓ 5 callersFunctionNewBlueBurstCryptoSession
NewBlueBurstCryptoSession returns a CryptoSession with newly initialized ciphers that can be used to communicate with a PSO Blue Burst client.
internal/core/client/crypto.go:35
↓ 5 callersFunctionexit
(format string, args ...interface{})
cmd/sniffer/main.go:45
↓ 5 callersFunctionfile_internal_core_proto_archon_proto_rawDescGZIP
()
internal/core/proto/archon.pb.go:857
↓ 5 callersMethodgetNextByte
()
internal/core/prs/decompress.go:95
↓ 4 callersMethodBroadcastIP
BroadcastIP converts the configured broadcast IP string into 4 bytes to be used with the redirect packet common to several servers.
internal/core/config.go:150
↓ 4 callersFunctionCreateAccount
CreateAccount persists the Account record to the database.
internal/core/data/account.go:77
↓ 4 callersMethodGetActiveShips
GetActiveShips returns the list of Ships that currently connected to the shipgate and ready to receive players.
internal/shipgate/shipgate.twirp.go:43
↓ 4 callersFunctionNewClient
(connection *net.TCPConn)
internal/core/client/client.go:62
↓ 4 callersFunctionNewClient
NewClient returns an RPC client for the shipgate, connected to the address defined in the config file. Since Archon does not (yet) support running in
internal/shipgate/service.go:42
↓ 4 callersMethodUpsertCharacter
UpsertCharacter creates a new character in a slot on an account.
internal/shipgate/shipgate.twirp.go:56
↓ 4 callersFunctionassertAccountsMatch
(t *testing.T, expected *Account, got *Account)
internal/core/data/account_test.go:31
↓ 4 callersFunctionclientFlagCacheKey
(c *client.Client)
internal/character/character_server.go:573
↓ 4 callersFunctionencryptSBlock
Mostly the same as standard Blowfish, but with some customization at the end.
internal/core/encryption/bb_block.go:107
↓ 4 callersMethodgetNextBit
getNextBit gets the next bit from the controlByte. If the controlByte has been exhausted (eg the bitPos is -1), then getNextBit will get the next cont
internal/core/prs/decompress.go:83
↓ 4 callersFunctionpopArg
(args []string, prompt string)
cmd/archon/account.go:152
↓ 3 callersFunctionCreatePlayerOptions
(db *gorm.DB, po *PlayerOptions)
internal/core/data/player_options.go:33
↓ 3 callersMethodDatabaseURL
DatabaseURL returns a database URL generated from the provided config values.
internal/core/config.go:128
↓ 3 callersMethodDeleteCharacter
DeleteCharacter deletes the character data in a slot on an account.
internal/shipgate/shipgate.twirp.go:59
↓ 3 callersFunctionFindAccountByUsername
FindAccountByUsername searches for an account with the specified username, returning the *Account instance if found or nil if there is no match.
internal/core/data/account.go:45
↓ 3 callersFunctionFindPlayerOptions
FindPlayerOptions returns all of hte PlayerOptions associated with an Account.
internal/core/data/player_options.go:19
↓ 3 callersFunctionFindUnscopedAccount
FindUnscopedAccount searches for a potentially soft-deleted account with the specified username, returning the *Account instance if found or nil if th
internal/core/data/account.go:62
↓ 3 callersMethodGetGuildcardEntries
GetGuildcardEntires returns the list of guildcards on an account.
internal/shipgate/shipgate.twirp.go:62
↓ 3 callersMethodGetPlayerOptions
GetPlayerOptions returns the player options tied to an account.
internal/shipgate/shipgate.twirp.go:65
↓ 3 callersFunctionNewBBCryptWithVector
(vector []uint8)
internal/core/encryption/encryption.go:49
↓ 3 callersFunctionNewPCCryptWithVector
(vector []uint8)
internal/core/encryption/encryption.go:32
↓ 3 callersFunctionPrintPacket
PrintCommand prints the contents of a command to a specified writer along with some inferred metadata about the command itself.
internal/core/debug/debug.go:66
↓ 3 callersMethodQualifiedPath
QualifiedPath returns the fully qualified path of files relative to c.BaseDir.
internal/core/config.go:164
↓ 3 callersMethodRegisterShip
RegisterShip informs the shipgate that it is able to serve players.
internal/shipgate/shipgate.twirp.go:46
↓ 3 callersMethodString
()
internal/shipgate/shipgate.pb.go:42
↓ 3 callersMethodUpsertPlayerOptions
GetPlayerOptions updates or creates the player options tied to an account.
internal/shipgate/shipgate.twirp.go:68
↓ 3 callersFunctionbaseServicePath
baseServicePath composes the path prefix for the service (without <Method>). e.g.: baseServicePath("/twirp", "my.pkg", "MyService") returns => "/twirp
internal/shipgate/shipgate.twirp.go:2899
↓ 3 callersFunctioncreateKey
Generate a cryptographically secure random string of bytes.
internal/core/encryption/encryption.go:81
↓ 3 callersFunctionfindAccount
(db *gorm.DB, username string)
cmd/archon/account.go:165
↓ 3 callersFunctionisHTTPRedirect
(status int)
internal/shipgate/shipgate.twirp.go:3068
↓ 3 callersFunctionnewPCCipher
(key []byte)
internal/core/encryption/pc.go:21
↓ 3 callersFunctionnewTestConnection
(t *testing.T, addr *net.TCPAddr)
internal/core/client/client_test.go:32
↓ 3 callersFunctionnewTestListener
(t *testing.T)
internal/core/client/client_test.go:24
↓ 3 callersMethodsendCharacterAck
Send the character acknowledgement command in response to the action taken. Setting flag to 0 indicates a creation ack, 1 acks a selected character, a
internal/character/character_server.go:419
↓ 3 callersMethodsendSecurity
(c *client.Client, errorCode uint32)
internal/ship/auth_server.go:124
↓ 3 callersMethodsendSecurity
(c *client.Client, errorCode uint32)
internal/ship/game_server.go:115
↓ 3 callersMethodsendSecurity
send the security initialization command with information about the user's authentication status.
internal/character/auth_server.go:125
↓ 3 callersMethodsendSecurity
send the security initialization command with information about the user's authentication status.
internal/character/character_server.go:203
↓ 3 callersFunctionwriteError
writeError writes Twirp errors in the response and triggers hooks.
internal/shipgate/shipgate.twirp.go:2842
↓ 2 callersMethodCode
()
internal/shipgate/shipgate.twirp.go:3127
↓ 2 callersFunctionDeleteAccount
DeleteAccount soft-deletes an Account record from the database.
internal/core/data/account.go:82
↓ 2 callersFunctionDeleteCharacter
DeleteCharacter soft-deletes a character record from the database.
internal/core/data/character.go:89
↓ 2 callersFunctionFindGuildcardEntries
FindGuildcardEntries returns all the GuildcardEntry rows associated with an Account.
internal/core/data/guildcard_entry.go:27
↓ 2 callersFunctionHashPassword
HashPassword returns a version of password with Archon's chosen hashing strategy.
internal/shipgate/service.go:177
↓ 2 callersMethodHeaderSize
HeaderSize returns the length of the header of all client commands.
internal/core/client/crypto.go:13
↓ 2 callersFunctionLoadConfig
LoadConfig initializes Viper with the contents of the config file under configPath.
internal/core/config.go:84
↓ 2 callersFunctionNewBBCrypt
Returns a newly allocated PSOCrypt with randomly generated, appropriately sized keys for encrypting packets over PSOBB connections.
internal/core/encryption/encryption.go:45
↓ 2 callersFunctionNewPCCryptoSession
NewPCCryptoSession returns a CryptoSession with newly initialized ciphers that can be used to communicate with either a PSO PC client or the patch pro
internal/core/client/crypto.go:70
↓ 2 callersFunctionPermanentlyDeleteAccount
PermanentlyDeleteAccount permanently deletes an Account record from the database.
internal/core/data/account.go:87
↓ 2 callersMethodShipgateAddress
ShipgateAddress returns the fully qualified address of the ship server. TODO: Since the current expectation is that the ship server is running alongsi
internal/core/config.go:144
↓ 2 callersMethodShutdown
(ctx context.Context)
internal/controller.go:152
↓ 2 callersMethodStart
(ctx context.Context)
internal/controller.go:32
↓ 2 callersFunctionUpsertCharacter
UpsertCharacter updates an existing Character row with the contents of character.
internal/core/data/character.go:81
next →1–100 of 570, ranked by callers