- numerous bug fixes
 - wtv-setup + bgmusic
  - wtv-setup pages thanks to https://github.com/JarHead4
  - wtv-backgroundmusic support
  - keyboard and text size settings support
  - removed small midi music demo in favor of backgroundmusic system
This commit is contained in:
zefie
2021-11-05 09:39:37 -04:00
parent 3b761a495c
commit 94e44cad41
594 changed files with 5318 additions and 545 deletions

View File

@@ -27,8 +27,8 @@ This open source server is in beta status. Use at your own risk.
- ~~No intentions to support user accounts, registration, or any form of database system~~ *(I guess this was a lie, but we still don't use a database!)*
### Feature Todo:
- wtv-setup and bgm support
- TellyScript generation and/or manipulation without external dependancies
- ~~wtv-setup and bgm support~~ ***Done [v0.9.23](https://github.com/zefie/zefie_wtvp_minisrv/releases/tag/v0.9.23)***
- ~~wtv-cookie full support~~ ***Done [v0.9.13](https://github.com/zefie/zefie_wtvp_minisrv/releases/tag/v0.9.13)***
- ~~Flashrom flashing for bf0app old classic~~ ***Done [v0.9.9](https://github.com/zefie/zefie_wtvp_minisrv/releases/tag/v0.9.9)***
- ~~SSID/IP black/whitelisting (including tying SSID to an IP or multiple IPs)~~ ***Done [v0.9.4](https://github.com/zefie/zefie_wtvp_minisrv/releases/tag/v0.9.4)***

View File

@@ -0,0 +1,92 @@
<html>
<head>
<title>
Access Denied
</title>
<display nostatus nooptions switchtowebmode nohome>
</head>
<body noscroll bgcolor="#191919" text="#42CC55" link="36d5ff"
hspace=0 vspace=0 fontsize="large"
>
<table cellspacing=0 cellpadding=0^C>
<tr>
<td width=104 height=74 valign=middle align=center bgcolor="3B3A4D">
<img src="file://ROM/Cache/WebTVLogoJewel.gif" width=86 height=64>
<td width=20 valign=top align=left bgcolor="3B3A4D">
<img src="ROMCache/Spacer.gif"
width=1 height=1>
<td colspan=10 width=436 valign=middle align=left bgcolor="3B3A4D">
<font color="D6DFD0" size="+2">
<blackface>
<shadow>
<img src="ROMCache/Spacer.gif"
width=1 height=4>
<br>
Access Denied
</shadow>
</blackface>
</font>
<tr>
<td colspan=12 width=560 height=10 valign=top align=left>
<img src="ROMCache/Shadow.gif" width=560 height=6>
<tr>
<td width=104 height=10 valign=top align=left>
<td width=20 valign=top align=left>
<td width=67 valign=top align=left>
<td width=20 valign=top align=left>
<td width=67 valign=top align=left>
<td width=20 valign=top align=left>
<td width=67 valign=top align=left>
<td width=20 valign=top align=left>
<td width=67 valign=top align=left>
<td width=20 valign=top align=left>
<td width=68 valign=top align=left>
<td width=20 valign=top align=left>
<form action="client:poweroff"
>
<tr>
<td width=104 valign=middle align=center>
<td width=20 valign=middle align=center>
<td colspan=9 width=100 height=258 valign=top align=left>
<font size=-1>You are not authorized to use this service. <p>Reason: ${REASON} </font>
<tr>
<td width=104 valign=middle align=center>
<td width=20 valign=middle align=center>
<td colspan=10 height=2 valign=middle align=center bgcolor="2B2B2B">
<img src="ROMCache/Spacer.gif" width=436 height=1>
<tr>
<td width=104 valign=middle align=center>
<td width=20 valign=middle align=center>
<td colspan=9 height=1 valign=top align=left>
<tr>
<td width=104 valign=middle align=center>
<td width=20 valign=middle align=center>
<td colspan=10 height=2 valign=top align=left bgcolor="0D0D0D">
<img src="ROMCache/Spacer.gif" width=436 height=1>
<tr>
<td width=104 valign=middle align=center>
<td width=20 valign=middle align=center>
<td colspan=9 height=4 valign=top align=left>
<tr>
<td width=104 valign=middle align=center>
<td width=20 valign=middle align=center>
<td colspan=9 width=416 valign=top align=left>
<table cellspacing=0 cellpadding=0>
<tr>
<td width=306 valign=top align=left>
<font size="-1"><i>
</i></font><td width=112 valign=top align=right>
<font size="-1" color="#E7CE4A">
<shadow>
<input selected
name="Power Off"
value="Power Off"
type=submit Value=Continue name="Continue" borderimage="file://ROM/Borders/ButtonBorder2.bif" usestyle width=110>
</shadow>
</font>
</form>
</table>
<td width=20 valign=middle align=center>
</table>
</body>
</html>

View File

@@ -9,19 +9,23 @@ if (!request_headers.query.path) {
headers = errpage[0];
data = errpage[1];
} else {
var wtvflashrom = new WTVFlashrom(minisrv_config, service_vaults, service_name, minisrv_config.services[service_name].use_zefie_server, false, true);
var wtvflashrom = new WTVFlashrom(minisrv_config, service_vaults, service_name, minisrv_config.services[service_name].use_zefie_server, false, (minisrv_config.services[service_name].debug ? false : true));
var request_path = request_headers.query.path;
// read flashrom header info into array using WTVFlashrom class
wtvflashrom.getFlashromMeta(request_path, function (data) {
processLC2DownloadPage(request_headers.query.path, data, (request_headers.query.numparts || null));
processLC2DownloadPage(request_headers.query.path, data, (request_headers.query.numparts ? request_headers.query.numparts : null));
});
}
async function processLC2DownloadPage(path, flashrom_info, numparts = null) {
if (numparts != null) flashrom_info.part_count = parseInt(numparts);
if (!flashrom_info.part_count) flashrom_info.part_count = parseInt(flashrom_info.message.substring(flashrom_info.message.length - 4).replace(/\D/g, ''));
if (!flashrom_info.part_number || !flashrom_info.is_last_part || !flashrom_info.rompath || !flashrom_info.next_rompath || !flashrom_info.is_bootrom) {
console.log(flashrom_info);
if (parseInt(flashrom_info.part_number) >= 0 && flashrom_info.rompath && flashrom_info.next_rompath) {
if (!flashrom_info.message && flashrom_info.is_bootrom) {
flashrom_info.message = "BootRom Part " + (flashrom_info.part_number + 1) + " of " + flashrom_info.part_count;
}
if (!flashrom_info.is_last_part) {
flashrom_info.next_rompath = request_headers.request_url.replace(escape(request_headers.query.path), escape(flashrom_info.next_rompath.replace(service_name+":/","")));
}
@@ -80,7 +84,7 @@ Your WebTV Unit is being<br>updated automatically.
<p> <font size=+1>
This will take a while, and<br>then you can use your WebTV again.
`;
if (flashrom_info.is_bootrom && flashrom_info.part_number == 16) {
if (flashrom_info.is_bootrom && flashrom_info.part_number == (flashrom_info.part_count - 1)) {
data += `<p>
The system will pause for about 30 seconds at the end of this
update. Please <strong>do not</strong> interrupt the system
@@ -90,7 +94,7 @@ This will take a while, and<br>then you can use your WebTV again.
data += `
</font>
<br><br><br><br><br>
<upgradeblock width=280 height=15
<upgradeblock width=250 height=15
nexturl="${flashrom_info.next_rompath}"
errorurl="${service_name}:/lc2-download-failed?"
blockurl="${flashrom_info.rompath}"`;

View File

@@ -4,8 +4,10 @@ if (request_headers.query.path) {
var url = service_name + ":/get-lc2-page?path=" + request_headers.query.path;
var romtype = ssid_sessions[socket.ssid].get("wtv-client-rom-type");
if (romtype == "bf0app") {
url = "client:updateflash?ipaddr=" + minisrv_config.services[service_name].host + "&port=" + minisrv_config.services[service_name].port + "&path=" + escape(service_name + ":/" +request_headers.query.path);
url = "client:updateflash?ipaddr=" + minisrv_config.services[service_name].host + "&port=" + minisrv_config.services[service_name].port + "&path=" + escape(service_name + ":/" + request_headers.query.path);
if (request_headers.query.numparts) url += escape("?numparts=" + request_headers.query.numparts);
} else {
if (request_headers.query.numparts) url += "&numparts=" + request_headers.query.numparts;
}
headers = "300 OK\n";
headers += "wtv-visit: " + url + "\n";

View File

@@ -31,12 +31,13 @@ function go() {
location.href=document.access.url.value;
}
</script>
<b>Welcome to ${z_title}`;
<b>Welcome to ${minisrv_config.config.service_name}`;
if (ssid_sessions[socket.ssid].getSessionData("registered")) data += ", " + ssid_sessions[socket.ssid].getSessionData("subscriber_username") + "!";
data += "</b><br>";
if (minisrv_config.config.git_commit) data += `<div width="540" align="right"><font size="-4"><i>git revision ${minisrv_config.config.git_commit}</i></small></font></div><br>`;
data += `</b><br>
<div width="540" align="right">
<font size="-4"><i>
minisrv v${minisrv_config.version}${(minisrv_config.config.git_commit) ? ' git-'+minisrv_config.config.git_commit : ''}, hosted by ${minisrv_config.config.service_owner}</i></small></font></div><br>
data += `
<hr>
<b>Status</b>: ${cryptstatus} (${compstatus})<br>
<b>Connection Speed</b>: &rate;
@@ -45,7 +46,7 @@ data += `
<ul>
<li><a href="client:relog">client:relog (direct)</a></li>
<li><a href="wtv-flashrom:/willie" selected>Ultra Willies</a> ~ <a href="wtv-tricks:/tricks">Tricks</a></li>
<li><a href="wtv-music:/demo/index">MIDI Music Demo</a></li>
<li><a href="wtv-setup:/setup">Setup (Including BG Music)</a></li>
`;
if (ssid_sessions[socket.ssid].hasCap("client-can-do-chat")) {
data += "<li><a href=\"wtv-chat:/home\">IRC Chat Test</a></li>\n"

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.0 KiB

View File

@@ -1,156 +0,0 @@
<html>
<head>
<title>
WebTV Music Index
</title>
<display switchtowebmode transition=none>
</head>
<body bgcolor="#171726" text="#82A9D9" link="#9DEFFF" vlink="#597DAA" alink="#9DEFFF" hspace=0 vspace=0 fontsize="small" logo="midi/webtv.gif" address="WebTV Music Index">
<sidebar width="115" border="0">
<table border=0 cellspacing=0 cellpadding=0>
<tr>
<td width=120 height=75 valign=middle align=center bgcolor="3B3A4D" colspan=3>
<a href="wtv-home:/home">
<img src="hacktv4.gif" border="0">
</a>
<tr>
<td width=5>
<tr>
<td bgcolor=#4A525A height=2 width=104 colspan=3>
<tr>
<td width=10 height=26>
<td width=105 valign=middle>
<table cellspacing=0 cellpadding=0 href="client:showalert?message=%3Cfont%20size%3D%22small%22%3EPlease%20download%20HackTV%20from%3Cbr%3E%3Cbr%3E%3Ccenter%3Ehttp%3A%2F%2Fturdinc.kicks-ass.net%2FMsntv%2F%3C%2Fcenter%3E%3Cbr%3E%3Cbr%3Efor%20the%20complete%20WebTV%20Music%20Experience%21%3C%2Ffont%3E&image=wtv-star:/ROMCache/HackTVLogoJewel.gif&buttonlabel1=Okay&buttonaction1=client:donothing">
<tr>
<td height=1>
<tr>
<td><shadow><strike><font sizerange=medium color=#E6CD4A>Karaoke</font></strike></shadow>
</table>
<tr>
<td width=5>
<tr>
<td bgcolor=#4A525A height=2 width=104 colspan=3>
<tr>
<td width=10 height=26>
<td width=105 valign=middle>
<table cellspacing=0 cellpadding=0 href="client:showalert?message=%3Cfont%20size%3D%22small%22%3EPlease%20download%20HackTV%20from%3Cbr%3E%3Cbr%3E%3Ccenter%3Ehttp%3A%2F%2Fturdinc.kicks-ass.net%2FMsntv%2F%3C%2Fcenter%3E%3Cbr%3E%3Cbr%3Efor%20the%20complete%20WebTV%20Music%20Experience%21%3C%2Ffont%3E&image=wtv-star:/ROMCache/HackTVLogoJewel.gif&buttonlabel1=Okay&buttonaction1=client:donothing">
<tr>
<td height=1>
<tr>
<td><shadow><strike><font sizerange=medium color=#E6CD4A>BG Music</font></strike></shadow>
</table>
<tr>
<td width=5>
<tr>
<td bgcolor=#4A525A height=2 width=104 colspan=3>
<tr>
<td width=10 height=26>
<td width=105 valign=middle>
<table cellspacing=0 cellpadding=0 href="client:showalert?message=%3Cfont%20size%3D%22small%22%3EPlease%20download%20HackTV%20from%3Cbr%3E%3Cbr%3E%3Ccenter%3Ehttp%3A%2F%2Fturdinc.kicks-ass.net%2FMsntv%2F%3C%2Fcenter%3E%3Cbr%3E%3Cbr%3Efor%20the%20complete%20WebTV%20Music%20Experience%21%3C%2Ffont%3E&image=wtv-star:/ROMCache/HackTVLogoJewel.gif&buttonlabel1=Okay&buttonaction1=client:donothing">
<tr>
<td height=1>
<tr>
<td><shadow><strike><font sizerange=medium color=#E6CD4A>Orig Classic</font></strike></shadow>
</table>
<tr>
<td width=5>
<tr>
<td bgcolor=#4A525A height=2 width=104 colspan=3>
<tr>
<td width=10 height=26>
<td width=105 valign=middle>
<table cellspacing=0 cellpadding=0 href="wtv-music:/demo/midi/index">
<tr>
<td height=1>
<tr>
<td><shadow><font sizerange=medium color=#E6CD4A>Midi</font></shadow>
</table>
<tr>
<td width=5>
<tr>
<td bgcolor=#4A525A height=2 width=104 colspan=3>
<tr>
<td width=10 height=26>
<td width=105 valign=middle>
<table cellspacing=0 cellpadding=0 href="client:showalert?message=%3Cfont%20size%3D%22small%22%3EPlease%20download%20HackTV%20from%3Cbr%3E%3Cbr%3E%3Ccenter%3Ehttp%3A%2F%2Fturdinc.kicks-ass.net%2FMsntv%2F%3C%2Fcenter%3E%3Cbr%3E%3Cbr%3Efor%20the%20complete%20WebTV%20Music%20Experience%21%3C%2Ffont%3E&image=wtv-star:/ROMCache/HackTVLogoJewel.gif&buttonlabel1=Okay&buttonaction1=client:donothing">
<tr>
<td height=1>
<tr>
<td><shadow><strike><font sizerange=medium color=#E6CD4A>RMF</font></strike></shadow>
</table>
<tr>
<td width=5>
<tr>
<td bgcolor=#4A525A height=2 width=104 colspan=3>
<tr>
<td width=10 height=26>
<td width=105 valign=middle>
<table cellspacing=0 cellpadding=0 href="client:showalert?message=%3Cfont%20size%3D%22small%22%3EPlease%20download%20HackTV%20from%3Cbr%3E%3Cbr%3E%3Ccenter%3Ehttp%3A%2F%2Fturdinc.kicks-ass.net%2FMsntv%2F%3C%2Fcenter%3E%3Cbr%3E%3Cbr%3Efor%20the%20complete%20WebTV%20Music%20Experience%21%3C%2Ffont%3E&image=wtv-star:/ROMCache/HackTVLogoJewel.gif&buttonlabel1=Okay&buttonaction1=client:donothing">
<tr>
<td height=1>
<tr>
<td><shadow><strike><font sizerange=medium color=#E6CD4A>Mod</font></strike></shadow>
</table>
<tr>
<td width=5>
<tr>
<td bgcolor=#4A525A height=2 width=104 colspan=3>
</td>
</tr>
</table>
</sidebar>
<table cellspacing=0 cellpadding=0 border=0>
<tr>
<td width=444 height=75 valign=middle align=left bgcolor="3B3A4D" colspan="2">
<font color="D6DFD0" size="+3">
<blackface>
<shadow>
<br>
&nbsp; WebTV Music Index
</shadow>
</blackface>
</font>
</td>
</tr>
<tr>
<td height=2 bgcolor=#4A525A colspan="2"></td>
</tr>
<tr>
<td width=2 bgcolor=#4A525A></td>
<td width=442 valign=top align=left>
<table cellpadding="3">
<tr>
<td>
<table cellspacing=0 cellpadding=0>
<tr>
<td align=center absheight=80>
<font size="+2" color="E7CE4A"><blackface><shadow>
&nbsp;&nbsp;&nbsp&nbsp;&nbsp;&nbsp&nbsp;&nbsp;&nbsp&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Select your poison!
<tr>
<td height=4>
</table>
<tr>
<td align=center width=480>
<img src="music.jpg"width="260" height="193"border="2" name="r1" alt="wtv" />
</font>
</td>
</tr>
</table>
</body>
</html>

Some files were not shown because too many files have changed in this diff Show More