• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..03-May-2022-

Makefile.amH A D29-Oct-2005516 3519

Makefile.inH A D03-May-202211.4 KiB405343

READMEH A D16-Oct-20053.7 KiB10370

buildH A D30-Dec-2005655 3824

build.inH A D29-Dec-2005639 3824

logging_proxy.cH A D03-May-202221.9 KiB1,005675

login_server.cH A D03-May-20227.4 KiB422285

nocipher_proxy.cH A D03-May-20229.4 KiB477327

redirect_server.cH A D03-May-20226.4 KiB366243

sendmessage.cH A D03-May-20229.5 KiB367211

socket.cH A D03-May-20229.1 KiB328141

README

1
2These samples demonstrate how to do a few things with the Meanwhile
3library. Some of these are also tools which can be used to help in
4debugging and obtaining protocol information.
5
6
7Examples
8========
9
10 socket.c
11
12Compile with `./build socket`. This is the simplest possible
13client. All it does is connect and authenticate to a host (specified
14on the command line). Most of the code is dedicated to performing I/O.
15
16
17 sendmessage.c
18
19Compile with `./build sendmessage`. Expands upon socket.c to send a
20message via the IM service after login, then immediately logs off and
21exits.
22
23
24 echo.c  (forthcoming)
25
26Compile with `./build echo`. This extends on the socket example above,
27but introduces the use of the IM service. All incoming messages will
28be echo'd verbatim back at whomever sends them. Can anger co-workers.
29
30
31 pipe.c  (forthcoming)
32
33Compile with `./build pipe`. Extending upon the echo example, but is
34slightly more amusing and can be possibly useful for scripting. Will
35output all incoming IM messages to stdout. Listens on stdin and will
36write each line from stdin back to anyone who sent us a message
37(responding in order received)
38
39Since this application uses stdout, glib logging is smothered.
40
41
42 blist_storage.c  (forthcoming)
43
44Compile with `./build blist_storage`. An example of the Storage
45service and buddy list parser. Operates in two modes, up and down. In
46up mode, this sample will read a buddy list file on stdin, check it
47for validity, then upload it to the storage service. In down mode,
48this sample will fetch the buddy list from the storage service and
49write it to stdout.
50
51Since this application uses stdout, glib logging is smothered.
52
53
54Utilities
55=========
56
57 redirect_server.c
58
59Compile with `./build redirect_server`. Acts as a redirecting sametime
60server; any client attempting to connect to the socket this utility
61listens on will be instructed to redirect its connection to an
62alternative host (which is specified on the command line). Useful for
63ensuring client code can handle redirects correctly when there's no
64real redirecting server to test against.
65
66
67 nocipher_proxy.c
68
69Compile with `./build nocipher_proxy`. Acts as a sametime server
70proxy, passing messages between a real client and server. However, it
71will intercept and mangle channel creation messages to ensure that
72they will not be used with encryption. This will cause many clients to
73fail in strange places (where they demand encryption), but is useful
74for getting some messages from a service in the clear. Will print all
75messages in hex pairs to stdout using the hexdump utility. This may be
76more useful than using ethereal, as it will actually group its output
77by message rather than by receipt from the TCP stream.
78
79
80 login_server.c
81
82Compile with `./build login_server`. Acts as a sametime server; any
83client attempting to connect to the socket this utility listens on
84will be able to complete handshaking and send a login message. The
85tool then analyzes the authentication method and data and prints the
86decrypted data to stdout. This was useful for reverse-engineering the
87RC2/128 auth method (and determining what one of the guint32 fields of
88the handshake ack was for). Probably not very useful for anything
89else.
90
91
92 logging_proxy.c
93
94Compile with `./build logging_proxy`. Acts as a sametime server proxy,
95passing messages between a real client and server. However, it will
96intercept and mangle channel data in order to obtain the unencrypted
97data. This should be invisible to both the client and the server. Will
98print all messages in hex pairs to stdout using the hexdump utility,
99and will print decrypted contents of encrypted channel messages
100separately. This is certainly more useful than using ethereal, as it
101groups its output by message as well as provides an unencrypted view
102of otherwise obscured service protocols.
103