Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/dcrodman/archon
/ functions
Functions
570 in github.com/dcrodman/archon
⨍
Functions
570
◇
Types & classes
113
↓ 2 callers
Function
adjustPacketLength
adjustPacketLength pads the length of a packet to a multiple of the header length and adjusts first two bytes of the header to the corrected size (may
internal/core/client/client.go:148
↓ 2 callers
Method
blockSize
()
internal/core/encryption/encryption.go:17
↓ 2 callers
Function
buildCommandLine
Build one line of formatted command data.
internal/core/debug/debug.go:141
↓ 2 callers
Function
callClientRequestPrepared
(ctx context.Context, h *twirp.ClientHooks, req *http.Request)
internal/shipgate/shipgate.twirp.go:3321
↓ 2 callers
Function
convertReadableName
(name []uint8)
internal/character/character_server.go:654
↓ 2 callers
Method
copyFromOffset
(offset int)
internal/core/prs/decompress.go:109
↓ 2 callers
Method
decompress
decompress expands a PRS compressed file
internal/core/prs/decompress.go:38
↓ 2 callers
Function
errorFromResponse
errorFromResponse builds a twirp.Error from a non-200 HTTP response. If the response has a valid serialized Twirp error, then it's returned. If not, t
internal/shipgate/shipgate.twirp.go:2991
↓ 2 callers
Function
initDB
()
cmd/archon/account.go:41
↓ 2 callers
Method
mixKeys
()
internal/core/encryption/pc.go:60
↓ 2 callers
Function
newDecompressor
newDecompressor is a type built to support decompressing a PRS file. The controlByte starts at the first byte, and bitPos starts at 7, indicating we c
internal/core/prs/decompress.go:26
↓ 2 callers
Function
newRequest
newRequest makes an http.Request from a client, adding common headers.
internal/shipgate/shipgate.twirp.go:2942
↓ 2 callers
Method
process
Perform the actual encryption/decryption. The operation is symmetrical, so the same algorithm can be applied for both.
internal/core/encryption/pc.go:100
↓ 2 callers
Method
readDataFromClient
(c *client.Client, n int, buffer []byte)
internal/frontend.go:228
↓ 2 callers
Function
sanitizeBaseURL
sanitizeBaseURL parses the the baseURL, and adds the "http" scheme if needed. If the URL is unparsable, the baseURL is returned unchaged.
internal/shipgate/shipgate.twirp.go:2883
↓ 2 callers
Function
seedRandomAccounts
(t *testing.T, db *gorm.DB)
internal/core/data/account_test.go:13
↓ 2 callers
Method
sendChangeDir
Tell the client to change to some directory within its file tree.
internal/patch/data_server.go:128
↓ 2 callers
Method
sendDirAbove
Tell the client to change to one directory above.
internal/patch/data_server.go:150
↓ 2 callers
Method
transmit
transmit writes the contents of data to the TCP connection until the number of bytes written >= length.
internal/core/client/client.go:110
↓ 2 callers
Function
twirpErrorFromIntermediary
twirpErrorFromIntermediary maps HTTP errors from non-twirp sources to twirp errors. The mapping is similar to gRPC: https://github.com/grpc/grpc/blob/
internal/shipgate/shipgate.twirp.go:3034
↓ 2 callers
Function
withoutRedirects
withoutRedirects makes sure that the POST request can not be redirected. The standard library will, by default, redirect requests (including POSTs) if
internal/shipgate/shipgate.twirp.go:3155
↓ 1 callers
Method
Decrypt
Decrypt a block of data in place.
internal/core/encryption/encryption.go:71
↓ 1 callers
Method
Encrypt
Encrypt a block of data in place.
internal/core/encryption/encryption.go:61
↓ 1 callers
Function
FindAccountByID
(db *gorm.DB, id uint)
internal/core/data/account.go:29
↓ 1 callers
Method
Handle
Handle is the main entry point for processing client commands. It's responsible for generally handling all commands from a client as well as sending a
internal/backend.go:30
↓ 1 callers
Method
Handshake
Handshake performs any connection initialization necessary to begin communicating with the client. This likely involves sending a "welcome" command.
internal/backend.go:26
↓ 1 callers
Method
Init
Init is called before a Backend is started as a hook for the Backend to perform any necessary initialization before it can accept clients.
internal/backend.go:17
↓ 1 callers
Method
MetaMap
()
internal/shipgate/shipgate.twirp.go:3130
↓ 1 callers
Method
Msg
()
internal/shipgate/shipgate.twirp.go:3128
↓ 1 callers
Function
NewLogger
NewLogger returns a logger intended to be used for general application logs.
internal/core/logging.go:11
↓ 1 callers
Function
NewPCCrypt
Returns a newly allocated PSOCrypt with randomly generated, appropriately sized keys for encrypting packets over PSOPC connections.
internal/core/encryption/encryption.go:28
↓ 1 callers
Function
NewShipgateProtobufClient
NewShipgateProtobufClient creates a Protobuf client that implements the Shipgate interface. It communicates using Protobuf and can be configured with
internal/shipgate/shipgate.twirp.go:84
↓ 1 callers
Function
NewShipgateServer
NewShipgateServer builds a TwirpServer that can be used as an http.Handler to handle HTTP requests that are routed to the right method in the provided
internal/shipgate/shipgate.twirp.go:1023
↓ 1 callers
Function
PermanentlyDeleteCharacter
PermanentlyDeleteCharacter permanently deletes a character record from the database.
internal/core/data/character.go:100
↓ 1 callers
Method
SetUpClient
SetUpClient performs any initialization on the Client needed to be able to begin the session. Namely, it's the server's responsibility to choose the a
internal/backend.go:22
↓ 1 callers
Function
Shutdown
Shutdown gracefully closes all connections to the shipgate, shuts the server down, and closes any external connections.
internal/shipgate/service.go:115
↓ 1 callers
Function
Start
Start starts the shipgate at the address defined in the config file.
internal/shipgate/service.go:47
↓ 1 callers
Function
StartPprofServer
This function starts the default pprof HTTP server that can be accessed via localhost to get runtime information about archon. See https://golang.org/
internal/core/debug/debug.go:23
↓ 1 callers
Function
UpdatePlayerOptions
(db *gorm.DB, po *PlayerOptions)
internal/core/data/player_options.go:37
↓ 1 callers
Method
acceptClient
acceptClient takes a connection and attempts to initiate a "session" by setting up the Client and sending the welcome command. If it succeeds, the gor
internal/frontend.go:114
↓ 1 callers
Function
buildPatchFileTree
Build the list of patch files present in the patch directory to sync with the client. Files are represented in a tree, directories act as nodes (direc
internal/patch/files.go:107
↓ 1 callers
Function
buildPatchIndex
Assign a unique index to each fileEntry in the tree and use those indices to populate the file lookup table.
internal/patch/files.go:171
↓ 1 callers
Method
callAuthenticateAccount
(ctx context.Context, in *AuthenticateAccountRequest)
internal/shipgate/shipgate.twirp.go:246
↓ 1 callers
Method
callAuthenticateAccount
(ctx context.Context, in *AuthenticateAccountRequest)
internal/shipgate/shipgate.twirp.go:714
↓ 1 callers
Method
callDeleteCharacter
(ctx context.Context, in *CharacterRequest)
internal/shipgate/shipgate.twirp.go:384
↓ 1 callers
Method
callDeleteCharacter
(ctx context.Context, in *CharacterRequest)
internal/shipgate/shipgate.twirp.go:852
↓ 1 callers
Method
callFindCharacter
(ctx context.Context, in *CharacterRequest)
internal/shipgate/shipgate.twirp.go:292
↓ 1 callers
Method
callFindCharacter
(ctx context.Context, in *CharacterRequest)
internal/shipgate/shipgate.twirp.go:760
↓ 1 callers
Method
callGetActiveShips
(ctx context.Context, in *google_protobuf.Empty)
internal/shipgate/shipgate.twirp.go:154
↓ 1 callers
Method
callGetActiveShips
(ctx context.Context, in *google_protobuf.Empty)
internal/shipgate/shipgate.twirp.go:622
↓ 1 callers
Method
callGetGuildcardEntries
(ctx context.Context, in *GetGuildcardEntriesRequest)
internal/shipgate/shipgate.twirp.go:430
↓ 1 callers
Method
callGetGuildcardEntries
(ctx context.Context, in *GetGuildcardEntriesRequest)
internal/shipgate/shipgate.twirp.go:898
↓ 1 callers
Method
callGetPlayerOptions
(ctx context.Context, in *GetPlayerOptionsRequest)
internal/shipgate/shipgate.twirp.go:476
↓ 1 callers
Method
callGetPlayerOptions
(ctx context.Context, in *GetPlayerOptionsRequest)
internal/shipgate/shipgate.twirp.go:944
↓ 1 callers
Method
callRegisterShip
(ctx context.Context, in *RegisterShipRequest)
internal/shipgate/shipgate.twirp.go:200
↓ 1 callers
Method
callRegisterShip
(ctx context.Context, in *RegisterShipRequest)
internal/shipgate/shipgate.twirp.go:668
↓ 1 callers
Function
callRequestReceived
Call twirp.ServerHooks.RequestReceived if the hook is available
internal/shipgate/shipgate.twirp.go:3275
↓ 1 callers
Method
callUpsertCharacter
(ctx context.Context, in *UpsertCharacterRequest)
internal/shipgate/shipgate.twirp.go:338
↓ 1 callers
Method
callUpsertCharacter
(ctx context.Context, in *UpsertCharacterRequest)
internal/shipgate/shipgate.twirp.go:806
↓ 1 callers
Method
callUpsertPlayerOptions
(ctx context.Context, in *UpsertPlayerOptionsRequest)
internal/shipgate/shipgate.twirp.go:522
↓ 1 callers
Method
callUpsertPlayerOptions
(ctx context.Context, in *UpsertPlayerOptionsRequest)
internal/shipgate/shipgate.twirp.go:990
↓ 1 callers
Function
characterFromProto
(character *proto.Character)
internal/shipgate/conversions.go:51
↓ 1 callers
Function
characterToProto
(character *data.Character)
internal/shipgate/conversions.go:8
↓ 1 callers
Method
closeConnectionAndRecover
closeConnectionAndRecover is the failsafe that catches any panics, disconnects the client, and removes them from the list regardless of the state of t
internal/frontend.go:181
↓ 1 callers
Method
copyCurrentByte
()
internal/core/prs/decompress.go:100
↓ 1 callers
Method
createKeys
Initialize the cipher.
internal/core/encryption/pc.go:40
↓ 1 callers
Method
createServers
Set up all of the client-facing servers we'll be running.
internal/controller.go:79
↓ 1 callers
Method
createSocket
createSocket opens a TCP socket to listen for client connections on the Address provided to the frontend.
internal/frontend.go:53
↓ 1 callers
Method
decrypt
(data []byte)
internal/core/encryption/encryption.go:16
↓ 1 callers
Function
decryptData
(l, r uint32, c *blowfishCipher)
internal/core/encryption/bb_block.go:148
↓ 1 callers
Method
determinePacketSize
Extract the packet length from the first two bytes of data.
internal/frontend.go:246
↓ 1 callers
Method
encrypt
(data []byte)
internal/core/encryption/encryption.go:15
↓ 1 callers
Function
encryptData
(l, r uint32, c *blowfishCipher)
internal/core/encryption/bb_block.go:137
↓ 1 callers
Function
encryptPBlock
PSO uses the standard Blowfish rounds for P table scheduling.
internal/core/encryption/bb_block.go:83
↓ 1 callers
Function
errFromPanic
errFromPanic returns the typed error if the recovered panic is an error, otherwise formats as error.
internal/shipgate/shipgate.twirp.go:3109
↓ 1 callers
Function
exitHandler
(cancelFn func(), c chan os.Signal, wg ...*sync.WaitGroup)
cmd/archon/server.go:48
↓ 1 callers
Function
expandKey
(key []byte, c *blowfishCipher)
internal/core/encryption/bb_block.go:20
↓ 1 callers
Method
fetchAndSendCharacter
(ctx context.Context, c *client.Client)
internal/ship/game_server.go:167
↓ 1 callers
Function
file_internal_core_proto_archon_proto_init
()
internal/core/proto/archon.pb.go:881
↓ 1 callers
Function
file_internal_shipgate_shipgate_proto_init
()
internal/shipgate/shipgate.pb.go:799
↓ 1 callers
Function
getCommand
(server ServerType, clientcommand bool, commandType uint16)
internal/core/debug/packet_types.go:75
↓ 1 callers
Function
getCommandName
(server ServerType, commandType uint16)
internal/core/debug/packet_names.go:63
↓ 1 callers
Function
getCustomHTTPReqHeaders
getCustomHTTPReqHeaders retrieves a copy of any headers that are set in a context through the twirp.WithHTTPRequestHeaders function. If there are no h
internal/shipgate/shipgate.twirp.go:2924
↓ 1 callers
Method
getNextKey
()
internal/core/encryption/pc.go:79
↓ 1 callers
Function
getServerType
Guesses the server type based on the sender of the packet and what ports the packet was sent between. Also returns whether or not this packet was sent
cmd/sniffer/sniffer.go:67
↓ 1 callers
Function
guildcardEntryToProto
(gcEntry *data.GuildcardEntry)
internal/shipgate/conversions.go:93
↓ 1 callers
Method
handleCharacterSelect
Handle the character select/preview request. For the preview request, this method will either send info about a character given a particular slot in
internal/character/character_server.go:390
↓ 1 callers
Method
handleCharacterUpdate
Performs a create or update/delete depending on whether the user followed the "dressing room" or "recreate" flows (as indicated by a client flag).
internal/character/character_server.go:579
↓ 1 callers
Method
handleFileStatus
The client sent us a checksum for one of the patch files. Compare it to what we have and add it to the list of files to update if there is any discrep
internal/patch/data_server.go:161
↓ 1 callers
Method
handleGuildcardChunk
send another chunk of the client's guildcard data.
internal/character/character_server.go:514
↓ 1 callers
Method
handleGuildcardDataStart
LoadConfig the player's saved guildcards, build the chunk data, and send the chunk header.
internal/character/character_server.go:472
↓ 1 callers
Method
handleLogin
(ctx context.Context, c *client.Client, loginPkt *commands.Login)
internal/ship/game_server.go:77
↓ 1 callers
Method
handleLogin
(ctx context.Context, c *client.Client, loginPkt *commands.Login)
internal/character/auth_server.go:80
↓ 1 callers
Method
handleLogin
(ctx context.Context, c *client.Client, loginPkt *commands.Login)
internal/character/character_server.go:153
↓ 1 callers
Method
handleOptionsRequest
LoadConfig key config and other option data from the database or provide defaults for new accounts.
internal/character/character_server.go:326
↓ 1 callers
Method
handlePacket
(server debug.ServerType, clientPacket bool, data []byte)
cmd/sniffer/sniffer.go:77
↓ 1 callers
Method
handlePatchLogin
Once the client has authenticated, send them the list of files to update.
internal/patch/data_server.go:87
↓ 1 callers
Method
handleShipLogin
(ctx context.Context, c *client.Client, loginPkt *commands.Login)
internal/ship/auth_server.go:94
↓ 1 callers
Method
handleShipSelection
Player selected one of the items on the ship select screen; respond with the IP address and port of the ship server to which the client will connect
internal/character/character_server.go:304
↓ 1 callers
Method
hasDressingRoomFlag
(c *client.Client)
internal/character/character_server.go:670
← previous
next →
101–200 of 570, ranked by callers