ObjXMPP  Check-in [3dcaf032f2]

Overview
Comment:Respectively do Nameprep/SASLPrep on domain name and password
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: 3dcaf032f272a592530e2e85dcd0d231a93c0d434210bce7774af5f0b6f3043f
User & Date: florob@babelmonkeys.de on 2011-02-11 01:25:15
Other Links: manifest | tags
Context
2011-02-12
00:04
Add some documentation check-in: baa634a6f1 user: florob@babelmonkeys.de tags: trunk
2011-02-11
01:25
Respectively do Nameprep/SASLPrep on domain name and password check-in: 3dcaf032f2 user: florob@babelmonkeys.de tags: trunk
01:06
Add a basic folder structure check-in: 2e7a482ea5 user: florob@babelmonkeys.de tags: trunk
Changes

Modified src/XMPPConnection.m from [cdbcbf0e8f] to [309d096214].

58
59
60
61
62
63
64










































65
66
67
68
69
70
71
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113







+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+







	}

	@try {
		username = [[OFString alloc] initWithCString: node];
	} @finally {
		free(node);
	}

	[old release];
}

- (void)setServer: (OFString*)server_
{
	OFString *old = server;
	char *srv;

	Stringprep_rc rc;
	if ((rc = stringprep_profile([server_ cString], &srv, "Nameprep", 0))
			!= STRINGPREP_OK) {
		of_log(@"Nameprep failed: %s", stringprep_strerror(rc));
		assert(0);
	}

	@try {
		server = [[OFString alloc] initWithCString: srv];
	} @finally {
		free(srv);
	}

	[old release];
}

- (void)setPassword: (OFString*)password_
{
	OFString *old = password;
	char *pass;

	Stringprep_rc rc;
	if ((rc = stringprep_profile([password_ cString], &pass, "SASLprep", 0))
			!= STRINGPREP_OK) {
		of_log(@"SASLprep failed: %s", stringprep_strerror(rc));
		assert(0);
	}

	@try {
		password = [[OFString alloc] initWithCString: pass];
	} @finally {
		free(pass);
	}

	[old release];
}

- (void)_startStream
{
	[sock writeFormat: @"<?xml version='1.0'?>\n"