[rt-users] 3.6 theme?
Hi I liked the ancient 3.6.x look of RT, but it is not available in latest releases. Is there a theme to bring it back? -- Emmanuel Dreyfus http://hcpnet.free.fr/pubz m...@netbsd.org
Re: [rt-users] charset troubles
Alex Vandiver ale...@bestpractical.com wrote: Which database? In your original mail, you said: p5-DBD-mysql-4.031 [...] postgresql-9.4.1 Which database are you using? PostgreSQL 9.4.1. And p5-DBD-postgresql-3.5.1 was missing in my list. -- Emmanuel Dreyfus http://hcpnet.free.fr/pubz m...@netbsd.org
[rt-users] Need help getting REST API calls to work using WinHttpRequest from VBA
Our goal is to create a Ticket in RT using VBA using the WinHttpRequest object. We understand that there are 2 login pages involved with RT. So, first we log into the first RT login page using using a POST request and passing the username and password using the SetCredentials function of the WinHttpRequest object. This request appears to return a valid session cookie which we parse to use in our second WinHttpRequest request. In making our second request we use a GET request setting the 2nd RT login username and password using the SetCredentials function and in addition we now are passing the session cookie (that is we send a portion of the session cookie returned from the previous request) info using the SetRequestHeader (as in SetRequestHeader Cookie, mvarSessionCookie ). In this second request we are asking for an RT Ticket to be returned using https://(our url)/REST/1.0/ticket/(a ticket #)/show. However, we receive the 401 Authorization error instead. Some sample code would be great. *Below is the code we are using presently to verify that the session cookie we receive from the 1st RT login page is valid by * *using a second request to return an existing RT ticket (which is hard coded for testing purposes):* Private Const cnstBase_URL As String = https://[our RT url] With WinHttpReq 'either of the following lines seems to work and return a cookie .Open POST, cnstBase_URL .SetRequestHeader User-Agent, Mozilla/5.0 (Windows NT 6.1; WOW64; rv:31.0) Gecko/20100101 Firefox/31.0 .SetRequestHeader Connection, keep-alive 'user name and password for 1st RT login page/url .SetCredentials cnstRequestor, cnstPWD, HTTPREQUEST_SETCREDENTIALS_FOR_SERVER On Error Resume Next .Send If Err.Number = 0 Then If .Status = 200 Then On Error Resume Next output_Cookie = .getResponseHeader(Set-Cookie) On Error GoTo 0 myCookie = Split(output_Cookie, ;) If UBound(myCookie) 0 Then 'implicit conversion to string mvarSessionCookie = myCookie(0) End If Else Debug.Print HTTP .Status .StatusText End If Else Debug.Print Error Err.Number Err.Source Err.Description End If On Error GoTo 0 End With Set WinHttpReq = Nothing If Trim(mvarSessionCookie) = Then Exit Function 'perform second request Set WinHttpReq = New WinHttp.WinHttpRequest With WinHttpReq 'get ticket data Dim TargetURL As String 'to test cookie, display a ticket 'hard coded for testing as this works from the Browser which I thought would be a good test 'to see if the Cookie variable works TargetURL = https://[our RT url]/REST/1.0/ticket/96494/show .Open GET, TargetURL, False .SetRequestHeader User-Agent, Mozilla/5.0 (Windows NT 6.1; WOW64; rv:31.0) Gecko/20100101 Firefox/31.0 .SetRequestHeader Connection, keep-alive .SetRequestHeader Cookie, mvarSessionCookie 'user name and password for 2nd RT login page/url .SetCredentials cnstBasic_Auth_User, cnstBasic_Auth_PWD, HTTPREQUEST_SETCREDENTIALS_FOR_SERVER On Error Resume Next .Send If Err.Number = 0 Then If .Status = 200 Then Debug.Print Debug.Print .ResponseText Debug.Print .GetAllResponseHeaders Else Debug.Print HTTP .Status .StatusText End If Else Debug.Print Error Err.Number Err.Source Err.Description End If On Error GoTo 0 Debug.Print .GetAllResponseHeaders End With Set WinHttpReq = Nothing Thanks, in advance, Tim
Re: [rt-users] charset troubles
On Fri, 1 May 2015 10:01:02 +0200 m...@netbsd.org (Emmanuel Dreyfus) wrote: In database, I have in both cases Which database? In your original mail, you said: p5-DBD-mysql-4.031 [...] postgresql-9.4.1 Which database are you using? - Alex
Re: [rt-users] rt-mailgate ignoring --no-verify-ssl?
Fixed it. Apparently --no-verify-ssl only deals with the hostname on the certificate. I added the following to the 'use' section at the top of rt-mailgate: use IO::Socket::SSL; and then in the get_useragent function, I added the following ssl_opts line: $ua-ssl_opts( SSL_verify_mode = IO::Socket::SSL::SSL_VERIFY_NONE ); Now my legitimately signed wildcard cert (*.mydomain.tld) doesn't error out because of a bad hostname, or an untrusted cert in the middle of the chain. -A On Wed, Apr 29, 2015 at 9:01 PM, Aaron C. de Bruyn aa...@heyaaron.com wrote: Mailgate has been driving me nuts. I downloaded 4.2.10 and set it up on a bright, shiny new server. I'm running fetchmail on my RT box using the following to send tickets to RT: poll mail.mydomain.tld with protocol pop3 username engineering password -redacted- mda /opt/rt4/bin/rt-mailgate --no-verify-ssl --queue engineering --action correspond --url https://tickets.mydomain.tld --debug Fetchmail complains about the MDA erroring out. Increasing fetchmail debugging shows: fetchmail: about to deliver with: /opt/rt4/bin/rt-mailgate --no-verify-ssl --queue engineering --action correspond --url https://tickets.mydomain.tld/ --debug #***/opt/rt4/bin/rt-mailgate: temp file is '/tmp/Ax6Or2dgc1/23FBulXCfc' /opt/rt4/bin/rt-mailgate: connecting to https://tickets.mydomain.tld//REST/1.0/NoAuth/mail-gateway HTTP request failed: 500 Can't connect to tickets.mydomain.tld:443 (certificate verify failed). Your webserver logs may have more information or there may be a network problem. /opt/rt4/bin/rt-mailgate: undefined server error fetchmail: MDA returned nonzero status 75 not flushed fetchmail: POP3 QUIT I even get an SSL error when running from the command line: root@tickets:/opt# /opt/rt4/bin/rt-mailgate --no-verify-ssl --queue engineering --action correspond --url https://tickets.mydomain.tld/ --debug test ctrl+d /opt/rt4/bin/rt-mailgate: temp file is '/tmp/9vlYhx9C9X/kI4IQo0RRw' /opt/rt4/bin/rt-mailgate: connecting to https://tickets.mydomain.tld//REST/1.0/NoAuth/mail-gateway HTTP request failed: 500 Can't connect to tickets.mydomain.tld:443 (certificate verify failed). Your webserver logs may have more information or there may be a network problem. /opt/rt4/bin/rt-mailgate: undefined server error root@tickets:/opt# It's acting like it's ignoring --no-verify-ssl. Am I missing something? Thanks, -A
Re: [rt-users] Issue Upgrading from 3.8.8
On 5/1/15 7:15 AM, II GG wrote: After importing the MySQL database data from the old server I used the rt-setup-database script. This errors: [1324] [Fri May 1 10:45:28 2015] [warning]: Resolver RT::URI::fsck_com_rt could not parse fsck.com-rt://Vaioni/ticket/0, maybe Organization config was changed? (/usr/share/request-tracker4/lib/RT/URI.pm:165) Couldn't finish 'upgrade' step. I am hoping the database hasn't been played with previously. Any ideas what might be causing this? Assuming $Oragnization is the same, this seems to be the case. What I would do is grab 3.8.8 from the downloads page and see if it runs against your copy of the database. This may shake out any accidental misconfiguration. Then maybe run 3.8's sbin/rt-validator on it (once with --check, and then with --check --resolve --force). After that run 4.2's upgrade script on it. Regards,
Re: [rt-users] charset troubles
Emmanuel Dreyfus m...@netbsd.org wrote: The generated HTML for creating and updating looks similar, hence I assume it is the server-side handling that differ. In database, I have in both cases contenttype: text/plain contentencoding: quoted-printable An attachment that displays correctly (added by updating the ticket on the web) indeed contains quoted-printable data: content: rh=C3=A2=C3=A2=C3=A2 An attachment that does not display correctly (added at ticket creation on the web) is not in quoted-printable: content: rhâââ -- Emmanuel Dreyfus http://hcpnet.free.fr/pubz m...@netbsd.org
[rt-users] Issue Upgrading from 3.8.8
I have inherited a very old RT installation. I plan to upgrade from 3.8.8 to the latest RT 4.2.x version included with Debian stable. I started with a full working installation of RT 4.2.8. After importing the MySQL database data from the old server I used the rt-setup-database script. This errors: Processing 3.8.9 Now inserting data. [1324] [Fri May 1 10:45:28 2015] [warning]: Resolver RT::URI::fsck_com_rt could not parse fsck.com-rt://Vaioni/ticket/0, maybe Organization config was changed? (/usr/share/request-tracker4/lib/RT/URI.pm:165) Couldn't finish 'upgrade' step. ERROR: One of initial functions failed: Target URI looks like local, but is not parseable at /usr/share/request-tracker4/etc/upgrade/3.8.9/content line 36, $handle line 1. The Organization setting in RT-SiteConfig.pm matches the old installation. As a test I tried changing to a random Organization and the upgrade script continues but I can no longer login. I am hoping the database hasn't been played with previously. Any ideas what might be causing this? Ian