MediaManager updates

Sarah Green reported MediaManager troubles. When clicking on media files to make them play, message “could not load media” would appear. Both in her Media Manager windows and with files embedded in blackboard.

Root cause was password protection. She had four folders, each password protected, and protected using old-style “AuthType Kerberos” methods as generated by the password protect utility of  September 23 2012  or earlier. The MediaManager itself uses AuthType WebAuth. Trying to view files protected by Kerberos while logged into an app using WebAuth caused electronic brains to hurt. Proscribed solution was to remove password protection from all 4 folders, then re-enable password protection on all four files. This fixed her troubles viewing files with the media manager.

But embeded files still broke. Why? Media files like “http://www.uvm.edu/~waw/podcast_folder/folder_A/media.mp4” were now password protected — try to access directly and you would get redirected to webauth.uvm.edu to enter credentials. But try to access via old-style embed code…

jwplayer("mediaspace48995").setup({ playlist: [{
file: "http://www.uvm.edu/~waw/podcast_folder/folder_A/media.mp4" }], height: 360, autostart: false, width: 640});

Media file would redirect, and jwplayer would go, “What? That ain’t no movie!”

Furthermore, The “link” form was on the order

;
http://www.uvm.edu/~waw/podcast_folder/Show.php?fn=folder_A/media.mp4

This link is to a PHP script Show.php outside of the protected folder, and fed a folder name and the name of a file inside the folder. Since the script is outside the protected folder, it doesn’t require a password to run. The HTML it produces is the same jwplayer code as above, with the same results.

The “preferred” youtube style ’embed’ using iframes simply wraps the link address above in an iframe

So we’re getting nowhere fast.

We can’t do anything about the base jwplayer code. What we need is to ensure webauth authentication occurs before the media is referenced.

To tha end, I modified the media manager code to dump a copy of Show.php into every sub-directory in podcast_folder. Now link address is

http://www.uvm.edu/~waw/podcast_folder/folder_A/Show.php?fn=media.mp4

This link is to a PHP script Show.php inside of the protected folder, and fed  the name of a file inside the folder. Since the script is inside the protected folder, it requires a password to run. The HTML it produces is the same jwplayer code as above, but since the script has authenticated, jwplayer has unfettered access to the media as well.

This renders what was recently the “alt” iframe embed code the ‘preferred’ embed code. Works equally well with protected and unprotected  media files. The more verbose embed code only works for unprotected, so it is now labeled old-style.

While I was at it, I also replaced any reference to local copies of jwplayer.js with links to same javascript library on jwplayer.com website, ensuring we always have the latest version.

Note that these changes are to the media manger interface itself. All the new better links are generated by the media manager, but old links and bad embed codes in the field are still old and bad. Users need to log into media manager to update their podcast_folders, then manually replace all their old media links in  blackboard to take advantage of the updates.

Posted in Wes | Tagged , , | Leave a comment

Admissions flat panel

On Jan 16, 2014, at 10:01 AM, Russ McDonald wrote:

Hi Wes,

I’ve been trying to figure out what broke with our LCD screen with PHP 5.3.27. The problem is with the footer.php code. Everything seems to work fine for a while and then it stops refreshing the page and getting new feeds after approximately an hour.

Here’s what I’ve tried:

Changed the feeds in the array to see if a particular feed might be the culprit… even reduced the array to two items and no luck.
Changed the refresh rate to 2 seconds (was set to 20) to try and determine if it had to do with the how many iterations of the loop are preformed. It still stops right around an hour after I restart it.

Here’s the page if you wouldn’t mind taking a look over my shoulder to see if it’s something obvious I’m missing.

http://php53test.uvm.edu/~remcdona/fpanel_2013/footer.php

Screen Shot 2014-01-30 at 2.28.19 PM

Wow, this was tricky. Apparently new php enables function curl_exec, which activates a section of simplepie (php news feed reader) code that contained some debugging code (print “stop”;exit;) inserted by me in 2012 and passed to Russ like a virus.

All is well now

Posted in Wes | Tagged , , | Leave a comment

Drupal for Sociology

Backported Sociology’s Drupal LDAP module from 7.x-2.xbeta8 to 7.x-1.xbeta12, which was not as easy as it sounds. But there you are.

Posted in Wes | Tagged , , | Leave a comment

Drupal for sociology

This isn’t confined to sociology’s use, thinking in broader terms of what serves as a minimal UVM application base. Specifically,

  • Single Sign On (SSO)
  • LDAP attributes to Drupal Roles mapping

SSO covered in previous posts. Now we tackle LDAP. Goal is to try LDAP module’s Organic Groups option.

 

OG Requires

  • Entity Reference  http://ftp.drupal.org/files/projects/entityreference-7.x-1.1.tar.gz
  • Features gz (88.2 KB)
  • Organic Groups gz (254.69 KB)

But it was all in vane.  LDAP mapping options same for OG as for normal Drupal groups, so unless you are leveraging LDAP groups it gets you nowhere

But get this: I’ve been using the ‘recomended’  7.x-2.x (Beta 8) LDAP module code. Switching to 7.x-1.x code adds a lot more options , including this:
Screen Shot 2014-01-29 at 2.08.43 PM
which works perfectly, except for annoying notices whenever somebody new logs in ….
Screen Shot 2014-01-29 at 2.14.27 PM
Looking for an option to turn off notices
The absence of this option in the 7,x-2.x code is noted in the module bug reports, hopefully it will work its way into the 7.x-2.x RC code
Posted in Wes | Tagged , | Leave a comment

CTL Events login updated in development branch, please test

On Jan 27, 2014, at 2:55 PM, Wesley Alan Wright wrote:

https://www.uvm.edu/ctl/development/ctlcal/

What’s new? Authentication. User names and passwords requested as per ETS ‘standard’ WebAuth system.

If no one has issues  by next Tuesday it’s going live

Posted in Wes | Tagged , , , | Leave a comment

CTL Calendar Admin/Reports

On Jan 24, 2014, at 11:09 AM, Nina Wu wrote:

Under “People” Can the two or more filters work at the same time? e.g. filter by affiliation and attended date.

Done!

On Jan 24, 2014, at 11:09 AM, Nina Wu wrote:

can we get a list of people at UVM whose job title is Office/Program Support Generlist?

https://www.uvm.edu/ctl/development/reports/ddc.php

Note new location

Posted in Wes | Tagged , , , | Leave a comment

RWG Mac version 5.0.48

On Jan 22, 2014, at 2:54 PM, Nick Ogrizovich <nogrizov@uvm.edu> wrote:

We just tried to install RWG on a student’s mac here at UVM and kept getting a “file is damaged” error. She does not have any antivirus running.  Her mac is using 10.9 (mavericks) and I think our version of RWG at UVM does not support 10.9.  I looked at the texthelp website, and it suggests build 48 (as in version 5.0.48) does support 10.9, but the current UVM build is 5.0.37.  We will need to update the installer so that people using Mavericks can install it without needing a serial #.

The file can be obtained here: http://www.texthelp.com/essentials/mac/site/readwrite-installer/
and our serial # seems to be: 334055412438447237  (required for login)

RWG 5 for Mac build 5.0.48 now available. Only took 2 hours — dog to download install and upload.

Note that this is the Student Home Version

http://www.texthelp.com/essentials/mac/site/additional-installation-options/create-a-take-home-version/

The “Installer” version is for installation on University owned machines; in particular, lab machines always tied to a local area network

Posted in Wes | Tagged | Leave a comment

Drupal for Sociology

Tom’s special theme installed.. He says, “Thanks so much, Wes. Fiddled just a tiny bit. There’s definitely a learning curve; we may need to consult a bit on terminologies and underlying logics. We’ll be in touch. “

Posted in Wes | Tagged , , | Leave a comment

Kathy Marmor’s fan project

Kathy Marmor’s fan project relies on the Twitter Search API, as implemented by a Perl Module downloaded from the web. Just days before her show at the Church Street Firehouse Gallery last May, Twitter updated their API from version 1 to v 1.1, causing a mad scramble to install a new updated Perl module and alter her code to use it.

Today at her show in Oregon, her fans stopped working, she was getting a 401 Forbidden error on her console. Apparently just today, Twitter changed their API such as to require HTTPS connections. I had to download and install 3 Perl modules and hack the code in one of them (/Library/Perl/5.16/Net/Twitter/Role/API/RESTv1_1.pm) to get things going again on my Mac — she has to do the same on hers.

What kind of luck is that?

Posted in Wes | Tagged , | Leave a comment

Drupal for Sociology

Granted soceval.w3.uvm.edu from SAA. Obtained account on webdb database server.

Attempted Drupal 7.25 install. Various failings due to SELinux file permissions. Had to unpack tar file directly into www-root. Who knew. after that, install was smooth.

LDAP integration and SSO:

Start at https://drupal.org/project/ldap

Enable above and LDAP…
LDAP Authentication
LDAP Authorization
LDAP Authorization – Drupal Roles
LDAP Servers
LDAP SSO
LDAP User Module
Configure Server
Screen Shot 2014-01-13 at 3.56.54 PM
Screen Shot 2014-01-13 at 3.57.12 PM
Configure Authentication, Authorization, SSO
Here’s where it falls off tracks: LDAP authentication works, but I can’t get any LDAP attribute to Drupal role mapping to work — looks like it wants to use ldap groups, not user attributes.
And SSO doesn’t work. Can’t seem to apply WebAuth to https://soceval.w3.uvm.edu/sociology/user/login/sso using .htaccess
Needed to create dummy directory sociology/users/login/sso and place .htaccess there.
I took out WebAuth stuff from root .htacccess, and added the rewrite statement
 RewriteRule user/.* index.php [L]
put this in user/login/sso/.htaccessAuthType WebAuth
Require valid-user
WebAuthOptional Offturned off “automated/seamless single sign-on” in LDAP AuthenticationUnder Structure=> Blocks Moved User Login Block from sidebar to disabled

Under Structure-> Menu added Login with path user/login/sso

And like magic, http://soceval.w3.uvm.edu/sociology/

LDAP mapping to Drupal rolles still pending. Going to try Organic Groups
Posted in Wes | Tagged , , | Leave a comment