Displaying 20 results from an estimated 33 matches for "str_append_c".
2003 Sep 29
1
Handling of X-Status flags
...': /* flagged */
@@ -168,9 +168,9 @@
nextflag = *oldflags == '\0' || *oldflags == ',' ? 256 :
(unsigned char) *oldflags;
- if ((flags & MAIL_DRAFT) && nextflag > 'D') {
+ if ((flags & MAIL_DELETED) && nextflag > 'D') {
str_append_c(flags_str, 'D');
- flags &= ~MAIL_DRAFT;
+ flags &= ~MAIL_DELETED;
}
if ((flags & MAIL_FLAGGED) && nextflag > 'F') {
str_append_c(flags_str, 'F');
@@ -184,9 +184,9 @@
str_append_c(flags_str, 'S');
flags &= ~MAIL_SEEN;...
2003 Oct 02
2
Patches
As the freeze for Debian sarge slowly approaches I want to make sure
the Dovecot packages are in as good condition as possible. I see there
have been a number of patches since 0.99.10. I have added the following
patches:
* segfault when user home directory is empty
* Proper PAM service name
* Make suid work on 2.6 kernels
Any other patches thatI ought to add. Or better yet, will there be a
2017 Oct 26
2
Bug: lmtp proxy does not quote local parts with spaces
On 26/10/2017 18:38, Alexander Dalloz wrote:
> Am 26.10.2017 um 12:20 schrieb David Zambonini:
>>
>> There seems to be a bug with RFC822 processing in ltmp proxying that
>> doesn't
>> quote local parts that, for example, contain spaces.
>
> Newer related RFCs are RFC 5321 and 5322.
Typo, meant to say RFC2822, which they still supercede, not that the
2010 Jun 14
1
Patch to fix leak in imap_refresh_proctitle in beta[5, 6]
...6)
+++ b/src/imap/main.c (working copy)
@@ -39,11 +39,12 @@
#define IMAP_PROCTITLE_PREFERRED_LEN 80
struct client *client;
struct client_command_context *cmd;
- string_t *title = t_str_new(128);
+ string_t *title;
if (!verbose_proctitle)
return;
+ title = str_new(default_pool, 128);
str_append_c(title, '[');
switch (imap_client_count) {
case 0:
@@ -72,6 +73,7 @@
}
str_append_c(title, ']');
process_title_set(str_c(title));
+ str_free(&title);
}
static void client_kill_idle(struct client *client)
And perhaps there should be a warning when data is allocated...
2017 Nov 01
2
Bug: lmtp proxy does not quote local parts with spaces
...p < domain; p++) {
+ if (!IS_ATEXT(*p))
+ break;
+ }
+
+ /* local part is atext */
+ if (p == domain) {
+ str_append(dest_r, str);
+ return;
+ }
+
+ /* need to quote the local part */
+ str_append_c(dest_r, '"');
+
+ /* see if we need to escape */
+ for (p=str; p < domain; p++) {
+ if (strchr("\t\"\r\n\\", *p))
+ break;
+ }
+
+ if (p == domain) {
+ /* only quote */
+ s...
2016 Jul 26
2
[BUG] Re: auth_bind with "()" in username not working
Hi guys,
I had a look in the sources about this problem.
the problem seems to be the ldap_escape function that is called from
ldap_verify_plain_auth_bind_userdn(..)
I dont really know if this escaping is needed at this point, but with
this change it works for me. No other problems discovered so far.
could somebody, who is deeper in the sources give me a hint if
this will make some troubles?
2006 Jun 26
2
[PATCH, RFC 3/13] OTP: parity table
Add OTP parity table.
diff -urdpNX /usr/share/dontdiff -x Makefile dovecot.vanilla/src/lib-otp/otp-parity.c dovecot/src/lib-otp/otp-parity.c
--- dovecot.vanilla/src/lib-otp/otp-parity.c 1970-01-01 03:00:00.000000000 +0300
+++ dovecot/src/lib-otp/otp-parity.c 2006-06-23 13:44:31.161891112 +0400
@@ -0,0 +1,29 @@
+/*
+ * OTP parity table.
+ *
+ * Copyright (c) 2006 Andrey Panin <pazke at
2017 Jun 10
0
Pacaging/build issues with AIX and vac (dovecot-2.2.25)
...struct option longopt;
+435
+436 i_zero(&longopt);
+437 longopt.name = par[i].name;
+438 if (par[i].short_opt != '\0') {
+439 longopt.val = par[i].short_opt;
+440 str_append_c(shortopts, par[i].short_opt);
+441 if (par[i].type != CMD_PARAM_BOOL)
+442 str_append_c(shortopts, ':');
+443 }
+444 if (par[i].type != CMD_PARAM_BOOL)
+445 lo...
2007 Mar 27
2
gssapi auth issue...
...ndard-- and probably not negotiable.
However, the hostname of the machine is: "foobar", not foobar.sfbay.sun.com
(as reported by gethostname(3c)).
So when dovecot does this:
mech-gssapi.c:
principal_name = t_str_new(128);
str_append(principal_name, service_name);
str_append_c(principal_name, '@');
---> str_append(principal_name, my_hostname);
We wind up asking kerberos to look for a ticket for imap at foobar,
instead of imap at foobar.sfbay.sun.com.
Obviously we can patch the source, but I was wondering if we could
have a gssapi_hostname setting in the...
2004 Jul 22
0
[PATCH] POP3 CAPA command RFC violation
...-authenticate.c 2004-07-14 14:48:01.000000000 +0400
+++ dovecot-1.0-test29/src/pop3-login/client-authenticate.c 2004-07-22 13:46:07.000000000 +0400
@@ -37,7 +37,6 @@ int cmd_capa(struct pop3_client *client,
if (mech[i].advertise &&
(client->secured || !mech[i].plaintext)) {
str_append_c(str, ' ');
- str_append(str, "AUTH=");
str_append(str, mech[i].name);
}
}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://dovecot.or...
2004 Dec 06
0
[PATCH] passdb cache fixes
...extra_finish(struct au
if (passdb_cache != NULL && cache_key != NULL) {
str = t_str_new(64);
- str_append_str(str, extra->str);
+ if (extra->str != NULL)
+ str_append_str(str, extra->str);
if (extra->request->no_failure_delay) {
if (str_len(str) > 0)
str_append_c(str, '\t');
@@ -266,7 +267,8 @@ void auth_request_extra_finish(struct au
}
auth_cache_insert(passdb_cache, extra->request, cache_key,
t_strconcat(extra->password == NULL ? "" :
- extra->password, "\t",
+ extra->password,
+...
2006 Sep 18
1
Incorrect GSSAPI Service Name for POP3
...tr_append(principal_name, t_str_lcase(request->service));
+ if(strcmp(request->service, "POP3") == 0) {
+ str_append(principal_name, "pop");
+ } else {
+ str_append(principal_name, t_str_lcase(request->service));
+ }
str_append_c(principal_name, '@');
str_append(principal_name, my_hostname);
-----------------------------END PATCH-----------------------------
2011 Mar 08
1
ID command bug & patch
...ag id ("a" "b" "c" "d")
then dovecot logs:
ID sent: a=b, b=c, c=d
The following patch makes it log instead:
ID sent: a=b, c=d
--- a/dovecot/src/lib-imap/imap-id.c (revision 113366)
+++ b/dovecot/src/lib-imap/imap-id.c (working copy)
@@ -164,6 +164,7 @@
str_append_c(reply, '=');
str_append(reply, str_sanitize(value, 80));
}
+ args++;
}
return str_len(reply) == 0 ? NULL : str_c(reply);
}
2019 May 19
3
Dict issue with PostgreSQL for last_login plugin (duplicate key)
On 19/05/2019 20:31, mabi via dovecot wrote:
>
> ??????? Original Message ???????
> On Sunday, May 19, 2019 7:36 PM, John Fawcett via dovecot
> <dovecot at dovecot.org> wrote:
>>
>> Attached is a tentative patch. I've verified no regression for mysql.
>> There should be no regression for sqlite as the code path is identical.
>>
>> Are you able to
2015 Oct 06
4
More information about - Dovecot 2.2.x quota mysql and dict
...elds, &field_count);
i_assert(field_count > 0);
query = t_str_new(64);
str_printfa(query, "UPDATE %s SET ", fields[0].map->table); #### this
in code, work excellent
for (i = 0; i < field_count; i++) {
if (i > 0)
str_append_c(query, ',');
str_printfa(query, "%s=%s", fields[i].map->value_field,
fields[i].map->value_field);
if (fields[i].value[0] != '-')
str_append_c(query, '+');
str_append(que...
2012 Oct 02
2
[PATCH] Add SCRAM-SHA-1 password scheme
...Calculate ClientKey */
+ hmac_init(&ctx, salted_password, sizeof(salted_password),
+ &hash_method_sha1);
+ hmac_update(&ctx, "Client Key", 10);
+ hmac_final(&ctx, client_key);
+
+ /* Calculate StoredKey */
+ sha1_get_digest(client_key, sizeof(client_key), stored_key);
+ str_append_c(str, ',');
+ base64_encode(stored_key, sizeof(stored_key), str);
+
+ /* Calculate ServerKey */
+ hmac_init(&ctx, salted_password, sizeof(salted_password),
+ &hash_method_sha1);
+ hmac_update(&ctx, "Server Key", 10);
+ hmac_final(&ctx, server_key);
+ str_append_c...
2019 May 19
0
Dict issue with PostgreSQL for last_login plugin (duplicate key)
...me, "mysql") == 0;
+ dict->has_on_conflict_do_update = strcmp(driver->name, "pgsql") == 0;
if (sql_db_cache_new(dict_sql_db_cache, &sql_set, &dict->db, error_r) < 0) {
pool_unref(&pool);
@@ -1108,12 +1110,15 @@
str_append_str(prefix, suffix);
str_append_c(prefix, ')');
- if (!dict->has_on_duplicate_key) {
+ if (dict->has_on_duplicate_key ) {
+ str_append(prefix, " ON DUPLICATE KEY UPDATE ");
+ } else if(dict->has_on_conflict_do_update) {
+ str_append(prefix, " ON CONFLICT DO UPDATE SET ");
+ } else {
*stmt_...
2003 Mar 07
1
Apple's Mail.app
Hi,
I solved the OSX Authentication issue; I'm now reliably able to get
authenticated using the Password Server with PAM with:
# login: auth account password session
auth required pam_nologin.so
auth sufficient pam_securityserver.so
auth sufficient pam_unix.so
auth required pam_deny.so
account required pam_permit.so
password required
2018 Mar 05
3
Coredump: Panic: file smtp-address.c: line 530 (smtp_address_write): assertion failed: (smtp_char_is_qpair(*p))
Got a coredump:
Mar 5 15:09:42 mail-cbf dovecot: lmtp(backup at backup.invalid)<15425><2B+kCaZPnVpBPAAAplP5LA>: Fatal: master: service(lmtp): child 15425 killed with signal 6 (core dumped)
#0 0x00007fea19977428 in __GI_raise (sig=sig at entry=6) at ../sysdeps/unix/sysv/linux/raise.c:54
resultvar = 0
pid = 15425
selftid = 15425
#1 0x00007fea1997902a in
2006 Jul 24
2
[PATCH] Substitution of dots to ", dc=" in variable expansions
Hi list,
my ldap directory uses DNs like this:
uid=solist,ou=People,dc=solistland,dc=net,ou=Virtuals
but I only could use something like
uid=solist,ou=People,dc=solistland.net,ou=Virtuals
with dovecot, which obviously isn't what the dcObject object class was
meant to present.
I've written a small function for var-expand.c which introduces a new
modifier for string variable